country_decisions = {
	curtail_estate_noble = {
		major = yes
		potential = {
			OR = {
				has_country_flag = estate_nobles_in_power
				has_country_modifier = noble_power_monarchy
				has_country_modifier = noble_power_elective_monarchy
				has_country_modifier = umera_dominance_ottoman_government
				has_country_modifier = junker_dominance_prussian_monarchy
				has_country_modifier = gentry_dominance
				has_country_modifier = bushi_power_japan
				has_country_modifier = boyar_dominance
				has_country_modifier = mamluk_amir_dominance
				has_country_modifier = amir_dominance
			}
		}
		allow = {
			stability = 1
			NOT = { num_of_rebel_armies = 1 }
			NOT = { num_of_rebel_controlled_provinces = 1 }			
			NOT = {
				estate_influence = {
					estate = estate_nobles
					influence = 60
				}				
			}
		}
		effect = {
			add_stability = -3
			add_prestige = -25
			if = {
				limit = {
					has_country_modifier = noble_power_monarchy
				}
				remove_country_modifier = noble_power_monarchy
			}
			else_if = {
				limit = {
					has_country_modifier = noble_power_elective_monarchy
				}
				remove_country_modifier = noble_power_elective_monarchy
			}
			else_if = {
				limit = {
					has_country_modifier = junker_dominance_prussian_monarchy
				}
				remove_country_modifier = junker_dominance_prussian_monarchy
			}
			else_if = {
				limit = {
					has_country_modifier = umera_dominance_ottoman_government
				}
				remove_country_modifier = umera_dominance_ottoman_government
			}
			else_if = {
				limit = {
					has_country_modifier = gentry_dominance
				}
				remove_country_modifier = gentry_dominance
			}
			else_if = {
				limit = {
					has_country_modifier = bushi_power_japan
				}
				remove_country_modifier = bushi_power_japan
			}
			else_if = {
				limit = {
					has_country_modifier = boyar_dominance
				}
				remove_country_modifier = boyar_dominance
			}
			else_if = {
				limit = {
					has_country_modifier = mamluk_amir_dominance
				}
				remove_country_modifier = mamluk_amir_dominance
			}
			else_if = {
				limit = {
					has_country_modifier = mamluk_amir_dominance
				}
				remove_country_modifier = mamluk_amir_dominance
			}
			else_if = {
				limit = {
					has_country_modifier = amir_dominance
				}
				remove_country_modifier = amir_dominance
			}
			clr_country_flag = estate_nobles_in_power
		}
		ai_will_do = {
			factor = 1
		}
	}
	
	curtail_estate_church = {
		major = yes
		potential = {
			has_country_flag = estate_church_in_power
		}
		allow = {
			stability = 1
			NOT = { num_of_rebel_armies = 1 }
			NOT = { num_of_rebel_controlled_provinces = 1 }			
			NOT = {
				estate_influence = {
					estate = estate_church
					influence = 60
				}				
			}
		}
		effect = {
			add_stability = -3
			add_piety = -0.5
			add_karma = -25
			add_patriarch_authority = -0.25
			add_fervor = -25
			add_church_power = -100
			clr_country_flag = estate_church_in_power
		}
		ai_will_do = {
			factor = 1
		}
	}
	
	curtail_estate_brahmins = {
		major = yes
		potential = {
			has_country_flag = estate_brahmins_in_power
		}
		allow = {
			stability = 1
			NOT = { num_of_rebel_armies = 1 }
			NOT = { num_of_rebel_controlled_provinces = 1 }			
			NOT = {
				estate_influence = {
					estate = estate_brahmins
					influence = 60
				}				
			}
		}
		effect = {
			add_stability = -3
			add_piety = -0.5
			add_karma = -25
			add_patriarch_authority = -0.25
			add_fervor = -25
			add_church_power = -100
			clr_country_flag = estate_brahmins_in_power
		}
		ai_will_do = {
			factor = 1
		}
	}
	
	curtail_estate_burghers = {
		major = yes
		potential = {
			has_country_flag = estate_burghers_in_power
		}
		allow = {
			stability = 1
			NOT = { num_of_rebel_armies = 1 }
			NOT = { num_of_rebel_controlled_provinces = 1 }			
			NOT = {
				estate_influence = {
					estate = estate_burghers
					influence = 60
				}				
			}
		}
		effect = {
			add_stability = -3
			capital_scope = {
				add_base_tax = -1
				add_base_production = -1
			}
			clr_country_flag = estate_burghers_in_power
		}
		ai_will_do = {
			factor = 1
		}
	}
	curtail_estate_vaisyas = {
		major = yes
		potential = {
			has_country_flag = estate_vaisyas_in_power
		}
		allow = {
			stability = 1
			NOT = { num_of_rebel_armies = 1 }
			NOT = { num_of_rebel_controlled_provinces = 1 }			
			NOT = {
				estate_influence = {
					estate = estate_vaisyas
					influence = 60
				}				
			}
		}
		effect = {
			add_stability = -3
			capital_scope = {
				add_base_tax = -1
				add_base_production = -1
			}
			clr_country_flag = estate_vaisyas_in_power
		}
		ai_will_do = {
			factor = 1
		}
	}
	curtail_estate_nomadic_tribes = {
		major = yes
		potential = {
			has_country_flag = estate_nomadic_tribes_in_power
		}
		allow = {
			stability = 1
			NOT = { num_of_rebel_armies = 1 }
			NOT = { num_of_rebel_controlled_provinces = 1 }			
			NOT = {
				estate_influence = {
					estate = estate_nomadic_tribes
					influence = 60
				}				
			}
		}
		effect = {
			add_stability = -3
			capital_scope = {
				add_base_tax = -1
				add_base_production = -1
			}
			clr_country_flag = estate_nomadic_tribes_in_power
		}
		ai_will_do = {
			factor = 1
		}
	}
	curtail_estate_jains = {
		major = yes
		potential = {
			has_country_flag = estate_jains_in_power
		}
		allow = {
			stability = 1
			NOT = { num_of_rebel_armies = 1 }
			NOT = { num_of_rebel_controlled_provinces = 1 }			
			NOT = {
				estate_influence = {
					estate = estate_jains
					influence = 60
				}				
			}
		}
		effect = {
			add_stability = -3
			capital_scope = {
				add_base_tax = -1
				add_base_production = -1
			}
			clr_country_flag = estate_jains_in_power
		}
		ai_will_do = {
			factor = 1
		}
	}
	cossack_nation = {
		major = yes
		potential = {
			tag = ZAZ
			NOT = { has_reform = cossacks_reform }
			has_dlc = "The Cossacks"
			NOT = { is_emperor_of_china = yes } 
			NOT = { is_revolutionary = yes }
		}
		allow = {
			stability = 0
			NOT = { government = dictatorship }
			NOT = { has_reform = presidential_despot_reform }
		}
		effect = {
			if = {
				limit = { NOT = { government = republic } }
				change_government = republic
			}
			add_government_reform = cossacks_reform
		}
		ai_will_do = {
			factor = 1
		}
	}
	gain_access_to_estate_dhimmi = {
		major = yes
		potential = {
			has_dlc = "The Cossacks"
			NOT = { has_estate = estate_dhimmi }
			NOT = { has_unlocked_estate = { estate = estate_dhimmi } }
			NOT = { has_government_attribute = is_merchant_republic }
			NOT = { has_reform = trading_city }
			NOT = { is_revolutionary_republic_trigger = yes }
			NOT = { government = native }
			NOT = { has_reform = siberian_tribe }
			NOT = { has_reform = cossacks_reform }
			NOT = { has_reform = veche_republic }
			NOT = { has_government_attribute = is_pirate_republic_reform }
			is_nomad = no
			is_colonial_nation = no
			NOT = { has_reform = celestial_empire }
			religion_group = muslim
			NOT = { has_reform = revolutionary_empire_reform }
		}
		allow = {
			stability = 1
			has_any_disaster = no
			NOT = { num_of_rebel_armies = 1 }
			NOT = { num_of_rebel_controlled_provinces = 1 }
			crown_land_share = 5
			if = {
				limit = {
					has_estate = estate_brahmins
				}
				estate_loyalty = {
					estate = estate_brahmins
					higher_than_influence = yes
				}
				NOT = {
					num_of_estate_privileges = {
						estate = estate_brahmins
						value = 1
					}
				}
				custom_trigger_tooltip = {
					tooltip = brahmin_estate_is_not_in_power_tt
					NOT = { has_country_flag = estate_brahmins_in_power }
				}
				num_of_owned_provinces_with = {
					NOT = { religion_group = muslim }
					NOT = { religion_group = dharmic }
					value = 1
				}
			}
			else = {
				num_of_owned_provinces_with = {
					NOT = { religion_group = muslim }
					value = 1
				}
			}
		}
		effect = {
			#custom_tooltip = gain_dhimmi_estate_tt
			unlock_estate = {
				estate = estate_dhimmi
			}
			if = {
				limit = {
					has_estate = estate_brahmins
				}
				custom_tooltip = lose_access_to_brahmins_tt
				add_stability = -4
			}
			hidden_effect = {
				country_event = {
					id = dhimmi_estate_events.10
					days = 7
				}
			}
		}
		ai_will_do = {
			factor = 1
		}
	}
	
	###China 1.35 Decisions###
	curtail_eunuch_estate_decision = {
		major = yes
		potential = { has_country_flag = estate_eunuchs_in_power }
		allow = {
			stability = 1
			NOT = { num_of_rebel_controlled_provinces = 1 }
		}
		effect = {
			add_stability = -3
			add_piety = -0.5
			add_karma = -25
			add_patriarch_authority = -0.25
			add_fervor = -25
			add_church_power = -100
			if = { 
				limit = { 
					OR = { 
						NOT = { 	
							estate_influence = {
								estate = estate_eunuchs 
								influence = 50 
							}
						}
						NOT = { 
							num_of_estate_privileges = {
								estate = estate_eunuchs 
								value = 1 
							}
						}
					}
				}
				clr_country_flag = estate_eunuchs_in_power
			}
			else_if = { 
				limit = { has_estate_privilege = estate_eunuchs_land_rights_privilege }
				remove_estate_privilege = estate_eunuchs_land_rights_privilege
			}
			else_if = { 
				limit = { has_estate_privilege = estate_eunuchs_allow_personal_fortunes_privilege }
				remove_estate_privilege = estate_eunuchs_allow_personal_fortunes_privilege
			}
			else_if = { 
				limit = { has_estate_privilege = estate_eunuchs_bookkeepers_privilege }
				remove_estate_privilege = estate_eunuchs_bookkeepers_privilege
				custom_tooltip = mng_eunuch_continue_stripping_privileges_tt
			}
			else_if = { 
				limit = { has_estate_privilege = estate_eunuchs_outwards_perfection_privilege }
				remove_estate_privilege = estate_eunuchs_outwards_perfection_privilege
			}
			else_if = { 
				limit = { has_estate_privilege = estate_eunuchs_palace_bureaucracy_privilege }
				remove_estate_privilege = estate_eunuchs_palace_bureaucracy_privilege
			}
			else_if = { 
				limit = { has_estate_privilege = estate_eunuchs_delegate_provincial_administration_privilege }
				remove_estate_privilege = estate_eunuchs_delegate_provincial_administration_privilege
			}
			else_if = { 
				limit = { has_estate_privilege = estate_eunuchs_imperial_council_privilege }
				remove_estate_privilege = estate_eunuchs_imperial_council_privilege
			}
			else_if = { 
				limit = { has_estate_privilege = estate_eunuchs_western_bureau_privilege }
				remove_estate_privilege = estate_eunuchs_western_bureau_privilege
			}
			else_if = { 
				limit = { has_estate_privilege = estate_eunuchs_eastern_bureau_privilege }
				remove_estate_privilege = estate_eunuchs_eastern_bureau_privilege
			}
			else_if = { 
				limit = { has_estate_privilege = estate_eunuchs_royal_intrigue_keepers_privilege }
				remove_estate_privilege = estate_eunuchs_royal_intrigue_keepers_privilege
			}
			else_if = { 
				limit = { has_estate_privilege = estate_eunuchs_promote_eunuch_rights }
				remove_estate_privilege = estate_eunuchs_promote_eunuch_rights
			}
			else_if = { 
				limit = { has_estate_privilege = estate_eunuchs_delegate_subject_diplomacy_privilege }
				remove_estate_privilege = estate_eunuchs_delegate_subject_diplomacy_privilege
			}
			else_if = { 
				limit = { has_estate_privilege = estate_eunuchs_supremacy_over_crown_privilege }
				remove_estate_privilege = estate_eunuchs_supremacy_over_crown_privilege
			}
			else_if = { 
				limit = { has_estate_privilege = estate_eunuchs_establish_favor_system_privilege }
				remove_estate_privilege = estate_eunuchs_establish_favor_system_privilege
			}
			else_if = { 
				limit = { has_estate_privilege = estate_eunuchs_single_whip_law_privilege }
				remove_estate_privilege = estate_eunuchs_single_whip_law_privilege
			}
			random_owned_province = {
				limit = { 
					same_continent = capital 
					controlled_by = ROOT 
				}
				spawn_rebels = {
					size = 3
					leader = noble_zealot
					type = religious_rebels
					win = yes 
				}
			}
			custom_tooltip = mng_every_sieged_province_rebels_10_mandate_lost_tt
		}
		ai_will_do = {
			factor = 1
		}
	}
	
	#1.36
	curtail_estate_qizilbash = {
		major = yes
		potential = {
			has_country_flag = estate_qizilbash_in_power
		}
		allow = {
			stability = 1
			NOT = { num_of_rebel_armies = 1 }
			NOT = { num_of_rebel_controlled_provinces = 1 }
			NOT = {
				estate_influence = {
					estate = estate_qizilbash
					influence = 60
				}				
			}
		}
		effect = {
			add_mil_power = -400
			add_army_tradition = -50
			add_army_professionalism = -5
			add_yearly_manpower = -3
			clr_country_flag = estate_qizilbash_in_power
		}
		ai_will_do = {
			factor = 1
		}
	}
	horse_breeding_decision = {
		potential = {
			has_unlocked_decision = { type = horse_breeding_decision }
			NOT = { has_country_flag = bred_a_new_war_steed }
		}
		allow = {
			has_global_modifier_value = {
				which = cavalry_power  
				value = 0.4
			}
			num_of_cavalry = 50 
			if = {
				limit = { has_dlc = "Cradle of Civilization" }
				OR = { 
					army_professionalism = 100
					army_tradition = 95 
				}
			}
			else = {
				army_tradition = 95 
			}
			num_of_owned_provinces_with = {
				trade_goods = livestock 
				has_manufactory_trigger = yes 
				base_production = 15 
				value = 1 
			}
		}
		effect = {
			custom_tooltip = horse_breeding_decision_ct
			hidden_effect = {
				country_event = { 
					id = flavor_per.54
					days = 3650 
				}
				set_country_flag = bred_a_new_war_steed
			}
		}
		ai_will_do = {
			factor = 10
		}
		ai_importance = 100
	}
}