<ResourceDictionary xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation" 
                    xmlns:c1="clr-namespace:C1.WPF;assembly=C1.WPF.4" xmlns:c1sched="clr-namespace:C1.WPF.Schedule" 
                    xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml">
    
    <ResourceDictionary.MergedDictionaries>
        <ResourceDictionary Source="/C1.WPF.Schedule.4;component/themes/SchedulerThemes/Office2007/Default.xaml" />
    </ResourceDictionary.MergedDictionaries>

    <!-- @ MS Office 2007 Black Color -->
    <Color x:Key="C1Scheduler_BaseBackgroundColor">#FF949AA5</Color>

    <!-- @ Base Colors used in Scheduler -->
    <Color x:Key="C1Scheduler_BaseColor">#FF9199A4</Color>

	<!-- Control area (time ruler and month grid header) -->
    <SolidColorBrush x:Key="C1Scheduler_ControlArea_Brush" Color="#FFF0F1F2" />
    <SolidColorBrush x:Key="C1Scheduler_ControlAreaText_Brush" Color="#FF4D545D" />
	<Style x:Key="C1Scheduler_ControlAreaDark_BrushStyle" TargetType="c1:C1BrushBuilder">
		<Setter Property="DesignColor" Value="{StaticResource C1Scheduler_BaseBackgroundColor}" />
		<Setter Property="DesignBrush" Value="{StaticResource C1Scheduler_ControlArea_Brush}" />
	</Style>
	<!-- C1BrushBuilder style which is used for coloring month header. -->
	<Style x:Key="C1Scheduler_MonthHeaderForeground_BrushStyle" TargetType="c1:C1BrushBuilder">
		<Setter Property="DesignColor" Value="{StaticResource C1Scheduler_BaseBackgroundColor}" />
		<Setter Property="DesignBrush" Value="{StaticResource C1Scheduler_ControlAreaText_Brush}" />
	</Style>

	<!-- Background and border -->
    <SolidColorBrush x:Key="C1Scheduler_Background" Color="#FF949AA5" />
    <SolidColorBrush x:Key="C1Scheduler_Border_Brush" Color="#FF9199A4" />

    <!-- Navigation panels -->
    <LinearGradientBrush x:Key="C1Scheduler_NavPane_Brush" StartPoint="0,0" EndPoint="0,1">
        <GradientStop Color="#FFCFD2D8" Offset="0" />
        <GradientStop Color="#FFB5BAC2" Offset="0.5" />
        <GradientStop Color="#FFB2B8C0" Offset="0.6" />
        <GradientStop Color="#FFB0B6BE" Offset="1" />
    </LinearGradientBrush>
    <LinearGradientBrush x:Key="C1Scheduler_NavPane_HoverBrush" StartPoint="0,0" EndPoint="0,1">
        <GradientStop Color="#FFD0D3D9" Offset="0" />
        <GradientStop Color="#FFC0C4CB" Offset="0.4" />
        <GradientStop Color="#FFBEC3CA" Offset="0.6" />
        <GradientStop Color="#FFBCC0C7" Offset="1" />
    </LinearGradientBrush>

    <!-- Day header -->
    <LinearGradientBrush x:Key="C1Scheduler_DayHeader_Brush" StartPoint="0,0" EndPoint="0,1">
        <GradientStop Color="#FFDCDFE2" Offset="0" />
        <GradientStop Color="#FFD3D6DA" Offset="0.5" />
        <GradientStop Color="#FFB4BAC1" Offset="0.55" />
        <GradientStop Color="#FFCBCED4" Offset="1" />
    </LinearGradientBrush>
    <LinearGradientBrush x:Key="C1Scheduler_DayHeader_HoverBrush" StartPoint="0,0" EndPoint="0,1">
        <GradientStop Color="#FFE1E4E7" Offset="0" />
        <GradientStop Color="#FFDCDFE2" Offset="0.5" />
        <GradientStop Color="#FFCACED3" Offset="0.55" />
        <GradientStop Color="#FFD7DADF" Offset="1" />
    </LinearGradientBrush>

    <!-- All-day area -->
    <SolidColorBrush x:Key="C1Scheduler_AllDayArea_Brush" Color="#FFC7CBD1" />
    <SolidColorBrush x:Key="C1Scheduler_AllDayArea_SelectedBrush" Color="#FF4C535C" />

    <!-- Time slots -->
    <SolidColorBrush x:Key="C1Scheduler_WorkHourBorder_Brush" Color="#FFC7CBD1" />
    <SolidColorBrush x:Key="C1Scheduler_WorkHourLightBorder_Brush" Color="#FFE8EAEC" />
    <SolidColorBrush x:Key="C1Scheduler_FreeHour_Brush" Color="#FFE8EAEC" />
    <SolidColorBrush x:Key="C1Scheduler_FreeHourBorder_Brush" Color="#FFC7CBD1" />
    <SolidColorBrush x:Key="C1Scheduler_FreeHourLightBorder_Brush" Color="#FFDDE0E3" />
    <SolidColorBrush x:Key="C1Scheduler_TimeSlot_SelectedBrush" Color="#FF4C535C" />

	<!-- C1BrushBuilder style which is used for coloring selected time slot. -->
	<Style x:Key="C1Scheduler_TimeSlotSelected_BrushStyle" TargetType="c1:C1BrushBuilder">
		<Setter Property="DesignColor" Value="{StaticResource C1Scheduler_BaseBackgroundColor}" />
		<Setter Property="DesignBrush" Value="{StaticResource C1Scheduler_TimeSlot_SelectedBrush}" />
	</Style>

	<!-- Week tabs in a month view -->
    <LinearGradientBrush x:Key="C1Scheduler_WeekTab_Brush" StartPoint="0,0" EndPoint="0,1">
        <GradientStop Color="#FFDBDFE1" Offset="0" />
        <GradientStop Color="#FFD1D5D9" Offset="0.5" />
        <GradientStop Color="#FFB6BBC2" Offset="0.55" />
        <GradientStop Color="#FFC9CDD3" Offset="1" />
    </LinearGradientBrush>
    <LinearGradientBrush x:Key="C1Scheduler_WeekTab_HoverBrush" StartPoint="0,0" EndPoint="0,1">
        <GradientStop Color="#FFE5E8E9" Offset="0" />
        <GradientStop Color="#FFDDE0E4" Offset="0.5" />
        <GradientStop Color="#FFCCD0D5" Offset="0.55" />
        <GradientStop Color="#FFD9DBDF" Offset="1" />
    </LinearGradientBrush>

    <!-- Selected day background in a month view -->
    <SolidColorBrush x:Key="C1Scheduler_Selected_Brush" Color="#FFE8EAEC" />

    <!-- Alternate month day background (used in a month view) -->
    <SolidColorBrush x:Key="C1Scheduler_AlternateMonthDay_Brush" Color="#FFC7CBD1" />

    <!-- determines the style used for displaying time slots in a Day view.
         Copy it into every theme, as using DynamicResource here affects performance -->
    <c1sched:TimeSlotStyleSelector x:Key="TimeSlotStyleSelector">
        <!-- Don't use selection states. With selection states multiple selection works incorrectly. -->
        <c1sched:TimeSlotStyleSelector.Resources>
            <ResourceDictionary>
                <Style x:Key="C1Scheduler_WorkSlot_Style" TargetType="c1sched:VisualIntervalPresenter">
                    <Setter Property="BorderBrush" Value="{StaticResource C1Scheduler_WorkHourLightBorder_Brush}" />
                    <Setter Property="Template">
                        <Setter.Value>
                            <ControlTemplate TargetType="c1sched:VisualIntervalPresenter">
                                <Grid>
                                    <Border Background="{Binding Path=Scheduler.AlternatingBackground}" IsHitTestVisible="False" BorderThickness="0,1,0,0" BorderBrush="{TemplateBinding BorderBrush}">
                                        <Rectangle Fill="{Binding Tag, RelativeSource={RelativeSource AncestorType={x:Type c1sched:VisualIntervalsPresenter}}}" Visibility="{Binding IsSelected, Converter={x:Static c1sched:BooleanToVisibilityConverter.Default}}" />
                                    </Border>
                                    <ContentPresenter Content="{TemplateBinding Content}" Margin="0,1,0,0" ContentTemplate="{TemplateBinding ContentTemplate}" />
                                </Grid>
                            </ControlTemplate>
                        </Setter.Value>
                    </Setter>
                </Style>

                <Style x:Key="C1Scheduler_TopWorkSlot_Style" BasedOn="{StaticResource C1Scheduler_WorkSlot_Style}" TargetType="c1sched:VisualIntervalPresenter">
                    <Setter Property="BorderBrush" Value="{StaticResource C1Scheduler_WorkHourBorder_Brush}" />
                </Style>

                <Style x:Key="C1Scheduler_FreeSlot_Style" TargetType="c1sched:VisualIntervalPresenter">
                    <Setter Property="BorderBrush" Value="{StaticResource C1Scheduler_FreeHourLightBorder_Brush}" />
                    <Setter Property="Template">
                        <Setter.Value>
                            <ControlTemplate TargetType="c1sched:VisualIntervalPresenter">
                                <Grid>
                                    <Border Background="{StaticResource C1Scheduler_FreeHour_Brush}" BorderThickness="0,1,0,0" IsHitTestVisible="False" BorderBrush="{TemplateBinding BorderBrush}">
                                        <Rectangle Fill="{Binding Tag, RelativeSource={RelativeSource AncestorType={x:Type c1sched:VisualIntervalsPresenter}}}" Visibility="{Binding IsSelected, Converter={x:Static c1sched:BooleanToVisibilityConverter.Default}}" />
                                    </Border>
                                    <ContentPresenter Content="{TemplateBinding Content}" Margin="0,1,0,0" ContentTemplate="{TemplateBinding ContentTemplate}" />
                                </Grid>
                            </ControlTemplate>
                        </Setter.Value>
                    </Setter>
                </Style>

                <Style x:Key="C1Scheduler_TopFreeSlot_Style" BasedOn="{StaticResource C1Scheduler_FreeSlot_Style}" TargetType="c1sched:VisualIntervalPresenter">
                    <Setter Property="BorderBrush" Value="{StaticResource C1Scheduler_FreeHourBorder_Brush}" />
                </Style>

            </ResourceDictionary>
        </c1sched:TimeSlotStyleSelector.Resources>
    </c1sched:TimeSlotStyleSelector>

    <!-- Determines the style used for displaying time slots in the TimeLine view availability status line.
         Copy it into every theme, as using DynamicResource here affects performance -->
    <c1sched:TimeSlotStyleSelector x:Key="AvailabilityStatusStyleSelector">
        <c1sched:TimeSlotStyleSelector.Resources>
            <ResourceDictionary>
                <Style x:Key="C1Scheduler_WorkSlot_Style" TargetType="c1sched:VisualIntervalPresenter">
                    <Setter Property="BorderBrush" Value="{StaticResource C1Scheduler_WorkHourLightBorder_Brush}" />
                    <Setter Property="Template">
                        <Setter.Value>
                            <ControlTemplate TargetType="c1sched:VisualIntervalPresenter">
                                <!-- Background="{Binding Path=Scheduler.AlternatingBackground}"-->
                                <Border x:Name="IntervalBorder" IsHitTestVisible="False" VerticalAlignment="Stretch" HorizontalAlignment="Stretch" BorderThickness="1,0,0,0" BorderBrush="{TemplateBinding BorderBrush}">
                                    <Rectangle Fill="{Binding Path=TotalStatusBrush}" Margin="-1,7,0,7" />
                                </Border>
                            </ControlTemplate>
                        </Setter.Value>
                    </Setter>
                </Style>

                <Style x:Key="C1Scheduler_TopWorkSlot_Style" BasedOn="{StaticResource C1Scheduler_WorkSlot_Style}" TargetType="c1sched:VisualIntervalPresenter">
                    <Setter Property="BorderBrush" Value="{StaticResource C1Scheduler_WorkHourBorder_Brush}" />
                </Style>

                <Style x:Key="C1Scheduler_FreeSlot_Style" BasedOn="{StaticResource C1Scheduler_WorkSlot_Style}" TargetType="c1sched:VisualIntervalPresenter">
                    <Setter Property="BorderBrush" Value="{StaticResource C1Scheduler_FreeHourLightBorder_Brush}" />
                </Style>

                <Style x:Key="C1Scheduler_TopFreeSlot_Style" BasedOn="{StaticResource C1Scheduler_WorkSlot_Style}" TargetType="c1sched:VisualIntervalPresenter">
                    <Setter Property="BorderBrush" Value="{StaticResource C1Scheduler_FreeHourBorder_Brush}" />
                </Style>
            </ResourceDictionary>
        </c1sched:TimeSlotStyleSelector.Resources>
    </c1sched:TimeSlotStyleSelector>

    <!-- Determines the style used for displaying time slots in the TimeLine view.
         Copy it into every theme, as using DynamicResource here affects performance -->
    <c1sched:TimeSlotStyleSelector x:Key="HorizontalTimeSlotStyleSelector">
        <c1sched:TimeSlotStyleSelector.Resources>
            <ResourceDictionary>
                <Style x:Key="C1Scheduler_WorkSlot_Style" TargetType="c1sched:VisualIntervalPresenter">
                    <Setter Property="BorderBrush" Value="{StaticResource C1Scheduler_WorkHourLightBorder_Brush}" />
                    <Setter Property="Template">
                        <Setter.Value>
                            <ControlTemplate TargetType="c1sched:VisualIntervalPresenter">
                                <Grid>
                                    <Border x:Name="IntervalBorder" IsHitTestVisible="False" Background="{Binding Path=Scheduler.AlternatingBackground}" BorderThickness="1,0,0,0" BorderBrush="{TemplateBinding BorderBrush}">
                                        <Rectangle Fill="{Binding Tag, RelativeSource={RelativeSource AncestorType={x:Type c1sched:VisualIntervalsPresenter}}}" Visibility="{Binding IsSelected, Converter={x:Static c1sched:BooleanToVisibilityConverter.Default}}" />
                                    </Border>
                                    <ContentPresenter Content="{TemplateBinding Content}" ContentTemplate="{TemplateBinding ContentTemplate}" Margin="1,0,0,0" />
                                </Grid>
                            </ControlTemplate>
                        </Setter.Value>
                    </Setter>
                </Style>

                <Style x:Key="C1Scheduler_TopWorkSlot_Style" BasedOn="{StaticResource C1Scheduler_WorkSlot_Style}" TargetType="c1sched:VisualIntervalPresenter">
                    <Setter Property="BorderBrush" Value="{StaticResource C1Scheduler_WorkHourBorder_Brush}" />
                </Style>

                <Style x:Key="C1Scheduler_FreeSlot_Style" TargetType="c1sched:VisualIntervalPresenter">
                    <Setter Property="BorderBrush" Value="{StaticResource C1Scheduler_FreeHourLightBorder_Brush}" />
                    <Setter Property="Template">
                        <Setter.Value>
                            <ControlTemplate TargetType="c1sched:VisualIntervalPresenter">
                                <Grid>
                                    <Border x:Name="IntervalBorder" IsHitTestVisible="False" Background="{StaticResource C1Scheduler_FreeHour_Brush}" BorderThickness="1,0,0,0" BorderBrush="{TemplateBinding BorderBrush}">
                                        <Rectangle Fill="{Binding Tag, RelativeSource={RelativeSource AncestorType={x:Type c1sched:VisualIntervalsPresenter}}}" Visibility="{Binding IsSelected, Converter={x:Static c1sched:BooleanToVisibilityConverter.Default}}" />
                                    </Border>
                                    <ContentPresenter Content="{TemplateBinding Content}" ContentTemplate="{TemplateBinding ContentTemplate}" Margin="1,0,0,0" />
                                </Grid>
                            </ControlTemplate>
                        </Setter.Value>
                    </Setter>
                </Style>

                <Style x:Key="C1Scheduler_TopFreeSlot_Style" BasedOn="{StaticResource C1Scheduler_FreeSlot_Style}" TargetType="c1sched:VisualIntervalPresenter">
                    <Setter Property="BorderBrush" Value="{StaticResource C1Scheduler_FreeHourBorder_Brush}" />
                </Style>
            </ResourceDictionary>
        </c1sched:TimeSlotStyleSelector.Resources>
    </c1sched:TimeSlotStyleSelector>

</ResourceDictionary>