<Page xmlns:local="clr-namespace:ForzaUI"
      xmlns:System="clr-namespace:System;assembly=mscorlib"
      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"
      x:Class="ForzaUI.A_PopupPurchaseOptions"
      mc:Ignorable="d"
      Style="{StaticResource A_Style_Page_Generic}"
      DataContext="{Binding RelativeSource={RelativeSource Self}}">

    <Page.Resources>
        <ResourceDictionary>
            <local:MappingConverter x:Key="A_Converter_VisibleIfFeaturedContentTypeNotExpansion"
                Default="{x:Static Visibility.Visible}">
                <local:MappingConverterEntry Key="{x:Static local:XAMLFeaturedContentType.Expansion}" Value="{x:Static Visibility.Collapsed}"/>
                <local:MappingConverterEntry Key="{x:Static local:XAMLFeaturedContentType.ExpansionPass}" Value="{x:Static Visibility.Collapsed}"/>
                <local:MappingConverterEntry Key="{x:Static local:XAMLFeaturedContentType.Bundle}" Value="{x:Static Visibility.Collapsed}"/>
                <local:MappingConverterEntry Key="{x:Static local:XAMLFeaturedContentType.Custom}" Value="{x:Static Visibility.Collapsed}"/>
                <local:MappingConverterEntry Key="{x:Static local:XAMLFeaturedContentType.CarPass}" Value="{x:Static Visibility.Collapsed}"/>
            </local:MappingConverter>

            <Style x:Key="A_Style_FZTextBlock_MarketplaceItem_Info" TargetType="{x:Type local:FZTextBlock}" BasedOn="{StaticResource A_Style_FZTextBlock_TileText}">
                <Setter Property="Color" Value="{StaticResource H_Color_Primary_Black}"/>
                <Setter Property="Margin" Value="26,0,0,160"/>
                <Setter Property="Visibility" Value="{Binding FeaturedContentType, Converter={StaticResource A_Converter_VisibleIfFeaturedContentTypeNotExpansion}}"/>
                <Setter Property="FontFamily" Value="Horizon_B"/>
                <Setter Property="CapHeight" Value="20"/>
                <Setter Property="Text" Value="{Binding ContentInfo}"/>
                <Setter Property="HorizontalAlignment" Value="Left"/>
                <Setter Property="VerticalAlignment" Value="Bottom"/>
                <Style.Triggers>
                    <DataTrigger Binding="{Binding FeaturedContentType}" Value="{x:Static local:XAMLFeaturedContentType.Vouchers}">
                        <Setter Property="Text" Value="{Binding SubTitle}" />
                        <Setter Property="Color" Value="#FFFFFFFF"/>
                        <Setter Property="HorizontalAlignment" Value="Center"/>
                        <Setter Property="VerticalAlignment" Value="Center"/>
                        <Setter Property="TextAlignment" Value="Center"/>
                        <Setter Property="Margin" Value="26,388,26,116"/>
                        <Setter Property="TextWrapping" Value="WrapWithOverflow"/>
                    </DataTrigger>
                </Style.Triggers>
            </Style>

            <ControlTemplate TargetType="ListBoxItem" x:Key="A_Template_ListBoxItem_PurchaseOptions">
                <ControlTemplate.Resources>
                    <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>
                </ControlTemplate.Resources>
                <Grid Width="284"
                      Height="auto"
                      Margin="0,0,4,0"
                      VerticalAlignment="Stretch"
                      local:UIPageTransitionManager.TransitionIndex="0">
                    <RoutedEventCommand x:Name="MouseLeftButtonUpCommand"
                                        RoutedEvent="UIElement.MouseLeftButtonUp"
                                        Style="{StaticResource A_Style_RoutedEventCommand_MouseLeftButtonUp}" />
                    <local:FZMaterial Style="{StaticResource A_Style_FZMaterial_TileShadow}" />
                    <ContentPresenter RoutedEventCommand.Action="{Binding ElementName=MouseLeftButtonUpCommand}"/>
                    <StrokeHighlightControl Style="{StaticResource A_Style_ContentControl_TileSelectionStroke}"
                                            ContentRadius="8" />
                </Grid>
                <ControlTemplate.Triggers>
                    <DataTrigger Binding="{Binding IsFocused}"
                                 Value="True">
                        <Setter Property="local:ZPanel.ZIndex"
                                Value="100" />
                    </DataTrigger>
                    <DataTrigger Binding="{Binding IsPurchased}"
                                 Value="True">
                        <Setter Property="Opacity"
                                Value="0.5" />
                        <Setter Property="Focusable"
                                Value="False"/>
                        <Setter Property="IsEnabled"
                                Value="False" />
                    </DataTrigger>
                    <MultiDataTrigger>
                      <MultiDataTrigger.Conditions>
                        <Condition Binding="{Binding FeaturedContentType}" Value="{x:Static local:XAMLFeaturedContentType.Expansion}" />
                        <Condition Binding="{Binding IsPurchased}" Value="False" />
                      </MultiDataTrigger.Conditions>
                      <Setter Property="Opacity"
                             Value="1" />
                      <Setter Property="Focusable"
                            Value="True" />
                      <Setter Property="IsEnabled"
                            Value="True" />
                  </MultiDataTrigger>
                </ControlTemplate.Triggers>
            </ControlTemplate>

            <Style x:Key="A_Style_ListBoxItem_MarketplaceItem"
                   TargetType="ListBoxItem">
                <Setter Property="Focusable"
                        Value="True" />
                <Setter Property="local:RecursiveFocusOnMouseOverBehaviour.Self"
                        Value="True" />
                <Setter Property="Template"
                        Value="{StaticResource A_Template_ListBoxItem_PurchaseOptions}" />
                <Setter Property="Panel.ZIndex" Value="0"/>
                <Setter Property="local:ZPanel.ZOffset" Value="0"/>
                <Setter Property="RenderTransformOrigin" Value="0.5,0.5"/>
                <Setter Property="RenderTransform">
                    <Setter.Value>
                        <TransformGroup>
                            <ScaleTransform/>
                            <SkewTransform/>
                            <RotateTransform/>
                            <TranslateTransform/>
                        </TransformGroup>
                    </Setter.Value>
                </Setter>
                <Style.Triggers>
                    <Trigger Property="IsKeyboardFocusWithin"
                             Value="True">
                        <Setter Property="Panel.ZIndex" Value="3"/>
                        <Setter Property="IsSelected" Value="True" />
                    </Trigger>
                </Style.Triggers>
            </Style>

            <Style x:Key="A_Style_FZMaterial_FlatPanel_FooterPanel_Margin" TargetType="{x:Type local:FZMaterial}" BasedOn="{StaticResource A_Style_FZMaterial_FlatPanel_FooterPanel}">
                <Setter Property="Margin" Value="7"/>
                <Setter Property="Preset" Value="{Roundtangle}" />
            </Style>

            <Style x:Key="A_Style_FZMaterial_MarketplaceItemIcon" TargetType="local:FZMaterial">
                <Setter Property="ImageSource" Value="/ForzaUI;component/Textures/Anthem/Marketplace/Single_Car.png" />
                <Setter Property="Stretch" Value="Uniform"/>
                <Setter Property="StretchDirection" Value="Both"/>
                <Setter Property="Height" Value="200"/>
                <Setter Property="Width" Value="200"/>
                <Setter Property="HorizontalAlignment" Value="Center"/>
                <Setter Property="VerticalAlignment" Value="Top"/>
                <Setter Property="Margin" Value="0,44,0,0"/>
                <Style.Triggers>
                    <DataTrigger Binding="{Binding FeaturedContentType}" Value="{x:Static local:XAMLFeaturedContentType.Car}">
                        <Setter Property="ImageSource" Value="/ForzaUI;component/Textures/Anthem/Marketplace/Single_Car.png" />
                    </DataTrigger>
                    <DataTrigger Binding="{Binding FeaturedContentType}" Value="{x:Static local:XAMLFeaturedContentType.CarPack}">
                        <Setter Property="ImageSource" Value="/ForzaUI;component/Textures/Anthem/Marketplace/Car_Pack.png" />
                    </DataTrigger>
                    <DataTrigger Binding="{Binding FeaturedContentType}" Value="{x:Static local:XAMLFeaturedContentType.CarPass}">
                        <Setter Property="ImageSource" Value="/ForzaUI;component/Textures/Anthem/Marketplace/Car_Pass.png" />
                    </DataTrigger>
                    <DataTrigger Binding="{Binding FeaturedContentType}" Value="{x:Static local:XAMLFeaturedContentType.ExpansionPass}">
                        <Setter Property="ImageSource" Value="/ForzaUI;component/Textures/Anthem/Marketplace/Expansion_Pass.png" />
                    </DataTrigger>
                    <DataTrigger Binding="{Binding FeaturedContentType}" Value="{x:Static local:XAMLFeaturedContentType.VIPMembership}">
                        <Setter Property="ImageSource" Value="/ForzaUI;component/Textures/Anthem/Marketplace/VIP_Pass.png" />
                    </DataTrigger>
                    <DataTrigger Binding="{Binding FeaturedContentType}" Value="{x:Static local:XAMLFeaturedContentType.Expansion}">
                        <Setter Property="ImageSource" Value="{Binding Image}" />
                    </DataTrigger>
                    <DataTrigger Binding="{Binding FeaturedContentType}" Value="{x:Static local:XAMLFeaturedContentType.Custom}">
                        <Setter Property="ImageSource" Value="{Binding Image}" />
                    </DataTrigger>
                    <DataTrigger Binding="{Binding FeaturedContentType}" Value="{x:Static local:XAMLFeaturedContentType.Bundle}">
                        <Setter Property="ImageSource" Value="/ForzaUI;component/Textures/Anthem/Marketplace/Bundle.png" />
                    </DataTrigger>
                    <DataTrigger Binding="{Binding FeaturedContentType}" Value="{x:Static local:XAMLFeaturedContentType.Vouchers}">
                        <Setter Property="ImageSource" Value="{Binding Image}" />
                        <Setter Property="Height" Value="Auto"/>
                        <Setter Property="Width" Value="Auto"/>
                        <Setter Property="HorizontalAlignment" Value="Stretch"/>
                        <Setter Property="VerticalAlignment" Value="Stretch"/>
                        <Setter Property="Margin" Value="0,0,0,0"/>
                    </DataTrigger>
                </Style.Triggers>
            </Style>
            
            <MappingConverter x:Key="A_LangStrToMarketplaceItemTitleLineAdjust" Default="-0.75">
                <MappingConverterEntry Key="CHS" Value="-0.35"/>
                <MappingConverterEntry Key="CHT" Value="-0.35"/>
                <MappingConverterEntry Key="CZ" Value="-0.45"/>
                <MappingConverterEntry Key="EN" Value="-0.75"/>
                <MappingConverterEntry Key="DEV" Value="-0.75"/>
                <MappingConverterEntry Key="GB" Value="-0.75"/>
                <MappingConverterEntry Key="JP" Value="-0.4"/>
                <MappingConverterEntry Key="KO" Value="-0.35"/>
                <MappingConverterEntry Key="TR" Value="-0.4"/>
            </MappingConverter>
            
            <Style x:Key="A_Style_FZTextBlock_MarketplaceItemTitle" TargetType="local:FZTextBlock" BasedOn="{StaticResource A_Style_FZTextBlock_TileTitle}">
                <Setter Property="Color" Value="{StaticResource H_Color_Primary_Black}"/>
                <Setter Property="TextWrapping" Value="WrapWithOverflow"/>
                <Setter Property="TextAlignment" Value="Left" />
                <Setter Property="MaxHeight" Value="100"/>
                <Setter Property="FontSize" Value="60"/>
                <Setter Property="LineAdjust" Value="{Binding LangStr, Source={StaticResource PART_UISceneContext}, Converter={StaticResource A_LangStrToMarketplaceItemTitleLineAdjust}}" />
                <Setter Property="Text" Value="{local:Loc InGameMarketplace.IDS_SingleCar}"/>
                <Style.Triggers>
                    <DataTrigger Binding="{Binding FeaturedContentType}" Value="{x:Static local:XAMLFeaturedContentType.Car}">
                        <Setter Property="Text" Value="{local:Loc InGameMarketplace.IDS_SingleCar}" />
                    </DataTrigger>
                    <DataTrigger Binding="{Binding FeaturedContentType}" Value="{x:Static local:XAMLFeaturedContentType.CarPack}">
                        <Setter Property="Text" Value="{Binding Title}" />
                    </DataTrigger>
                    <DataTrigger Binding="{Binding FeaturedContentType}" Value="{x:Static local:XAMLFeaturedContentType.CarPass}">
                        <Setter Property="Text" Value="{local:Loc InGameMarketplace.IDS_SeasonPass}" />
                    </DataTrigger>
                    <DataTrigger Binding="{Binding FeaturedContentType}" Value="{x:Static local:XAMLFeaturedContentType.ExpansionPass}">
                        <Setter Property="Text" Value="{Binding Title}" />
                    </DataTrigger>
                    <DataTrigger Binding="{Binding FeaturedContentType}" Value="{x:Static local:XAMLFeaturedContentType.VIPMembership}">
                        <Setter Property="Text" Value="{local:Loc InGameMarketplace.IDS_VIPMembership}" />
                    </DataTrigger>
                    <DataTrigger Binding="{Binding FeaturedContentType}" Value="{x:Static local:XAMLFeaturedContentType.Expansion}">
                        <Setter Property="Text" Value="{Binding Title}" />
                    </DataTrigger>
                    <DataTrigger Binding="{Binding FeaturedContentType}" Value="{x:Static local:XAMLFeaturedContentType.Bundle}">
                        <Setter Property="Text" Value="{Binding Title}" />
                    </DataTrigger>
                    <DataTrigger Binding="{Binding FeaturedContentType}" Value="{x:Static local:XAMLFeaturedContentType.Custom}">
                        <Setter Property="Text" Value="{Binding Title}" />
                    </DataTrigger>
                    <DataTrigger Binding="{Binding FeaturedContentType}" Value="{x:Static local:XAMLFeaturedContentType.Vouchers}">
                        <Setter Property="Text" Value="{Binding Title}" />
                        <Setter Property="Color" Value="#FFFFFFFF"/>
                        <Setter Property="Visibility" Value="Collapsed"/>
                    </DataTrigger>
                </Style.Triggers>
            </Style>
            
            <Style x:Key="A_Style_FZTextBlock_Price" TargetType="local:FZTextBlock" BasedOn="{StaticResource A_Style_FZTextBlock_TileTitle}">
                <Setter Property="Color" Value="{StaticResource H_Color_Primary_Yellow}"/>
                <Setter Property="Text" Value="{Binding Price}"/>
                <Setter Property="FontFamily" Value="Horizon_A"/>
                <Setter Property="CapHeight" Value="33"/>
                <Style.Triggers>
                    <DataTrigger Binding="{Binding IsPurchased}" Value="True">
                        <Setter Property="Text" Value="{local:Loc InGameMarketplace.IDS_Purchased}" />
                        <Setter Property="Color" Value="{StaticResource H_Color_Primary_White}"/>
                    </DataTrigger>
                </Style.Triggers>
            </Style>

            <Style x:Key="A_Style_Grid_BasePrice" TargetType="Grid">
                <Setter Property="Visibility" Value="{Binding IsOnSale, Converter={StaticResource A_FZBooleanToVisibilityConverter}}"/>
                <Style.Triggers>
                    <DataTrigger Binding="{Binding IsPurchased}" Value="True">
                        <Setter Property="Visibility" Value="Collapsed" />
                    </DataTrigger>
                    <DataTrigger Binding="{Binding BasePriceString, Converter={StaticResource A_StringVisConverter}}" Value="{x:Static Visibility.Collapsed}">
                        <Setter Property="Visibility" Value="Collapsed" />
                    </DataTrigger>
                </Style.Triggers>
            </Style>

            <Style x:Key="A_Style_ListBox_PurchaseOptions" TargetType="ListBox">
                <Setter Property="SelectedIndex" Value="0" />
                <Setter Property="ItemContainerStyle" Value="{StaticResource A_Style_ListBoxItem_MarketplaceItem}" />
                <Setter Property="Template">
                    <Setter.Value>
                        <ControlTemplate TargetType="ListBox">
                            <StackPanel Orientation="Horizontal" IsItemsHost="True" />
                        </ControlTemplate>
                    </Setter.Value>
                </Setter>
                <Setter Property="ItemTemplate">
                    <Setter.Value>
                        <DataTemplate>
                            <DockPanel>
                                <local:FZMaterial Style="{StaticResource A_Style_FZMaterial_TileBackground_NoAlternate}"
                                    Preset="{Roundtangle CornerRadius=8}">
                                    <Grid>
                                        <local:FZMaterial Style="{StaticResource A_Style_FZMaterial_MarketplaceItemIcon}"/>
                                        <local:FZTextBlock Style="{StaticResource A_Style_FZTextBlock_MarketplaceItemTitle}" 
                                            HorizontalAlignment="Left"
                                            VerticalAlignment="Top"
                                            Margin="23,281,23,0"/>
                                        <local:FZTextBlock Style="{StaticResource A_Style_FZTextBlock_MarketplaceItem_Info}"/>
                                        <StackPanel Orientation="Vertical" VerticalAlignment="Bottom">
                                            <DockPanel HorizontalAlignment="Stretch"
                                                       Visibility="{Binding HighlightDiscount, Converter={StaticResource A_FZBooleanToVisibilityConverter}, FallbackValue=Collapsed}"
                                                       Margin="7,-7">
                                                <local:FZMaterial Color="{StaticResource H_Color_Primary_Yellow}" HorizontalAlignment="Stretch" Height="65">
                                                    <local:FZTextBlock Text="{local:Loc InGameMarketplace.IDS_HighlightDiscount}"
                                                                       Color="#FF000000"
                                                                       VerticalAlignment="Center"
                                                                       HorizontalAlignment="Center"
                                                                       CapHeight="15"
                                                                       Margin="10"
                                                                       TextWrapping="Wrap"
                                                                       TextAlignment="Left"
                                                                       FontFamily="Horizon_C" />
                                                </local:FZMaterial>
                                            </DockPanel>
                                            <local:FZMaterial Style="{StaticResource A_Style_FZMaterial_FlatPanel_FooterPanel_Margin}" Height="77"  Color="{StaticResource H_Color_Primary_Black}">
                                                <Viewbox StretchDirection="DownOnly"
                                                         VerticalAlignment="Center"
                                                         HorizontalAlignment="Center"
                                                         Margin="5,0">
                                                    <StackPanel Orientation="Horizontal">
                                                        <Grid Style="{StaticResource A_Style_Grid_BasePrice}" Margin="5,0">
                                                            <local:FZTextBlock Style="{StaticResource A_Style_FZTextBlock_TileTitle}"
                                                                               Color="{StaticResource H_Color_Primary_White}"
                                                                               HorizontalAlignment="Center"
                                                                               VerticalAlignment="Center"
                                                                               Text="{Binding BasePriceString}"
                                                                               Margin="5,0"/>
                                                            <local:FZMaterial VerticalAlignment="Center" Color="{StaticResource H_Color_Primary_Pink}" Height="4" />
                                                        </Grid>
                                                        <local:FZTextBlock Style="{StaticResource A_Style_FZTextBlock_Price}"
                                                            HorizontalAlignment="Center"
                                                            VerticalAlignment="Center"
                                                        />
                                                    </StackPanel>
                                                </Viewbox>
                                            </local:FZMaterial>
                                        </StackPanel>
                                    </Grid>
                                </local:FZMaterial>
                            </DockPanel>
                        </DataTemplate>
                    </Setter.Value> 
                </Setter>
            </Style>

            <Style x:Key="A_Style_Run_Purchase_CarDetails" TargetType="local:FZRun">
                <Setter Property="FontFamily" Value="Horizon_C" />
                <Setter Property="FontSize" Value="19" />
            </Style>

            <Style x:Key="A_Style_Run_Purchase_BOLD" TargetType="local:FZRun">
                <Setter Property="FontFamily" Value="Horizon_C" />
                <Setter Property="Color" Value="{StaticResource H_Color_Primary_Green}" />
            </Style>

            <MappingConverter x:Key="A_MappingConverter_CarDetails">
                <MappingConverterEntry Key="{NoCase CarDetails}" Value="{StaticResource A_Style_Run_Purchase_CarDetails}" />
                <MappingConverterEntry Key="{NoCase BOLD}" Value="{StaticResource A_Style_Run_Purchase_BOLD}" />
            </MappingConverter>

            <AutoScrollSettings x:Key="H_AutoScrollSettings_PopupPurchaseOptions" 
                ScrollSeparation="50"
                ScrollOrientation="Vertical"
                Speed="20"
                InitialPause="0:0:0.5"/>
                
            <Style x:Key="A_Style_FZTextBlock_DescriptionBlockBody_Description" BasedOn="{StaticResource A_Style_FZTextBlock_DescriptionBlockBody}" TargetType="FZTextBlock">
                <Setter Property="local:MultiStringFormatter.Format" Value="{local:Loc InGameMarketplace.IDS_DescriptionDisclaimerFormat}" />
                <Setter Property="Text" Value="{Binding Description}" />
                <Setter Property="TextWrapping" Value="Wrap" />
                <Setter Property="MarkupConverter" Value="{StaticResource A_MappingConverter_CarDetails}" />
                <Setter Property="AutoScroll" Value="{StaticResource H_AutoScrollSettings_PopupPurchaseOptions}"/>
                <Setter Property="AutoScroll.AllowScrolling" Value="True" />
                <Style.Triggers>
                <DataTrigger Binding="{Binding IsPartOfUltimateBundle, FallbackValue=False}" Value="True">
                    <Setter Property="local:MultiStringFormatter.Param0" Value="{local:Loc InGameMarketplace.IDS_UltimateAddOnDisclaimer}" />
                    <Setter Property="local:MultiStringFormatter.Param1" Value="{Binding Description}" />
                    <Setter Property="Text" Value="{Binding (local:MultiStringFormatter.Output), RelativeSource={RelativeSource Self}}"/>
                </DataTrigger>
                <DataTrigger Binding="{Binding IsPartOfSeasonPass, FallbackValue=False}" Value="True">
                    <Setter Property="local:MultiStringFormatter.Param0" Value="{local:Loc InGameMarketplace.IDS_CarPackDisclaimer}" />
                    <Setter Property="local:MultiStringFormatter.Param1" Value="{Binding Description}" />
                    <Setter Property="Text" Value="{Binding (local:MultiStringFormatter.Output), RelativeSource={RelativeSource Self}}"/>
                </DataTrigger>
                <DataTrigger Binding="{Binding IsPartOfExpansionPass, FallbackValue=False}" Value="True">
                    <Setter Property="local:MultiStringFormatter.Param0" Value="{local:Loc InGameMarketplace.IDS_ExpansionPassDisclaimer}" />
                    <Setter Property="local:MultiStringFormatter.Param1" Value="{Binding Description}" />
                    <Setter Property="Text" Value="{Binding (local:MultiStringFormatter.Output), RelativeSource={RelativeSource Self}}"/>
                </DataTrigger>
                    <MultiDataTrigger>
                        <MultiDataTrigger.Conditions>
                            <Condition Binding="{Binding Visibility, ElementName=PART_UltimateAddOn}" Value="{x:Static Visibility.Collapsed}" />
                            <Condition Binding="{Binding DataItem.Visibility, ElementName=PART_CarPack}" Value="{x:Static Visibility.Collapsed}" />
                            <Condition Binding="{Binding (FrameworkElement.Visibility), ElementName=PART_ExpansionPass}" Value="{x:Static Visibility.Collapsed}" />
                        </MultiDataTrigger.Conditions>
                        <Setter Property="Margin" Value="0,6,0,0" />
                    </MultiDataTrigger>
                </Style.Triggers>
            </Style>

            <ControlTemplate x:Key="A_ControlTemplate_SidePanelContent" TargetType="ContentControl">
                <local:FZMaterial Style="{StaticResource H_Style_Container_GlassHighBlur_Description}" Margin="0,0,0,8">
                    <ContentPresenter/>
                </local:FZMaterial>
            </ControlTemplate>

        </ResourceDictionary>
    </Page.Resources>

    <local:UIPageTransitionManager.TransitionManager>
        <local:UIPageTransitionManager Preset="{StaticResource A_UIPageTransitionManagerPreset_Popup}"/>
    </local:UIPageTransitionManager.TransitionManager>

    <Border x:Name="PART_LayoutRoot">
        <Grid>
            <!-- Background Blur -->
            <local:FZMaterialGlassCapture />
            <local:FZMaterial Style="{StaticResource A_Style_FZMaterial_Popup_Background}"/>

            <!-- Help Button Bar -->
            <ContentControl x:Name="BottomBar" Style="{StaticResource A_Style_ButtonBar}">
                <ContentControl x:Name="PART_DefaultHelpPanel"
                    local:ControllerButtonPanel.ADescription="{local:Loc HelpButtons.IDS_Select}"
                    local:ControllerButtonPanel.BDescription="{local:Loc HelpButtons.IDS_Back}"
                    Style="{StaticResource A_Style_ContentControl_DefaultButtonBar}" />
            </ContentControl>

            <Grid Style="{StaticResource A_Style_FrameworkElement_LayoutRoot}">
                <StackPanel Orientation="Vertical" VerticalAlignment="Center" HorizontalAlignment="Center"
                    Style="{StaticResource A_Style_FrameworkElement_DefaultTransition_0}">

                    <ContentControl Style="{StaticResource A_Style_ContentControl_ScreenTitleBlock}"
                                    Content="{local:Loc InGameMarketplace.IDS_UpsellTitle}" 
                                    local:BindingProxy.A="/ForzaUI;component/Textures/Anthem/Icons/Titles/Car.png"
                                    HorizontalAlignment="Left"/>

                    <StackPanel Orientation="Horizontal"
                                Height="572">
                        <local:CommonListBox x:Name="PART_Menu"
                                             ItemsSource="{Binding PurchaseOptions}"
                                             Style="{StaticResource A_Style_ListBox_PurchaseOptions}"
                                             local:ZPanel.ZIndex="1"/>
                        <ContentControl Width="364"
                                        Template="{StaticResource A_ControlTemplate_SidePanel}"
                                        Tag="{local:Loc InGameMarketplace.IDS_Description}">
                            <Decorator Margin="24,22" ClipToBounds="True">
                                <FZTextBlock 
                                    Style="{StaticResource A_Style_FZTextBlock_DescriptionBlockBody_Description}"
                                    Margin="0,2"
                                    Visibility="{Binding Path=HasItems, ElementName=PART_Menu, Converter={StaticResource A_FZBooleanToVisibilityConverter}}"
                                    DataContext="{Binding SelectedItem, ElementName=PART_Menu}"/>
                            </Decorator>
                        </ContentControl>
                    </StackPanel>
                </StackPanel>
            </Grid>
        </Grid>
    </Border>
</Page>
