<Page x:Class="SkyTeam.RegistrationPage"
      xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
      xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
      xmlns:iconPacks="http://metro.mahapps.com/winfx/xaml/iconpacks"
      Title="Registrierungsseite"
      Background="#F0F2F5">

    <Grid Margin="40,20">
        <Grid.RowDefinitions>
            <RowDefinition Height="Auto"/>
            <RowDefinition Height="*"/>
        </Grid.RowDefinitions>

        <StackPanel Grid.Row="0"
                    Orientation="Horizontal"
                    VerticalAlignment="Center"
                    Margin="0,0,0,30">
            <iconPacks:PackIconMaterial Kind="AccountPlus"
                                        Width="40"
                                        Height="40"
                                        Foreground="#1E88E5"
                                        Margin="0,0,15,0"/>
            <StackPanel>
                <TextBlock Text="Registrieren"
                           FontSize="28"
                           FontWeight="Bold"
                           Foreground="#333"/>
                <TextBlock Text="Erstellen Sie Ihren Sky Team Account"
                           FontSize="14"
                           Foreground="#666"/>
            </StackPanel>
        </StackPanel>

        <Border Grid.Row="1"
                Background="White"
                CornerRadius="12"
                Padding="30"
                BorderBrush="#E0E0E0"
                BorderThickness="1"
                VerticalAlignment="Top"
                HorizontalAlignment="Center"
                MaxWidth="500">

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

                <Grid.ColumnDefinitions>
                    <ColumnDefinition Width="Auto"/>
                    <ColumnDefinition Width="250"/>
                </Grid.ColumnDefinitions>

                <Label Content="Anrede:" Grid.Row="0" Grid.Column="0" VerticalAlignment="Center" Margin="0,0,12,12"/>
                <ComboBox x:Name="SalutationComboBox" Grid.Row="0" Grid.Column="1" Margin="0,0,0,12" Height="30" VerticalContentAlignment="Center">
                    <ComboBoxItem Content="Herr"/>
                    <ComboBoxItem Content="Frau"/>
                    <ComboBoxItem Content="Divers"/>
                </ComboBox>

                <Label Content="Vorname:" Grid.Row="1" Grid.Column="0" VerticalAlignment="Center" Margin="0,0,12,12"/>
                <TextBox x:Name="FirstNameTextBox" Grid.Row="1" Grid.Column="1" Margin="0,0,0,12" Height="30" VerticalContentAlignment="Center"/>

                <Label Content="Nachname:" Grid.Row="2" Grid.Column="0" VerticalAlignment="Center" Margin="0,0,12,12"/>
                <TextBox x:Name="LastNameTextBox" Grid.Row="2" Grid.Column="1" Margin="0,0,0,12" Height="30" VerticalContentAlignment="Center"/>

                <Label Content="Geburtsdatum:" Grid.Row="3" Grid.Column="0" VerticalAlignment="Center" Margin="0,0,12,12"/>
                <DatePicker x:Name="BirthDatePicker" Grid.Row="3" Grid.Column="1" Margin="0,0,0,12" Height="30" VerticalContentAlignment="Center"/>

                <Label Content="E-Mail:" Grid.Row="4" Grid.Column="0" VerticalAlignment="Center" Margin="0,0,12,12"/>
                <TextBox x:Name="EmailTextBox" Grid.Row="4" Grid.Column="1" Margin="0,0,0,12" Height="30" VerticalContentAlignment="Center"/>

                <Label Content="Stadt:" Grid.Row="5" Grid.Column="0" VerticalAlignment="Center" Margin="0,0,12,12"/>
                <TextBox x:Name="CityTextBox" Grid.Row="5" Grid.Column="1" Margin="0,0,0,12" Height="30" VerticalContentAlignment="Center"/>

                <Label Content="Land:" Grid.Row="6" Grid.Column="0" VerticalAlignment="Center" Margin="0,0,12,12"/>
                <TextBox x:Name="CountryTextBox" Grid.Row="6" Grid.Column="1" Margin="0,0,0,12" Height="30" VerticalContentAlignment="Center"/>

                <Label Content="Passwort:" Grid.Row="7" Grid.Column="0" VerticalAlignment="Center" Margin="0,0,12,0"/>
                <PasswordBox x:Name="PasswordBox" Grid.Row="7" Grid.Column="1" Height="30" VerticalContentAlignment="Center"/>

                <StackPanel Grid.Row="9" Grid.ColumnSpan="2" Orientation="Horizontal" HorizontalAlignment="Center">
                    <Button Content="Registrieren"
                            Width="120"
                            Height="40"
                            Margin="0,0,15,0"
                            Background="#1E88E5"
                            Foreground="White"
                            FontWeight="Bold"
                            Click="RegisterButton_Click"/>

                    <Button Content="Abbrechen"
                            Width="120"
                            Height="40"
                            Background="#F5F5F5"
                            BorderBrush="#DDD"
                            Click="CancelButton_Click"/>
                </StackPanel>
            </Grid>
        </Border>
    </Grid>
</Page>