.tb-wrap {
	/* Brand palette — matches BookEgyptTravel navy + gold logo. Adjust here if your branding changes. */
	--tb-primary: #14284a;
	--tb-primary-light: #1f3f6e;
	--tb-accent: #d9a441;
	--tb-accent-light: #f3c56c;
	--tb-accent-soft: #fbf1de;
	--tb-bg: #ffffff;
	--tb-surface: #f7f8fa;
	--tb-border: #e4e7ee;
	--tb-text: #182233;
	--tb-muted: #6b7280;
	--tb-gradient-navy: linear-gradient(135deg, #14284a 0%, #274a7e 100%);
	--tb-gradient-gold: linear-gradient(135deg, #d9a441 0%, #f3c56c 100%);
	--tb-gradient-identity: linear-gradient(120deg, #14284a 0%, #274a7e 55%, #d9a441 100%);

	max-width: 960px;
	margin: 0 auto;
	padding: 48px 24px 56px;
	font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
	color: var(--tb-text);
	box-sizing: border-box;
}
.tb-wrap * { box-sizing: border-box; }

/* Hard override: the [hidden] attribute must always win over component display
   rules. Without this, buttons/steps that should be hidden (e.g. Submit showing
   on every step alongside Next) can incorrectly remain visible. */
.tb-wrap [hidden] { display: none !important; }

.tb-header { text-align: center; margin-bottom: 36px; }
.tb-eyebrow {
	display: inline-block;
	font-size: 12.5px;
	letter-spacing: 0.1em;
	text-transform: uppercase;
	color: var(--tb-accent);
	font-weight: 700;
	margin-bottom: 12px;
}
.tb-title {
	font-size: 34px;
	margin: 0 0 14px;
	line-height: 1.25;
	font-weight: 800;
	color: var(--tb-primary); /* fallback for browsers without background-clip support */
	background: var(--tb-gradient-identity);
	-webkit-background-clip: text;
	background-clip: text;
	-webkit-text-fill-color: transparent;
}
.tb-subtitle { color: var(--tb-muted); font-size: 16px; max-width: 560px; margin: 0 auto; line-height: 1.6; }

/* Pill tab navigation */
.tb-tabs {
	display: flex;
	gap: 10px;
	flex-wrap: wrap;
	justify-content: center;
	padding-bottom: 24px;
	margin-bottom: 36px;
	border-bottom: 1px solid var(--tb-border);
}
.tb-tab {
	display: flex;
	align-items: center;
	gap: 9px;
	padding: 10px 20px;
	border-radius: 999px;
	background: var(--tb-surface);
	color: var(--tb-muted);
	font-weight: 700;
	font-size: 14px;
	transition: all .2s ease;
}
.tb-tab.active {
	background: var(--tb-gradient-navy);
	color: #fff;
	box-shadow: 0 6px 16px rgba(20, 40, 74, .25);
}
.tb-tab.done {
	background: var(--tb-gradient-gold);
	color: var(--tb-primary);
}
.tb-tab-num {
	width: 22px;
	height: 22px;
	border-radius: 50%;
	background: #fff;
	color: var(--tb-muted);
	border: 1px solid var(--tb-border);
	display: flex;
	align-items: center;
	justify-content: center;
	font-size: 11.5px;
	flex-shrink: 0;
}
.tb-tab.active .tb-tab-num { background: rgba(255, 255, 255, .22); color: #fff; border-color: transparent; }
.tb-tab.done .tb-tab-num { background: var(--tb-primary); color: #fff; border-color: transparent; }
@media (max-width: 700px) {
	.tb-tab-label { display: none; }
	.tb-tab { padding: 10px 14px; }
}

.tb-step h3 { font-size: 22px; margin: 0 0 6px; color: var(--tb-primary); font-weight: 800; }
.tb-step h3.tb-mt { margin-top: 40px; }
.tb-hint { color: var(--tb-muted); font-size: 14px; margin-bottom: 24px; }

.tb-grid { display: grid !important; gap: 16px; margin-bottom: 24px; }
.tb-grid-2 { grid-template-columns: repeat(2, 1fr) !important; }
.tb-grid-3 { grid-template-columns: repeat(3, 1fr) !important; }
.tb-grid-4 { grid-template-columns: repeat(4, 1fr) !important; }
.tb-grid > * { width: auto !important; max-width: none !important; float: none !important; }
@media (max-width: 760px) {
	.tb-grid-3, .tb-grid-4 { grid-template-columns: repeat(2, 1fr) !important; }
}
@media (max-width: 480px) {
	.tb-grid-2, .tb-grid-3, .tb-grid-4 { grid-template-columns: 1fr !important; }
}

/* Destination photo carousel */
.tb-dest-carousel-wrap {
	position: relative;
	margin-bottom: 24px;
}
.tb-dest-carousel {
	display: flex;
	gap: 18px;
	overflow-x: auto;
	scroll-snap-type: x mandatory;
	scroll-behavior: smooth;
	padding: 4px 4px 14px;
	-ms-overflow-style: none;
	scrollbar-width: thin;
}
.tb-dest-carousel::-webkit-scrollbar { height: 6px; }
.tb-dest-carousel::-webkit-scrollbar-thumb { background: var(--tb-border); border-radius: 999px; }

.tb-dest-card {
	position: relative;
	display: flex;
	align-items: flex-end;
	flex: 0 0 230px;
	scroll-snap-align: start;
	height: 190px;
	border-radius: 18px;
	overflow: hidden;
	cursor: pointer;
	background-size: cover;
	background-position: center;
	background-color: var(--tb-surface); /* visible if a broken image URL is ever used */
	border: 2px solid transparent;
	transition: all .18s ease;
	padding: 16px;
}
.tb-dest-card:hover { transform: translateY(-3px); box-shadow: 0 12px 26px rgba(20, 40, 74, .22); }
.tb-dest-card input { position: absolute; opacity: 0; }
.tb-dest-overlay {
	position: absolute;
	inset: 0;
	/* Uniform dark film so text stays legible on any photo, darker toward the bottom for the label */
	background: linear-gradient(180deg, rgba(8, 14, 26, .35) 0%, rgba(8, 14, 26, .45) 45%, rgba(6, 10, 20, .85) 100%);
}
.tb-dest-label {
	position: relative;
	z-index: 1;
	color: #fff;
	font-weight: 700;
	font-size: 16px;
	text-shadow: 0 1px 4px rgba(0, 0, 0, .5);
}
.tb-dest-check {
	position: absolute;
	top: 12px;
	right: 12px;
	width: 26px;
	height: 26px;
	border-radius: 50%;
	background: rgba(255, 255, 255, .22);
	border: 1.5px solid rgba(255, 255, 255, .75);
	color: transparent;
	display: flex;
	align-items: center;
	justify-content: center;
	font-size: 14px;
	font-weight: 700;
	z-index: 1;
	transition: all .15s ease;
}
.tb-dest-card:has(input:checked) {
	border-color: var(--tb-accent);
	box-shadow: 0 0 0 2px var(--tb-accent), 0 12px 26px rgba(20, 40, 74, .25);
}
.tb-dest-card:has(input:checked) .tb-dest-check {
	background: var(--tb-gradient-gold);
	border-color: transparent;
	color: var(--tb-primary);
}

.tb-carousel-arrow {
	position: absolute;
	top: 50%;
	transform: translateY(-50%);
	width: 40px;
	height: 40px;
	border-radius: 50%;
	background: #fff;
	border: 1px solid var(--tb-border);
	color: var(--tb-primary);
	display: flex;
	align-items: center;
	justify-content: center;
	cursor: pointer;
	box-shadow: 0 6px 16px rgba(20, 40, 74, .18);
	z-index: 2;
	transition: all .15s ease;
}
.tb-carousel-arrow:hover { background: var(--tb-primary); color: #fff; }
.tb-carousel-arrow.prev { left: -14px; }
.tb-carousel-arrow.next { right: -14px; }
@media (max-width: 640px) {
	.tb-carousel-arrow { display: none; } /* rely on native touch-swipe on mobile */
}

/* Icon cards */
.tb-check-card, .tb-radio-card {
	position: relative;
	display: flex !important;
	flex-direction: column;
	gap: 6px;
	border: 2px solid var(--tb-border);
	border-radius: 16px;
	padding: 22px 18px;
	cursor: pointer;
	transition: all .18s ease;
	background: var(--tb-bg);
}
.tb-check-card:hover, .tb-radio-card:hover {
	border-color: var(--tb-accent);
	transform: translateY(-2px);
	box-shadow: 0 8px 20px rgba(20, 40, 74, .08);
}
.tb-check-card input, .tb-radio-card input { position: absolute; opacity: 0; }
.tb-check-card:has(input:checked),
.tb-radio-card:has(input:checked) {
	border-color: var(--tb-primary);
	background: var(--tb-accent-soft);
	box-shadow: 0 0 0 1px var(--tb-primary);
}
.tb-card-icon {
	width: 44px;
	height: 44px;
	border-radius: 12px;
	background: var(--tb-surface);
	color: var(--tb-primary);
	display: flex;
	align-items: center;
	justify-content: center;
	margin-bottom: 6px;
}
.tb-card-icon svg { width: 22px; height: 22px; }
.tb-check-card input:checked ~ .tb-card-icon,
.tb-radio-card input:checked ~ .tb-card-icon {
	background: var(--tb-gradient-navy) !important;
	color: #fff !important;
}
.tb-radio-card strong { font-size: 16px; color: var(--tb-primary); }
.tb-radio-card span:not(.tb-card-icon) { font-size: 13px; color: var(--tb-muted); }
.tb-card-label { font-size: 14.5px; font-weight: 600; color: var(--tb-text); }

.tb-field { display: flex; flex-direction: column; gap: 7px; margin-bottom: 18px; font-size: 13.5px; font-weight: 700; color: var(--tb-primary); }
.tb-field input, .tb-field select, .tb-field textarea {
	font: inherit;
	font-weight: 400;
	padding: 12px 14px;
	border: 2px solid var(--tb-border);
	border-radius: 10px;
	color: var(--tb-text);
	background: #fff;
}
.tb-field input:focus, .tb-field select:focus, .tb-field textarea:focus {
	outline: none;
	border-color: var(--tb-primary);
}

.tb-nav {
	display: flex;
	justify-content: space-between;
	align-items: center;
	margin-top: 32px;
	gap: 12px;
}
.tb-btn {
	font: inherit;
	font-weight: 700;
	font-size: 15px;
	padding: 13px 32px;
	border-radius: 999px;
	border: 2px solid transparent;
	cursor: pointer;
	transition: all .18s ease;
	display: inline-flex;
	align-items: center;
	gap: 8px;
}
.tb-btn-primary { background: var(--tb-gradient-navy); color: #fff; margin-left: auto; box-shadow: 0 8px 20px rgba(20, 40, 74, .22); }
.tb-btn-primary:hover { filter: brightness(1.08); }
.tb-btn-primary:disabled { opacity: .5; cursor: not-allowed; }
.tb-btn-ghost { background: transparent; border-color: var(--tb-border); color: var(--tb-text); }
.tb-btn-ghost:hover { border-color: var(--tb-primary); color: var(--tb-primary); }
.tb-arrow { transition: transform .15s ease; }
.tb-btn-primary:hover .tb-arrow { transform: translateX(3px); }

.tb-message {
	margin-top: 18px;
	padding: 13px 18px;
	border-radius: 10px;
	font-size: 14px;
	background: #fdecea;
	color: #8a1f11;
	border: 1px solid #f4c7c0;
}

.tb-success {
	text-align: center;
	padding: 56px 24px;
}
.tb-success-icon {
	width: 72px; height: 72px;
	border-radius: 50%;
	background: var(--tb-gradient-navy);
	color: var(--tb-accent-light);
	font-size: 34px;
	display: flex; align-items: center; justify-content: center;
	margin: 0 auto 22px;
	box-shadow: 0 10px 24px rgba(20, 40, 74, .25);
}
.tb-success h3 { color: var(--tb-primary); margin-bottom: 10px; font-size: 22px; }
.tb-success p { color: var(--tb-muted); font-size: 15px; }

/* Shared helpers */
.tb-field-label { font-size: 13.5px; font-weight: 700; color: var(--tb-primary); margin-bottom: 10px; }
.tb-mt { margin-top: 40px; }
.tb-mt-sm { margin-top: 28px; }

/* Chip groups (Month, Duration, Referral source, Contact method) */
.tb-chip-grid { display: grid; gap: 10px; margin-bottom: 4px; }
.tb-chip-grid-6 { grid-template-columns: repeat(6, 1fr); }
.tb-chip-grid-5 { grid-template-columns: repeat(5, 1fr); }
.tb-chip-grid-4 { grid-template-columns: repeat(4, 1fr); }
.tb-chip-grid-3 { grid-template-columns: repeat(3, 1fr); }
@media (max-width: 700px) {
	.tb-chip-grid-6, .tb-chip-grid-5, .tb-chip-grid-4 { grid-template-columns: repeat(3, 1fr); }
}
@media (max-width: 480px) {
	.tb-chip-grid-6, .tb-chip-grid-5, .tb-chip-grid-4, .tb-chip-grid-3 { grid-template-columns: repeat(2, 1fr); }
}
.tb-chip {
	font: inherit;
	font-weight: 600;
	font-size: 13.5px;
	padding: 11px 10px;
	border-radius: 10px;
	border: 2px solid var(--tb-border);
	background: #fff;
	color: var(--tb-text);
	cursor: pointer;
	text-align: center;
	transition: all .15s ease;
}
.tb-chip:hover { border-color: var(--tb-accent); }
.tb-chip.active {
	background: var(--tb-gradient-navy);
	border-color: transparent;
	color: #fff;
	box-shadow: 0 6px 14px rgba(20, 40, 74, .22);
}

/* Budget cards — bigger "chip" variant with title + subtitle */
.tb-chip-card {
	display: flex;
	flex-direction: column;
	align-items: flex-start;
	gap: 4px;
	padding: 18px 16px;
	text-align: left;
	border-radius: 14px;
}
.tb-chip-card strong { font-size: 15.5px; color: var(--tb-primary); }
.tb-chip-card small { font-size: 12.5px; color: var(--tb-muted); font-weight: 500; }
.tb-chip-card.active strong,
.tb-chip-card.active small { color: #fff; }

/* Inline checkbox (flexible dates) */
.tb-checkbox-inline {
	display: flex;
	align-items: flex-start;
	gap: 12px;
	padding: 14px 16px;
	border: 2px solid var(--tb-border);
	border-radius: 12px;
	cursor: pointer;
	margin-bottom: 20px;
}
.tb-checkbox-inline input { margin-top: 3px; width: 16px; height: 16px; accent-color: var(--tb-primary); flex-shrink: 0; }
.tb-checkbox-inline strong { display: block; font-size: 14px; color: var(--tb-primary); margin-bottom: 2px; }
.tb-checkbox-inline small { display: block; font-size: 12.5px; color: var(--tb-muted); font-weight: 400; }

/* Traveler counter cards */
.tb-counter-card {
	display: flex;
	align-items: center;
	gap: 16px;
	padding: 18px 20px;
	border: 2px solid var(--tb-border);
	border-radius: 14px;
	margin-bottom: 16px;
}
.tb-counter-info { flex: 1; display: flex; flex-direction: column; gap: 2px; }
.tb-counter-info strong { font-size: 16px; color: var(--tb-primary); }
.tb-counter-info span { font-size: 13px; color: var(--tb-muted); }
.tb-counter-controls { display: flex; align-items: center; gap: 14px; }
.tb-counter-btn {
	width: 36px;
	height: 36px;
	border-radius: 50%;
	border: 2px solid var(--tb-border);
	background: #fff;
	color: var(--tb-primary);
	font-size: 18px;
	font-weight: 700;
	cursor: pointer;
	display: flex;
	align-items: center;
	justify-content: center;
	line-height: 1;
	transition: all .15s ease;
}
.tb-counter-btn:hover { background: var(--tb-gradient-navy); color: #fff; border-color: transparent; }
.tb-counter-value {
	display: inline-block;
	min-width: 24px;
	text-align: center;
	font-size: 16px;
	font-weight: 700;
	color: var(--tb-primary);
	user-select: none;
}

/* Phone number with country-code select */
.tb-phone-group { display: flex; gap: 8px; min-width: 0; }
.tb-phone-code {
	flex: 0 0 88px;
	min-width: 0;
	font: inherit;
	padding: 12px 8px;
	border: 2px solid var(--tb-border);
	border-radius: 10px;
	background: #fff;
	color: var(--tb-text);
}
.tb-phone-group input[type="tel"] { flex: 1 1 auto; min-width: 0; }
.tb-phone-code:focus, .tb-phone-group input:focus { outline: none; border-color: var(--tb-primary); }

/* ==========================================================================
   Compact home page widget — [tour_builder_mini]
   Scoped under .tb-mini-wrap so it never collides with the full wizard.
   ========================================================================== */
.tb-mini-wrap {
	--tb-primary: #14284a;
	--tb-primary-light: #1f3f6e;
	--tb-accent: #d9a441;
	--tb-accent-light: #f3c56c;
	--tb-border: #e4e7ee;
	--tb-text: #182233;
	--tb-muted: #6b7280;
	--tb-gradient-navy: linear-gradient(135deg, #14284a 0%, #274a7e 100%);

	max-width: 100%;
	width: 100%;
	margin: 0;
	padding: 24px;
	font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
	color: var(--tb-text);
	box-sizing: border-box;
}
.tb-mini-wrap * { box-sizing: border-box; }

.tb-mini-card {
	display: grid;
	grid-template-columns: 1.35fr 1fr;
	background: #fff;
	border-radius: 20px;
	box-shadow: 0 20px 50px rgba(20, 40, 74, .14);
	overflow: hidden;
	min-height: 560px;
}
@media (max-width: 860px) {
	.tb-mini-card { grid-template-columns: 1fr; }
}

.tb-mini-form-col { padding: 40px; }
.tb-mini-badge {
	display: inline-block;
	background: var(--tb-accent-light);
	color: #6b4a10;
	font-size: 12px;
	font-weight: 700;
	padding: 5px 14px;
	border-radius: 999px;
	margin-bottom: 14px;
}
.tb-mini-title { font-size: 28px; font-weight: 800; color: var(--tb-primary); margin: 0 0 24px; }

.tb-mini-grid-3 { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; margin-bottom: 14px; }
.tb-mini-grid-3 > * { min-width: 0; }
@media (max-width: 640px) {
	.tb-mini-grid-3 { grid-template-columns: 1fr; }
}

.tb-mini-form-col input[type="text"],
.tb-mini-form-col input[type="email"],
.tb-mini-form-col input[type="tel"],
.tb-mini-form-col input[type="date"],
.tb-mini-form-col select,
.tb-mini-form-col textarea {
	width: 100%;
	font: inherit;
	font-size: 13.5px;
	padding: 12px 14px;
	border: 2px solid var(--tb-border);
	border-radius: 10px;
	color: var(--tb-text);
	background: #fff;
}
.tb-mini-form-col input:focus,
.tb-mini-form-col select:focus,
.tb-mini-form-col textarea:focus { outline: none; border-color: var(--tb-primary); }
.tb-mini-form-col textarea { resize: vertical; margin-bottom: 18px; }

.tb-mini-field-label { display: block; font-size: 13px; font-weight: 700; color: var(--tb-primary); margin-bottom: 8px; }
.tb-mini-field-label span { font-weight: 400; color: var(--tb-muted); font-size: 12px; }

.tb-mini-counter {
	display: flex;
	flex-direction: column;
	gap: 6px;
	border: 2px solid var(--tb-border);
	border-radius: 10px;
	padding: 8px 12px;
}
.tb-mini-counter-label { font-size: 12px; font-weight: 700; color: var(--tb-primary); }
.tb-mini-counter-label em { color: #c0392b; font-style: normal; }
.tb-mini-counter .tb-counter-controls { justify-content: space-between; gap: 8px; }
.tb-mini-counter .tb-counter-btn { width: 28px; height: 28px; font-size: 15px; }
.tb-mini-counter .tb-counter-controls .tb-counter-value { min-width: 18px; font-size: 14px; }

.tb-mini-radio-row { display: flex; flex-wrap: wrap; gap: 16px; margin-bottom: 22px; }
.tb-mini-radio { display: flex; align-items: center; gap: 6px; font-size: 13.5px; color: var(--tb-text); cursor: pointer; }
.tb-mini-radio input { width: 15px; height: 15px; accent-color: var(--tb-primary); }

.tb-mini-submit {
	font: inherit;
	font-weight: 700;
	font-size: 15px;
	padding: 14px 30px;
	border-radius: 999px;
	border: none;
	background: var(--tb-gradient-navy);
	color: #fff;
	cursor: pointer;
	box-shadow: 0 8px 20px rgba(20, 40, 74, .22);
	transition: filter .15s ease;
}
.tb-mini-submit:hover { filter: brightness(1.08); }
.tb-mini-submit:disabled { opacity: .6; cursor: not-allowed; }

.tb-mini-image-col {
	position: relative;
	background-size: cover;
	background-position: center;
	min-height: 300px;
}

@media (max-width: 860px) {
	.tb-mini-image-col { min-height: 220px; order: -1; }
}

.tb-mini-success { padding: 40px 0; text-align: center; }
.tb-mini-success h3 { color: var(--tb-primary); font-size: 22px; margin-bottom: 10px; }
.tb-mini-success p { color: var(--tb-muted); font-size: 15px; }
