﻿add_namespace = csa
add_namespace = csa_secession

# add_namespace = csa_secession ### MUST BE CHANGED TO csa.XXX

########################### Southern Secession Crisis ###############################
# South Carolina (start) > MS
# news_event = {
# 	id = csa_secession.1
# 	title = csa_secession.1.t
# 	desc = {
#     trigger = { has_country_flag = USA_LincolnElected }
#     text = csa_secession.1.d_lincoln
#   }
#   desc = {
#     trigger = { has_country_flag = USA_DouglasElected }
#     text = csa_secession.1.d_douglas
#   }
#   desc = {
#     trigger = { has_country_flag = USA_BellElected }
#     text = csa_secession.1.d_bell
#   }
# 	desc = {
#     trigger = { has_country_flag = USA_BreckinridgeElected }
#     text = csa_secession.1.d_beckenridge
#   }

# 	is_triggered_only = yes

# 	immediate = {
# 		hidden_effect = {
# 			CSA = {
# 				if = {
# 					limit = { NOT = { has_global_flag = CSA_NA_B_idea_working_class_exploitation_score_var_set_flag } }
# 					hidden_effect = {
# 						set_variable = { var = CSA.NA_B_idea_working_class_exploitation_score_var@CSA value = USA.NA_B_idea_working_class_exploitation_score_var@USA }
# 						set_variable = { var = CSA.NA_B_idea_working_class_organization_score_var@CSA value = USA.NA_B_idea_working_class_organization_score_var@USA }
# 						country_event = { id = balkanized_usa.10 }
# 					}
# 					set_global_flag = CSA_NA_B_idea_working_class_exploitation_score_var_set_flag
# 				}
# 			}
# 			if = {
# 				limit = {
# 					OR = {
# 						USA = { has_country_flag = USA_LincolnElected }
# 						USA = { has_country_flag = USA_BellElected }
# 					}
# 				}
# 				news_event = { id = csa_secession.2 days = 20 }
# 			}
# 			else_if = {
# 				limit = {
# 					OR = {
# 						USA = { has_country_flag = USA_DouglasElected }
# 						USA = { has_country_flag = USA_BreckinridgeElected }
# 					}
# 				}
# 				news_event = { id = csa_secession.2 days = 7 }
# 			}
# 		}
# 		if = {
# 			limit = { tag = USA }
# 			remove_state_core = 364
# 			add_state_claim = 364
# 			hidden_effect = {
# 				CSA = { news_event { id = csa_secession.1 hours = 2 } }
# 			}
# 		}
# 		if = {
# 			limit = { tag = CSA }
# 			add_state_core = 364
# 			hidden_effect = {
# 				USA = {
# 					set_variable = { rival_country = CSA.id }
# 				}
# 				CSA = {
# 					set_variable = { rival_country = USA.id }
# 				}
# 			}
# 		}
# 	}

# 	option = {
# 		name = csa_secession.1.a
# 		custom_effect_tooltip = 01_ACW_GENERIC_tt
# 		trigger = { tag = USA }
# 		ai_chance = { factor = 100 }
# 		hidden_effect = {
# 			news_event = { id = usa_news.6 }
# 			add_popularity = {
# 				ideology = traditional_conservatism
# 				popularity = -0-.15
# 			}
# 			add_popularity = {
# 				ideology = radical_democracy
# 				popularity = 0.10
# 			}
# 			CSA = {
# 				transfer_state = 364
# 				set_capital = 364
# 				inherit_technology = USA
# 				set_politics = { ruling_party = traditional_conservatism }
# 				add_popularity = {
# 					ideology = traditional_conservatism
# 					popularity = 0.63
# 				}
# 				if = { limit = { USA = { has_country_flag = USA_BreckinridgeElected } }
# 					create_country_leader = {
# 						name = "John C. Beckenridge"
# 						desc = "POLITICS_FRANKLIN_DELANO_ROOSEVELT_DESC"
# 						picture = "Portrait_CSA_John_Breckinridge.dds"
# 						expire = "1900.1.1"
# 						ideology = conserv
# 					}
# 				}
# 				else = {
# 					create_country_leader = {
# 						name = "Jefferson Davis"
# 						desc = "POLITICS_FRANKLIN_DELANO_ROOSEVELT_DESC"
# 						picture = "Portrait_CSA_Jefferson_Davis.dds"
# 						expire = "1900.1.1"
# 						ideology = conserv
# 					}
# 				}
# 			}
# 		}
# 	}
# 	option = {
# 		name = csa_secession.1.b
# 		custom_effect_tooltip = 02_ACW_GENERIC_tt
# 		trigger = { tag = USA }
# 		ai_chance = { factor = 100 }
# 		hidden_effect = {
# 			news_event = { id = usa_news.6 }
# 			add_popularity = {
# 				ideology = traditional_conservatism
# 				popularity = -0-.15
# 			}
# 			add_popularity = {
# 				ideology = radical_democracy
# 				popularity = 0.10
# 			}
# 			CSA = {
# 				transfer_state = 364
# 				set_capital = 364
# 				inherit_technology = USA
# 				set_politics = { ruling_party = traditional_conservatism }
# 				add_popularity = {
#   				ideology = traditional_conservatism
#   				popularity = 0.63
#   			}
# 				if = { limit = { USA = { has_country_flag = USA_BreckinridgeElected } }
# 					create_country_leader = {
# 						name = "John C. Beckenridge"
# 						desc = "POLITICS_FRANKLIN_DELANO_ROOSEVELT_DESC"
# 						picture = "Portrait_CSA_John_Breckinridge.dds"
# 						expire = "1900.1.1"
# 						ideology = conserv
# 					}
# 				}
# 				else = {
# 					create_country_leader = {
# 						name = "Jefferson Davis"
# 						desc = "POLITICS_FRANKLIN_DELANO_ROOSEVELT_DESC"
# 						picture = "Portrait_CSA_Jefferson_Davis.dds"
# 						expire = "1900.1.1"
# 						ideology = conserv
# 					}
# 				}
# 			}
# 			CSA = { change_tag_from = USA }
# 		}
# 	}

# 	option = {
# 		name = csa_secession.1.c
# 		trigger = { tag = CSA }
# 		CSA = { news_event { id = csa_secession.2 days = 20} }
# 	}
# }

# # Mississippi > FL, AL
# news_event = {
# 	id = csa_secession.2
# 	title = csa_secession.2.t
# 	desc = {
# 		trigger = {
# 			OR = {
# 				has_country_flag = USA_LincolnElected
# 				has_country_flag = USA_BellElected
# 			}
# 		}
# 		text = csa_secession.2.d
# 	}
# 	desc = {
# 	  trigger = { has_country_flag = USA_DouglasElected }
# 	  text = csa_secession.2.d_douglas
# 	}
# 	desc = {
# 		trigger = { has_country_flag = USA_BreckinridgeElected }
# 		text = csa_secession.2.d_beckenridge
# 	}

# 	picture = GFX_report_event_german_reichstag_gathering

# 	is_triggered_only = yes

# 	immediate = {
# 		hidden_effect = {
# 			if = {
# 				news_event = { id = csa_secession.3 days = 1 }
# 			}
# 			news_event = { id = csa_secession.4 days = 2 }
# 		}
# 		if = {
# 			limit = { tag = USA }
# 			remove_state_core = 370
# 			add_state_claim = 370
# 		}
# 		if = {
# 			limit = { tag = CSA }
# 			transfer_state = 370
# 			add_state_core = 370
# 		}
# 	}

# 	option = {
# 		name = csa_secession.2.a
# 		trigger = { tag = USA }
# 		add_popularity = {
# 			ideology = traditional_conservatism
# 			popularity = -0.01
# 		}
# 	}
# 	option = {
# 		name = csa_secession.2.b
# 		trigger = { tag = CSA }
# 	}
# }

# # Alabama > GA
# news_event = {
# 	id = csa_secession.4
# 	title = csa_secession.4.t
# 	desc = {
# 		trigger = {
# 			OR = {
# 				has_country_flag = USA_LincolnElected
# 				has_country_flag = USA_BellElected
# 			}
# 		}
# 		text = csa_secession.2.d
# 	}
# 	desc = {
# 	  trigger = { has_country_flag = USA_DouglasElected }
# 	  text = csa_secession.2.d_douglas
# 	}
# 	desc = {
# 		trigger = { has_country_flag = USA_BreckinridgeElected }
# 		text = csa_secession.2.d_beckenridge
# 	}
# 	picture = GFX_report_event_german_reichstag_gathering

# 	is_triggered_only = yes

# 	immediate = {
# 		hidden_effect = {
# 			if = {
# 				limit = {
# 					OR = {
# 						USA = { has_country_flag = USA_LincolnElected }
# 						USA = { has_country_flag = USA_BellElected }
# 					}
# 				}
# 				news_event = { id = csa_secession.5 days = 8 }
# 			}
# 			else_if = {
# 				limit = {
# 					OR = {
# 						USA = { has_country_flag = USA_DouglasElected }
# 						USA = { has_country_flag = USA_BreckinridgeElected }
# 					}
# 				}
# 				news_event = { id = csa_secession.5 days = 4 }
# 			}
# 		}
# 		if = {
# 			limit = { tag = USA }
# 			remove_state_core = 367
# 			add_state_claim = 367
# 		}
# 		if = {
# 			limit = { tag = CSA }
# 			transfer_state = 367
# 			add_state_core = 367
# 		}
# 	}

# 	option = {
# 		name = csa_secession.2.a
# 		trigger = { tag = USA }
# 		add_popularity = {
# 			ideology = traditional_conservatism
# 			popularity = -0.01
# 		}
# 	}
# 	option = {
# 		name = csa_secession.2.b
# 		trigger = { tag = CSA }
# 	}
# }

# # Georgia > LA
# news_event = {
# 	id = csa_secession.5
# 	title = csa_secession.5.t
# 	desc = {
# 		trigger = {
# 			OR = {
# 				has_country_flag = USA_LincolnElected
# 				has_country_flag = USA_BellElected
# 			}
# 		}
# 		text = csa_secession.2.d
# 	}
# 	desc = {
# 	  trigger = { has_country_flag = USA_DouglasElected }
# 	  text = csa_secession.2.d_douglas
# 	}
# 	desc = {
# 		trigger = { has_country_flag = USA_BreckinridgeElected }
# 		text = csa_secession.2.d_beckenridge
# 	}
# 	picture = GFX_report_event_german_reichstag_gathering

# 	is_triggered_only = yes

