/**
 * Test Dates — Figma node 148:18439
 *
 * @package SSDC
 */

/* Same top-only page-bg pattern as About / Courses (page-bg.png) */
.td-page.st-page {
	position: relative;
	background-color: #ffffff;
	background-image: url('../img/page-bg.png');
	background-repeat: no-repeat;
	background-position: right top;
	background-size: 50% auto;
	padding-top: 0;
	padding-bottom: 80px;
	overflow: visible;
	min-height: 0;
}

@media (max-width: 1024px) {
	.td-page.st-page {
		/* Keep deco at top only — avoid body.ssdc-page-bg cover bleed */
		background-size: 100% auto;
	}
}

.td-page .st-container {
	max-width: none;
	width: 100%;
	margin: 0;
	padding: 0;
	position: relative;
	z-index: 1;
}

body.ssdc-testdates-page {
	background-color: #ffffff;
	background-image: none;
}

/* -------------------------------------------------------------------------
   1. Hero & Header Section
   ------------------------------------------------------------------------- */
.td-hero {
	position: relative;
	background: transparent;
	padding: 64px 0 0;
	margin: 0;
	overflow: hidden;
	border-bottom: none;
}

.td-hero__inner {
	position: relative;
	z-index: 2;
	max-width: var(--ssdc-page-max, none);
	margin: 0 auto;
	padding: 0 var(--ssdc-gutter, 112px) 48px;
	box-sizing: border-box;
}

.td-hero .st-crumbs {
	display: flex;
	align-items: center;
	flex-wrap: wrap;
	gap: 8px;
	margin-bottom: 24px;
	font-family: 'Inter', var(--font-body, sans-serif);
	font-size: 16px;
	font-weight: 600;
	line-height: 24px;
}

.td-hero .st-crumbs a {
	display: inline-flex;
	align-items: center;
	color: #64748B;
	text-decoration: none;
	font-size: 16px;
	font-weight: 600;
	line-height: 24px;
	transition: color 0.15s ease;
}

.td-hero .st-crumbs a:hover {
	color: #03287C;
}

.td-hero .st-crumbs__home svg {
	width: 20px;
	height: 20px;
	display: block;
	stroke: currentColor;
}

.td-hero .st-crumbs__sep {
	color: #CBD5E1;
	font-size: 16px;
	display: inline-flex;
	align-items: center;
}

.td-hero .st-crumbs__current {
	color: #03287C;
	font-weight: 600;
	font-size: 16px;
	line-height: 24px;
}

.td-hero .st-title {
	font-family: 'Hanken Grotesk', var(--font-heading, -apple-system, sans-serif);
	font-size: clamp(34px, 4vw, 48px);
	line-height: 1.25;
	font-weight: 600;
	letter-spacing: -0.02em;
	text-transform: uppercase;
	color: #0f172a;
	margin-bottom: 16px;
}

.td-hero .st-desc {
	font-family: 'Inter', var(--font-body, -apple-system, sans-serif);
	font-size: 18px;
	line-height: 28px;
	color: #334155;
	max-width: 768px;
	margin-bottom: 0;
}

.td-hero .td-tabs {
	margin-top: 24px;
}

/* Horizontal Tabs (Figma 98:407) */
.td-tabs {
	display: inline-flex;
	gap: 4px;
	padding: 4px;
	border: 1px solid #e2e8f0;
	border-radius: 10px;
	background: #f8fafc;
	box-sizing: border-box;
}

.td-tabs__btn {
	appearance: none;
	border: 0;
	background: transparent;
	padding: 8px 14px;
	border-radius: 6px;
	font-family: 'Inter', var(--font-body, sans-serif);
	font-size: 14px;
	font-weight: 600;
	color: #64748b;
	cursor: pointer;
	line-height: 20px;
	transition: all 0.15s ease;
	white-space: nowrap;
}

.td-tabs__btn:hover {
	color: #334155;
}

