/* Course Booking Manager - Public Styles */

.cbm-booking-form {
	max-width: 640px;
	margin: 0 auto;
	font-family: inherit;
}

.cbm-booking-form__header { margin-bottom: 24px; }
.cbm-booking-form__image img { width: 100%; border-radius: 6px; margin-bottom: 16px; }
.cbm-booking-form__title { font-size: 28px; margin: 0 0 8px; }
.cbm-booking-form__excerpt { color: #444; margin: 0 0 12px; }

.cbm-booking-form__sessions { margin: 12px 0; }
.cbm-booking-form__sessions summary { cursor: pointer; font-weight: 600; }
.cbm-booking-form__sessions ul { margin: 8px 0 0 1.2em; }

.cbm-booking-form__price { font-size: 22px; margin: 16px 0 4px; }
.cbm-price-label { font-size: 14px; color: #777; margin-left: 8px; font-weight: normal; }

.cbm-booking-form__seats { font-size: 14px; color: #2e7d32; }
.cbm-booking-form__seats--low { color: #c0392b; font-weight: 600; }

.cbm-notice {
	padding: 14px 18px;
	border-radius: 6px;
	margin: 16px 0;
}
.cbm-notice--error { background: #fde2e1; color: #842029; }
.cbm-notice--full { background: #fff3cd; color: #664d03; }
.cbm-notice--success { background: #d1e7dd; color: #0f5132; }

.cbm-field-row { display: flex; gap: 16px; }
.cbm-field-row .cbm-field { flex: 1; }

.cbm-field { margin-bottom: 16px; }
.cbm-field label { display: block; font-weight: 600; margin-bottom: 6px; font-size: 14px; }
.cbm-field input[type="text"],
.cbm-field input[type="email"],
.cbm-field input[type="tel"],
.cbm-field select,
.cbm-field textarea {
	width: 100%;
	padding: 10px 12px;
	border: 1px solid #d0d5dd;
	border-radius: 5px;
	font-size: 15px;
	box-sizing: border-box;
}
.cbm-field--checkbox label { display: flex; align-items: flex-start; gap: 8px; font-weight: normal; }
.cbm-field--checkbox input { margin-top: 3px; }
.required { color: #c0392b; }

.cbm-field--has-error input,
.cbm-field--has-error select,
.cbm-field--has-error textarea { border-color: #c0392b; }
.cbm-field-error { display: block; color: #c0392b; font-size: 13px; margin-top: 4px; }

.cbm-field--coupon { display: flex; align-items: flex-end; gap: 8px; flex-wrap: wrap; }
.cbm-field--coupon input { flex: 1; min-width: 160px; }
.cbm-coupon-result { font-size: 13px; }
.cbm-coupon-result.is-valid { color: #2e7d32; }
.cbm-coupon-result.is-invalid { color: #c0392b; }

.cbm-form-errors { color: #c0392b; font-weight: 600; margin: 12px 0; }

.cbm-submit-button {
	width: 100%;
	padding: 14px;
	font-size: 16px;
	font-weight: 600;
	border-radius: 6px;
	cursor: pointer;
}
.cbm-submit-button:disabled { opacity: .6; cursor: not-allowed; }

.cbm-loading-spinner {
	width: 20px;
	height: 20px;
	border: 3px solid #ccc;
	border-top-color: #2271b1;
	border-radius: 50%;
	margin: 12px auto 0;
	animation: cbm-spin 0.8s linear infinite;
}
@keyframes cbm-spin { to { transform: rotate(360deg); } }

.cbm-course-selector { max-width: 480px; margin: 0 auto; }
.cbm-course-selector select { width: 100%; padding: 10px; font-size: 15px; }

/* Gallery */
.cbm-gallery__grid {
	display: grid;
	gap: 12px;
}
.cbm-gallery__grid--cols-2 { grid-template-columns: repeat(2, 1fr); }
.cbm-gallery__grid--cols-3 { grid-template-columns: repeat(3, 1fr); }
.cbm-gallery__grid--cols-4 { grid-template-columns: repeat(4, 1fr); }
@media (max-width: 600px) {
	.cbm-gallery__grid { grid-template-columns: repeat(2, 1fr) !important; }
}

.cbm-gallery__item {
	display: block;
	padding: 0;
	border: none;
	background: none;
	cursor: pointer;
	overflow: hidden;
	border-radius: 6px;
}
.cbm-gallery__item img { width: 100%; height: 100%; object-fit: cover; display: block; transition: transform .2s; }
.cbm-gallery__item:hover img { transform: scale(1.04); }

.cbm-gallery__grid--ratio-square .cbm-gallery__item { aspect-ratio: 1 / 1; }
.cbm-gallery__grid--ratio-4-3 .cbm-gallery__item { aspect-ratio: 4 / 3; }
.cbm-gallery__grid--ratio-16-9 .cbm-gallery__item { aspect-ratio: 16 / 9; }

/* Lightbox */
.cbm-lightbox {
	position: fixed;
	inset: 0;
	background: rgba(0,0,0,.9);
	display: flex;
	flex-direction: column;
	align-items: center;
	justify-content: center;
	z-index: 100000;
}
.cbm-lightbox__image { max-width: 90vw; max-height: 80vh; object-fit: contain; }
.cbm-lightbox__caption { color: #fff; margin-top: 12px; font-size: 14px; }
.cbm-lightbox__close,
.cbm-lightbox__prev,
.cbm-lightbox__next {
	position: absolute;
	background: rgba(255,255,255,.1);
	color: #fff;
	border: none;
	border-radius: 50%;
	width: 44px;
	height: 44px;
	font-size: 24px;
	cursor: pointer;
	display: flex;
	align-items: center;
	justify-content: center;
}
.cbm-lightbox__close { top: 20px; right: 20px; }
.cbm-lightbox__prev { left: 20px; top: 50%; transform: translateY(-50%); }
.cbm-lightbox__next { right: 20px; top: 50%; transform: translateY(-50%); }
.cbm-lightbox__close:hover,
.cbm-lightbox__prev:hover,
.cbm-lightbox__next:hover { background: rgba(255,255,255,.25); }
