/**
 * Course session booking (month + slot select).
 *
 * @package Cursusgroep
 */

.course-dates.cg-session-booking h3 {
	font-size: 1.15rem;
	font-weight: 600;
	color: #111827;
	margin: 0 0 0.65rem;
}

.cg-session-fields {
	display: flex;
	flex-direction: column;
	gap: 0.6rem;
	padding: 0;
	background: transparent;
	border: 0;
	margin-bottom: 0.25rem;
}

.cg-field {
	display: flex;
	flex-direction: column;
	gap: 0.4rem;
}

.cg-field-label {
	font-weight: 600;
	font-size: 0.9rem;
	color: #111827;
}

/* Native appearance removed: need generous vertical padding + min-height or text clips (esp. WebKit). */
.course-dates.cg-session-booking .cg-session-select,
.woocommerce div.product form.cart .course-dates.cg-session-booking .cg-session-select {
	width: 100%;
	max-width: 100%;
	display: block;
	min-height: 2.5rem;
	height: auto;
	padding: 0.5rem 2rem 0.5rem 0.65rem;
	font-size: 0.95rem;
	line-height: 1.3;
	color: #0f172a;
	background-color: #fff;
	border: 1px solid #cbd5e1;
	border-radius: 4px;
	box-sizing: border-box;
	cursor: pointer;
	transition: border-color 0.18s ease, box-shadow 0.18s ease, background-color 0.18s ease;
	-webkit-appearance: none;
	-moz-appearance: none;
	appearance: none;
	background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12'%3E%3Cpath fill='%23475569' d='M6 8L1 3h10z'/%3E%3C/svg%3E");
	background-repeat: no-repeat;
	background-position: right 0.75rem center;
	background-size: 12px 12px;
	overflow: visible;
	vertical-align: middle;
}

.course-dates.cg-session-booking .cg-session-select:hover,
.woocommerce div.product form.cart .course-dates.cg-session-booking .cg-session-select:hover {
	border-color: #b8c3d0;
}

.course-dates.cg-session-booking .cg-session-select:focus,
.woocommerce div.product form.cart .course-dates.cg-session-booking .cg-session-select:focus {
	outline: none;
	border-color: #94a3b8;
	box-shadow: 0 0 0 2px rgba(148, 163, 184, 0.2);
}

.no-sessions {
	text-align: center;
	padding: 16px 12px;
	background: #fff;
	border: 1px solid #d1d5db;
	color: #111827;
	font-weight: 500;
}

#cg-participant-quantity-section {
	margin-top: calc(1rem + 1pt);
	margin-bottom: 1pt;
	display: block;
	clear: both;
}

.cg-add-participant-btn {
	display: block;
	width: fit-content;
	justify-self: center;
	padding: 10px 12px;
	margin: 0.6rem 0 0;
	border: 1px solid #cbd5e1;
	border-radius: 4px;
	background: #fff;
	color: #111827;
	font-size: 14px;
	font-weight: 600;
	text-align: center;
	cursor: pointer;
	transition: background-color 0.18s ease, border-color 0.18s ease;
}

.cg-add-participant-btn:disabled {
	opacity: 0.6;
	cursor: not-allowed;
}

.cg-participant-heading {
	display: block;
	font-size: 0.95rem;
	font-weight: 700;
	margin-bottom: 0.35rem;
	color: #0f172a;
}

#participant-fields-wrapper {
	margin-top: 0.75rem;
	display: grid;
	gap: 0.75rem;
	clear: both;
	width: 100%;
}

#cg-participant-quantity-section .quantity {
	display: none !important;
}

.cg-participant-card {
	padding: 12px;
	border: 1px solid #dbe3ec;
	border-radius: 4px;
	background: #ffffff;
	box-shadow: none;
}

.cg-participant-card__title {
	margin: 0 0 0.45rem;
	font-size: 1rem;
}

.cg-participant-card__header {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 10px;
	margin-bottom: 0.35rem;
}

.cg-participant-remove {
	padding: 3px 8px;
	border: 1px solid #cbd5e1;
	border-radius: 4px;
	background: #fff;
	color: #334155;
	font-size: 12px;
	cursor: pointer;
	transition: color 0.18s ease, border-color 0.18s ease, background-color 0.18s ease;
}

.cg-participant-remove[disabled] {
	opacity: 0.5;
	cursor: not-allowed;
}

.cg-booking-confirmation {
	margin: 0.4rem 0 0.35rem;
	padding: 8px 10px;
	border: 1px solid #dbe3ec;
	border-radius: 4px;
	background: #fff;
}

.cg-booking-confirmation__text {
	margin: 0;
	font-size: 0.88rem;
	line-height: 1.45;
	color: #111827;
}

.cg-participant-card__label {
	display: block;
	font-weight: 600;
	margin-bottom: 0.35rem;
}

.cg-participant-card__input {
	width: 100%;
	margin-bottom: 0.55rem;
	padding: 9px 10px;
	font-size: 0.94rem;
	line-height: 1.35;
	color: #0f172a;
	background: #fff;
	border: 1px solid #cbd5e1;
	border-radius: 4px;
	transition: border-color 0.18s ease, box-shadow 0.18s ease;
}

.cg-participant-card__input:focus {
	outline: none;
	border-color: #94a3b8;
	box-shadow: 0 0 0 2px rgba(148, 163, 184, 0.2);
}

.cg-participant-card__input:last-child {
	margin-bottom: 0;
}

@media (max-width: 768px) {
	.course-dates.cg-session-booking h3 {
		font-size: 1rem;
	}

	.cg-session-fields {
		padding: 0;
	}

	.course-dates.cg-session-booking .cg-session-select,
	.woocommerce div.product form.cart .course-dates.cg-session-booking .cg-session-select {
		font-size: 16px; /* Reduces iOS zoom on focus */
		min-height: 2.75rem;
		padding-top: 0.875rem;
		padding-bottom: 0.875rem;
	}

	#cg-participant-quantity-section {
		margin-top: calc(0.75rem + 1pt);
		margin-bottom: 1pt;
	}

	.cg-participant-heading {
		font-size: 1rem;
		margin-bottom: 0.35rem;
	}

	.cg-booking-confirmation {
		margin-top: 0.6rem;
		padding: 8px;
	}

	.cg-booking-confirmation__text {
		font-size: 0.84rem;
	}

	#participant-fields-wrapper {
		margin-top: 0.5rem;
		gap: 0.6rem;
	}

	.cg-participant-card {
		padding: 10px;
	}
}