# 	immediate = {
# 		hidden_effect = {
# 			if = {
# 				limit = {
# 					OR = {
# 						USA = { has_country_flag = USA_LincolnElected }
# 						USA = { has_country_flag = USA_BellElected }
# 					}
# 				}
# 				news_event = { id = csa_secession.6 days = 7 }
# 			}
# 			else_if = {
# 				limit = {
# 					OR = {
# 						USA = { has_country_flag = USA_DouglasElected }
# 						USA = { has_country_flag = USA_BreckinridgeElected }
# 					}
# 				}
# 				news_event = { id = csa_secession.6 days = 4 }
# 			}
# 		}
# 		if = {
# 			limit = { tag = USA }
# 			remove_state_core = 365
# 			add_state_claim = 365
# 		}
# 		if = {
# 			limit = { tag = CSA }
# 			transfer_state = 365
# 			add_state_core = 365
# 			if = {
# 				limit = { USA = { NOT = { has_country_flag = USA_DouglasElected } } }
# 				hidden_effect = {
# 					load_oob = CSA_1861
# 				}
# 			}
# 		}
# 	}

# 	option = {
# 		name = csa_secession.2.a
# 		trigger = { tag = USA }
# 		add_popularity = {
# 			ideology = traditional_conservatism
# 			popularity = -0.01
# 		}
# 	}
# 	option = {
# 		name = csa_secession.2.b
# 		trigger = { tag = CSA }
# 	}
# }

# # LA > TX
# news_event = {
# 	id = csa_secession.6
# 	title = csa_secession.6.t
# 	desc = {
# 		trigger = {
# 			OR = {
# 				has_country_flag = USA_LincolnElected
# 				has_country_flag = USA_BellElected
# 			}
# 		}
# 		text = csa_secession.2.d
# 	}
# 	desc = {
# 	  trigger = { has_country_flag = USA_DouglasElected }
# 	  text = csa_secession.2.d_douglas
# 	}
# 	desc = {
# 		trigger = { has_country_flag = USA_BreckinridgeElected }
# 		text = csa_secession.2.d_beckenridge
# 	}
# 	picture = GFX_report_event_german_reichstag_gathering

# 	is_triggered_only = yes

# 	immediate = {
# 		hidden_effect = {
# 			if = {
# 				limit = { USA = { has_country_flag = USA_DouglasElected } }
# 				news_event = { id = csa_secession.10 days = 15 }
# 			}
# 			else = {
# 				news_event = { id = csa_secession.7 days = 5 }
# 			}
# 		}
# 		if = {
# 			limit = { tag = USA }
# 			remove_state_core = 371
# 			add_state_claim = 371
# 		}
# 		if = {
# 			limit = { tag = CSA }
# 			transfer_state = 371
# 			add_state_core = 371
# 		}
# 	}

# 	option = {
# 		name = csa_secession.2.a
# 		trigger = { tag = USA }
# 		add_popularity = {
# 			ideology = traditional_conservatism
# 			popularity = -0.01
# 		}
# 	}
# 	option = {
# 		name = csa_secession.2.b
# 		trigger = { tag = CSA }
# 	}
# }

# # TX > Houston, MO, VA, (Sumter)
# news_event = {
# 	id = csa_secession.7
# 	title = csa_secession.7.t
# 	desc = {
# 		trigger = {
# 			OR = {
# 				has_country_flag = USA_LincolnElected
# 				has_country_flag = USA_BellElected
# 			}
# 		}
# 		text = csa_secession.2.d
# 	}
# 	desc = {
# 	  trigger = { has_country_flag = USA_DouglasElected }
# 	  text = csa_secession.2.d_douglas
# 	}
# 	desc = {
# 		trigger = { has_country_flag = USA_BreckinridgeElected }
# 		text = csa_secession.2.d_beckenridge
# 	}
# 	picture = GFX_report_event_german_reichstag_gathering

# 	is_triggered_only = yes

# 	immediate = {
# 		hidden_effect = {
# 			if = {
# 				limit = {
# 					USA = { has_country_flag = USA_BreckinridgeElected }
# 				}
# 				if = {
# 					limit = { tag = CSA }
# 					country_event = { id = acw_generic.2 days = 30 }
# 				}
# 				news_event = { id = csa_secession.8 days = 20 }
# 			}
# 			else_if = {
# 				limit = {
# 					OR = {
# 						USA = { has_country_flag = USA_BellElected }
# 						USA = { has_country_flag = USA_LincolnElected }
# 						USA = { has_country_flag = USA_DouglasElected }
# 					}
# 				}
# 				if = {
# 					limit = {
# 						tag = CSA
# 						NOT = { has_country_flag = USA_DouglasElected }
# 					}
# 					country_event = { id = acw_generic.2 days = 70 }
# 				}
# 				news_event = { id = csa_secession.9 days = 48 }
# 			}
# 		}
# 		if = {
# 			limit = { tag = USA }
# 			remove_state_core = 375
# 			add_state_claim = 375
# 		}
# 		if = {
# 			limit = { tag = CSA }
# 			transfer_state = 375
# 			add_state_core = 375
# 		}
# 	}

# 	option = {
# 		name = csa_secession.2.a
# 		trigger = { tag = USA }
# 		add_stability = -0.05
# 		add_popularity = {
# 			ideology = traditional_conservatism
# 			popularity = -0.05
# 		}
# 		hidden_effect = {
# 			if = {
# 				# Houston Revolt
# 				limit = { has_country_flag = USA_Houston_Revolt_Marked }
# 				country_event = { id = acw.60 days = 15 }
# 			}
# 		}
# 	}
# 	option = {
# 		name = csa_secession.2.b
# 		trigger = { tag = CSA }
# 		add_war_support = 0.05
# 	}
# }

# # Missouri Leaves
# news_event = {
# 	id = csa_secession.8
# 	title = csa_secession.8.t
# 	desc = csa_secession.2.d_beckenridge
# 	picture = GFX_report_event_german_reichstag_gathering

# 	is_triggered_only = yes

# 	immediate = {
# 		hidden_effect = {
# 			news_event = { id = csa_secession.10 days = 14 }
# 		}
# 		if = {
# 			limit = { tag = USA }
# 			remove_state_core = 373
# 			add_state_claim = 373
# 		}
# 		if = {
# 			limit = { tag = CSA }
# 			transfer_state = 373
# 			add_state_core = 373
# 		}
# 	}

# 	option = {
# 		name = csa_secession.2.a
# 		trigger = { tag = USA }
# 		add_popularity = {
# 			ideology = traditional_conservatism
# 			popularity = -0.01
# 		}
# 	}
# 	option = {
# 		name = csa_secession.2.b
# 		trigger = { tag = CSA }
# 	}
# }

# # Missouri Stays
# news_event = {
# 	id = csa_secession.9
# 	title = csa_secession.9.t
# 	desc = {
# 		trigger = { NOT = { USA = { has_country_flag = USA_DouglasElected } } }
# 		text = csa_secession.9.d
# 	}
# 	desc = {
# 	  trigger = { has_country_flag = USA_DouglasElected }
# 	  text = csa_secession.2.d_douglas
# 	}
# 	picture = GFX_report_event_generic_riot

# 	is_triggered_only = yes

# 	immediate = {
# 		hidden_effect = {
# 			news_event = { id = csa_secession.10 days = 27 }
# 		}
# 		if = {
# 			limit = { tag = CSA }
# 			add_state_claim = 373
# 		}
# 	}

# 	option = {
# 		name = csa_secession.9.a
# 		trigger = { tag = USA }
# 	}
# 	option = {
# 		name = csa_secession.2.a
# 		trigger = { tag = CSA }
# 	}
# }

# # Virginia Leaves
# news_event = {
# 	id = csa_secession.10
# 	title = csa_secession.10.t
# 	desc = {
# 		trigger = {
# 			OR = {
# 				has_country_flag = USA_LincolnElected
# 				has_country_flag = USA_BellElected
# 			}
# 		}
# 		text = csa_secession.2.d
# 	}
# 	desc = {
# 	  trigger = { has_country_flag = USA_DouglasElected }
# 	  text = csa_secession.2.d_douglas
# 	}
# 	desc = {
# 		trigger = { has_country_flag = USA_BreckinridgeElected }
# 		text = csa_secession.2.d_beckenridge
# 	}
# 	picture = GFX_report_event_german_reichstag_gathering

# 	is_triggered_only = yes

# 	immediate = {
# 		hidden_effect = {
# 			if = {
# 				limit = {
# 					OR = {
# 						USA = { has_country_flag = USA_DouglasElected }
# 						USA = { has_country_flag = USA_BreckinridgeElected }
# 					}
# 				}
# 				news_event = { id = csa_secession.11 days = 8 }
# 			}
# 			else_if = {
# 				limit = {
# 					OR = {
# 						USA = { has_country_flag = USA_BellElected }
# 						USA = { has_country_flag = USA_LincolnElected }
# 					}
# 				}
# 				news_event = { id = csa_secession.11 days = 20 }
# 			}
# 		}
# 		if = {
# 			limit = { tag = USA }
# 			remove_state_core = 362
# 			add_state_claim = 362
# 			if = {
# 				limit = { NOT = { USA = { has_country_flag = USA_DouglasElected } } }
# 				remove_state_core = 746
# 				add_state_claim = 746
# 			}
# 		}
# 		if = {
# 			limit = { tag = CSA }
# 			transfer_state = 362
# 			add_state_core = 362
# 			if = {
# 				limit = { USA = { NOT = { has_country_flag = USA_DouglasElected } } }
# 				transfer_state = 746
# 				add_state_core = 746
# 			}
# 			hidden_effect = {
# 				362 = { set_demilitarized_zone = no }
# 				746 = { set_demilitarized_zone = no }
# 			}
# 		}
# 	}

# 	option = {
# 		name = csa_secession.2.a
# 		trigger = { tag = USA }
# 		add_popularity = {
# 			ideology = traditional_conservatism
# 			popularity = -0.01
# 		}
# 	}
# 	option = {
# 		name = csa_secession.2.b
# 		trigger = { tag = CSA }
# 	}
# }

# # Arkansas Leaves
# news_event = {
# 	id = csa_secession.11
# 	title = csa_secession.11.t
# 	desc = {
# 		trigger = {
# 			OR = {
# 				has_country_flag = USA_LincolnElected
# 				has_country_flag = USA_BellElected
# 			}
# 		}
# 		text = csa_secession.2.d
# 	}
# 	desc = {
# 	  trigger = { has_country_flag = USA_DouglasElected }
# 	  text = csa_secession.2.d_douglas
# 	}
# 	desc = {
# 		trigger = { has_country_flag = USA_BreckinridgeElected }
# 		text = csa_secession.2.d_beckenridge
# 	}
# 	picture = GFX_report_event_german_reichstag_gathering

# 	is_triggered_only = yes

