<Page
  xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
  xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
  xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
  xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
  xmlns:noesis="clr-namespace:NoesisGUIExtensions"
  xmlns:b="http://schemas.microsoft.com/xaml/behaviors"
  xmlns:system="clr-namespace:System"
  mc:Ignorable="d"
  d:DesignWidth="3400" d:DesignHeight="1080" Width="3400" Height="1080">
  <Page.Resources>
    <ResourceDictionary>
      <Style x:Key="Style.ItemContainer" TargetType="ListBoxItem">
        <Setter Property="Template" Value="{DynamicResource ListBox_ItemsContainer_Carousel_Template}"/>
      </Style>
    </ResourceDictionary>
  </Page.Resources>
  <Grid x:Name="Master_Grid">
    <noesis:LayoutScaler x:Name="Master_LayoutScaler" ReferenceResolution="3400,1080">
      <Border x:Name="ScreenShape_Border">
        <Border.Clip>
          <RectangleGeometry Rect="0,0,3400,1080" RadiusX="32" RadiusY="32"/>
        </Border.Clip>
        <Grid x:Name="Screen_Grid">
          <Grid x:Name="Background_Grid">
            <MediaElement x:Name="BackgroundVideo_MediaElement" Source="Assets/Background_Video/Background_Video_Tintable_Compressed.mp4" Stretch="UniformToFill" LoadedBehavior="Manual" VerticalAlignment="Center">
              <b:Interaction.Triggers>
                <b:EventTrigger x:Name="StartBackgroundVideoOnLoad">
                  <noesis:PlayMediaAction TargetName="BackgroundVideo_MediaElement"/>
                </b:EventTrigger>
                <b:EventTrigger x:Name="LoopBackgroundVideo" EventName="MediaEnded">
                  <noesis:StopMediaAction TargetName="BackgroundVideo_MediaElement"/>
                  <noesis:PlayMediaAction TargetName="BackgroundVideo_MediaElement"/>
                </b:EventTrigger>
              </b:Interaction.Triggers>
            </MediaElement>
            <Border x:Name="BackgroundTint_Border" Background="{DynamicResource Key_Grad_BG}"/>
          </Grid>
          <Grid x:Name="ScreenLayout_Grid">
            <Grid.ColumnDefinitions>
              <ColumnDefinition Width="64"/>
              <ColumnDefinition Width="1*"/>
              <ColumnDefinition Width="64"/>
            </Grid.ColumnDefinitions>
            <Grid.RowDefinitions>
              <RowDefinition Height="64"/>
              <RowDefinition Height="1*"/>
              <RowDefinition Height="64"/>
            </Grid.RowDefinitions>
            <Border x:Name="Interface_Border" Grid.Column="1" Grid.Row="1" BorderThickness="4,4,4,4" CornerRadius="64,64,64,64">
              <Border.BorderBrush>
                <SolidColorBrush Color="{DynamicResource Key_Med}"/>
              </Border.BorderBrush>
              <Grid x:Name="InterfaceContent_Grid" Margin="32,32,32,32">
                <Grid.RowDefinitions>
                  <RowDefinition Height="Auto"/>
                  <RowDefinition Height="1*"/>
                </Grid.RowDefinitions>
                <Grid x:Name="Header_Grid">
                  <Grid.RowDefinitions>
                    <RowDefinition Height="Auto"/>
                    <RowDefinition Height="Auto"/>
                  </Grid.RowDefinitions>
                  <Grid x:Name="MainHeader_Grid">
                    <Border x:Name="Backer_Border" Background="{DynamicResource Key_Grad_UI}" CornerRadius="24,48,0,0">
                      <Grid x:Name="Layout_Grid" Margin="24,24,24,24">
                        <Grid.ColumnDefinitions>
                          <ColumnDefinition/>
                          <ColumnDefinition Width="auto"/>
                          <ColumnDefinition/>
                        </Grid.ColumnDefinitions>
                        <Grid x:Name="Left_Grid">
                          <Button Content="Main Menu" HorizontalAlignment="Left" Template="{DynamicResource Button_Back_Button_Template}"/>
                        </Grid>
                        <Grid x:Name="Middle_Grid" Grid.Column="1" HorizontalAlignment="Center" VerticalAlignment="Center">
                          <TextBlock x:Name="ScreenTitle_TextBlock" Text="THE TRIALS OF THE ANCIENTS" FontFamily="{DynamicResource Font_Primary}" FontSize="{DynamicResource TextSize_56}" TextWrapping="Wrap">
                            <TextBlock.Foreground>
                              <SolidColorBrush Color="{DynamicResource Light}"/>
                            </TextBlock.Foreground>
                          </TextBlock>
                        </Grid>
                        <Grid x:Name="Right_Grid" Grid.Column="2">
                          <StackPanel x:Name="PlayerModule_HorizontalStack" Orientation="Horizontal" HorizontalAlignment="Right">
                            <Button Content="Button" Margin="0,0,8,0" Template="{DynamicResource Button_AddCurrency_Button_Template}"/>
                            <Grid x:Name="Currency_Grid" Margin="0,0,8,0">
                              <Border x:Name="Currency_Backer_Border" Background="{DynamicResource Dark_50}"/>
                              <StackPanel x:Name="Currency_HorizontalStackPanel" Orientation="Horizontal" Margin="32,0,32,0" HorizontalAlignment="Center" VerticalAlignment="Center">
                                <Image x:Name="CurrencyIcon_Image" Source="Assets/Iconography_Bitmap/Iconography_Bitmap_Currency.png" Margin="0,0,16,0">
                                  <Image.Width>
                                    <Binding Path="ActualHeight" ElementName="Currency_TextBlock">
                                      <Binding.Converter>
                                        <noesis:MathConverter Expression="{}{0}-16"/>
                                      </Binding.Converter>
                                    </Binding>
                                  </Image.Width>
                                </Image>
                                <TextBlock x:Name="Currency_TextBlock" Text="1,320" FontFamily="{DynamicResource Font_Primary}" FontSize="{DynamicResource TextSize_40}" TextWrapping="Wrap">
                                  <TextBlock.Foreground>
                                    <SolidColorBrush Color="{DynamicResource Accent}"/>
                                  </TextBlock.Foreground>
                                </TextBlock>
                              </StackPanel>
                            </Grid>
                            <Grid x:Name="Gamertag_Grid" Margin="0,0,8,0">
                              <Border x:Name="Gamertag_Backer_Border" Background="{DynamicResource Dark_50}"/>
                              <TextBlock x:Name="Gamertag_TextBlock" Text="username" Margin="24,0,24,0" HorizontalAlignment="Center" VerticalAlignment="Center" FontFamily="{DynamicResource Font_Primary}" FontSize="{DynamicResource TextSize_40}" TextWrapping="Wrap">
                                <TextBlock.Foreground>
                                  <SolidColorBrush Color="{DynamicResource Light}"/>
                                </TextBlock.Foreground>
                              </TextBlock>
                            </Grid>
                            <Grid x:Name="Avatar_Grid">
                              <Border x:Name="AvatarBacker_Border" Width="{Binding Path=ActualHeight, RelativeSource={RelativeSource Self}}" Background="{DynamicResource Dark_50}" CornerRadius="0,24,0,0"/>
                              <Border x:Name="AvatarImage_Border" Margin="0,-8,0,0">
                                <Border.Background>
                                  <ImageBrush Stretch="UniformToFill" ImageSource="Assets/AvatarImagery_Bitmap/AvatarImagery_1.png"/>
                                </Border.Background>
                              </Border>
                            </Grid>
                          </StackPanel>
                        </Grid>
                      </Grid>
                    </Border>
                  </Grid>
                  <Grid x:Name="Header_DividerBlock_Grid" Margin="0,16,0,16" Grid.Row="1">
                    <ContentControl x:Name="Header_BottomDivider_ContentControl" Content="ContentControl" Template="{DynamicResource ContentControl_Header_BottomDivider_Template}"/>
                  </Grid>
                </Grid>
                <Grid x:Name="Missions_Grid" Grid.Row="1">
                  <Grid.ColumnDefinitions>
                    <ColumnDefinition Width="128"/>
                    <ColumnDefinition Width="1*"/>
                    <ColumnDefinition Width="2*"/>
                    <ColumnDefinition Width="2*"/>
                    <ColumnDefinition Width="1*"/>
                    <ColumnDefinition Width="128"/>
                  </Grid.ColumnDefinitions>
                  <ContentControl x:Name="MissionDetails_Wing_Left" Grid.Column="2" Style="{DynamicResource MissionDetails_WingAndContent_Left_Style}" Template="{DynamicResource ContentControl_MissionDetails_Wing_Template}" ContentTemplate="{DynamicResource ContentControl_Content_MissionDescription_Template}"/>
                  <ContentControl x:Name="MissionDetails_Wing_Right" Grid.Column="3" Style="{DynamicResource MissionDetails_WingAndContent_Right_Style}" Template="{DynamicResource ContentControl_MissionDetails_Wing_Template}" ContentTemplate="{DynamicResource ContentControl_Content_Squad_Template}"/>
                  <Grid x:Name="CarouselZone_Grid" Grid.Column="1" Grid.ColumnSpan="4" Visibility="Collapsed" ClipToBounds="True">
                    <Grid.OpacityMask>
                      <LinearGradientBrush EndPoint="1,0.5" StartPoint="0,0.5">
                        <GradientStop Color="#00000000" Offset="1"/>
                        <GradientStop Color="#FF000000" Offset="0.5"/>
                        <GradientStop Color="#00000000" Offset="0"/>
                        <GradientStop Color="#FF000000" Offset="0.172"/>
                        <GradientStop Color="#FF000000" Offset="0.846"/>
                      </LinearGradientBrush>
                    </Grid.OpacityMask>
                    <Grid x:Name="CarsouselClip_Grid" Background="#00000000" ClipToBounds="True">
                      <ListBox x:Name="Missions_Master_ListBox" SelectedIndex="1" ScrollViewer.HorizontalScrollBarVisibility="Auto" Width="320" ItemContainerStyle="{DynamicResource Style.ItemContainer}" Template="{DynamicResource ListBox_Carousel_Template}" ItemsPanel="{DynamicResource ListBox_ItemsPanel_Carousel_Template}" ItemTemplate="{DynamicResource ListBox_Item_Carousel_Template}">
                        <system:String>Item #1</system:String>
                        <system:String>Item #2</system:String>
                        <system:String>Item #3</system:String>
                        <system:String>Item #4</system:String>
                        <system:String>Item #5</system:String>
                        <system:String>Item #6</system:String>
                        <system:String>Item #7</system:String>
                        <system:String>Item #8</system:String>
                        <system:String>Item #9</system:String>
                        <system:String>Item #10</system:String>
                      </ListBox>
                    </Grid>
                  </Grid>
                  <Button x:Name="Prev_Button" RenderTransformOrigin="0.5,0.5" Content="Button" Margin="0" HorizontalAlignment="Right" VerticalAlignment="Center" Template="{DynamicResource Button_PrevNext_Template}">
                    <Button.RenderTransform>
                      <TransformGroup>
                        <ScaleTransform ScaleX="-1"/>
                        <SkewTransform/>
                        <RotateTransform/>
                        <TranslateTransform/>
                      </TransformGroup>
                    </Button.RenderTransform>
                  </Button>
                  <Button x:Name="Next_Button" Content="Button" Margin="0" Grid.Column="5" HorizontalAlignment="Left" VerticalAlignment="Center" Template="{DynamicResource Button_PrevNext_Template}"/>
                </Grid>
              </Grid>
            </Border>
          </Grid>
          <Grid x:Name="Foreground_HitTestInvisible_Grid" IsHitTestVisible="False" d:IsLocked="True">
            <Image x:Name="Noise_Image" Source="Assets/Foreground_Bitmap/Foreground_Bitmap_Noise.png" Stretch="UniformToFill" VerticalAlignment="Center" Opacity="0.33" BlendingMode="Multiply"/>
            <Image x:Name="ScratchedGlass_Image" Source="Assets/Foreground_Bitmap/Foreground_Bitmap_ScratchedGlass.png" Stretch="UniformToFill" VerticalAlignment="Top" Opacity="0.33" BlendingMode="Additive"/>
          </Grid>
        </Grid>
      </Border>
    </noesis:LayoutScaler>
  </Grid>
</Page>