.td-tabs__btn.is-active {
	background: #ffffff;
	color: #334155;
	box-shadow: 0px 1px 2px -1px rgba(0, 0, 0, 0.1), 0px 1px 3px 0px rgba(0, 0, 0, 0.1);
}

/* -------------------------------------------------------------------------
   2. Table Section & Cards
   ------------------------------------------------------------------------- */
.td-content {
	max-width: var(--ssdc-page-max, none);
	margin: 0 auto;
	padding: 0 var(--ssdc-gutter, 112px) 80px;
}

.td-table-section {
	padding: 48px 32px 0;
	max-width: var(--ssdc-page-max, none);
	margin: 0 auto;
	box-sizing: border-box;
	width: 100%;
	position: relative;
	z-index: 1;
	background-color: #ffffff;
}

.td-booking,
.td-cta-section {
	position: relative;
	z-index: 1;
	background-color: #ffffff;
}

.td-table-panel {
	display: none;
}

.td-table-panel.is-active {
	display: block;
}

.td-table-card {
	border: 1px solid #e2e8f0;
	border-radius: 12px;
	overflow: hidden;
	background: #ffffff;
	box-shadow: 0px 1px 2px 0px rgba(0, 0, 0, 0.05);
	margin-bottom: 24px;
}

.td-table-card:last-child {
	margin-bottom: 0;
}

.td-table-card--legacy .tablepress-scroll-wrapper {
	overflow-x: auto;
}

/* Grouped Data Table — Figma 122:16672 & 122:16914 */
.td-gt {
	width: 100%;
	font-family: 'Inter', var(--font-body, sans-serif);
	overflow-x: auto;
	-webkit-overflow-scrolling: touch;
}

.td-gt__head,
.td-gt__row {
	display: grid;
	grid-template-columns: minmax(0, 1fr) 240px 90px;
	align-items: center;
	column-gap: 16px;
	box-sizing: border-box;
	min-width: 600px;
	background: #ffffff;
	border-bottom: 1px solid #e2e8f0;
}

.td-gt__head {
	padding: 12px 24px;
	background: #ffffff;
}

.td-gt__row {
	padding: 16px 24px;
}

.td-gt__h {
	padding: 0;
	color: #334155;
	font-size: 14px;
	font-weight: 600;
	line-height: 20px;
	background: transparent;
	text-align: left;
}

.td-gt__group {
	display: block;
	box-sizing: border-box;
	min-width: 600px;
	background: #f8fafc;
	border-bottom: 1px solid #e2e8f0;
}

.td-gt__group-title {
	padding: 20px 24px 8px;
	font-size: 14px;
	font-weight: 600;
	line-height: 20px;
	color: #0f172a;
	text-align: left;
}

.td-gt__group--sub .td-gt__group-title {
	padding: 12px 24px 8px;
	color: #334155;
	font-weight: 600;
}

.td-gt__cell {
	padding: 0;
	font-size: 14px;
	line-height: 20px;
	font-weight: 400;
	min-width: 0;
}

.td-gt__cell--desc {
	text-align: left;
	color: #0f172a;
	font-weight: 400;
}

/* When in a flat list without group titles (like Theory Test), description is Semibold */
.td-gt__section:first-child:last-child:not(:has(.td-gt__group)) .td-gt__cell--desc,
.td-gt:not(:has(.td-gt__group)) .td-gt__cell--desc {
	font-weight: 600;
}

.td-gt__cell--date,
.td-gt__cell--day {
	color: #334155;
	text-align: left;
	white-space: nowrap;
}

.td-gt__date {
	display: flex;
	align-items: center;
	justify-content: flex-start;
	gap: 6px;
	width: 100%;
}

.td-gt__date-text {
	flex: 0 0 auto;
	white-space: nowrap;
}

.td-gt__na {
	color: #64748b;
	font-weight: 400;
}

.td-gt__section:last-child .td-gt__row:last-child,
.td-gt__section:last-child .td-gt__group:last-child {
	border-bottom: 0;
}