# 	immediate = {
# 		hidden_effect = {
# 			if = {
# 				limit = {
# 					OR = {
# 						USA = { has_country_flag = USA_DouglasElected }
# 						USA = { has_country_flag = USA_BreckinridgeElected }
# 					}
# 				}
# 				news_event = { id = csa_secession.12 days = 7 }
# 			}
# 			else_if = {
# 				limit = {
# 					OR = {
# 						USA = { has_country_flag = USA_BellElected }
# 						USA = { has_country_flag = USA_LincolnElected }
# 					}
# 				}
# 				news_event = { id = csa_secession.12 days = 11 }
# 			}
# 		}
# 		if = {
# 			limit = { tag = USA }
# 			remove_state_core = 372
# 			add_state_claim = 372
# 		}
# 		if = {
# 			limit = { tag = CSA }
# 			transfer_state = 372
# 			add_state_core = 372
# 			hidden_effect = {
# 				372 = { set_demilitarized_zone = no }
# 				if = {
# 					limit = { owns_state = 373 }
# 					373 = { set_demilitarized_zone = no }
# 				}
# 			}
# 		}
# 	}

# 	option = {
# 		name = csa_secession.2.a
# 		trigger = { tag = USA }
# 		add_popularity = {
# 			ideology = traditional_conservatism
# 			popularity = -0.01
# 		}
# 	}
# 	option = {
# 		name = csa_secession.2.b
# 		trigger = { tag = CSA }
# 	}
# }

# # North Carolina
# news_event = {
# 	id = csa_secession.12
# 	title = csa_secession.12.t
# 	desc = {
# 		trigger = {
# 			OR = {
# 				has_country_flag = USA_LincolnElected
# 				has_country_flag = USA_BellElected
# 			}
# 		}
# 		text = csa_secession.2.d
# 	}
# 	desc = {
# 	  trigger = { has_country_flag = USA_DouglasElected }
# 	  text = csa_secession.2.d_douglas
# 	}
# 	desc = {
# 		trigger = { has_country_flag = USA_BreckinridgeElected }
# 		text = csa_secession.2.d_beckenridge
# 	}
# 	picture = GFX_report_event_german_reichstag_gathering

# 	is_triggered_only = yes

# 	immediate = {
# 		hidden_effect = {
# 			if = {
# 				limit = {
# 					OR = {
# 						USA = { has_country_flag = USA_DouglasElected }
# 						USA = { has_country_flag = USA_BreckinridgeElected }
# 					}
# 				}
# 				news_event = { id = csa_secession.13 days = 6 }
# 			}
# 			else_if = {
# 				limit = {
# 					OR = {
# 						USA = { has_country_flag = USA_BellElected }
# 						USA = { has_country_flag = USA_LincolnElected }
# 					}
# 				}
# 				news_event = { id = csa_secession.13 days = 14 }
# 			}
# 		}
# 		if = {
# 			limit = { tag = USA }
# 			remove_state_core = 363
# 			add_state_claim = 363
# 		}
# 		if = {
# 			limit = { tag = CSA }
# 			transfer_state = 363
# 			add_state_core = 363
# 			set_capital = 362
# 			hidden_effect = {
# 				362 = { set_demilitarized_zone = no }
# 				363 = { set_demilitarized_zone = no }
# 			}
# 		}
# 	}

# 	option = {
# 		name = csa_secession.2.a
# 		trigger = { tag = USA }
# 		add_popularity = {
# 			ideology = traditional_conservatism
# 			popularity = -0.01
# 		}
# 	}
# 	option = {
# 		name = csa_secession.2.b
# 		trigger = { tag = CSA }
# 	}
# }

# # Tennessee >KTY
# news_event = {
# 	id = csa_secession.13
# 	title = csa_secession.13.t
# 	desc = {
# 		trigger = {
# 			OR = {
# 				has_country_flag = USA_LincolnElected
# 				has_country_flag = USA_BellElected
# 			}
# 		}
# 		text = csa_secession.2.d
# 	}
# 	desc = {
# 	  trigger = { has_country_flag = USA_DouglasElected }
# 	  text = csa_secession.2.d_douglas
# 	}
# 	desc = {
# 		trigger = { has_country_flag = USA_BreckinridgeElected }
# 		text = csa_secession.2.d_beckenridge
# 	}
# 	picture = GFX_report_event_german_reichstag_gathering

# 	is_triggered_only = yes

# 	immediate = {
# 		hidden_effect = {
# 			if = {
# 				limit = {
# 					USA = { has_country_flag = USA_BreckinridgeElected }
# 				}
# 				news_event = { id = csa_secession.14 days = 2 }
# 			}
# 			else_if = {
# 				limit = {
# 					OR = {
# 						USA = { has_country_flag = USA_BellElected }
# 						USA = { has_country_flag = USA_LincolnElected }
# 					}
# 				}
# 				news_event = { id = csa_secession.15 days = 5 }
# 			}
# 			else_if = {
# 				limit = { USA = { has_country_flag = USA_DouglasElected } }
# 				news_event = { id = csa_secession.17 days = 14 }
# 			}
# 		}
# 		if = {
# 			limit = { tag = USA }
# 			remove_state_core = 368
# 			add_state_claim = 368
# 		}
# 		if = {
# 			limit = { tag = CSA }
# 			transfer_state = 368
# 			add_state_core = 368
# 			hidden_effect = {
# 				368 = { set_demilitarized_zone = no }
# 			}
# 		}
# 	}

# 	option = {
# 		name = csa_secession.2.a
# 		trigger = { tag = USA }
# 		add_popularity = {
# 			ideology = traditional_conservatism
# 			popularity = -0.01
# 		}
# 	}
# 	option = {
# 		name = csa_secession.2.b
# 		trigger = { tag = CSA }
# 	}
# }

# # Kentucky Leaves
# news_event = {
# 	id = csa_secession.14
# 	title = csa_secession.14.t
# 	desc = csa_secession.2.d_beckenridge
# 	picture = GFX_report_event_german_reichstag_gathering

# 	is_triggered_only = yes

# 	immediate = {
# 		news_event = { id = csa_secession.16 days = 7 }
# 		if = {
# 			limit = { tag = USA }
# 			remove_state_core = 369
# 			add_state_claim = 369
# 		}
# 		if = {
# 			limit = { tag = CSA }
# 			transfer_state = 373
# 			add_state_core = 373
# 			hidden_effect = {
# 				373 = { set_demilitarized_zone = no }
# 			}
# 		}
# 	}

# 	option = {
# 		name = csa_secession.2.a
# 		trigger = { tag = USA }
# 		add_popularity = {
# 			ideology = traditional_conservatism
# 			popularity = -0.01
# 		}
# 	}
# 	option = {
# 		name = csa_secession.2.b
# 		trigger = { tag = CSA }
# 	}
# }

# # Kentucky Stays
# news_event = {
# 	id = csa_secession.15
# 	title = csa_secession.15.t
# 	desc = {
# 		text = csa_secession.9.d
# 		trigger = { NOT = { has_country_flag = USA_DouglasElected } }
# 	}
# 	desc = {
# 	  trigger = { has_country_flag = USA_DouglasElected }
# 	  text = csa_secession.2.d_douglas
# 	}
# 	picture = GFX_report_event_generic_riot

# 	is_triggered_only = yes

# 	immediate = {
# 		news_event = { id = csa_secession.16 days = 11 }
# 		if = {
# 			limit = { tag = CSA }
# 			add_state_claim = 369
# 		}
# 	}

# 	option = {
# 		name = csa_secession.9.a
# 		trigger = { tag = USA }
# 		add_popularity = {
# 			ideology = traditional_conservatism
# 			popularity = 0.01
# 		}
# 	}
# 	option = {
# 		name = csa_secession.2.a
# 		trigger = { tag = CSA }
# 	}
# }

# # Maryland & Delaware Stays
# news_event = {
# 	id = csa_secession.16
# 	title = csa_secession.16.t
# 	desc = csa_secession.2.d
# 	picture = GFX_report_event_generic_riot

# 	is_triggered_only = yes

# 	immediate = {
# 		hidden_effect = {
# 			if = {
# 				limit = { tag = USA }
# 				news_event = { id = csa_secession.17 }
# 			}
# 		}
# 		if = {
# 			limit = { tag = CSA }
# 			add_state_claim = 369
# 			if = {
# 				limit = { USA = { has_country_flag = USA_BreckinridgeElected } }
# 				add_state_core = 1091
# 			}
# 		}
# 	}

# 	option = {
# 		name = csa_secession.9.a
# 		trigger = { tag = USA }
# 	}
# 	option = {
# 		name = csa_secession.2.a
# 		trigger = { tag = CSA }
# 	}
# }

# # Cuba Secedes
# news_event = {
# 	id = csa_secession.17
# 	title = csa_secession.17.t
# 	desc = {
# 		trigger = {
# 			OR = {
# 				has_country_flag = USA_LincolnElected
# 				has_country_flag = USA_BellElected
# 			}
# 		}
# 		text = csa_secession.2.d
# 	}
# 	desc = {
# 	  trigger = { has_country_flag = USA_DouglasElected }
# 	  text = csa_secession.2.d_douglas
# 	}
# 	desc = {
# 		trigger = { has_country_flag = USA_BreckinridgeElected }
# 		text = csa_secession.2.d_beckenridge
# 	}

# 	is_triggered_only = yes
# 	trigger = {
# 		USA = {
# 			OR = {
# 				owns_state = 315
# 				owns_state = 1022
# 			}
# 		}
# 	}

# 	immediate = {
# 		if = {
# 			limit = { tag = USA }
# 			if = {
# 				limit = { owns_state = 315 }
# 				remove_state_core = 315
# 				add_state_claim = 315
# 			}
# 			if = {
# 				limit = { owns_state = 1022 }
# 				remove_state_core = 1022
# 				add_state_claim = 1022
# 			}
# 		}
# 		if = {
# 			limit = { tag = CSA }
# 			random_list = {
# 				68 = {
# 					# Cuba joins with CSA
# 					if = {
# 						limit = { USA = { owns_state = 315 } }
# 						remove_state_core = 315
# 						add_state_claim = 315
# 					}
# 					if = {
# 						limit = { USA = { owns_state = 1022 } }
# 						remove_state_core = 1022
# 						add_state_claim = 1022
# 					}
# 				}
# 				32 = {
# 					# Cuba fights for Independence
# 					add_state_claim = 315
# 					CUB = {
# 						if = {
# 							limit = { USA = { owns_state = 315 } }
# 							remove_state_core = 315
# 							add_state_claim = 315
# 						}
# 						if = {
# 							limit = { USA = { owns_state = 1022 } }
# 							remove_state_core = 1022
# 							add_state_claim = 1022
# 						}
# 						declare_war_on = {
# 							target = CSA
# 							type = acw_civil_war_wargoal
# 						}
# 					}
# 				}
# 			}
# 		}
# 	}

