/* Thanks https://loading.io/css/ */
@keyframes loadingAnimation {
	0% {
		transform: translate(-50%, -50%) rotate(0deg);
	}
	100% {
		transform: translate(-50%, -50%) rotate(360deg);
	}
}

/**
 * General styles
 */

.p-4 {
	flex-grow: 1;
}

.is-hidden {
	display: none !important;
}

.agcga-page-wrapper {
	display: flex;
	justify-content: center;
	align-items: center;
	padding-top: 48px;
	padding-bottom: 48px;
}

.agcga-page-container {
	width: 100%;
	max-width: 1170px;
}

.agcga-logout-link {
	color: #cf152d;
	text-decoration: none;
	font-weight: 500;
	transition: color 0.3s ease;
}

.agcga-logout-link:hover {
	color: #b01126;
}
/* End of general styles */

/* Loading animation */
.loading-anim {
	display: none;
	position: relative;
	margin-left: auto;
	margin-right: auto;
	width: 100px;
	height: 100px;
	overflow: hidden;
	background-color: transparent;
}

.loading-anim.is-loading {
	display: block;
}

.loading-anim .loading-indicator {
	width: 100%;
	height: 100%;
	position: relative;
	transform: translateZ(0) scale(1);
	backface-visibility: hidden;
	transform-origin: 0 0;
}

.loading-anim .loading-indicator div {
	box-sizing: content-box;
	position: absolute;
	top: 50px;
	left: 50px;
	width: 35px;
	height: 35px;
	border: 6px solid #cf152d;
	border-top-color: transparent;
	border-radius: 50%;
	animation: loadingAnimation 1s linear infinite;
}
/* End of loading animation */

.member-position {
	min-height: 40px; /* Adjust as needed */
	margin: 5px !important;
}

.member-item {
	display: flex;
	flex-direction: column;
	justify-content: space-between;
	height: 100%; /* Ensures equal height for all cards */
}

.member-name {
	clip-path: polygon(0 0, 100% 0, 100% 100%, 0% 100%) !important;
	background-color: #d7282f !important;

	min-height: 40px; /* Adjust to match all names */
	display: flex;
	align-items: center;
	justify-content: center;
}

.member-name-red {
	clip-path: polygon(0 0, 100% 0, 90% 100%, 0% 100%) !important;
	background-color: #d7282f !important;

	min-height: 40px; /* Adjust to match all names */
	display: flex;
	align-items: center;
	justify-content: center;
}

.member-item,
.cal-item,
.cal-title {
	font-family: "Montserrat", sans-serif !important;
}

.cal-tag {
	font-weight: 600;
}

.cal-item {
	position: relative;
}

.cal-item .p-4 {
	padding-top: 40px; /* Add padding to prevent overlap */
}
.event-tag {
	position: absolute;
	top: 10px;
	left: 10px;
	background: #1a202c;
	color: white;
	font-size: 0.75rem;
	padding: 4px 8px;
	border-radius: 4px;
	z-index: 10; /* Ensure it's above other elements */
}

.member-title,
.cal-title {
	font-family: "Montserrat", sans-serif !important;
	font-weight: 600 !important;
}

.cal-title {
	font-size: 1.25rem !important;
}

.member-company {
	font-family: "Montserrat", sans-serif !important;
	font-weight: 400 !important;
}

.governor-name,
.safety-name,
.ga-safety-name,
.legislative-name,
.political-action-committee-name,
.council-member-name,
.ylp-member-name,
.exec-alliance-member-name,
.executive-team-name {
	font-family: "Montserrat", sans-serif !important;
	font-weight: normal !important;
}

.board-of-foundations img {
	height: auto !important;
	max-width: unset !important;
	border-radius: 50% !important; /* Keep the round shape */
	width: 96px !important; /* Set a fixed width */
	height: 96px !important; /* Set a fixed height */
	object-fit: cover !important; /* Ensure proper scaling */
}

.board-of-executives img {
	max-height: 250px;
}

/**
 * Iframe styles to load external pages
 */
.agcga-iframe-container {
	position: relative;
	width: 100%;
	overflow-y: hidden;
}

.iframe-loading-overlay {
	display: none;
	position: fixed;
	left: 0;
	top: 0;
	width: 100%;
	height: 100%;
	background-color: rgba(255, 255, 255, 0.8);
	border-radius: 8px;
}

.iframe-loading-overlay.is-loading {
	display: flex;
	align-items: center;
	justify-content: center;
}

.iframe-loading-overlay.is-loading .loading-indicator {
	position: relative;
	width: 35px;
	height: 35px;
	border: 6px solid #cf152d;
	border-top-color: transparent;
	border-radius: 50%;
	animation: loadingAnimation 1s linear infinite;
}

.agcga-iframe-container iframe {
	width: 100%;
}

.agcga-iframe-fallback {
	display: none;
	position: absolute;
	top: 0;
	left: 0;
	width: 100%;
	height: 100%;
	background: #f8f9fa;
	border-radius: 8px;
	border: 1px solid #e0e0e0;
}

.agcga-iframe-error {
	display: flex;
	flex-direction: column;
	align-items: center;
	justify-content: center;
	text-align: center;
	height: 100%;
	padding: 2rem;
}

.agcga-iframe-error h3 {
	margin-bottom: 1rem;
	color: #cf152d;
}

.agcga-iframe-error p {
	margin-bottom: 1.5rem;
	max-width: 500px;
}
/* End of iframe styles */

@media (max-width: 576px) {
	.agcga-page-wrapper {
		padding-top: 24px;
		padding-bottom: 24px;
	}
}
