<Window
    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:materialDesign="http://materialdesigninxaml.net/winfx/xaml/themes"
    x:Name="MainWindow"
    x:Class="MainWindow"
    TextElement.Foreground="{DynamicResource MaterialDesignBody}"
    TextElement.FontWeight="Regular"
    TextElement.FontSize="13"
    TextOptions.TextFormattingMode="Ideal"
    TextOptions.TextRenderingMode="Auto"
    Background="{DynamicResource MaterialDesignPaper}"
    FontFamily="{DynamicResource MaterialDesignFont}"
    mc:Ignorable="d"
    Title="Dokumentáció készítő"
    Height="417"
    Width="614"
    FontSize="13"
    WindowStyle="None"
    ResizeMode="NoResize"
    WindowStartupLocation="CenterScreen"
    SizeToContent="WidthAndHeight"
    MinHeight="370"
    MaxHeight="370">

    <Window.Resources>
        <!-- Correct BundledTheme usage -->
        <materialDesign:BundledTheme
            BaseTheme="Light"
            PrimaryColor="Teal"
            SecondaryColor="Teal" />
    </Window.Resources>

    <Grid x:Name="MainGrid" HorizontalAlignment="Center" Height="360" VerticalAlignment="Top" Width="614">
        <Grid.RowDefinitions>
            <RowDefinition Height="14*"/>
            <RowDefinition Height="173*"/>
        </Grid.RowDefinitions>

        <Label Content="Dokumentáció készítő" Height="22" VerticalAlignment="Top" FontSize="14" MouseDown="Label_MouseDown" HorizontalAlignment="Left" Width="462"/>

        <TabControl Style="{StaticResource MaterialDesignTabControl}" Margin="0,27,0,2" HorizontalAlignment="Left" Width="600" Grid.RowSpan="2">
            <TabControl.Background>
                <ImageBrush/>
            </TabControl.Background>

            <TabItem Header="DOKSI készítő" FontSize="13" Width="140">
                <Grid HorizontalAlignment="Left" Width="600" Margin="0,0,0,-6" Height="325" VerticalAlignment="Top">
                    <Button x:Name="CreateDocument" Content="Dokumentáció készítése" HorizontalAlignment="Left" Margin="434,222,0,0" VerticalAlignment="Top" Width="156" RenderTransformOrigin="0.785,1.101"/>
                    <ListBox x:Name="ListBox1" Height="52" Margin="542,176,-396,0" VerticalAlignment="Top" Background="{x:Null}" BorderThickness="2" BorderBrush="#FFECE0E0"/>
                    <StackPanel Margin="10,10,0,0" HorizontalAlignment="Left" Width="180">
                        <GroupBox Header="Dokumentáció típusa" Padding="5">
                            <StackPanel>
                                <CheckBox x:Name="PDFCheckBox" Content="PDF"/>
                                <CheckBox x:Name="DXFCheckBox" Content="DXF"/>
                                <CheckBox x:Name="XLSCheckbox" Content="XLS"/>
                                <CheckBox x:Name="TIFFCheckbox" Content="TIFF"/>
                            </StackPanel>
                        </GroupBox>
                    </StackPanel>
                    <StackPanel Margin="0,10,215,243" HorizontalAlignment="Right" Width="180">
                        <GroupBox Header="Dokumentáció" Padding="5">
                            <StackPanel>
                                <RadioButton x:Name="NamingSyntaxStefani" Content="Stefani"/>
                                <RadioButton x:Name="NamingSyntaxAudi" Content="Audi"/>
                            </StackPanel>
                        </GroupBox>
                    </StackPanel>
                    <StackPanel Margin="10,126,0,71" HorizontalAlignment="Left" Width="250">
                        <GroupBox Header="Egyéb" Padding="5">
                            <StackPanel>
                                <CheckBox x:Name="AutomaticFolderSelect" Content="Automatikus mappa választás"/>
                                <CheckBox x:Name="PDFOsszeCheckBox" Content="PDF összefűzése"/>
                            </StackPanel>
                        </GroupBox>
                    </StackPanel>
                    <GroupBox Header="Rajz használat módja" Margin="390,10,0,0" Width="200" HorizontalAlignment="Left" VerticalAlignment="Top" Padding="5">
                        <StackPanel>
                            <RadioButton x:Name="MaterialRadioButton3" Content="Aktív rajz használata"/>
                            <RadioButton x:Name="KulonAloRajzok" Content="Különálló rajzok használata"/>
                        </StackPanel>
                    </GroupBox>
                    <Button x:Name="Files_Browse" Content="Böngészés" HorizontalAlignment="Left" Margin="390,87,0,0" VerticalAlignment="Top" Width="200" RenderTransformOrigin="0.785,1.101" Height="30" FontSize="8"/>
                    <Grid HorizontalAlignment="Left" Height="32" Margin="10,222,0,0" VerticalAlignment="Top" Width="419">
                        <Grid.ColumnDefinitions>
                            <ColumnDefinition Width="308*"/>
                            <ColumnDefinition Width="111*"/>
                        </Grid.ColumnDefinitions>
                        <ProgressBar x:Name="Progressbar" HorizontalAlignment="Left" Height="32" VerticalAlignment="Center" Width="419" Grid.ColumnSpan="2" />
                        <Label x:Name="ProgressText" Content="" HorizontalAlignment="Left" VerticalAlignment="Center" Height="22" Margin="206,0,0,0"/>
                    </Grid>
                    <CheckBox x:Name="DWGCheckBox" HorizontalAlignment="Left" Margin="109,55,0,0" VerticalAlignment="Top" Content="DWG" RenderTransformOrigin="0.763,0.741"/>
                </Grid>
            </TabItem>

            <TabItem Header="Egyéb" IsEnabled="False">
                <Grid>
                    <TabControl HorizontalAlignment="Right" Width="500" Height="297" VerticalAlignment="Top" Background="{x:Null}" IsEnabled="False">
                        <TabItem Header="Drw osztó">
                            <TabItem.RenderTransform>
                                <TransformGroup>
                                    <ScaleTransform/>
                                    <SkewTransform AngleY="-0.415"/>
                                    <RotateTransform/>
                                    <TranslateTransform Y="0.326"/>
                                </TransformGroup>
                            </TabItem.RenderTransform>
                            <Grid Margin="0,0,0,-1">
                                <Grid.RowDefinitions>
                                    <RowDefinition Height="33*"/>
                                    <RowDefinition Height="8*"/>
                                </Grid.RowDefinitions>
                                <Button x:Name="drwSplitButton" Content="Split" HorizontalAlignment="Left" Margin="10,54,0,0" VerticalAlignment="Top" Width="91" RenderTransformOrigin="0.785,1.101"/>
                                <CheckBox x:Name="AktualisRajzRadioButton" HorizontalAlignment="Left" Margin="10,91,0,0" VerticalAlignment="Top" Content="Aktuális rajz mentése" Width="156"/>
                                <Button x:Name="test" Content="Split" HorizontalAlignment="Left" Margin="393,54,0,0" VerticalAlignment="Top" Width="91" RenderTransformOrigin="0.785,1.101"/>
                                <CheckBox x:Name="RajzCsereRadioButton" HorizontalAlignment="Left" Margin="328,91,0,0" VerticalAlignment="Top" Content="Rajz csere" Width="156"/>
                            </Grid>
                        </TabItem>
                        <TabItem Header="Purge">
                            <Grid>
                                <CheckBox x:Name="PRTCheckBox" HorizontalAlignment="Left" Margin="10,104,0,0" VerticalAlignment="Top" Content="PRT" RenderTransformOrigin="-0.023,5.167"/>
                                <CheckBox x:Name="ASMCheckBox" HorizontalAlignment="Left" Margin="114,104,0,0" VerticalAlignment="Top" Content="ASM"/>
                                <CheckBox x:Name="DRWCheckBox" HorizontalAlignment="Left" Margin="58,104,0,0" VerticalAlignment="Top" Content="DRW"/>
                                <Button x:Name="FixNamesButton" Content="Fix names" HorizontalAlignment="Left" Margin="124,67,0,0" VerticalAlignment="Top" Width="94" RenderTransformOrigin="0.785,1.101"/>
                                <Button x:Name="PurgeBongeszesButton" Content="Böngészés" HorizontalAlignment="Left" Margin="10,67,0,0" VerticalAlignment="Top" Width="109" RenderTransformOrigin="0.785,1.101"/>
                                <CheckBox x:Name="subdirctories" HorizontalAlignment="Left" Margin="179,104,0,0" VerticalAlignment="Top" Content="ASM"/>
                            </Grid>
                        </TabItem>
                        <TabItem Header="Translator">
                            <Grid Height="287" VerticalAlignment="Top" Margin="0,0,2,0">
                                <Button x:Name="Button1" Content="Button" HorizontalAlignment="Left" Margin="10,137,0,0" VerticalAlignment="Top" Width="75"/>
                                <CheckBox x:Name="PromtTranslateCBOX" Content="CheckBox" HorizontalAlignment="Left" Margin="10,174,0,0" VerticalAlignment="Top"/>
                            </Grid>
                        </TabItem>
                    </TabControl>
                </Grid>
            </TabItem>

            <TabItem Header="Nényjegy" Width="124" IsEnabled="False">
                <Grid>
                    <Image HorizontalAlignment="Center" Height="98" Margin="46,70,48,129" VerticalAlignment="Center" Width="406" Source="logo.png" Stretch="Fill"/>
                </Grid>
            </TabItem>

            <Image Height="100" Width="100"/>

        </TabControl>
        <Button
    HorizontalAlignment="Right"
    VerticalAlignment="Top"
    Width="40"
    Height="40"
    Click="Button_Click"
    Background="Transparent"
    BorderBrush="DarkRed"
    BorderThickness="1"
    ToolTip="Exit" Grid.RowSpan="2">
            <Button.Content>
                <TextBlock
            Text="✕"
            FontSize="32"
            Foreground="DarkRed"
            HorizontalAlignment="Center"
            VerticalAlignment="Center"
            TextAlignment="Center"
            />
            </Button.Content>
            <Button.Style>
                <Style TargetType="Button" BasedOn="{StaticResource MaterialDesignFlatButton}">
                    <Setter Property="Background" Value="Transparent" />
                    <Setter Property="BorderBrush" Value="DarkRed" />
                    <Setter Property="BorderThickness" Value="1" />
                    <Style.Triggers>
                        <Trigger Property="IsMouseOver" Value="True">
                            <Setter Property="Background" Value="#30FF0000" />
                        </Trigger>
                        <Trigger Property="IsPressed" Value="True">
                            <Setter Property="Background" Value="#50FF0000" />
                        </Trigger>
                    </Style.Triggers>
                </Style>
            </Button.Style>
        </Button>



    </Grid>
</Window>