# 	option = {
# 		name = csa_secession.2.a
# 		trigger = { tag = USA }
# 	}
# 	option = {
# 		name = csa_secession.2.b
# 		trigger = { tag = CSA }
# 	}
# }

# Entire South Secedes (usa.126)
country_event = {
	id = csa_secession.20
	title = csa_secession.20.t
	desc = csa_secession.20.d
	picture = GFX_report_event_usa_secession

	fire_only_once = yes
	is_triggered_only = yes

	immediate = {
		hidden_effect = {
			add_popularity = {
				ideology = traditional_conservatism
				popularity = -0.19
			}
			ROOT = {
				remove_ideas = USA_Spirit_Southern_Secession_Crisis
				if = {
					limit = { NOT = { has_country_flag = USA_LincolnorDouglas_Moderate_Appeal } }
					remove_state_core = 746
					add_state_claim = 746
				}
				remove_state_core = 362
				add_state_claim = 362
				remove_state_core = 363
				add_state_claim = 363
				remove_state_core = 364
				add_state_claim = 364
				remove_state_core = 365
				add_state_claim = 365
				if = {
					limit = { owns_state = 366 }
					remove_state_core = 366
					add_state_claim = 366
				}
				remove_state_core = 367
				add_state_claim = 367
				remove_state_core = 368
				add_state_claim = 368
				remove_state_core = 370
				add_state_claim = 370
				remove_state_core = 371
				add_state_claim = 371
				remove_state_core = 372
				add_state_claim = 372
				if = {
					limit = {	owns_state = 315 }
					remove_state_core = 315
					add_state_claim = 315
				}
				if = {
					limit = {	owns_state = 1022 }
					remove_state_core = 1022
					add_state_claim = 1022
				}
				if = {
					limit = {	owns_state = 1350 }
					remove_state_core = 1350
					add_state_claim = 1350
				}
			}
			CSA = {
				if = {
					limit = { NOT = { has_global_flag = CSA_NA_B_idea_working_class_exploitation_score_var_set_flag } }
					hidden_effect = {
						set_variable = { var = CSA.NA_B_idea_working_class_exploitation_score_var@CSA value = USA.NA_B_idea_working_class_exploitation_score_var@USA }
						set_variable = { var = CSA.NA_B_idea_working_class_organization_score_var@CSA value = USA.NA_B_idea_working_class_organization_score_var@USA }
						country_event = { id = balkanized_usa.10 }
					}
					set_global_flag = CSA_NA_B_idea_working_class_exploitation_score_var_set_flag
				}
				if = {
					limit = { NOT = { USA = { has_country_flag = USA_LincolnorDouglas_Moderate_Appeal } } }
					transfer_state = 746
					add_state_core = 746
				}
				transfer_state = 362
				add_state_core = 362
				transfer_state = 363
				add_state_core = 363
				transfer_state = 364
				add_state_core = 364
				transfer_state = 365
				add_state_core = 365
				if = {
					limit = { ROOT = { owns_state = 366 } }
					transfer_state = 366
					add_state_core = 366
				}
				transfer_state = 367
				add_state_core = 367
				transfer_state = 368
				add_state_core = 368
				transfer_state = 370
				add_state_core = 370
				transfer_state = 371
				add_state_core = 371
				transfer_state = 372
				add_state_core = 372
				inherit_technology = USA
				country_event = { id = balkanized_usa.6 days = 2 }
				if = {
					limit = { NOT = { has_global_flag = NA_B_test_cuba_free } }
					if = {
						limit = {	ROOT = { owns_state = 315 } }
						transfer_state = 315
						add_state_core = 315
					}
					if = {
						limit = {	ROOT = { owns_state = 1022 } }
						transfer_state = 1022
						add_state_core = 1022
					}
					if = {
						limit = {	ROOT = { owns_state = 1350 } }
						transfer_state = 1350
						add_state_core = 1350
					}
				}
				else = {
					if = {
						limit = {	ROOT = { owns_state = 315 } }
						CUB = {
							transfer_state = 315
							add_state_core = 315
						}
					}
					if = {
						limit = {	ROOT = { owns_state = 1022 } }
						CUB = {
							transfer_state = 1022
							add_state_core = 1022
						}
					}
					if = {
						limit = {	ROOT = { owns_state = 1350 } }
						CUB = {
							transfer_state = 1350
							add_state_core = 1350
						}
					}
					CUB = {
						country_event = { id = balkanized_usa.6 days = 2 }
					}
				}
			}
		}
	}

	option = {
		name = acw_generic.62.a
	}
	option = {
		name = acw_generic.62.b
		trigger = { is_ai = no }
		hidden_effect = {
			CSA = { change_tag_from  = ROOT }
		}
	}
}

# CSA Troops
country_event = {
	id = csa.1
	title = csa.1.t
	desc = csa.1.d

	picture = GFX_report_event_german_reichstag_gathering
	fire_only_once = yes
	is_triggered_only = yes
	trigger = { tag = CSA }

	immediate = {
		load_oob = CSA_1861
	}

	option = {
		name = csa.1.a
	}
}

# Texas
country_event = {
	id = csa.6
	title = csa.6.t
	desc = csa.6.d
	picture = GFX_report_event_german_reichstag_gathering

	is_triggered_only = yes

	option = {
		name = csa.1.a
		trigger = { tag = USA }

		hidden_effect = {
			CSA = {
				transfer_state = 375
				add_state_core = 375
				country_event = { id = csa.6 }
			}
	  	remove_state_core = 375
	  	add_state_claim = 375

			add_popularity = {
				ideology = traditional_conservatism
				popularity = -0.05
			}
		}
  	hidden_effect = {
  		if = {
  			limit = {
  				USA = { has_country_flag = USA_Houston_Revolt_Marked }
  			}
  			USA = { country_event = { id = acw.60 days = 5 } } # Houston Revolt
  		}
  	}
		hidden_effect = {
			if = {
				limit = {
					USA = { has_country_flag = USA_Radical_Coup }
				}
				USA = { country_event = { hours = 15 id = acw_beckenridge.7 } }
				USA = { country_event = { days = 2 id = acw_beckenridge.10 } } # Hamlin Revolt
				USA = { add_stability = -0.1 }
		    USA = { country_event = { id = acw_beckenridge.7 hours = 12 } }
			}
			else = {
				USA = { country_event = { days = 5 id = csa.7 } }
			}
		}
	}
	option = {
		trigger = {
			tag = CSA
		}
		name = csa.6.b
	}
}

# Refusal of Access
country_event = {
	id = csa.7
	title = csa.7.t
	desc = csa.7.d
	picture = GFX_report_event_german_reichstag_gathering

	fire_only_once = yes

	is_triggered_only = yes

	option = {
		name = csa.7.a
		363 = { set_demilitarized_zone = yes }
		362 = { set_demilitarized_zone = yes }
		368 = { set_demilitarized_zone = yes }
		372 = { set_demilitarized_zone = yes }
		369 = { set_demilitarized_zone = yes }
		373 = { set_demilitarized_zone = yes }
		374 = { set_demilitarized_zone = yes }
		746 = { set_demilitarized_zone = yes }
	}
}

# Flag Referendum
country_event = {
	id = csa.11
	title = csa.11.t
	desc = csa.11.d
	picture = GFX_report_event_german_reichstag_gathering

	fire_only_once = yes
	trigger = { tag = CSA NOT = { has_global_flag = GER_ACW_SUPEREVENT_FLAG } }
	mean_time_to_happen = { days = 20 }

	option = {
		name = csa.11.a
		ai_chance = { base = 25 }
		hidden_effect = { set_cosmetic_tag = CSA_stars_and_bars }
 	}
 	option = {
		name = csa.11.b
		hidden_effect = { set_cosmetic_tag = CSA_battle_flag }
		ai_chance = { base = 25 }
 	}
 	option = {
		name = csa.11.c
		hidden_effect = { set_cosmetic_tag = CSA_blood_stained_banner }
		ai_chance = { base = 25 }
 	}
 	option = {
		name = csa.11.e
		ai_chance = { base = 25 }
 	}
}

# Convention Path Choice
country_event = {
	id = csa.13
	title = csa.13.t
	desc = csa.13.d
	picture = GFX_report_event_german_reichstag_gathering

	is_triggered_only = yes

	fire_only_once = yes

	option = {
		name = csa.13.a
		trigger = {
			check_variable = {
				var = CSA_convention
				value = 2
				compare = less_than_or_equals
			}
		}
		set_country_flag = CSA_convention_confederation_path
 	}
 	option = {
		name = csa.13.b
		trigger = {
			check_variable = {
				var = CSA_convention
				value = 2
				compare = greater_than
			}
			check_variable = {
				var = CSA_convention
				value = 8
				compare = less_than
			}
		}
		set_country_flag = CSA_convention_federalism_path
	}
	option = {
		name = csa.13.c
		trigger = {
			check_variable = {
				var = CSA_convention
				value = 8
				compare = greater_than_or_equals
			}
		}
		set_country_flag = CSA_convention_unitarian_path
	}
}

#Right to Secede
country_event = {
	id = csa.14
	title = csa.14.t
	desc = csa.14.d
	picture = GFX_report_event_german_reichstag_gathering

	is_triggered_only = yes

	fire_only_once = yes

	option = {
		name = csa.14.a
		add_stability = -0.05
		add_political_power = 25
		set_country_flag = CSA_secession_legal
		custom_effect_tooltip = CSA_convention_drift_confed
		subtract_from_variable = {
			var = CSA_convention
			value = 2
		}
		hidden_effect = { CSA = { set_country_flag = CSA_right_to_secede_state_flag } }
		hidden_effect = {
			if = {
				limit = {
					has_completed_focus = CSA_convention_taxation
					has_completed_focus = CSA_convention_trade_of_slaves
					has_completed_focus = CSA_convention_commerce_clause
					has_completed_focus = CSA_convention_landowner_elite
					has_completed_focus = CSA_convention_right_to_secede
				}
				country_event = { id = csa.13 hours = 1 }
			}
		}
 	}
 	option = {
		name = csa.14.b
		add_stability = 0.05
		add_political_power = -25
		reverse_add_opinion_modifier = {
			target = USA
			modifier = CSA_hypocritical
		}
		add_to_variable = {
			var = CSA_convention
			value = 2
		}
		custom_effect_tooltip = CSA_convention_drift_central
		set_country_flag = CSA_secession_illegal
		hidden_effect = { CSA = { set_country_flag = CSA_right_to_secede_federal_flag } }
		hidden_effect = {
			if = {
				limit = {
					has_completed_focus = CSA_convention_taxation
					has_completed_focus = CSA_convention_trade_of_slaves
					has_completed_focus = CSA_convention_commerce_clause
					has_completed_focus = CSA_convention_landowner_elite
					has_completed_focus = CSA_convention_right_to_secede
				}
				country_event = { id = csa.13 hours = 1 }
			}
		}
	}
}

