/* Free class registration from the timetable (Gym Builder). */
.gb-tt-register {
	display: inline-block;
	margin-top: 8px;
	padding: 6px 14px;
	border: 0;
	border-radius: 999px;
	background: var(--gym-builder-primary-color, #005dd0);
	color: #fff;
	font-size: 13px;
	font-weight: 600;
	line-height: 1.4;
	cursor: pointer;
}
.gb-tt-register:hover,
.gb-tt-register:focus-visible { filter: brightness( .92 ); }
.gb-tt-register[disabled] { opacity: .55; cursor: default; }
.gb-tt-spots,
.gb-tt-full {
	display: block;
	margin-top: 4px;
	font-size: 12px;
	opacity: .8;
}
.gb-tt-full { font-weight: 600; }

.gb-tt-open { overflow: hidden; }
.gb-tt-modal {
	position: fixed;
	inset: 0;
	z-index: 99999;
	display: flex;
	align-items: center;
	justify-content: center;
	padding: 16px;
	background: rgba( 15, 23, 42, .55 );
}
.gb-tt-modal[hidden] { display: none; }
.gb-tt-dialog {
	position: relative;
	width: 100%;
	max-width: 420px;
	max-height: calc( 100vh - 32px );
	overflow: auto;
	padding: 24px;
	border-radius: 14px;
	background: #fff;
	color: #0f172a;
	box-shadow: 0 20px 50px rgba( 15, 23, 42, .25 );
	text-align: left;
}
.gb-tt-dialog h3 { margin: 0 0 4px; font-size: 20px; }
.gb-tt-class { margin: 0 0 16px; color: #475569; font-size: 14px; }
/* Scoped under the dialog so theme button styles (background, padding, hover
   colours) cannot turn the close icon into a filled button. */
.gb-tt-dialog .gb-tt-close {
	position: absolute;
	top: 10px;
	right: 12px;
	width: 32px;
	height: 32px;
	min-height: 0;
	margin: 0;
	padding: 0;
	border: 0;
	border-radius: 8px;
	background: transparent;
	box-shadow: none;
	color: #64748b;
	font-size: 24px;
	line-height: 32px;
	text-align: center;
	cursor: pointer;
}
.gb-tt-dialog .gb-tt-close:hover,
.gb-tt-dialog .gb-tt-close:focus {
	background: #f1f5f9;
	color: #0f172a;
	box-shadow: none;
}
.gb-tt-dialog .gb-tt-close:focus-visible { outline: 2px solid var(--gym-builder-primary-color, #005dd0); outline-offset: 2px; }
.gb-tt-form label { display: block; margin-bottom: 12px; font-size: 14px; font-weight: 600; }
.gb-tt-form input[type=text],
.gb-tt-form input[type=email],
.gb-tt-form input[type=tel] {
	display: block;
	width: 100%;
	margin-top: 4px;
	padding: 10px 12px;
	border: 1px solid #cbd5e1;
	border-radius: 8px;
	font-size: 15px;
	font-weight: 400;
	box-sizing: border-box;
}
.gb-tt-plans { margin: 0 0 14px; padding: 0; border: 0; min-width: 0; }
.gb-tt-plans[hidden] { display: none; }
.gb-tt-plans legend { padding: 0; margin-bottom: 8px; font-size: 14px; font-weight: 600; }
.gb-tt-plan-list { display: grid; gap: 8px; }
.gb-tt-form .gb-tt-plan {
	display: flex;
	align-items: center;
	flex-wrap: wrap;
	gap: 6px 10px;
	margin: 0;
	padding: 10px 12px;
	border: 1px solid #cbd5e1;
	border-radius: 8px;
	font-weight: 500;
	cursor: pointer;
}
.gb-tt-form .gb-tt-plan:has( input:checked ) { border-color: var(--gym-builder-primary-color, #005dd0); background: #eff6ff; }
.gb-tt-plan input { margin: 0; accent-color: var(--gym-builder-primary-color, #005dd0); }
.gb-tt-plan-name { flex: 1 1 auto; }
.gb-tt-plan-price { font-weight: 700; white-space: nowrap; }
.gb-tt-plan-yours {
	padding: 2px 8px;
	border-radius: 999px;
	background: #dcfce7;
	color: #15803d;
	font-size: 11px;
	font-weight: 700;
}
.gb-tt-form .gb-tt-hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }
.gb-tt-submit {
	width: 100%;
	padding: 12px;
	border: 0;
	border-radius: 8px;
	background: var(--gym-builder-primary-color, #005dd0);
	color: #fff;
	font-size: 15px;
	font-weight: 700;
	cursor: pointer;
}
.gb-tt-dialog .gb-tt-submit:hover,
.gb-tt-dialog .gb-tt-submit:focus {
	background: var(--gym-builder-primary-color, #005dd0);
	color: #fff;
	filter: brightness( .92 );
}
.gb-tt-submit[disabled] { opacity: .6; cursor: default; }
.gb-tt-dialog .gb-tt-submit.is-loading { position: relative; color: transparent; opacity: 1; }
.gb-tt-dialog .gb-tt-submit.is-loading::after {
	content: "";
	position: absolute;
	top: 50%;
	left: 50%;
	width: 18px;
	height: 18px;
	margin: -9px 0 0 -9px;
	border: 2px solid rgba( 255, 255, 255, .45 );
	border-top-color: #fff;
	border-radius: 50%;
	animation: gb-tt-spin .7s linear infinite;
}
@keyframes gb-tt-spin { to { transform: rotate( 360deg ); } }
@media ( prefers-reduced-motion: reduce ) {
	.gb-tt-dialog .gb-tt-submit.is-loading::after { animation-duration: 1.6s; }
}
.gb-tt-message { margin: 4px 0 12px; font-size: 14px; }
.gb-tt-message:empty { display: none; }
.gb-tt-message.is-ok { color: #15803d; font-weight: 600; }
.gb-tt-message.is-error { color: #b91c1c; }
.gb-tt-as { margin: 0 0 12px; font-size: 14px; }

/* Book column of a single class page's timetable */
.class-schedule-book .gb-tt-register { margin-top: 0; }
.class-schedule-book .gb-tt-spots { margin-top: 4px; }