/* Theory tab — Figma matching horizontal table layout */
.td-gt--theory .td-gt__head,
.td-gt--theory .td-gt__row {
	display: grid;
	grid-template-columns: minmax(0, 1fr) 240px 90px;
	align-items: center;
	column-gap: 16px;
	box-sizing: border-box;
	min-width: 600px;
	background: #ffffff;
	border-bottom: 1px solid #e2e8f0;
}

.td-gt--theory .td-gt__cell--desc {
	font-weight: 600;
	color: #0f172a;
	text-align: left;
	writing-mode: horizontal-tb;
	transform: none;
	display: block;
	min-height: auto;
}

.td-gt--theory .td-gt__row {
	padding: 16px 24px;
	min-height: auto;
}

.td-table-panel--theory .td-table-card {
	width: 100%;
	max-width: 100%;
}

/* Upcoming Badge Pill (Figma 98:146) */
.td-badge {
	display: inline-flex;
	align-items: center;
	padding: 2px 8px;
	border-radius: 9999px;
	font-size: 12px;
	font-weight: 500;
	line-height: 18px;
	white-space: nowrap;
	flex-shrink: 0;
}

.td-badge--upcoming {
	background: #fcf2f2;
	color: #e20004;
	border: 1px solid #fabdbd;
}

/* -------------------------------------------------------------------------
   3a. Booking section — SSDC Section container + course heading
   ------------------------------------------------------------------------- */
.td-page .td-booking-section.ssdc-section-frame {
	background-color: #ffffff;
	position: relative;
	z-index: 1;
}

.td-page .td-booking-section .ssdc-section-frame__wrap {
	max-width: var(--ssdc-page-max, none);
	padding: 0 var(--ssdc-gutter, 112px);
	box-sizing: border-box;
}