#Landowner Elite
country_event = {
	id = csa.15
	title = csa.15.t
	desc = csa.15.d
	picture = GFX_report_event_german_reichstag_gathering

	is_triggered_only = yes

	fire_only_once = yes

	option = {
		name = csa.15.a
		hidden_effect = {
			add_timed_idea = {
				idea = CSA_aristocrats_encouraged
				days = 720
			}
			hidden_effect = {
				add_to_variable = { var = ROOT.NA_B_idea_working_class_exploitation_score_var@ROOT value = 1 }
				add_to_variable = { var = ROOT.NA_B_idea_working_class_organization_score_var@ROOT value = -3 }
				country_event = { id = balkanized_usa.10 } 
			}
		}
		subtract_from_variable = {
			var = CSA_convention
			value = 2
		}
		custom_effect_tooltip = CSA_convention_drift_confed
		hidden_effect = { CSA = { set_country_flag = CSA_landowner_elite_state_flag } }
		hidden_effect = {
			if = {
				limit = {
					has_completed_focus = CSA_convention_taxation
					has_completed_focus = CSA_convention_trade_of_slaves
					has_completed_focus = CSA_convention_commerce_clause
					has_completed_focus = CSA_convention_landowner_elite
					has_completed_focus = CSA_convention_right_to_secede
				}
				country_event = { id = csa.13 hours = 1 }
			}
		}
 	}
 	option = {
		name = csa.15.b
		hidden_effect = { CSA = { set_country_flag = CSA_landowner_elite_mix_flag } }
		hidden_effect = {
			if = {
				limit = {
					has_completed_focus = CSA_convention_taxation
					has_completed_focus = CSA_convention_trade_of_slaves
					has_completed_focus = CSA_convention_commerce_clause
					has_completed_focus = CSA_convention_landowner_elite
					has_completed_focus = CSA_convention_right_to_secede
				}
				country_event = { id = csa.13 hours = 1 }
			}
		}
	}
	option = {
		name = csa.15.c
		hidden_effect = {
			add_timed_idea = {
				idea = CSA_aristocrats_discouraged
				days = 720
			}
			hidden_effect = {
				add_to_variable = { var = ROOT.NA_B_idea_working_class_exploitation_score_var@ROOT value = -1 }
				add_to_variable = { var = ROOT.NA_B_idea_working_class_organization_score_var@ROOT value = 3 }
				country_event = { id = balkanized_usa.10 } 
			}
		}
		add_to_variable = {
			var = CSA_convention
			value = 2
		}
		custom_effect_tooltip = CSA_convention_drift_central
		hidden_effect = { CSA = { set_country_flag = CSA_landowner_elite_federal_flag } }
		hidden_effect = {
			if = {
				limit = {
					has_completed_focus = CSA_convention_taxation
					has_completed_focus = CSA_convention_trade_of_slaves
					has_completed_focus = CSA_convention_commerce_clause
					has_completed_focus = CSA_convention_landowner_elite
					has_completed_focus = CSA_convention_right_to_secede
				}
				country_event = { id = csa.13 hours = 1 }
			}
		}
	}
}

#Commerce Clause
country_event = {
	id = csa.16
	title = csa.16.t
	desc = csa.16.d
	picture = GFX_report_event_german_reichstag_gathering

	is_triggered_only = yes

	fire_only_once = yes

	option = {
		name = csa.16.a
		swap_ideas = {
			add_idea = free_trade
			remove_idea = export_focus
		}
		subtract_from_variable = {
			var = CSA_convention
			value = 2
		}
		hidden_effect = { CSA = { set_country_flag = CSA_commerce_clause_state_flag } }
		custom_effect_tooltip = CSA_convention_drift_confed
		hidden_effect = {
			if = {
				limit = {
					has_completed_focus = CSA_convention_taxation
					has_completed_focus = CSA_convention_trade_of_slaves
					has_completed_focus = CSA_convention_commerce_clause
					has_completed_focus = CSA_convention_landowner_elite
					has_completed_focus = CSA_convention_right_to_secede
				}
				country_event = { id = csa.13 hours = 1 }
			}
		}
 	}
 	option = {
		name = csa.16.b
		hidden_effect = { CSA = { set_country_flag = CSA_commerce_clause_mix_flag } }
		hidden_effect = {
			if = {
				limit = {
					has_completed_focus = CSA_convention_taxation
					has_completed_focus = CSA_convention_trade_of_slaves
					has_completed_focus = CSA_convention_commerce_clause
					has_completed_focus = CSA_convention_landowner_elite
					has_completed_focus = CSA_convention_right_to_secede
				}
				country_event = { id = csa.13 hours = 1 }
			}
		}
	}
	option = {
		name = csa.16.c
		swap_ideas = {
			add_idea = limited_exports
			remove_idea = export_focus
		}
		custom_effect_tooltip = CSA_convention_drift_central
		add_to_variable = {
			var = CSA_convention
			value = 2
		}
		hidden_effect = { CSA = { set_country_flag = CSA_commerce_clause_federal_flag } }
		hidden_effect = {
			if = {
				limit = {
					has_completed_focus = CSA_convention_taxation
					has_completed_focus = CSA_convention_trade_of_slaves
					has_completed_focus = CSA_convention_commerce_clause
					has_completed_focus = CSA_convention_landowner_elite
					has_completed_focus = CSA_convention_right_to_secede
				}
				country_event = { id = csa.13 hours = 1 }
			}
		}
	}
}

#Slave Trade
country_event = {
	id = csa.17
	title = csa.17.t
	desc = csa.17.d
	picture = GFX_report_event_german_reichstag_gathering

	is_triggered_only = yes

	fire_only_once = yes

	option = {
		name = csa.17.a
		add_political_power = 25
		custom_effect_tooltip = CSA_convention_drift_confed
		subtract_from_variable = {
			var = CSA_convention
			value = 1
		}
		hidden_effect = { CSA = { set_country_flag = CSA_slave_trade_state_flag } }
		hidden_effect = {
			if = {
				limit = {
					has_completed_focus = CSA_convention_taxation
					has_completed_focus = CSA_convention_trade_of_slaves
					has_completed_focus = CSA_convention_commerce_clause
					has_completed_focus = CSA_convention_landowner_elite
					has_completed_focus = CSA_convention_right_to_secede
				}
				country_event = { id = csa.13 hours = 1 }
			}
		}
 	}
 	option = {
		name = csa.17.b
		hidden_effect = { CSA = { set_country_flag = CSA_slave_trade_mix_flag } }
		hidden_effect = {
			if = {
				limit = {
					has_completed_focus = CSA_convention_taxation
					has_completed_focus = CSA_convention_trade_of_slaves
					has_completed_focus = CSA_convention_commerce_clause
					has_completed_focus = CSA_convention_landowner_elite
					has_completed_focus = CSA_convention_right_to_secede
				}
				country_event = { id = csa.13 hours = 1 }
			}
		}
	}
	option = {
		name = csa.17.c
		add_political_power = -25
		custom_effect_tooltip = CSA_convention_drift_central
		add_to_variable = {
			var = CSA_convention
			value = 1
		}
		hidden_effect = { CSA = { set_country_flag = CSA_slave_trade_federal_flag } }
		hidden_effect = {
			if = {
				limit = {
					has_completed_focus = CSA_convention_taxation
					has_completed_focus = CSA_convention_trade_of_slaves
					has_completed_focus = CSA_convention_commerce_clause
					has_completed_focus = CSA_convention_landowner_elite
					has_completed_focus = CSA_convention_right_to_secede
				}
				country_event = { id = csa.13 hours = 1 }
			}
		}
	}
}

#Taxation Rights
country_event = {
	id = csa.18
	title = csa.18.t
	desc = csa.18.d
	picture = GFX_report_event_german_reichstag_gathering

	is_triggered_only = yes

	fire_only_once = yes

	option = {
		name = csa.18.a
		custom_effect_tooltip = CSA_convention_drift_confed
		subtract_from_variable = {
			var = CSA_convention
			value = 2
		}
		hidden_effect = { CSA = { set_country_flag = CSA_taxation_rights_state_flag } }
		hidden_effect = {
			if = {
				limit = {
					has_completed_focus = CSA_convention_taxation
					has_completed_focus = CSA_convention_trade_of_slaves
					has_completed_focus = CSA_convention_commerce_clause
					has_completed_focus = CSA_convention_landowner_elite
					has_completed_focus = CSA_convention_right_to_secede
				}
				country_event = { id = csa.13 hours = 1 }
			}
		}
     	}
     	option = {
		name = csa.18.b
		hidden_effect = { CSA = { set_country_flag = CSA_taxation_rights_mix_flag } }
		hidden_effect = {
			if = {
				limit = {
					has_completed_focus = CSA_convention_taxation
					has_completed_focus = CSA_convention_trade_of_slaves
					has_completed_focus = CSA_convention_commerce_clause
					has_completed_focus = CSA_convention_landowner_elite
					has_completed_focus = CSA_convention_right_to_secede
				}
				country_event = { id = csa.13 hours = 1 }
			}
		}
	}
	option = {
		name = csa.18.c
		custom_effect_tooltip = CSA_convention_drift_central
		add_to_variable = {
			var = CSA_convention
			value = 2
		}
		hidden_effect = { CSA = { set_country_flag = CSA_taxation_rights_federal_flag } }
		hidden_effect = {
			if = {
				limit = {
					has_completed_focus = CSA_convention_taxation
					has_completed_focus = CSA_convention_trade_of_slaves
					has_completed_focus = CSA_convention_commerce_clause
					has_completed_focus = CSA_convention_landowner_elite
					has_completed_focus = CSA_convention_right_to_secede
				}
				country_event = { id = csa.13 hours = 1 }
			}
		}
	}
}

#Borders for CSA States when Decentralizing
country_event = {
	id = csa.19
	title = csa.19.t
	desc = csa.19.d
	picture = GFX_report_event_german_reichstag_gathering

	is_triggered_only = yes

	fire_only_once = yes

	option = {
		name = csa.19.a
 	}
 	option = {
		name = csa.19.b
		set_country_flag = CSA_group_up_states
	}
}

#Finish Decentralization
country_event = {
	id = csa.20
	title = csa.20.t
	desc = csa.20.d
	picture = GFX_report_event_german_reichstag_gathering

	is_triggered_only = yes

	fire_only_once = yes

	option = {
		name = csa.20.a
		trigger = { NOT = { has_country_flag = CSA_group_up_states } }
     	}
     	option = {
		name = csa.20.b
		trigger = {
			has_country_flag = CSA_group_up_states
		}
	}
}

