<Page xmlns:local="clr-namespace:ForzaUI;assembly="
      xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
      xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
      xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
      xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
      xmlns:System="clr-namespace:System;assembly=mscorlib"
      x:Class="ForzaUI.A_ViewAuction"
      mc:Ignorable="d"
      Style="{StaticResource A_Style_Page_Generic}"
      DataContext="{Binding RelativeSource={RelativeSource Self}}">

    <Page.Resources>
        <ResourceDictionary>

            <Style x:Key="A_Style_ContentControl_BidBox_Bid"
                   TargetType="ContentControl"
                   BasedOn="{StaticResource A_Style_ContentControl_BidBox_HighestBid}">
                <Style.Resources>
                    <TextAlignment x:Key="A_TextAlignment_BidBox_Title">Left</TextAlignment>
                </Style.Resources>
            </Style>

            <Style x:Key="A_Style_ContentControl_BidBox_Buyout"
                   TargetType="ContentControl">
                <Style.Resources>
                    <TextAlignment x:Key="A_TextAlignment_BidBox_Title">Left</TextAlignment>
                </Style.Resources>
                <Setter Property="Template"
                        Value="{StaticResource A_Template_ContentControl_BidBox}" />
                <Setter Property="Tag"
                        Value="{Binding Source={local:Loc AuctionHouse.IDS_AuctionHouseDetails_Buyout}, Converter={StaticResource A_StringToUpper}}" />
            </Style>

            <Style x:Key="A_Style_FZTextBlock_BidBox_Value"
                   TargetType="{x:Type local:FZTextBlock}"
                   BasedOn="{StaticResource A_Style_FZTextBlock_Auction_CanExpire}">
                <Setter Property="Text" Value="{Binding Tag, RelativeSource={RelativeSource AncestorType=ContentControl}}" />
                <Setter Property="CapHeight" Value="26" />
                <Setter Property="FontFamily" Value="Horizon_A" />
                <Setter Property="TextAlignment" Value="Left" />
                <Setter Property="VerticalAlignment" Value="Center" />
            </Style>

            <Style x:Key="A_Style_Border_ScenePadding_ViewAuction"
                TargetType="Border"
                BasedOn="{StaticResource A_Style_Border_ScenePadding_Opus}">
                <!-- <Style.Triggers>
                    <DataTrigger Binding="{Binding Collection.Count}" Value="3"> -->
                        <Setter Property="Padding" Value="71,143,71,152"/>
                    <!-- </DataTrigger>
                </Style.Triggers> -->
            </Style>
                        
            <Style x:Key="A_Style_FZMaterial_AuctionOption_Icon"
                TargetType="local:FZMaterial">
                <Setter Property="Visibility" Value="Hidden" />
                <Setter Property="Color" Value="{StaticResource H_Color_Primary_Black}" />
                <Style.Triggers>
                    <DataTrigger
                        Binding="{Binding IsKeyboardFocusWithin, RelativeSource={RelativeSource FindAncestor, AncestorType=ListBoxItem}}"
                        Value="True">
                        <Setter
                            Property="Color"
                            Value="{StaticResource H_Color_Primary_White}" />
                    </DataTrigger>
                    <DataTrigger Binding="{Binding Option}" Value="{x:Static local:AuctionOption.Back}">
                        <Setter Property="ImageSource" Value="/ForzaUI;component/Textures/Anthem/Icons/Auction/Back_Icon.png"/>
                        <Setter Property="Visibility" Value="Visible" />
                    </DataTrigger>
                    <DataTrigger Binding="{Binding Option}" Value="{x:Static local:AuctionOption.Bid}">
                        <Setter Property="ImageSource" Value="/ForzaUI;component/Textures/Anthem/Icons/Auction/Highest_Bid.png"/>
                        <Setter Property="Visibility" Value="Visible" />
                    </DataTrigger>
                    <DataTrigger Binding="{Binding Option}" Value="{x:Static local:AuctionOption.Buyout}">
                        <Setter Property="ImageSource" Value="/ForzaUI;component/Textures/Anthem/Icons/Auction/Buy_Out_Icon.png"/>
                        <Setter Property="Visibility" Value="Visible" />
                    </DataTrigger>
                    <DataTrigger Binding="{Binding Option}" Value="{x:Static local:AuctionOption.ClaimCar}">
                        <Setter Property="ImageSource" Value="/ForzaUI;component/Textures/Anthem/Icons/Auction/Collect_Car_Icon.png"/>
                        <Setter Property="Visibility" Value="Visible" />
                    </DataTrigger>
                    <DataTrigger Binding="{Binding Option}" Value="{x:Static local:AuctionOption.ReclaimCar}">
                        <Setter Property="ImageSource" Value="/ForzaUI;component/Textures/Anthem/Icons/Auction/Reclaim_Icon.png"/>
                        <Setter Property="Visibility" Value="Visible" />
                    </DataTrigger>
                    <DataTrigger Binding="{Binding Option}" Value="{x:Static local:AuctionOption.ClaimCredits}">
                        <Setter Property="ImageSource" Value="/ForzaUI;component/Textures/Anthem/Icons/Auction/Collect_Credits_Icon.png"/>
                        <Setter Property="Visibility" Value="Visible" />
                    </DataTrigger>
                    <DataTrigger Binding="{Binding Option}" Value="{x:Static local:AuctionOption.ReclaimCredits}">
                        <Setter Property="ImageSource" Value="/ForzaUI;component/Textures/Anthem/Icons/Auction/Collect_Credits_Icon.png"/>
                        <Setter Property="Visibility" Value="Visible" />
                    </DataTrigger>
                    <DataTrigger Binding="{Binding Option}" Value="{x:Static local:AuctionOption.GiftCar}">
                        <Setter Property="ImageSource" Value="/ForzaUI;component/Textures/Anthem/Icons/Auction/Gift_Car_Icon.png"/>
                        <Setter Property="Visibility" Value="Visible" />
                    </DataTrigger>
                    <DataTrigger Binding="{Binding Option}" Value="{x:Static local:AuctionOption.RemoveBanned}">
                        <Setter Property="ImageSource" Value="/ForzaUI;component/Textures/Anthem/Icons/Auction/Delete_Icon.png"/>
                        <Setter Property="Visibility" Value="Visible" />
                    </DataTrigger>
                </Style.Triggers>
            </Style>

            <Style x:Key="A_Style_Control_AuctionOption_SubIcon"
                TargetType="Control" BasedOn="{StaticResource H_Style_Control_CreditsIcon}">
                <Setter Property="Visibility" Value="Hidden" />
                <Style.Triggers>
                    <DataTrigger Binding="{Binding Option}" Value="{x:Static local:AuctionOption.Buyout}">
                        <Setter Property="Visibility" Value="Visible" />
                    </DataTrigger>
                    <DataTrigger Binding="{Binding Option}" Value="{x:Static local:AuctionOption.Bid}">
                        <Setter Property="Visibility" Value="Visible" />
                    </DataTrigger>
                </Style.Triggers>
            </Style>

            <DataTemplate x:Key="A_DataTemplate_TextMenu_ViewAuctionDetails">
                <DataTemplate.Resources>
                    <Style x:Key="A_Style_FZTextBlock_OptionText_ViewAuctionOption"
                           TargetType="local:FZTextBlock"
                           BasedOn="{StaticResource A_Style_FZTextBlock_OptionText}">
                        <Setter Property="FontFamily"
                                Value="Horizon_B" />
                        <Setter Property="HorizontalAlignment"
                                Value="Left" /> 
                        <Setter Property="VerticalAlignment"
                                Value="Center" />
                    </Style>
                </DataTemplate.Resources>
                <Grid IsHitTestVisible="False"
                      Margin="20,7,17,7">
                    <StackPanel HorizontalAlignment="Left"
                                Orientation="Horizontal">
                        <local:FZMaterial Width="45"
                                          Height="45"
                                          VerticalAlignment="Center"
                                          Style="{StaticResource A_Style_FZMaterial_AuctionOption_Icon}"
                                          HorizontalAlignment="Left"/>
                        <local:FZTextBlock x:Name="MainText"
                                           Text="{Binding Text}"
                                           Style="{StaticResource A_Style_FZTextBlock_OptionText_ViewAuctionOption}"
                                           CapHeight="21"
                                           Margin="11,0,0,0"
                                           HorizontalAlignment="Left"/>
                    </StackPanel>
                    <StackPanel HorizontalAlignment="Right"
                                Orientation="Horizontal">
                        <Control x:Name="SubIcon"
                                    Width="30"
                                    Height="30"
                                    VerticalAlignment="Center"
                                    Style="{StaticResource A_Style_Control_AuctionOption_SubIcon}"
                                    HorizontalAlignment="Right"/> 
                        <FZTextBlock x:Name="OptionText"
                                     Text="{Binding Subtext}"
                                     Style="{StaticResource A_Style_FZTextBlock_OptionText_ViewAuctionOption}"
                                     FontFamily="Horizon_A"
                                     CapHeight="25"
                                     Margin="11,0,0,0"
                                     VerticalAlignment="Center"/>
                        <FZMaterial x:Name="Arrow"
                                    Visibility="Collapsed"
                                    Style="{StaticResource A_Style_FZMaterial_BuyoutPriceHigh_Arrow}"/> 
                    </StackPanel>
                </Grid>
                <DataTemplate.Triggers>
                    <MultiDataTrigger>
                        <MultiDataTrigger.Conditions>
                            <Condition Binding="{Binding Option}" Value="{x:Static local:AuctionOption.Buyout}"/>
                            <Condition Binding="{Binding Auction.IsBuyoutAboveCarPrice, RelativeSource={RelativeSource AncestorType=Page}}" Value="True"/>
                        </MultiDataTrigger.Conditions>
                        <Setter TargetName="Arrow" Property="Visibility" Value="Visible"/>
                        <Setter TargetName="OptionText" Property="Color" Value="{StaticResource A_Color_AuctionHouse_HighPrice}"/>
                    </MultiDataTrigger>
                </DataTemplate.Triggers>
            </DataTemplate>

            <ControlTemplate TargetType="Control" 
                             x:Key="A_Template_Control_Upgrades_Bars">
                <StackPanel Orientation="Vertical" 
                            x:Name="root"
                            local:BindingProxy.A="{Binding (local:BindingProxy.A), RelativeSource={RelativeSource TemplatedParent}}"
                            local:BindingProxy.B="{Binding (local:BindingProxy.B), RelativeSource={RelativeSource TemplatedParent}}"
                            Margin="0">
                    <FZMaterial Height="50"
                                Margin="0,0,0,4"
                                VerticalAlignment="Center"
                                HorizontalAlignment="Stretch"
                                Style="{StaticResource H_Style_Container_GlassMediumBlur_Description}" >
                        <Grid Margin="23,0,26,0">
                            <local:FZTextBlock Text="{Binding Tag, RelativeSource={RelativeSource TemplatedParent}}"
                                               CapHeight="18"
                                               Color="{StaticResource H_Color_Primary_White}"
                                               FontFamily="Horizon_B"
                                               VerticalAlignment="Center"
                                               HorizontalAlignment="Left"/>
                            <local:FZTextBlock Text="{Binding Path=(local:BindingProxy.B), ElementName=root, Converter={StaticResource A_NumUnitConverter_NoUnit_1dp}}"
                                               TextAlignment="Right"
                                               CapHeight="18"
                                               FontFamily="Horizon_A"
                                               Color="{StaticResource H_Color_Primary_White}"
                                               x:Name="ValueText"
                                               VerticalAlignment="Center"
                                               HorizontalAlignment="Right"/>
                        </Grid>
                    </FZMaterial>
                </StackPanel>
                <ControlTemplate.Triggers>
                    <Trigger Property="local:BindingProxy.A"
                         Value="{x:Null}">
                        <Setter TargetName="root" Property="local:BindingProxy.A">
                            <Setter.Value>
                                <System:Double>0</System:Double>
                            </Setter.Value>
                        </Setter>
                        <Setter TargetName="root" Property="local:BindingProxy.B">
                            <Setter.Value>
                                <System:Double>0</System:Double>
                            </Setter.Value>
                        </Setter>
                    </Trigger>
                    <Trigger Property="local:BindingProxy.B"
                         Value="{x:Null}">
                        <Setter TargetName="root" Property="local:BindingProxy.A"
                        Value="{Binding Path=(local:BindingProxy.B), ElementName=root}" />
                    </Trigger>
                </ControlTemplate.Triggers>
            </ControlTemplate>

            <ControlTemplate TargetType="Control" 
                             x:Key="A_Template_Control_Upgrades_Stats">
                <StackPanel Orientation="Vertical"
                            x:Name="root"
                            local:BindingProxy.A="{Binding (local:BindingProxy.A), RelativeSource={RelativeSource TemplatedParent}}"
                            local:BindingProxy.B="{Binding (local:BindingProxy.B), RelativeSource={RelativeSource TemplatedParent}}"
                            Margin="0">
                    <FZMaterial Height="50"
                                Margin="0,0,0,4"
                                VerticalAlignment="Center"
                                HorizontalAlignment="Stretch"
                                Style="{StaticResource H_Style_Container_GlassMediumBlur_Description}" >
                                <Grid Margin="23,0,26,0">
                                    <local:FZTextBlock Text="{Binding Path=(local:BindingProxy.A), ElementName=root}"
                                                       CapHeight="18"
                                                       Color="{StaticResource H_Color_Primary_White}"
                                                       FontFamily="Horizon_B"
                                                       VerticalAlignment="Center"
                                                       HorizontalAlignment="Left"/>
                                    <local:FZTextBlock Text="{Binding Path=(local:BindingProxy.B), ElementName=root}"
                                                       Style="{StaticResource A_Style_TextBlock_PerformanceStatsDeltaText_Garage}"
                                                       Tag="{Binding Tag, RelativeSource={RelativeSource TemplatedParent}}"
                                                       TextAlignment="Right"
                                                       FontFamily="Horizon_A"
                                                       CapHeight="18"
                                                       Color="{StaticResource H_Color_Primary_White}"
                                                       x:Name="ValueText"
                                                       VerticalAlignment="Center"
                                                       HorizontalAlignment="Right"/>
                                </Grid>
                    </FZMaterial>
                </StackPanel>
            </ControlTemplate>

            <ControlTemplate TargetType="Control" 
                             x:Key="A_Template_Control_Upgrades_Stats_Drivetrain">
                <StackPanel Orientation="Vertical"
                            x:Name="root"
                            local:BindingProxy.A="{Binding (local:BindingProxy.A), RelativeSource={RelativeSource TemplatedParent}}"
                            Margin="0">
                    <FZMaterial Height="50"
                                Margin="0,0,0,4"
                                VerticalAlignment="Center"
                                HorizontalAlignment="Stretch"
                                Style="{StaticResource H_Style_Container_GlassMediumBlur_Description}" >
                                <Grid Margin="23,0,26,0">
                                    <local:FZTextBlock Text="{Binding Path=(local:BindingProxy.A), ElementName=root}"
                                                       CapHeight="18"
                                                       Color="{StaticResource H_Color_Primary_White}"
                                                       FontFamily="Horizon_B"
                                                       VerticalAlignment="Center"
                                                       HorizontalAlignment="Left"/>
                                    <Control Style="{StaticResource A_Style_Control_DriveTrainDisplay}"
                                             VerticalAlignment="Center"
                                             Height="34"
                                             HorizontalAlignment="Right"/>
                                </Grid>
                    </FZMaterial>
                </StackPanel>
            </ControlTemplate>

            <Style
                x:Key="H_Style_ListBoxItem_TextMenu_ViewAuction"
                BasedOn="{StaticResource A_Style_ListBoxItem_TextMenu}"
                TargetType="{Type ListBoxItem}">
                <Setter Property="Template">
                    <Setter.Value>
                        <ControlTemplate TargetType="ListBoxItem">
                            <ControlTemplate.Resources>
                                <ResourceDictionary>
                                    <Style
                                        x:Key="A_Style_RoutedEventCommand_MouseLeftButtonUp"
                                        TargetType="local:RoutedEventCommand">
                                        <Setter
                                            Property="Command"
                                            Value="{Binding ItemFuncCommand}" />
                                        <Style.Triggers>
                                            <DataTrigger
                                                Binding="{Binding ItemFuncCommand}"
                                                Value="{Null}">
                                                <Setter
                                                    Property="Command"
                                                    Value="{Binding SelectCommand, RelativeSource={RelativeSource AncestorType={Type Page}}}" />
                                            </DataTrigger>
                                        </Style.Triggers>
                                    </Style>
                                </ResourceDictionary>
                            </ControlTemplate.Resources>
                            <Grid x:Name="OuterContainer">
                                <local:FZMaterial
                                    x:Name="DropShadow"
                                    Style="{StaticResource H_Style_FZMaterial_ShadowBase_ForSubgraph}">
                                    <local:FZMaterial.RenderTransform>
                                        <TransformGroup>
                                            <ScaleTransform
                                            ScaleX="0"
                                            ScaleY="0"
                                            x:Name="ShadowScale" />
                                        </TransformGroup>
                                    </local:FZMaterial.RenderTransform>
                                </local:FZMaterial>
                                <Grid
                                    x:Name="Background"
                                    RenderTransformOrigin="0.5,0.5">
                                    <Grid.RenderTransform>
                                        <TransformGroup>
                                            <ScaleTransform />
                                            <SkewTransform />
                                            <RotateTransform />
                                            <TranslateTransform />
                                        </TransformGroup>
                                    </Grid.RenderTransform>
                                    <RoutedEventCommand
                                        x:Name="MouseLeftButtonUpCommand"
                                        RoutedEvent="UIElement.MouseLeftButtonUp"
                                        Style="{StaticResource A_Style_RoutedEventCommand_MouseLeftButtonUp}" />
                                    <StrokeHighlightControl
                                        x:Name="FocusHighlight"
                                        Style="{StaticResource H_Style_StrokeHighlight_Animated}"
                                        IsEnabled="{Binding (Selector.IsSelected), FallbackValue=False, RelativeSource={RelativeSource TemplatedParent}}" />
                                    <FZMaterial
                                        x:Name="BackgroundMaterial"
                                        RoutedEventCommand.Action="{Binding ElementName=MouseLeftButtonUpCommand}"
                                        Style="{StaticResource A_Style_FZMaterial_FlatPanel_Tile}"
                                        Preset="{StaticResource H_Roundtangle_Outer_1px}"
                                        Color="{StaticResource H_Color_Primary_White}">
                                        <ContentPresenter
                                            Focusable="{Binding Focusable, Mode=OneWay, RelativeSource={RelativeSource TemplatedParent}}"
                                            x:Name="Presenter"
                                            PropertySetter.Value="{Binding IsKeyboardFocused, RelativeSource={RelativeSource Self}}"
                                            PropertySetter.Property="Content.(FocusSelf.WhenTrue)"/>
                                    </FZMaterial>
                                </Grid>
                            </Grid>
                            <ControlTemplate.Triggers>
                                <Trigger
                                    Property="IsKeyboardFocused"
                                    Value="True">
                                    <Setter
                                        TargetName="Presenter"
                                        Property="FocusSelf.WhenTrue"
                                        Value="True" />
                                </Trigger>
                                <Trigger
                                    Property="Tag"
                                    Value="GroupHeader">
                                    <Setter
                                        Property="Visibility"
                                        TargetName="BackgroundMaterial"
                                        Value="Collapsed" />
                                </Trigger>
                                <Trigger
                                    Property="Tag"
                                    Value="Inactive">
                                    <Setter
                                        TargetName="BackgroundMaterial"
                                        Property="Preset"
                                        Value="{StaticResource H_GlassRoundtangle_1px}" />
                                    <Setter
                                        TargetName="BackgroundMaterial"
                                        Property="Color"
                                        Value="{StaticResource H_Color_Glass_Purple_20pc}" />
                                </Trigger>
                                <Trigger
                                    Property="IsEnabled"
                                    Value="False">
                                    <Setter
                                        TargetName="BackgroundMaterial"
                                        Property="Opacity"
                                        Value="0.3" />
                                </Trigger>
                                <MultiDataTrigger>
                                    <MultiDataTrigger.Conditions>
                                        <Condition
                                            Binding="{Binding IsKeyboardFocusWithin, RelativeSource={RelativeSource Self}}"
                                            Value="True" />
                                        <Condition
                                            Binding="{Binding (ItemContainerGenerator.ItemForItemContainer), RelativeSource={RelativeSource Self}, Converter={StaticResource A_Converter_IsNotNull}}"
                                            Value="True" />
                                    </MultiDataTrigger.Conditions>
                                    <Setter
                                        Property="IsSelected"
                                        Value="True" />
                                </MultiDataTrigger>
                                <MultiDataTrigger>
                                    <MultiDataTrigger.Conditions>
                                        <Condition
                                            Binding="{Binding Focusable, RelativeSource={RelativeSource Self}}"
                                            Value="False" />
                                        <Condition
                                            Binding="{Binding Tag, RelativeSource={RelativeSource Self}}"
                                            Value="{Null}" />
                                    </MultiDataTrigger.Conditions>
                                    <Setter
                                        TargetName="BackgroundMaterial"
                                        Property="Visibility"
                                        Value="Collapsed" />
                                </MultiDataTrigger>
                            </ControlTemplate.Triggers>
                        </ControlTemplate>
                    </Setter.Value>
                </Setter>
                <Setter
                    Property="local:FocusOnMouseOverBehaviour.Self"
                    Value="True" />
                <Setter
                    Property="Margin"
                    Value="0,2,0,2" />
            </Style>

            <Style x:Key="A_Style_Control_ViewAuction_Seller"
                   TargetType="Control">
                <Style.Resources>
                    <Style x:Key="A_Style_ProgressBar_WaitSpinner_Dynamic"
                        TargetType="{x:Type ProgressBar}"
                        BasedOn="{StaticResource A_Style_ProgressBar_WaitSpinner}"/>
                </Style.Resources>
                <Setter Property="Template" Value="{DynamicResource A_Template_Control_ViewAuction_Seller}"/>
            </Style>

            <ControlTemplate TargetType="Control"
                             x:Key="A_Template_Control_ViewAuction_Seller">
                <StackPanel Height="85" Orientation="Horizontal">
                    <Grid Width="85">
                        <local:FZMaterial x:Name="SellerGamerPicMaterial"
                                          Style="{StaticResource A_Style_FZMaterial_Auction_Seller}"
                                          Height="85"
                                          Preset="{StaticResource A_FZMaterialPresetRoundtangle_FlatPanel_InnerInnerAll}"
                                          Stretch="Uniform"
                                          Tag="{Binding Path=(local:BindingProxy.B), RelativeSource={RelativeSource TemplatedParent}}"
                                          Visibility="{Binding Downloaded, RelativeSource={RelativeSource Self}, Converter={StaticResource A_FZBooleanToVisibilityConverter_UseHidden}}" />
                        <ProgressBar Style="{DynamicResource A_Style_ProgressBar_WaitSpinner_Dynamic}"
                                     HorizontalAlignment="Center"
                                     VerticalAlignment="Center"
                                     Visibility="{Binding Downloaded, ElementName=SellerGamerPicMaterial, Converter={StaticResource A_FZBooleanToVisibilityConverter_Inverse}}"/>
                    </Grid>

                    <StackPanel Orientation="Vertical" Margin="10,10,0,3">
                        <local:FZTextBlock Text="{local:Loc AuctionHouse.IDS_Seller}"
                                           x:Name="SellerTitle"
                                           HorizontalAlignment="Left"
                                           StretchDirection="Both"
                                           Stretch="Uniform"
                                           CapHeight="20"
                                           TextAlignment="Left"
                                           FontFamily="Horizon_B"
                                           Color="{StaticResource H_Color_Primary_Grey_70pc}"/>
                        <Decorator Height="25"/>
                        <local:FZTextBlock Text="{Binding Seller.FormattedGamertag}"
                                           x:Name="SellerName"
                                           HorizontalAlignment="Left"
                                           VerticalAlignment="Bottom"
                                           FontFamily="Horizon_A"
                                           CapHeight="22"
                                           Stretch="Uniform"
                                           Color="{TemplateBinding local:BindingProxy.A}"/>
                    </StackPanel>
                </StackPanel>
            </ControlTemplate>

            <Style x:Key="A_Style_Control_ViewAuction_HighestBidder"
                   TargetType="Control">
                <Style.Resources>
                    <Style x:Key="A_Style_ProgressBar_WaitSpinner_Dynamic"
                        TargetType="{x:Type ProgressBar}"
                        BasedOn="{StaticResource A_Style_ProgressBar_WaitSpinner}"/>
                </Style.Resources>
                <Setter Property="Template" Value="{DynamicResource A_Template_Control_ViewAuction_HighestBidder}"/>
            </Style>

            <ControlTemplate TargetType="Control"
                             x:Key="A_Template_Control_ViewAuction_HighestBidder">
                <StackPanel Height="85" Orientation="Horizontal">
                    <Grid Width="85">
                        <local:FZMaterial x:Name="GamerPicMaterial"
                                          Style="{StaticResource A_Style_FZMaterial_Auction_HighestBidder}"
                                          Height="85"
                                          Preset="{StaticResource A_FZMaterialPresetRoundtangle_FlatPanel_InnerInnerAll}"
                                          Stretch="Uniform"
                                          Tag="{Binding Path=(local:BindingProxy.B), RelativeSource={RelativeSource TemplatedParent}}"
                                          Visibility="{Binding Downloaded, RelativeSource={RelativeSource Self}, Converter={StaticResource A_FZBooleanToVisibilityConverter_UseHidden}}" />
                        <ProgressBar Style="{DynamicResource A_Style_ProgressBar_WaitSpinner_Dynamic}"
                                     HorizontalAlignment="Center"
                                     VerticalAlignment="Center"
                                     Visibility="{Binding Downloaded, ElementName=GamerPicMaterial, Converter={StaticResource A_FZBooleanToVisibilityConverter_Inverse}}"/>
                    </Grid>

                    <StackPanel Orientation="Vertical" Margin="10,10,0,3">
                        <local:FZTextBlock Style="{StaticResource A_Style_FZTextBlock_Auction_HighestBidder_Title}"
                                           x:Name="HighestBidderTitle"
                                           HorizontalAlignment="Left"
                                           StretchDirection="Both"
                                           Stretch="Uniform"
                                           CapHeight="20"
                                           TextAlignment="Left"
                                           FontFamily="Horizon_B"
                                           Color="{StaticResource H_Color_Primary_Grey_70pc}"
                                           TrackingAdjust="0.03"/>
                        <Decorator Height="25"/>

                        <local:FZTextBlock Style="{StaticResource A_Style_FZTextBlock_Auction_HighestBidder}"
                                           x:Name="HighestBidderName"
                                           HorizontalAlignment="Left"
                                           VerticalAlignment="Bottom"
                                           FontFamily="Horizon_A"
                                           CapHeight="22"
                                           TrackingAdjust="0.03"
                                           Stretch="Uniform"
                                           Color="{TemplateBinding local:BindingProxy.A}"/>
                    </StackPanel>
                </StackPanel>
            </ControlTemplate>

        </ResourceDictionary>
    </Page.Resources>
    <VisualStateManager.VisualStateGroups>
        <VisualStateGroup>
            <VisualState Name="PART_Bars">
                <VisualState.Storyboard>
                    <Storyboard>
                        <ObjectAnimationUsingKeyFrames Storyboard.TargetName="Bars"
                                                       Storyboard.TargetProperty="(UIElement.Visibility)">
                            <DiscreteObjectKeyFrame KeyTime="0:0:0"
                                                    Value="{x:Static Visibility.Visible}" />
                        </ObjectAnimationUsingKeyFrames>
                        <ObjectAnimationUsingKeyFrames Storyboard.TargetName="CarClassControl"
                                                       Storyboard.TargetProperty="(UIElement.Visibility)">
                            <DiscreteObjectKeyFrame KeyTime="0:0:0"
                                                    Value="{x:Static Visibility.Visible}" />
                        </ObjectAnimationUsingKeyFrames>
                        <ObjectAnimationUsingKeyFrames Storyboard.TargetName="CategoryLabel"
                                                       Storyboard.TargetProperty="(FZTextBlock.Text)">
                            <DiscreteObjectKeyFrame KeyTime="0:0:0"
                                                    Value="{Convert {Loc AuctionHouse.IDS_CarPerformance}, Converter={StringToUpper}}" />
                        </ObjectAnimationUsingKeyFrames>
                    </Storyboard>
                </VisualState.Storyboard>
            </VisualState>
            <VisualState Name="PART_Stats">
                <VisualState.Storyboard>
                    <Storyboard>
                        <ObjectAnimationUsingKeyFrames Storyboard.TargetName="Stats"
                                                       Storyboard.TargetProperty="(UIElement.Visibility)">
                            <DiscreteObjectKeyFrame KeyTime="0:0:0"
                                                    Value="{x:Static Visibility.Visible}" />
                        </ObjectAnimationUsingKeyFrames>
                        <ObjectAnimationUsingKeyFrames Storyboard.TargetName="CarClassControl"
                                                       Storyboard.TargetProperty="(UIElement.Visibility)">
                            <DiscreteObjectKeyFrame KeyTime="0:0:0"
                                                    Value="{x:Static Visibility.Visible}" />
                        </ObjectAnimationUsingKeyFrames>
                        <ObjectAnimationUsingKeyFrames Storyboard.TargetName="CategoryLabel"
                                                       Storyboard.TargetProperty="(FZTextBlock.Text)">
                            <DiscreteObjectKeyFrame KeyTime="0:0:0"
                                                    Value="{Convert {Loc AuctionHouse.IDS_CarDetails}, Converter={StringToUpper}}" />
                        </ObjectAnimationUsingKeyFrames>
                    </Storyboard>
                </VisualState.Storyboard>
            </VisualState>
            <VisualState Name="PART_Collaborators">
                <VisualState.Storyboard>
                    <Storyboard>
                        <ObjectAnimationUsingKeyFrames Storyboard.TargetName="Collaborators"
                                                       Storyboard.TargetProperty="(UIElement.Visibility)">
                            <DiscreteObjectKeyFrame KeyTime="0:0:0"
                                                    Value="{x:Static Visibility.Visible}" />
                        </ObjectAnimationUsingKeyFrames>
                        <ObjectAnimationUsingKeyFrames Storyboard.TargetName="CarInfoContainer"
                                                       Storyboard.TargetProperty="(UIElement.Visibility)">
                            <DiscreteObjectKeyFrame KeyTime="0:0:0"
                                                    Value="{x:Static Visibility.Collapsed}" />
                        </ObjectAnimationUsingKeyFrames>
                        <ObjectAnimationUsingKeyFrames Storyboard.TargetName="CategoryLabel"
                                                       Storyboard.TargetProperty="(FZTextBlock.Text)">
                            <DiscreteObjectKeyFrame KeyTime="0:0:0"
                                                    Value="{Convert {Loc AuctionHouse.IDS_Contributors}, Converter={StringToUpper}}" />
                        </ObjectAnimationUsingKeyFrames>
                    </Storyboard>
                </VisualState.Storyboard>
            </VisualState>
            <VisualState Name="PART_Bids">
                <VisualState.Storyboard>
                    <Storyboard>
                        <ObjectAnimationUsingKeyFrames Storyboard.TargetName="Bids"
                                                       Storyboard.TargetProperty="(UIElement.Visibility)">
                            <DiscreteObjectKeyFrame KeyTime="0:0:0"
                                                    Value="{x:Static Visibility.Visible}" />
                        </ObjectAnimationUsingKeyFrames>
                        <ObjectAnimationUsingKeyFrames Storyboard.TargetName="CarInfoContainer"
                                                       Storyboard.TargetProperty="(UIElement.Visibility)">
                            <DiscreteObjectKeyFrame KeyTime="0:0:0"
                                                    Value="{x:Static Visibility.Collapsed}" />
                        </ObjectAnimationUsingKeyFrames>
                        <ObjectAnimationUsingKeyFrames Storyboard.TargetName="CategoryLabel"
                                                       Storyboard.TargetProperty="(FZTextBlock.Text)">
                            <DiscreteObjectKeyFrame KeyTime="0:0:0"
                                                    Value="{Convert {Loc AuctionHouse.IDS_BiddingDetails}, Converter={StringToUpper}}" />
                        </ObjectAnimationUsingKeyFrames>
                    </Storyboard>
                </VisualState.Storyboard>
            </VisualState>
        </VisualStateGroup>
    </VisualStateManager.VisualStateGroups>
    <local:UIPageTransitionManager.TransitionManager>
        <local:UIPageTransitionManager Preset="{StaticResource A_UIPageTransitionManagerPreset_Menu}" />
    </local:UIPageTransitionManager.TransitionManager>

    <Grid>
        <Grid Style="{StaticResource A_Style_FrameworkElement_FadeOnlyTransition}">
            <local:PlayerBarControl Style="{StaticResource A_Style_PlayerBarControl}"
                                    x:Name="PART_TopBar" />
        </Grid>

        <local:RoutedEventCommand x:Name="ToggleStatsRoutedEventCommand"
                                  RoutedEvent="UIElement.MouseLeftButtonUp"
                                  Command="{Binding ToggleStatsCommand, RelativeSource={RelativeSource AncestorType=Page}}" />

        <ContentControl x:Name="BottomBar"
                        Style="{StaticResource A_Style_ButtonBar}">
            <local:ControllerButtonPanel x:Name="PART_HelpPanel"
                                         Style="{StaticResource A_Style_ControllerButtonPanel_Default}">
                <local:ControllerButtonControl Button="A"
                                               Description="{local:Loc HelpButtons.IDS_Select}" />
                <local:ControllerButtonControl Button="B"
                                               Description="{local:Loc HelpButtons.IDS_Back}" />
                <local:ControllerButtonControl Button="X"
                                               Description="{local:Loc HelpButtons.IDS_ChangeCamera}" />
                <local:ControllerButtonControl Button="DPadHorizontal"
                                               Description="{local:Loc HelpButtons.IDS_Toggle}"
                                               Visibility="{Binding IsControllerActiveInput, Converter={StaticResource A_FZBooleanToVisibilityConverter}}"/>
                <local:ControllerButtonControl Description="{local:Loc HelpButtons.IDS_Toggle}"
                                               local:RoutedEventCommand.Action="{Binding ElementName=ToggleStatsRoutedEventCommand}"
                                               Visibility="{Binding IsControllerActiveInput, Converter={StaticResource A_FZBooleanToVisibilityConverter_Inverse}}" 
                                               InputOverride="{local:Input Command=INPUTCMD_UI_DPAD_RIGHT_PRESS, Context=INPUTCONTEXT_UI}"/>
            </local:ControllerButtonPanel>
        </ContentControl>

        <Border Style="{StaticResource A_Style_Border_ScenePadding_ViewAuction}">
            <StackPanel Orientation="Vertical"
                        Width="438"
                        HorizontalAlignment="Left"
                        Style="{StaticResource A_Style_FrameworkElement_DefaultTransition_0}">
                <!-- Title -->
                <ContentControl Content="{local:Loc AuctionHouse.IDS_AuctionDetails}"
                                Style="{StaticResource A_Style_ContentControl_ScreenTitleBlock}"
                                local:BindingProxy.A="/ForzaUI;component/Textures/Anthem/Icons/Titles/AuctionHouse.png"
                                Margin="0,0,0,8" />
                <local:FZMaterial Style="{StaticResource H_Style_Container_GlassMediumBlur_Description}"
                                  Height="48"
                                  Margin="0,0,0,4">
                    <Grid Margin="16,0">
                        <local:FZButton
                            HorizontalAlignment="Left"
                            Style="{StaticResource A_Style_Button_SpinnerArrowButton}"
                            Command="{Binding PrevStatsCommand, RelativeSource={RelativeSource AncestorType=Page}}">
                            <Control Style="{StaticResource A_Style_Arrow_Left}"
                                            HorizontalAlignment="Left"
                                            Margin="-2,0,0,0" />
                        </local:FZButton>

                        <local:FZTextBlock x:Name="CategoryLabel"
                                           FontFamily="Horizon_B"
                                           HorizontalAlignment="Center"
                                           VerticalAlignment="Center"
                                           Color="{StaticResource H_Color_Primary_White}"
                                           CapHeight="19"/>
                        <local:FZButton
                            HorizontalAlignment="Right"
                            Style="{StaticResource A_Style_Button_SpinnerArrowButton}"
                            Command="{Binding NextStatsCommand, RelativeSource={RelativeSource AncestorType=Page}}">
                            <Control Style="{StaticResource A_Style_Arrow_Right}"
                                            HorizontalAlignment="Right"
                                            Margin="0,0,-2,0" />
                        </local:FZButton>
                    </Grid>
                </local:FZMaterial>
                <DockPanel Height="477"
                           Margin="0,0,0,0">
                    <local:FZMaterial Style="{StaticResource H_Style_Container_GlassMediumBlur_Description}"
                                      x:Name="CarInfoContainer"
                                      Visibility="Visible"
                                      DockPanel.Dock="Top"
                                      Height="152"
                                      Margin="0,0,0,5">
                        <StackPanel DataContext="{Binding Auction}"
                                    Orientation="Vertical"
                                    Margin="21">
                            <local:FZTextBlock Text="{Binding ShortName, Converter={StaticResource A_StringToUpper}}"
                                               CapHeight="26"
                                               Color="{StaticResource H_Color_Primary_White}"/>
                            <Decorator Height="9"/>
                            <local:FZTextBlock Color="{StaticResource H_Color_Primary_Grey_70pc}"
                                               FontFamily="Horizon_B"
                                               CapHeight="26">
                                    <local:FZRun Text="{Binding CarYear}" />
                                    <local:FZRun Text=" " />
                                    <local:FZRun Text="{Binding CarManufacturer, Converter={StaticResource A_StringToUpper}}"/>
                            </local:FZTextBlock>
                            <Decorator Height="15"/>
                            <StackPanel HorizontalAlignment="Left"
                                        MaxWidth="197"
                                        VerticalAlignment="Bottom"
                                        Orientation="Horizontal">
                                <Control Style="{StaticResource A_Style_Control_AuctionHouse_RarityPill}" 
                                         HorizontalAlignment="Left"
                                         Height="35"/>
                                <Control Style="{StaticResource H_Style_TemplatedElement_CarClassBadge}"
                                        local:BindingProxy.A="{Binding CarPI}"
                                        local:BindingProxy.B="{Binding CarClass}"
                                        Height="35"
                                        Margin="8,0,0,0"
                                        x:Name="CarClassControl"/>
                            </StackPanel>
                        </StackPanel>
                    </local:FZMaterial>
                    <Grid VerticalAlignment="Stretch">
                        <Grid Margin="0,0,0,0"
                              x:Name="Bars"
                              Visibility="Collapsed"
                              DataContext="{Binding Stats}">
                            <StackPanel Orientation="Vertical">
                                <Control Template="{StaticResource A_Template_Control_Upgrades_Bars}" 
                                         local:BindingProxy.A="{Binding Current.SpeedRating}"
                                         local:BindingProxy.B="{Binding Upgraded.SpeedRating}"
                                         Tag="{local:Loc CarFlow.IDS_Stat_Speed}"/>
                                <Control Template="{StaticResource A_Template_Control_Upgrades_Bars}" 
                                         local:BindingProxy.A="{Binding Current.HandlingRating}"
                                         local:BindingProxy.B="{Binding Upgraded.HandlingRating}"
                                         Tag="{local:Loc CarFlow.IDS_Stat_Handling}"/>
                                <Control Template="{StaticResource A_Template_Control_Upgrades_Bars}" 
                                         local:BindingProxy.A="{Binding Current.AccelerationRating}"
                                         local:BindingProxy.B="{Binding Upgraded.AccelerationRating}"
                                         Tag="{local:Loc CarFlow.IDS_Stat_Accel}"/>
                                <Control Template="{StaticResource A_Template_Control_Upgrades_Bars}" 
                                         local:BindingProxy.A="{Binding Current.LaunchRating}"
                                         local:BindingProxy.B="{Binding Upgraded.LaunchRating}"
                                         Tag="{local:Loc CarFlow.IDS_Stat_Launch}"/>
                                <Control Template="{StaticResource A_Template_Control_Upgrades_Bars}" 
                                         local:BindingProxy.A="{Binding Current.BrakingRating}"
                                         local:BindingProxy.B="{Binding Upgraded.BrakingRating}"
                                         Tag="{local:Loc CarFlow.IDS_Stat_Braking}"/>
                                <Control Template="{StaticResource A_Template_Control_Upgrades_Bars}" 
                                         local:BindingProxy.A="{Binding Current.OffroadRating}"
                                         local:BindingProxy.B="{Binding Upgraded.OffroadRating}"
                                         Tag="{local:Loc CarFlow.IDS_Stat_Offroad}" />
                            </StackPanel>
                        </Grid>

                        <Grid Margin="0"
                              Visibility="Collapsed"
                              x:Name="Stats"
                              DataContext="{Binding Stats}"
                              >
                            <StackPanel Orientation="Vertical">
                                <Control Template="{StaticResource A_Template_Control_Upgrades_Stats_Drivetrain}" 
                                         local:BindingProxy.A="{local:Loc CarFlow.IDS_Stat_Drivetrain}"
                                         DataContext="{Binding Upgraded}"/>
                                <Control Template="{StaticResource A_Template_Control_Upgrades_Stats}" 
                                         local:BindingProxy.A="{local:Loc CarFlow.IDS_Stat_Power}"
                                         local:BindingProxy.B="{Binding Upgraded.SimPeakPower, ConverterParameter=power, Converter={StaticResource A_NumUnitConverter_ShowUnit_0dp}, FallbackValue={local:Loc BarnFind.IDS_UnknownValue}}"
                                         Tag="{Binding SimPeakPowerChange, FallbackValue=0}"/>
                                <Control Template="{StaticResource A_Template_Control_Upgrades_Stats}" 
                                         local:BindingProxy.A="{local:Loc CarFlow.IDS_Stat_Torque}"
                                         local:BindingProxy.B="{Binding Upgraded.SimPeakTorque, ConverterParameter=torque, Converter={StaticResource A_NumUnitConverter_ShowUnit_0dp}, FallbackValue={local:Loc BarnFind.IDS_UnknownValue}}"
                                         Tag="{Binding SimPeakTorqueChange, FallbackValue=0}"/>
                                <Control Template="{StaticResource A_Template_Control_Upgrades_Stats}" 
                                         local:BindingProxy.A="{local:Loc CarFlow.IDS_Stat_Weight}"
                                         local:BindingProxy.B="{Binding Upgraded.CurbWeight, ConverterParameter=mass, Converter={StaticResource A_NumUnitConverter_ShowUnit_0dp}, FallbackValue={local:Loc BarnFind.IDS_UnknownValue}}"
                                         Tag="{Binding CurbWeightChange, FallbackValue=0}" />
                                <Control Template="{StaticResource A_Template_Control_Upgrades_Stats}" 
                                         local:BindingProxy.A="{local:Loc CarFlow.IDS_Stat_Front}"
                                         local:BindingProxy.B="{Binding Upgraded.WeightDistribution, ConverterParameter=fracpercentage, Converter={StaticResource A_NumUnitConverter_ShowUnit_0dp}, FallbackValue={local:Loc BarnFind.IDS_UnknownValue}}"
                                         Tag="{Binding WeightDistributionChange, FallbackValue=0}"/>
                                <Control Template="{StaticResource A_Template_Control_Upgrades_Stats}" 
                                         local:BindingProxy.A="{local:Loc CarFlow.IDS_Stat_Displacement}"
                                         local:BindingProxy.B="{Binding Upgraded.Displacement, Converter={StaticResource A_NumUnitConverter_ShowUnit_0dp}, FallbackValue={local:Loc BarnFind.IDS_UnknownValue}}"
                                         Tag="{Binding DisplacementChange, FallbackValue=0}"/>
                            </StackPanel>
                        </Grid>

                        <local:FZMaterial Style="{StaticResource H_Style_Container_GlassMediumBlur_Description}"
                                          Visibility="Collapsed"
                                          x:Name="Collaborators"
                                          DataContext="{Binding Auction}"
                                          Margin="0">
                            <StackPanel Margin="19,20,16,0">
                                <!-- Painter -->
                                <Control Template="{StaticResource A_Template_Control_Auction_Collaborator}"
                                        HorizontalContentAlignment="Left"
                                        local:BindingProxy.A="{Binding Painter}"
                                        local:BindingProxy.B="{x:Static local:UGCThreadType.Vinyl}"
                                        local:BindingProxy.C="{local:Loc AuctionHouse.IDS_Paint}"
                                        Margin="1,0,0,0"
                                        Tag="{Binding VinylGroupContributors}" />

                                <Decorator Height="15" />
                                
                                <local:FZMaterial Height="2"
                                    Color="{StaticResource A_Color_White}"
                                    Opacity="0.4" />

                                <Decorator Height="15" />

                                <!-- Tuner -->
                                <Control Template="{StaticResource A_Template_Control_Auction_Collaborator}"
                                        HorizontalContentAlignment="Left"
                                        local:BindingProxy.A="{Binding Tuner}"
                                        local:BindingProxy.B="{x:Static local:UGCThreadType.Tuning}"
                                        local:BindingProxy.C="{local:Loc AuctionHouse.IDS_Tune}" />

                            </StackPanel>
                        </local:FZMaterial>

                        <local:FZMaterial Style="{StaticResource H_Style_Container_GlassMediumBlur_Description}"
                                          Visibility="Collapsed"
                                          x:Name="Bids"
                                          DataContext="{Binding Auction}"
                                          Margin="0">
                            <StackPanel Orientation="Vertical"
                                        Margin="19,20,16,0">
                                <!-- Seller --> 
                                <Control HorizontalAlignment="Left"
                                         Style="{StaticResource A_Style_Control_ViewAuction_Seller}"
                                         local:BindingProxy.A="{StaticResource H_Color_Primary_White}"
                                         local:BindingProxy.B="{StaticResource A_Color_AuctionHouse_Expired}" />

                                <Decorator Height="16" />
                                <StackPanel Orientation="Horizontal"
                                            Margin="92,0,0,0">
                                    <local:FZMaterial x:Name="BuyoutIcon"
                                                      Width="45"
                                                      Height="45"
                                                      Stretch="Uniform"
                                                      VerticalAlignment="Center"
                                                      ImageSource="/ForzaUI;component/Textures/Anthem/Icons/Auction/Buy_Out_Icon.png"/>
        
                                    <Control Style="{StaticResource H_Style_Control_CreditsIcon}"
                                                      Width="30"
                                                      Height="30"
                                                      Margin="12,0,0,0"
                                                      VerticalAlignment="Center"/>
        
                                    <local:FZTextBlock Style="{StaticResource A_Style_FZTextBlock_Auction_Pill_CreditValueText}"
                                                       Text="{Binding Buyout, Converter={StaticResource A_NumUnitConverter_NoUnit_0dp}}"
                                                       FontFamily="Horizon_A"
                                                       Margin="10,0,0,0"
                                                       CapHeight="20"
                                                       TrackingAdjust="-0.005"
                                                       VerticalAlignment="Center"
                                                       Color="{StaticResource H_Color_Primary_White}"/>
                                </StackPanel>
                                
                                <Decorator Height="13" />
                                
                                <local:FZMaterial Height="2"
                                      Color="{StaticResource A_Color_White}"
                                      Opacity="0.4" />

                                <Decorator Height="13" />

                                <!-- High bidder -->
                                <Control Style="{StaticResource A_Style_Control_ViewAuction_HighestBidder}"
                                         local:BindingProxy.A="{StaticResource H_Color_Primary_White}"
                                         local:BindingProxy.B="{StaticResource A_Color_AuctionHouse_Expired}"
                                         HorizontalAlignment="Left"
                                         VerticalAlignment="Center"/>

                                <Decorator Height="13" />

                                <StackPanel Orientation="Horizontal"
                                            Margin="92,0,0,0">
                                    <local:FZMaterial x:Name="HighestBidIcon"
                                                      Width="45"
                                                      Height="45"
                                                      Stretch="Uniform"
                                                      VerticalAlignment="Center"
                                                      ImageSource="/ForzaUI;component/Textures/Anthem/Icons/Auction/Highest_Bid.png"/>

                                    <Control Style="{StaticResource H_Style_Control_CreditsIcon}"
                                                      Height="30"
                                                      Margin="12,0,0,0"
                                                      VerticalAlignment="Center"/>
        
                                    <local:FZTextBlock Style="{StaticResource A_Style_FZTextBlock_Auction_Pill_CreditValueText}"
                                                       Text="{Binding HighestBid, Converter={StaticResource A_NumUnitConverter_NoUnit_0dp}}"
                                                       FontFamily="Horizon_A"
                                                       Margin="10,0,0,0"
                                                       CapHeight="20"
                                                       TrackingAdjust="-0.005"
                                                       VerticalAlignment="Center"
                                                       Color="{StaticResource H_Color_Primary_Yellow}"/>
                                </StackPanel>
                            </StackPanel>
                        </local:FZMaterial>
                    </Grid>
                </DockPanel>
                <Decorator Height="4" />
                <!-- Start Bid Buy out Time Remaining -->
                <local:FZMaterial Style="{StaticResource H_Style_Container_GlassMediumBlur_Description}"
                                  GreedyMeasure="True"
                                  DataContext="{Binding Auction}"
                                  Height="60">
                    <Grid>
                        <Grid Margin="19,0,0,0">
                            <local:FZMaterial Height="24"
                                              Width="24"
                                              ImageSource="/ForzaUI;component/Textures/Anthem/Icons/Auction/Clock_Icon.png"
                                              VerticalAlignment="Center"
                                              HorizontalAlignment="Left"
                                              Color="{StaticResource H_Color_Primary_Yellow}"
                                              Visibility="{Binding State, Converter={StaticResource A_Converter_AuctionState_to_SoldVisibility_Inverse}}"/>
                            <local:FZTextBlock Text="{local:Loc AuctionHouse.IDS_Ended}"
                                               Color="{StaticResource H_Color_Primary_White}"
                                               CapHeight="22"
                                               VerticalAlignment="Center"
                                               FontFamily="Horizon_A"
                                               Visibility="{Binding State, Converter={StaticResource A_Converter_AuctionState_to_SoldVisibility}}"/>
                        </Grid>

                        <local:FZTextBlock Style="{StaticResource A_Style_FZTextBlock_AuctionDetails_TimeRemaining}"
                                           Text="{Binding TimeRemaining, Converter={StaticResource A_Converter_AuctionTime}}"
                                           Color="{StaticResource H_Color_Primary_Yellow}"
                                           CapHeight="22"
                                           VerticalAlignment="Center"
                                           FontFamily="Horizon_A"
                                           Visibility="{Binding State, Converter={StaticResource A_Converter_AuctionState_to_SoldVisibility_Inverse}}"
                                           Margin="54,0,0,0"/>
                        
                        <Control Margin="0,0,20,0"
                                 HorizontalAlignment="Right"
                                 VerticalAlignment="Center"
                                 BindingProxy.A="{Binding State}"
                                 Template="{StaticResource A_Template_Control_Auction_StateBox}" />
                    </Grid>
                </local:FZMaterial>
                <Decorator Height="4" />
                <local:CommonListBox Style="{StaticResource A_Style_ListBox_TextMenu}"
                                     SelectedItem="{Binding SelectedItem, Mode=OneWayToSource}"
                                     ItemContainerStyle="{StaticResource A_Style_ListBoxItem_TextMenu_Gaps}"
                                     ItemTemplate="{StaticResource A_DataTemplate_TextMenu_ViewAuctionDetails}"
                                     ItemsSource="{Binding Collection}"
                                     x:Name="PART_List"
                                     local:FocusOnPageFocusGained.SelectorSelectedItem="True">
                    <local:CommonListBox.Resources>
                        <Thickness x:Key="A_Thickness_ScrollViewer_TextMenu_Margin_Dynamic">-18,-18,-18,-18</Thickness>
                        <Thickness x:Key="A_Thickness_ListBox_TextMenu_PanelMargin_Dynamic">18,18,18,18</Thickness>
                    </local:CommonListBox.Resources>
                </local:CommonListBox>
            </StackPanel>
        </Border>
    </Grid>
</Page>