.td-page .wp-block-acf-ssdc-course-section.ssdc-crs-sect--booking-head,
.td-page .wp-block-acf-ssdc-course-section:has(#testdates-booking),
.td-page .wp-block-acf-ssdc-course-section:has(.ssdc-crs-sect--booking-head),
.td-page .wp-block-acf-ssdc-section.td-booking-section {
	width: 100% !important;
	max-width: none !important;
	margin-left: 0 !important;
	margin-right: 0 !important;
	box-sizing: border-box;
}

.td-page > .wp-block-acf-ssdc-course-section.ssdc-crs-sect--booking-head,
.td-page > .wp-block-acf-ssdc-course-section:has(#testdates-booking),
.td-page > .wp-block-acf-ssdc-course-section:has(.ssdc-crs-sect--booking-head) {
	max-width: var(--ssdc-page-max, none);
	margin-left: auto;
	margin-right: auto;
	padding: 80px 32px 32px;
}

.td-page > .wp-block-acf-ssdc-course-section:has(#testdates-booking) + .td-booking-section.ssdc-section--pad-default,
.td-page > .wp-block-acf-ssdc-course-section.ssdc-crs-sect--booking-head + .td-booking-section.ssdc-section--pad-default {
	padding-top: 0;
}

.td-page .td-booking-section .wp-block-acf-ssdc-course-section {
	max-width: none;
	margin: 0;
	padding: 0;
	width: auto;
}

.td-page .td-booking-section .ssdc-crs-sect--booking-head,
.td-page .ssdc-crs-sect.ssdc-crs-sect--booking-head {
	max-width: none;
	margin: 0;
	padding: 0 0 32px;
	background-color: transparent;
	border: none;
	box-sizing: border-box;
}

.td-page .td-booking-section .ssdc-crs-sect--booking-head .ssdc-crs-eyebrow,
.td-page .ssdc-crs-sect.ssdc-crs-sect--booking-head .ssdc-crs-eyebrow {
	margin-bottom: 16px;
}

.td-page .td-booking-section .ssdc-crs-sect--booking-head .ssdc-crs-eyebrow::before,
.td-page .ssdc-crs-sect.ssdc-crs-sect--booking-head .ssdc-crs-eyebrow::before {
	width: 22px;
	height: 1px;
	border-radius: 0;
	background: #e20004;
}

.td-page .td-booking-section .ssdc-crs-sect--booking-head .ssdc-crs-sect-title,
.td-page .ssdc-crs-sect.ssdc-crs-sect--booking-head .ssdc-crs-sect-title {
	margin: 0;
	font-family: 'Hanken Grotesk', var(--font-heading, sans-serif);
	font-size: clamp(26px, 3vw, 32px);
	font-weight: 700;
	line-height: 1.5;
	color: #0f172a;
}

.td-page .td-booking-section .td-booking {
	padding: 0;
}

.td-page .td-booking-section .td-booking__grid {
	max-width: none;
	margin: 0;
	padding: 0;
}

.td-page .td-booking.td-booking--no-head {
	padding-top: 0;
}

/* -------------------------------------------------------------------------
   3b. Composable booking section / SSDC Section Frame
   ------------------------------------------------------------------------- */
.td-page .hv2-eyebrow,
.td-page .ssdc-section-frame .hv2-eyebrow,
.ssdc-section-frame .hv2-eyebrow {
	display: inline-flex;
	align-items: center;
	gap: 8px;
	margin-bottom: 16px;
}

.td-page .hv2-eyebrow span,
.td-page .ssdc-section-frame .hv2-eyebrow span,
.ssdc-section-frame .hv2-eyebrow span {
	font-family: 'Inter', sans-serif;
	font-size: 14px;
	font-weight: 600;
	text-transform: uppercase;
	color: #ae0404;
	line-height: 20px;
	letter-spacing: normal;
}

.td-page .hv2-eyebrow .hv2-rule,
.td-page .ssdc-section-frame .hv2-eyebrow .hv2-rule,
.ssdc-section-frame .hv2-eyebrow .hv2-rule {
	width: 22px;
	height: 1px;
	background: #e20004;
	display: inline-block;
	flex-shrink: 0;
}

.td-page .ssdc-section-frame .ssdc-section-heading-wrap,
.ssdc-section-frame .ssdc-section-heading-wrap {
	margin-bottom: 32px;
}

.td-page .ssdc-section-frame .ssdc-section-heading,
.ssdc-section-frame .ssdc-section-heading {
	font-family: 'Hanken Grotesk', var(--font-heading, sans-serif);
	font-size: clamp(26px, 3vw, 32px);
	font-weight: 700;
	line-height: 1.5;
	color: #0f172a;
	margin: 0;
}


.td-page .ssdc-grid--booking-cards {
	padding-top: 0;
	padding-bottom: 0;
}

.td-page .ssdc-grid--booking-cards .ssdc-card--type-booking {
	border: none !important;
}

/* -------------------------------------------------------------------------
   3. "Before you board" Section (Info Cards) — Figma 122:16829
   ------------------------------------------------------------------------- */
.td-booking {
	padding: 80px 0 0;
}

.td-booking--no-head {
	padding-top: 24px;
}

.td-booking__head {
	padding: 0 var(--ssdc-gutter, 112px) 32px;
	max-width: var(--ssdc-page-max, none);
	margin: 0 auto;
}

.td-booking__eyebrow {
	display: inline-flex;
	align-items: center;
	gap: 8px;
	margin-bottom: 16px;
	font-family: 'Inter', sans-serif;
	font-size: 14px;
	font-weight: 600;
	text-transform: uppercase;
	color: #ae0404;
	line-height: 20px;
}

.td-booking__eyebrow::before {
	content: '';
	width: 22px;
	height: 1px;
	background: #e20004;
	display: inline-block;
}

.td-booking__title {
	margin: 0;
	font-family: 'Hanken Grotesk', var(--font-heading, sans-serif);
	font-size: clamp(26px, 3vw, 32px);
	font-weight: 700;
	line-height: 1.5;
	color: #020617;
	text-transform: none;
}

.td-booking__grid {
	display: grid;
	grid-template-columns: repeat(2, minmax(0, 1fr));
	gap: 16px 24px;
	max-width: var(--ssdc-page-max, none);
	margin: 0 auto;
	padding: 0 var(--ssdc-gutter, 112px);
	box-sizing: border-box;
}

.td-booking__grid--stack {
	grid-template-columns: 1fr !important;
}

.td-card,
.ssdc-card--type-booking {
	display: flex;
	flex-direction: row;
	gap: 24px;
	align-items: flex-start;
	padding: 24px;
	border-radius: 12px;
	background: #f8fafc;
	box-sizing: border-box;
	border: none;
	box-shadow: none;
}

.td-card__icon,
.ssdc-card--type-booking .ssdc-card__icon {
	flex: 0 0 48px;
	width: 48px;
	height: 48px;
	border-radius: 10px;
	background: #01319d !important;
	color: #ffffff !important;
	display: flex;
	align-items: center;
	justify-content: center;
	box-shadow: inset 0px 0px 0px 1px rgba(0, 0, 0, 0.18), inset 0px -2px 0px 0px rgba(0, 0, 0, 0.05), 0px 1px 2px 0px rgba(0, 0, 0, 0.05);
	margin-bottom: 0;
}

.td-card__icon img,
.td-card__icon svg,
.ssdc-card--type-booking .ssdc-card__icon img,
.ssdc-card--type-booking .ssdc-card__icon svg {
	width: 24px;
	height: 24px;
	display: block;
	object-fit: contain;
	color: #ffffff;
	stroke: #ffffff;
}

.td-card__body,
.ssdc-card--type-booking .ssdc-card__body {
	flex: 1;
	min-width: 0;
	padding: 0;
}

.td-card__title,
.ssdc-card--type-booking .ssdc-card__title {
	margin: 0 0 4px;
	font-family: 'Inter', sans-serif;
	font-size: 18px;
	font-weight: 600;
	line-height: 28px;
	color: #020617;
}

.td-card__text,
.ssdc-card--type-booking .ssdc-card__desc {
	margin: 0;
	font-family: 'Inter', sans-serif;
	font-size: 16px;
	line-height: 24px;
	color: #1e293b;
}

/* -------------------------------------------------------------------------
   4. Call To Action (CTA Banner) — Figma 122:16886
   ------------------------------------------------------------------------- */
.td-cta-section {
	max-width: var(--ssdc-page-max, none);
	margin: 0 auto;
	padding: 48px 32px 64px;
	box-sizing: border-box;
}

.td-cta-section .ssdc-cta-banner {
	min-height: 276px;
	background-color: #052161;
	background-size: auto 125%;
	background-position: right center;
	background-repeat: no-repeat;
	border-radius: 16px;
	padding: 40px clamp(28px, 5vw, 64px);
	position: relative;
	overflow: hidden;
	display: flex;
	align-items: center;
	justify-content: space-between;
	box-shadow: 0 12px 32px rgba(5, 33, 97, 0.18);
	width: 100%;
	box-sizing: border-box;
	margin: 0;
	text-align: left;
}

.td-cta-section .ssdc-cta-banner::after {
	display: none;
}

.td-cta-section .ssdc-cta-banner__title {
	font-family: 'Hanken Grotesk', var(--font-heading, sans-serif);
	font-size: clamp(28px, 3.5vw, 48px);
	font-weight: 600;
	line-height: 1.25;
	text-transform: uppercase;
	letter-spacing: -0.02em;
	color: #ffffff !important;
	margin: 0 0 8px;
}

.td-cta-section .ssdc-cta-banner__subtitle {
	font-family: 'Inter', var(--font-body, sans-serif);
	font-size: 18px;
	font-weight: 400;
	line-height: 28px;
	color: #ffffff !important;
	max-width: 600px;
	margin: 0 0 24px;
}

.td-cta-section .ssdc-cta-banner__actions {
	display: flex;
	gap: 14px;
	align-items: center;
	flex-wrap: wrap;
	z-index: 2;
	margin-top: 4px;
}

/* Red Button (Primary) */
.td-cta-section .ssdc-cta-btn--red {
	background: #e20004 !important;
	color: #ffffff !important;
	border-radius: 9999px;
	padding: 12px 18px;
	font-family: 'Inter', sans-serif;
	font-size: 16px;
	font-weight: 600;
	line-height: 24px;
	display: inline-flex;
	align-items: center;
	gap: 6px;
	text-decoration: none !important;
	border: 2px solid transparent;
	box-shadow: 0px 1px 2px 0px rgba(0, 0, 0, 0.05), inset 0px -2px 0px 0px rgba(0, 0, 0, 0.05), inset 0px 0px 0px 1px rgba(0, 0, 0, 0.18);
	transition: all 0.2s ease;
}

.td-cta-section .ssdc-cta-btn--red:hover {
	background: #b40b0e !important;
	transform: translateY(-1px);
}

/* White Button (Secondary) */
.td-cta-section .ssdc-cta-btn--white {
	background: #ffffff !important;
	color: #334155 !important;
	border: 1px solid #cbd5e1 !important;
	border-radius: 9999px;
	padding: 12px 18px;
	font-family: 'Inter', sans-serif;
	font-size: 16px;
	font-weight: 600;
	line-height: 24px;
	display: inline-flex;
	align-items: center;
	gap: 6px;
	text-decoration: none !important;
	box-shadow: 0px 1px 2px 0px rgba(0, 0, 0, 0.05), inset 0px -2px 0px 0px rgba(0, 0, 0, 0.05), inset 0px 0px 0px 1px rgba(0, 0, 0, 0.18);
	transition: all 0.2s ease;
}

.td-cta-section .ssdc-cta-btn--white:hover {
	background: #f1f5f9 !important;
	color: #03287c !important;
	transform: translateY(-1px);
}

/* -------------------------------------------------------------------------
   5. Responsive Breakpoints
   ------------------------------------------------------------------------- */
@media (min-width: 768px) and (max-width: 1100px) {
	.td-cta-section {
		padding: 40px 24px 48px;
	}

	.td-cta-section .ssdc-cta-banner {
		padding: 36px 32px;
	}
}

@media (max-width: 992px) {
	.td-hero__inner,
	.td-table-section,
	.td-booking-section .ssdc-section-frame__wrap,
	.td-page > .wp-block-acf-ssdc-course-section.ssdc-crs-sect--booking-head,
	.td-page > .wp-block-acf-ssdc-course-section:has(#testdates-booking),
	.td-page > .wp-block-acf-ssdc-course-section:has(.ssdc-crs-sect--booking-head),
	.td-booking__head,
	.td-booking__grid {
		padding-left: 20px;
		padding-right: 20px;
	}

	.td-booking__grid {
		grid-template-columns: 1fr;
		grid-template-rows: none;
		grid-auto-flow: row;
	}
}

@media (max-width: 767px) {
	.td-hero {
		padding-top: 40px;
	}

	.td-hero__inner {
		padding-bottom: 32px;
	}

	.td-booking {
		padding-top: 48px;
	}

	.st-page:has(.td-cta-section),
	.td-page.st-page {
		padding-bottom: 0;
	}

	.td-cta-section {
		padding: 0;
		max-width: none;
		width: 100%;
	}

	.st-container .td-cta-section {
		width: 100vw !important;
		max-width: 100vw !important;
		margin-left: calc(50% - 50vw) !important;
		margin-right: calc(50% - 50vw) !important;
	}

	.td-cta-section .ssdc-cta-banner {
		min-height: 0;
		padding: 24px 20px;
		border-radius: 0;
	}

	.td-card {
		padding: 16px;
		gap: 16px;
	}

	.td-card__icon {
		flex: 0 0 40px;
		width: 40px;
		height: 40px;
	}

	.td-card__icon img,
	.td-card__icon svg {
		width: 20px;
		height: 20px;
	}
}