#CSA Elections
country_event = {
	id = csa.21
	title = csa.21.t
	desc = {
		text = csa.21.d
		trigger = {
			NOT = { has_completed_focus = CSA_convention_unitarian_finish }
		}
	}
	desc = {
		text = csa.21.d_unitarian
		trigger = {
			has_completed_focus = CSA_convention_unitarian_finish
		}
	}
	picture = GFX_report_event_german_reichstag_gathering

	is_triggered_only = yes
	fire_only_once = yes

	# option = {
		# name = csa.21.a
		# set_politics = {
			# ruling_party = traditional_conservatism
			# elections_allowed = yes
			# election_frequency = 72
		# }
		# set_country_flag = CSA_davis_elected
 	# }
 	option = {
		name = csa.21.b
		set_politics = {
			ruling_party = traditional_conservatism
			elections_allowed = yes
			election_frequency = 72
		}
		create_country_leader = {
			name = "John Breckinridge"
			desc = ""
			picture = "Portrait_CSA_John_Breckinridge.png"
			expire = "1965.1.1"
			ideology = federal
			traits = {
			}
		}
		set_country_flag = CSA_breckinridge_elected
	}
	option = {
		name = csa.21.c
		set_politics = {
			ruling_party = traditional_conservatism
			elections_allowed = yes
			election_frequency = 72
		}
		create_country_leader = {
			name = "Robert Toombs"
			desc = ""
			#picture = ""
			expire = "1965.1.1"
			ideology = federal
			traits = {
			}
		}
		set_country_flag = CSA_toombs_elected
	}
	option = {
		name = csa.21.e
		trigger = {
			NOT = { has_completed_focus = CSA_convention_unitarian_finish }
		}
		set_politics = {
			ruling_party = traditional_conservatism
			elections_allowed = yes
			election_frequency = 72
		}
		create_country_leader = {
			name = "Robert E. Lee"
			desc = ""
			picture = "Portrait_CSA_Robert_Lee.png"
			expire = "1965.1.1"
			ideology = federal
			traits = {
			}
		}
		set_country_flag = CSA_lee_elected
	}
}

#Rebirth of the Whigs
country_event = {
	id = csa.22
	title = csa.22.t
	desc = csa.22.d
	picture = GFX_report_event_german_reichstag_gathering

	trigger = {
		tag = CSA
		date > 1870.1.1
	}

	mean_time_to_happen = {
		days = 500
	}

	fire_only_once = yes

	option = {
		name = csa.22.a
		add_popularity = {
			ideology = centrism
			popularity = 0.05
		}
		set_country_flag = CSA_whig_party_flag
		set_party_name = { ideology = centrism long_name = CSA_whig_party name = CSA_whig_party }
 	}
}

#Democrat or Dixiecrat
country_event = {
	id = csa.23
	title = csa.23.t
	desc = csa.23.d
	picture = GFX_report_event_german_reichstag_gathering

	is_triggered_only = yes

	option = {
		name = csa.23.a
 	}
 	option = {
		name = csa.23.b
		set_party_name = { ideology = traditional_conservatism long_name = CSA_dixiecrat_party name = CSA_dixiecrat_party }
 	}
}
#Purchase of Sonora and Chihuahua
country_event = {
	id = csa.24
	title = csa.24.t
	desc = csa.24.d
	picture = GFX_report_event_german_reichstag_gathering

	is_triggered_only = yes

	option = {
		name = csa.24.a
		ai_chance = {
			factor = 80
			modifier = {
				add = -30
				num_of_civilian_factories > 29
			}
			modifier = {
				add = -80
				num_of_civilian_factories > 39
			}
		}
		if = {
			limit = {
				USA = { exists = yes }
			}
			USA = { country_event = { id = csa.25 hours = 3 } }
		}
		else = {
			CSA = { country_event = { id = csa.27 hours = 3 } }
		}
 	}
 	option = {
		name = csa.24.b
		ai_chance = {
			factor = 20
			modifier = {
				add = 30
				num_of_civilian_factories > 29
			}
			modifier = {
				add = 80
				num_of_civilian_factories > 39
			}
		}
		CSA = { country_event = { id = csa.26 hours = 3 } }
 	}
}

#USA reacts to purchase of Sonora and Chihuahua
country_event = {
	id = csa.25
	title = csa.25.t
	desc = csa.25.d
	picture = GFX_report_event_german_reichstag_gathering

	is_triggered_only = yes

	option = {
		name = csa.25.a
		ai_chance = {
			factor = 50
			modifier = {
				add = 50
				has_government = centrism
			}
			modifier = {
				add = 100
				has_government = social_egalitarianism
			}
		}
		CSA = { country_event = { id = csa.28 hours = 3 } }
 	}
 	option = {
		name = csa.25.b
		ai_chance = {
			factor = 50
			modifier = {
				add = 50
				has_government = traditional_conservatism
			}
			modifier = {
				add = 50
				has_war = yes
			}
			modifier = {
				add = 50
				has_war_support < 0.2
			}
		}
		CSA = { country_event = { id = csa.27 hours = 3 } }
 	}
}

#CSA is refused by mexico
country_event = {
	id = csa.26
	title = csa.26.t
	desc = csa.26.d
	picture = GFX_report_event_german_reichstag_gathering

	is_triggered_only = yes

	option = {
		name = csa.26.a
		add_political_power = -10
		set_country_flag = CSA_mexico_refused_purchase
 	}
}

#CSA is granted territory by Mexico
country_event = {
	id = csa.27
	title = csa.27.t
	desc = csa.27.d
	picture = GFX_report_event_german_reichstag_gathering

	is_triggered_only = yes

	option = {
		name = csa.27.a
		add_political_power = 10
		set_country_flag = CSA_mexico_accepted_purchase_goes
		random_owned_controlled_state = {
			remove_building = {
				type = industrial_complex
				level = 1
			}
		}
		random_owned_controlled_state = {
			remove_building = {
				type = industrial_complex
				level = 1
			}
		}
		MEX = {
			random_owned_controlled_state = {
				add_building_construction = {
					type = industrial_complex
					level = 1
					instant_build = yes
				}
			}
			random_owned_controlled_state = {
				add_building_construction = {
					type = industrial_complex
					level = 1
					instant_build = yes
				}
			}
		}
		add_timed_idea = {
			idea = CSA_payment_for_states
			days = 120
		}
		MEX = {
			add_timed_idea = {
				idea = CSA_recieving_payment
				days = 120
			}
		}
		transfer_state = 482
		add_state_core = 482
		transfer_state = 483
		add_state_core = 483
 	}
}

#USA demands CSA to not go with purchase
country_event = {
	id = csa.28
	title = csa.28.t
	desc = csa.28.d
	picture = GFX_report_event_german_reichstag_gathering

	is_triggered_only = yes

	option = {
		name = csa.28.a
		ai_chance = { factor = 85 }
		USA = {
			declare_war_on = {
				target = CSA
				type = second_mexican_war_wargoal
			}
		}
		MEX = {
			add_to_war = {
				targeted_alliance = CSA
				enemy = USA
			}
		}
		set_country_flag = CSA_second_mexican_war
		set_global_flag = ACW_second_mexican_war
		hidden_effect = { news_event = csa.51 }
 	}
 	option = {
		name = csa.28.b
		ai_chance = { factor = 15 }
 	}
}

#CSA ask uk and france for aid
country_event = {
	id = csa.29
	title = csa.29.t
	desc = csa.29.d
	picture = GFX_report_event_german_reichstag_gathering

	fire_only_once = yes

	trigger = {
		tag = CSA
		has_country_flag = CSA_second_mexican_war
		surrender_progress > 0.05
	}

	option = {
		name = csa.29.a
		ai_chance = { factor = 90 }
		ENG = { country_event = { id = csa.30 hours = 3 } }
 	}
 	option = {
		name = csa.29.b
		ai_chance = {	factor = 10 }
 	}
}

#CSA ask uk and france for aid
country_event = {
	id = csa.30
	title = csa.30.t
	desc = {
		text = csa.30.d
		trigger = { tag = ENG }
	}
	desc = {
		text = csa.30.d_uk
		trigger = {
			tag = FRA
			CSA = { has_country_flag = CSA_UK_second_mexican_war }
		}
	}
	desc = {
		text = csa.30.d_no_uk
		trigger = {
			tag = FRA
			NOT = {
				CSA = { has_country_flag = CSA_UK_second_mexican_war }
			}
		}
	}
	picture = GFX_report_event_german_reichstag_gathering

	is_triggered_only = yes

	option = {
		name = csa.30.a
		ai_chance = {
			factor = 90
			modifier = {
				add = -90
				AND = {
					tag = FRA
					NOT = { CSA = { has_country_flag = CSA_UK_second_mexican_war } }
				}
			}
		}
		if = {
			limit = {
				tag = ENG
			}
			CSA = { set_country_flag = CSA_UK_second_mexican_war }
			FRA = {
				country_event = { id = csa.30 hours = 3 }
			}
		}
		if = {
			limit = {
				tag = FRA
			}
			CSA = {
				country_event = { id = csa.31 hours = 3 }
			}
			CSA = { set_country_flag = CSA_FRA_second_mexican_war }
		}
     	}
     	option = {
		name = csa.30.b
		ai_chance = {
			factor = 10
		}
		if = {
			limit = {
				tag = ENG
			}
			FRA = {
				country_event = { id = csa.30 hours = 3 }
			}
		}
		if = {
			limit = {
				tag = FRA
			}
			CSA = {
				country_event = { id = csa.31 hours = 3 }
			}
		}
 	}
}

#CSA response
country_event = {
	id = csa.31
	title = csa.31.t
	desc = csa.31.d
	picture = GFX_report_event_german_reichstag_gathering

	is_triggered_only = yes

	option = {
		name = csa.31.a
		trigger = {
			AND = {
				has_country_flag = CSA_UK_second_mexican_war
				has_country_flag = CSA_FRA_second_mexican_war
			}
		}
		ENG = {
			add_to_war = {
				targeted_alliance = CSA
				enemy = USA
			}
		}
		FRA = {
			add_to_war = {
				targeted_alliance = CSA
				enemy = USA
			}
		}
		swap_ideas = {
			remove_idea = usa_slavery_law
			add_idea = slavery_all_but_name
		}
 	}
 	option = {
		name = csa.31.b
		trigger = {
			AND = {
				has_country_flag = CSA_UK_second_mexican_war
				NOT = { has_country_flag = CSA_FRA_second_mexican_war }
			}
		}
		ENG = {
			add_to_war = {
				targeted_alliance = CSA
				enemy = USA
			}
		}
		swap_ideas = {
			remove_idea = usa_slavery_law
			add_idea = slavery_all_but_name
		}
 	}
 	option = {
		name = csa.31.c
		trigger = {
			AND = {
				NOT = { has_country_flag = CSA_UK_second_mexican_war }
				has_country_flag = CSA_FRA_second_mexican_war
			}
		}
		FRA = {
			add_to_war = {
				targeted_alliance = CSA
				enemy = USA
			}
		}
		swap_ideas = {
			remove_idea = usa_slavery_law
			add_idea = slavery_all_but_name
		}
 	}
 	option = {
		name = csa.31.e
		trigger = {
			AND = {
				NOT = { has_country_flag = CSA_UK_second_mexican_war }
				NOT = { has_country_flag = CSA_FRA_second_mexican_war }
			}
		}
		add_political_power = -25
 	}
}

#End of the Second Mexican War
country_event = {
	id = csa.32
	title = csa.32.t
	desc = {
		text = csa.32.d
		trigger = { tag = CSA }
	}
	desc = {
		text = csa.32.d_usa
		trigger = { tag = USA }
	}
	picture = GFX_report_event_german_reichstag_gathering

	is_triggered_only = yes

	option = {
		name = csa.32.a
		trigger = { tag = CSA }
		CSA = { white_peace = USA }
		MEX = { white_peace = USA }
		if = {
			limit = { CSA = { has_country_flag = CSA_UK_second_mexican_war } }
			ENG = { white_peace = USA }
		}
		if = {
			limit = {	CSA = { has_country_flag = CSA_FRA_second_mexican_war } }
			FRA = { white_peace = USA }
		}
		random_owned_controlled_state = {
			remove_building = {
				type = industrial_complex
				level = 1
			}
		}
		random_owned_controlled_state = {
			remove_building = {
				type = industrial_complex
				level = 1
			}
		}
		MEX = {
			random_owned_controlled_state = {
				add_building_construction = {
					type = industrial_complex
					level = 1
					instant_build = yes
				}
			}
			random_owned_controlled_state = {
				add_building_construction = {
					type = industrial_complex
					level = 1
					instant_build = yes
				}
			}
		}
		add_timed_idea = {
			idea = CSA_payment_for_states
			days = 120
		}
		MEX = {
			add_timed_idea = {
				idea = CSA_recieving_payment
				days = 120
			}
		}
		transfer_state = 482
		add_state_core = 482
		transfer_state = 483
		add_state_core = 483
		USA = { add_stability = -0.1 }
 	}
 	option = {
		name = csa.32.b
		trigger = { tag = USA }
		CSA = { white_peace = USA }
		MEX = { white_peace = USA }
		if = {
			limit = {	CSA = { has_country_flag = CSA_UK_second_mexican_war } }
			ENG = { white_peace = USA }
		}
		if = {
			limit = {	CSA = { has_country_flag = CSA_FRA_second_mexican_war } }
			FRA = { white_peace = USA }
		}
		add_stability = 0.1
 	}
}

#Purchase of Cuba
country_event = {
	id = csa.33
	title = csa.33.t
	desc = csa.33.d
	picture = GFX_report_event_german_reichstag_gathering

	is_triggered_only = yes

	option = {
		name = csa.33.a
		CSA = { country_event = { id = csa.35 } }
 	}
 	option = {
		name = csa.33.b
		CSA = { country_event = { id = csa.34 } }
 	}
}

#Spain Refuses to Sell Cuba
country_event = {
	id = csa.34
	title = csa.34.t
	desc = csa.34.d
	picture = GFX_report_event_german_reichstag_gathering

	is_triggered_only = yes

	option = {
		name = csa.34.a
		add_political_power = -10
 	}
}

#Spain Sells Cuba
country_event = {
	id = csa.35
	title = csa.35.t
	desc = csa.35.d
	picture = GFX_report_event_german_reichstag_gathering

	is_triggered_only = yes

	option = {
		name = csa.35.a
		transfer_state = 315
		add_state_core = 315
		transfer_state = 1022
		add_state_core = 1022
		transfer_state = 1350
		add_state_core = 1350
		random_owned_controlled_state = {
			remove_building = {
				type = industrial_complex
				level = 1
			}
		}
		random_owned_controlled_state = {
			remove_building = {
				type = industrial_complex
				level = 1
			}
		}
		SPR = {
			random_owned_controlled_state = {
				add_building_construction = {
					type = industrial_complex
					level = 1
					instant_build = yes
				}
			}
			random_owned_controlled_state = {
				add_building_construction = {
					type = industrial_complex
					level = 1
					instant_build = yes
				}
			}
		}
		add_timed_idea = {
			idea = CSA_payment_for_states
			days = 120
		}
		SPR = {
			add_timed_idea = {
				idea = CSA_recieving_payment
				days = 120
			}
		}
 	}
}

#Seizing Comanche Territory
country_event = {
	id = csa.36
	title = csa.36.t
	desc = csa.36.d
	picture = GFX_report_event_german_reichstag_gathering

	is_triggered_only = yes

	option = {
		name = csa.36.a
		ai_chance = { factor = 90 }
		if = {
			limit = {	owns_state = 1280 }
			CSA = {
				transfer_state = 1280
				add_state_core = 1280
			}
		}
		if = {
			limit = {	owns_state = 1293 }
			CSA = {
				transfer_state = 1293
				add_state_core = 1293
			}
		}
		if = {
			limit = { CSA = { owns_state = 1285 } }
			CSA = {
				transfer_state = 1279
			}
		}
 	}
 	option = {
		name = csa.36.b
		ai_chance = {	factor = 10 }
		CSA = { country_event = { id = csa.37 } }
 	}
}

#Comanche refuse!
country_event = {
	id = csa.37
	title = csa.37.t
	desc = csa.37.d
	picture = GFX_report_event_german_reichstag_gathering

	is_triggered_only = yes

	option = {
		name = csa.37.a
 	}
 	option = {
		name = csa.37.b
		add_political_power = -25
 	}
}

#Seizing Apache Territory
country_event = {
	id = csa.38
	title = csa.38.t
	desc = csa.38.d
	picture = GFX_report_event_german_reichstag_gathering

	is_triggered_only = yes

	option = {
		name = csa.38.a
		ai_chance = { factor = 90 }
		CSA = {
			transfer_state = 1301
		}
 	}
 	option = {
		name = csa.38.b
		ai_chance = { factor = 10 }
		CSA = { country_event = { id = csa.39 } }
 	}
}

#Apache refuse!
country_event = {
	id = csa.39
	title = csa.39.t
	desc = csa.39.d
	picture = GFX_report_event_german_reichstag_gathering

	is_triggered_only = yes

	option = {
		name = csa.39.a
		declare_war_on = {
			target = APA
			type = annex_everything
		}
 	}
 	option = {
		name = csa.39.b
		add_political_power = -25
 	}
}

#Trade with CSA?
country_event = {
	id = csa.40
	title = csa.40.t
	desc = csa.40.d
	picture = GFX_report_event_german_reichstag_gathering

	is_triggered_only = yes

	option = {
		name = csa.40.a
		CSA = { set_country_flag = CSA_USA_reapproach }
 	}
 	option = {
		name = csa.39.b
		CSA = { set_country_flag = CSA_USA_no_reapproach }
 	}
}

#Generic USA Election
country_event = {
	id = csa.50
	title = csa.50.t
	desc = csa.50.d
	picture = GFX_report_event_german_reichstag_gathering

	is_triggered_only = yes

	trigger = {
		tag = CSA
		date > 1868.1.1
	}

	option = {
		trigger = {
			has_country_flag = CSA_whig_party_flag
			centrism > traditional_conservatism
		}
		name = csa_election.1000.a
		retire_country_leader = yes
		set_politics = {
			ruling_party = centrism
			election_frequency = 72
			elections_allowed = yes
		}
		add_popularity = {
			ideology = traditional_conservatism
			popularity = 0.03
		}
		clr_country_flag = CSA_generic_president_reelected
	}
	option = {
		name = csa_election.1000.b
		trigger = {
			OR = {
				NOT = { has_country_flag = CSA_whig_party_flag }
				centrism < traditional_conservatism
			}
			has_country_flag = CSA_whig_party_flag
			centrism < traditional_conservatism
		}
		retire_country_leader = yes
		set_politics = {
			ruling_party = traditional_conservatism
			election_frequency = 72
  			elections_allowed = yes
		}
		add_popularity = {
			ideology = centrism
			popularity = 0.03
		}
		clr_country_flag = CSA_generic_president_reelected
	}
	option = {
		name = csa_election.1000.c
		trigger = {
			NOT = { has_country_flag = CSA_generic_president_reelected }
		}
		set_country_flag = CSA_generic_president_reelected
		random_list = {
			50 = {
				add_popularity = {
					ideology = centrism
					popularity = 0.03
				}
			}
			50 = {
				add_popularity = {
					ideology = traditional_conservatism
					popularity = 0.03
				}
			}
		}
	}
}

#Second Mexican War
news_event = {
	id = csa.51
	title = csa.51.t
	desc = csa.51.d

	picture = GFX_news_event_generic_army

	major = yes

	is_triggered_only = yes

	option = {
		name = csa.51.a
		trigger = {
			NOT = {
				tag = USA
				tag = CSA
				tag = MEX
			}
		}
	}
	option = {
		name = csa.51.b
		trigger = {
			tag = USA
		}
	}
	option = {
		name = csa.51.c
		trigger = {
			OR = {
				tag = CSA
				tag = MEX
			}
		}
	}
}

country_event = {
	id = csa.52
	title = csa.52.t
	desc = csa.52.d
	picture = GFX_report_event_election_vote
	
	immediate = {
		hidden_effect = {
			ROOT = {
				set_party_name = {
					ideology = ideology_social_liberalism 
					long_name = CSA_state_ideology_social_liberalism_party_long
					name = CSA_state_ideology_social_liberalism_party 
				}
				set_party_name = {
					ideology = ideology_radical_socialism 
					long_name = CSA_state_ideology_radical_socialism_party_long 
					name = CSA_state_ideology_radical_socialism_party 
				}
				set_party_name = {
					ideology = social_egalitarianism 
					long_name = CSA_state_social_egalitarianism_party_long 
					name = CSA_state_social_egalitarianism_party 
				}
				set_party_name = {
					ideology = centrism 
					long_name = CSA_state_centrism_party_long 
					name = CSA_state_centrism_party 
				}
				set_party_name = {
					ideology = radical_democracy 
					long_name = CSA_state_radical_democracy_party_long 
					name = CSA_state_radical_democracy_party 
				}
				set_party_name = {
					ideology = traditional_conservatism 
					long_name = CSA_state_traditional_conservatism_party_long 
					name = CSA_state_traditional_conservatism_party 
				}
				set_party_name = {
					ideology = autocracy 
					long_name = CSA_state_autocracy_party_long 
					name = CSA_state_autocracy_party 
				}
				set_party_name = {
					ideology = chauvinist_populism 
					long_name = CSA_state_chauvinist_populism_party_long 
					name = CSA_state_chauvinist_populism_party 
				}
				set_party_name = {
					ideology = anarchism 
					long_name = CSA_state_anarchism_party_long 
					name = CSA_state_anarchism_party 
				}
				set_party_name = {
					ideology = fundamentalism 
					long_name = CSA_state_fundamentalism_party_long 
					name = CSA_state_fundamentalism_party 
				}
			}
		}
	}
		
	is_triggered_only = yes
		
	option = {
		name = csa.52.a
		ai_chance = {
        factor = 0
        }
		custom_effect_tooltip = csa_member_state_select_platform_tooltip
		hidden_effect = { ROOT = { country_event = { id = csa.52 days = 50 random = 15 } } }
	}
	option = {
		name = csa.52.b
		ai_chance = {
			factor = 100
		}
		custom_effect_tooltip = csa_member_state_congress_platform_tooltip
		hidden_effect = { ROOT = { country_event = { id = csa.53 days = 50 random = 15 } } }
	}
}

country_event = {
	id = csa.53
	title = csa.53.t
	desc = csa.53.d
	picture = GFX_report_event_election_vote
		
	is_triggered_only = yes
	
	immediate = {
		hidden_effect = {
			ROOT = {
				random_list = {
					90 = {
						set_country_flag = CSA_member_state_policies_voted_privileged_education_flag
						modifier = {
							factor = 0
							CSA = { has_idea = open_schools }
							CSA = { has_country_flag = CSA_slave_trade_federal_flag }
						}
						add_popularity = { ideology = traditional_conservatism	popularity = 0.01 }
					}
					10 = {
						set_country_flag = CSA_member_state_policies_voted_open_schools_flag
						modifier = {
							factor = 0
							CSA = { NOT = { has_idea = open_schools } }
							CSA = { has_country_flag = CSA_slave_trade_federal_flag }
						}
						modifier = {
							factor = 2
							ROOT = { has_country_flag = CSA_member_state_selected_platform_open_schools_flag }
							CSA = { has_country_flag = CSA_slave_trade_state_flag }
						}
						add_popularity = { ideology = centrism	popularity = 0.03 }
						add_popularity = { ideology = social_egalitarianism	popularity = 0.06 }
					}
				}
				random_list = {
					50 = {
						set_country_flag = CSA_member_state_policies_voted_export_focus_flag
						modifier = {
							factor = 0
							CSA = { NOT = { has_idea = export_focus } }
							CSA = { has_country_flag = CSA_commerce_clause_federal_flag }
						}
						add_popularity = { ideology = traditional_conservatism	popularity = 0.02 }
					}
					50 = {
						set_country_flag = CSA_member_state_policies_voted_free_trade_flag
						modifier = {
							factor = 0
							CSA = { NOT = { has_idea = free_trade } }
							CSA = { has_country_flag = CSA_commerce_clause_federal_flag }
						}
						add_popularity = { ideology = centrism	popularity = 0.06 }
					}
				}
				random_list = {
					10 = {
						set_country_flag = CSA_member_state_policies_voted_very_high_taxes_flag
						modifier = {
							factor = 0
							CSA = { NOT = { has_idea = taxation_level_5 } }
							CSA = { has_country_flag = CSA_taxation_rights_federal_flag }
						}
					}
					20 = {
						set_country_flag = CSA_member_state_policies_voted_high_taxes_flag
						modifier = {
							factor = 0
							CSA = { NOT = { has_idea = taxation_level_4 } }
							CSA = { has_country_flag = CSA_taxation_rights_federal_flag }
						}
					}
					40 = {
						set_country_flag = CSA_member_state_policies_voted_normal_taxes_flag
						modifier = {
							factor = 0
							CSA = { NOT = { has_idea = taxation_level_3 } }
							CSA = { has_country_flag = CSA_taxation_rights_federal_flag }
						}
						add_popularity = { ideology = centrism	popularity = 0.01 }
					}
					20 = {
						set_country_flag = CSA_member_state_policies_voted_low_taxes_flag
						modifier = {
							factor = 0
							CSA = { NOT = { has_idea = taxation_level_2 } }
							CSA = { has_country_flag = CSA_taxation_rights_federal_flag }
						}
						add_popularity = { ideology = centrism	popularity = 0.02 }
						add_popularity = { ideology = chauvinist_populism	popularity = 0.03 }
					}
					10 = {
						set_country_flag = CSA_member_state_policies_voted_very_low_taxes_flag
						modifier = {
							factor = 0
							CSA = { NOT = { has_idea = taxation_level_1 } }
							CSA = { has_country_flag = CSA_taxation_rights_federal_flag }
						}
						add_popularity = { ideology = centrism	popularity = 0.03 }
						add_popularity = { ideology = chauvinist_populism	popularity = 0.06 }
					}
				}
				random_list = {
					25 = {
						set_country_flag = CSA_member_state_policies_voted_universal_male_suffrage_flag
						modifier = {
							factor = 3
							CSA = { NOT = { has_country_flag = CSA_landowner_elite_state_flag } }
						}
						modifier = {
							factor = 2
							CSA = { has_country_flag = CSA_landowner_elite_state_flag }
						}
						add_popularity = { ideology = centrism	popularity = 0.02 }
					}
					25 = {
						set_country_flag = CSA_member_state_policies_voted_property_owners_suffrage_flag
						modifier = {
							factor = 2
							CSA = { has_country_flag = CSA_landowner_elite_state_flag }
							ROOT = { has_country_flag = CSA_member_state_policies_voted_privileged_education_flag }
						}
						modifier = {
							factor = 0
							CSA = { has_country_flag = CSA_landowner_elite_federal_flag }
						}
						add_popularity = { ideology = chauvinist_populism	popularity = 0.06 }
						add_popularity = { ideology = traditional_conservatism	popularity = 0.02 }
						add_ideas = CSA_aristocrats_encouraged
						hidden_effect = {
							add_to_variable = { var = ROOT.NA_B_idea_working_class_exploitation_score_var@ROOT value = 2 }
							add_to_variable = { var = ROOT.NA_B_idea_working_class_organization_score_var@ROOT value = -7 }
							country_event = { id = balkanized_usa.10 } 
						}
					}
					10 = {
						set_country_flag = CSA_member_state_policies_voted_universal_suffrage_flag
						modifier = {
							factor = 0
							ROOT = { NOT = { has_country_flag = CSA_member_state_policies_voted_privileged_education_flag } }
						}
						modifier = {
							factor = 0
							CSA = { NOT = { has_country_flag = CSA_landowner_elite_state_flag } }
						}
						add_popularity = { ideology = centrism	popularity = 0.06 }
						add_popularity = { ideology = social_egalitarianism	popularity = 0.10 }
						add_timed_idea = {
							idea = CSA_aristocrats_discouraged
							days = 1800
						}
						hidden_effect = {
							add_to_variable = { var = ROOT.NA_B_idea_working_class_exploitation_score_var@ROOT value = -2 }
							add_to_variable = { var = ROOT.NA_B_idea_working_class_organization_score_var@ROOT value = 7 }
							country_event = { id = balkanized_usa.10 } 
						}
					}
				}
			}
		}
	}
		
	option = {
		name = csa.53.a
		ai_chance = {
			factor = 100
		}
		custom_effect_tooltip = CSA_member_state_policies_voted_choices
		if = {
			limit = { has_country_flag = CSA_member_state_policies_voted_privileged_education_flag }
			custom_effect_tooltip = CSA_member_state_policies_voted_privileged_education
			hidden_effect = { add_ideas = privileged_education }
		}
		if = {
			limit = { has_country_flag = CSA_member_state_policies_voted_open_schools_flag }
			custom_effect_tooltip = CSA_member_state_policies_voted_open_schools
			hidden_effect = { add_ideas = open_schools }
		}
		if = {
			limit = { has_country_flag = CSA_member_state_policies_voted_export_focus_flag }
			custom_effect_tooltip = CSA_member_state_policies_voted_export_focus
			hidden_effect = { add_ideas = export_focus }
		}
		if = {
			limit = { has_country_flag = CSA_member_state_policies_voted_free_trade_flag }
			custom_effect_tooltip = CSA_member_state_policies_voted_free_trade
			hidden_effect = { add_ideas = free_trade }
		}
		if = {
			limit = { has_country_flag = CSA_member_state_policies_voted_very_high_taxes_flag }
			custom_effect_tooltip = CSA_member_state_policies_voted_very_high_taxes
			hidden_effect = { add_ideas = taxation_level_5 }
		}
		if = {
			limit = { has_country_flag = CSA_member_state_policies_voted_high_taxes_flag }
			custom_effect_tooltip = CSA_member_state_policies_voted_high_taxes
			hidden_effect = { add_ideas = taxation_level_4 }
		}
		if = {
			limit = { has_country_flag = CSA_member_state_policies_voted_normal_taxes_flag }
			custom_effect_tooltip = CSA_member_state_policies_voted_normal_taxes
			hidden_effect = { add_ideas = taxation_level_3 }
		}
		if = {
			limit = { has_country_flag = CSA_member_state_policies_voted_low_taxes_flag }
			custom_effect_tooltip = CSA_member_state_policies_voted_low_taxes
			hidden_effect = { add_ideas = taxation_level_2 }
		}
		if = {
			limit = { has_country_flag = CSA_member_state_policies_voted_very_low_taxes_flag }
			custom_effect_tooltip = CSA_member_state_policies_voted_very_low_taxes
			hidden_effect = { add_ideas = taxation_level_1 }
		}
		if = {
			limit = { has_country_flag = CSA_member_state_policies_voted_universal_male_suffrage_flag }
			custom_effect_tooltip = CSA_member_state_policies_voted_universal_male_suffrage
			hidden_effect = { add_ideas = universal_male_suffrage }
		}
		if = {
			limit = { has_country_flag = CSA_member_state_policies_voted_property_owners_suffrage_flag }
			custom_effect_tooltip = CSA_member_state_policies_voted_property_owners_suffrage
			hidden_effect = { add_ideas = property_owners_suffrage }
		}
		if = {
			limit = { has_country_flag = CSA_member_state_policies_voted_universal_suffrage_flag }
			custom_effect_tooltip = CSA_member_state_policies_voted_universal_suffrage
			hidden_effect = { add_ideas = universal_suffrage }
		}
		if = {
			limit = { has_country_flag = CSA_member_state_policies_voted_free_elections_flag }
			custom_effect_tooltip = CSA_member_state_policies_voted_free_elections
			hidden_effect = { add_ideas = free_elections }
		}
	}
}