/**
 * Components: cards, chips, grids, accordions, booking card, empty state.
 * Consumes tokens from 01-tokens.css only.
 */

/* ---------- Tour card ---------- */

.tpt-grid {
	display: grid;
	grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
	gap: var(--tpt-space-8);
}

.tpt-card {
	background: var(--tpt-surface);
	border: 1px solid var(--tpt-sand-300);
	border-radius: var(--tpt-radius-card);
	box-shadow: var(--tpt-shadow-rest);
	overflow: hidden;
	transition: transform var(--tpt-transition), box-shadow var(--tpt-transition);
}

.tpt-card:hover,
.tpt-card:focus-within {
	transform: translateY(-3px);
	box-shadow: var(--tpt-shadow-hover);
}

.tpt-card__link {
	display: block;
	color: inherit;
	text-decoration: none;
}

.tpt-card__media {
	position: relative;
	aspect-ratio: 4 / 3;
	background: var(--tpt-sand-100);
	overflow: hidden;
}

.tpt-card__media img {
	width: 100%;
	height: 100%;
	object-fit: cover;
	transition: transform 240ms ease-out;
}

.tpt-card:hover .tpt-card__media img {
	transform: scale(1.03);
}

.tpt-card__media--placeholder::after {
	/* subtle geometric stand-in until photography arrives */
	content: "";
	position: absolute;
	inset: 0;
	background:
		radial-gradient(circle at 30% 40%, rgba(20, 96, 106, 0.12), transparent 55%),
		repeating-linear-gradient(135deg, transparent 0 14px, rgba(180, 85, 45, 0.06) 14px 15px);
}

.tpt-card__body {
	padding: var(--tpt-space-5) var(--tpt-space-6) var(--tpt-space-6);
}

.tpt-card__title {
	font-size: var(--tpt-text-h3);
	margin-bottom: var(--tpt-space-2);
}

.tpt-card__meta {
	color: var(--tpt-ink-600);
	font-size: var(--tpt-text-small);
	margin-bottom: var(--tpt-space-3);
}

.tpt-card__excerpt {
	color: var(--tpt-ink-600);
	font-size: var(--tpt-text-small);
	margin-bottom: var(--tpt-space-4);
	display: -webkit-box;
	-webkit-line-clamp: 2;
	-webkit-box-orient: vertical;
	overflow: hidden;
}

.tpt-card__footer {
	display: flex;
	align-items: baseline;
	justify-content: space-between;
	gap: var(--tpt-space-4);
	padding-top: var(--tpt-space-4);
	border-top: 1px solid var(--tpt-sand-300);
}

.tpt-card__price {
	margin: 0;
	font-size: var(--tpt-text-small);
	color: var(--tpt-ink-600);
}

.tpt-card__price strong {
	display: block;
	font-size: 1.125rem;
	font-family: var(--tpt-font-display);
	font-weight: 600;
	color: var(--tpt-clay-600);
}

.tpt-card__price-note {
	display: block;
	font-size: 0.75rem;
}

.tpt-card__cta {
	color: var(--tpt-nile-700);
	font-weight: 600;
	font-size: var(--tpt-text-small);
	white-space: nowrap;
}

.tpt-card:hover .tpt-card__cta {
	text-decoration: underline;
	text-underline-offset: 3px;
}

.tpt-card--placeholder {
	min-height: 320px;
	display: flex;
	align-items: center;
	justify-content: center;
	border-style: dashed;
	box-shadow: none;
}

/* ---------- Chips ---------- */

.tpt-chip {
	display: inline-flex;
	align-items: center;
	gap: var(--tpt-space-1);
	padding: var(--tpt-space-1) var(--tpt-space-3);
	border-radius: var(--tpt-radius-badge);
	background: var(--tpt-surface);
	border: 1px solid var(--tpt-sand-300);
	font-size: 0.75rem;
	font-weight: 600;
	line-height: 1.6;
}

.tpt-chip--destination {
	position: absolute;
	top: var(--tpt-space-4);
	left: var(--tpt-space-4);
	background: var(--tpt-sand-050);
	color: var(--tpt-ink-900);
}

.tpt-chip--duration {
	position: absolute;
	top: var(--tpt-space-4);
	right: var(--tpt-space-4);
	background: rgba(34, 27, 20, 0.72);
	color: #fff;
	border-color: transparent;
}

/* ---------- Destination cards ---------- */

.tpt-dest-grid {
	display: grid;
	grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
	gap: var(--tpt-space-6);
}

.tpt-dest-card {
	position: relative;
	display: block;
	border-radius: var(--tpt-radius-card);
	overflow: hidden;
	text-decoration: none;
	min-height: 300px;
}

.tpt-dest-card--featured {
	grid-column: span 2;
	grid-row: span 2;
	min-height: 100%;
}

.tpt-dest-card__media {
	position: absolute;
	inset: 0;
}

.tpt-dest-card__media img {
	width: 100%;
	height: 100%;
	object-fit: cover;
}

.tpt-dest-card__media::after {
	content: "";
	position: absolute;
	inset: 0;
	background: var(--tpt-scrim);
}

.tpt-dest-card__media--placeholder::before {
	content: "";
	position: absolute;
	inset: 0;
	z-index: -1;
	background:
		radial-gradient(circle at 65% 30%, rgba(20, 96, 106, 0.25), transparent 60%),
		var(--tpt-sand-100);
}

.tpt-dest-card__label {
	position: absolute;
	inset-inline: 0;
	bottom: 0;
	padding: var(--tpt-space-5) var(--tpt-space-6);
	color: #fff;
}

.tpt-dest-card__title {
	font-size: var(--tpt-text-h3);
	color: #fff;
	margin: 0 0 var(--tpt-space-1);
}

.tpt-dest-card__count {
	margin: 0;
	font-size: var(--tpt-text-small);
	color: rgba(255, 255, 255, 0.85);
}

.tpt-dest-card--placeholder {
	display: flex;
	align-items: center;
	justify-content: center;
	border: 1px dashed var(--tpt-sand-300);
	border-radius: var(--tpt-radius-card);
}

/* ---------- Filter chips ---------- */

.tpt-filters {
	display: flex;
	flex-wrap: wrap;
	gap: var(--tpt-space-3);
	margin-bottom: var(--tpt-space-10);
}

.tpt-chip--filter {
	padding: var(--tpt-space-2) var(--tpt-space-4);
	border-radius: var(--tpt-radius-pill);
	text-decoration: none;
	color: var(--tpt-ink-900);
	font-size: var(--tpt-text-small);
	transition: background-color var(--tpt-transition), color var(--tpt-transition);
}

.tpt-chip--filter:hover {
	border-color: var(--tpt-nile-700);
	color: var(--tpt-nile-700);
}

.tpt-chip--filter.is-active {
	background: var(--tpt-nile-700);
	border-color: var(--tpt-nile-700);
	color: #fff;
}

.tpt-chip__count {
	opacity: 0.7;
	font-weight: 500;
}

/* ---------- Experience chips ---------- */

.tpt-experiences {
	display: flex;
	flex-wrap: wrap;
	gap: var(--tpt-space-4);
}

.tpt-experience-chip {
	display: inline-flex;
	align-items: center;
	min-height: var(--tpt-control-height);
	padding: var(--tpt-space-3) var(--tpt-space-6);
	background: var(--tpt-surface);
	border: 1px solid var(--tpt-sand-300);
	border-radius: var(--tpt-radius-pill);
	text-decoration: none;
	color: var(--tpt-ink-900);
	font-weight: 600;
	transition: background-color var(--tpt-transition), color var(--tpt-transition),
		transform var(--tpt-transition);
}

.tpt-experience-chip:hover {
	background: var(--tpt-nile-700);
	border-color: var(--tpt-nile-700);
	color: #fff;
	transform: translateY(-2px);
}

/* ---------- Accordion (details/summary — no JS) ---------- */

.tpt-itinerary__day,
.tpt-faq__item {
	background: var(--tpt-surface);
	border: 1px solid var(--tpt-sand-300);
	border-radius: var(--tpt-radius-card);
	margin-bottom: var(--tpt-space-4);
	overflow: hidden;
}

.tpt-itinerary__day summary,
.tpt-faq__item summary {
	display: flex;
	align-items: center;
	gap: var(--tpt-space-4);
	padding: var(--tpt-space-5) var(--tpt-space-6);
	cursor: pointer;
	font-family: var(--tpt-font-display);
	font-weight: 560;
	list-style: none;
}

.tpt-itinerary__day summary::-webkit-details-marker,
.tpt-faq__item summary::-webkit-details-marker {
	display: none;
}

.tpt-itinerary__day summary::after,
.tpt-faq__item summary::after {
	content: "+";
	margin-left: auto;
	font-family: var(--tpt-font-body);
	font-size: 1.25rem;
	color: var(--tpt-nile-700);
	flex-shrink: 0;
}

.tpt-itinerary__day[open] summary::after,
.tpt-faq__item[open] summary::after {
	content: "\2212";
}

.tpt-itinerary__index {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 32px;
	height: 32px;
	border-radius: 50%;
	background: var(--tpt-nile-050);
	color: var(--tpt-nile-700);
	font-family: var(--tpt-font-body);
	font-size: var(--tpt-text-small);
	font-weight: 600;
	flex-shrink: 0;
}

.tpt-itinerary__content,
.tpt-faq__answer {
	padding: 0 var(--tpt-space-6) var(--tpt-space-5);
	color: var(--tpt-ink-600);
}

.tpt-itinerary__content p:last-child,
.tpt-faq__answer p:last-child {
	margin-bottom: 0;
}

/* ---------- Inclusions / highlights ---------- */

.tpt-inclusions {
	display: grid;
	gap: var(--tpt-space-8);
}

.tpt-inclusions h3 {
	font-size: var(--tpt-text-h4);
}

.tpt-inclusions__list li,
.tpt-highlights li {
	display: flex;
	gap: var(--tpt-space-3);
	padding: var(--tpt-space-2) 0;
	align-items: baseline;
}

.tpt-inclusions__list--yes li > span {
	color: var(--tpt-nile-700);
	font-weight: 700;
}

.tpt-inclusions__list--no li > span {
	color: var(--tpt-clay-600);
	font-weight: 700;
}

.tpt-highlights li > span {
	color: var(--tpt-clay-600);
	font-size: 0.75em;
}

/* ---------- Booking card ---------- */

.tpt-booking-card {
	background: var(--tpt-surface);
	border: 1px solid var(--tpt-sand-300);
	border-radius: var(--tpt-radius-card);
	box-shadow: var(--tpt-shadow-rest);
	padding: var(--tpt-space-8);
	position: sticky;
	top: calc(var(--tpt-header-height) + var(--tpt-space-4));
}

.tpt-booking-card__price {
	margin-bottom: var(--tpt-space-5);
	padding-bottom: var(--tpt-space-5);
	border-bottom: 1px solid var(--tpt-sand-300);
}

.tpt-booking-card__price-prefix {
	display: block;
	font-size: var(--tpt-text-small);
	color: var(--tpt-ink-600);
}

.tpt-booking-card__price strong {
	font-family: var(--tpt-font-display);
	font-size: 2rem;
	font-weight: 600;
	color: var(--tpt-clay-600);
}

.tpt-booking-card__price-note {
	color: var(--tpt-ink-600);
	font-size: var(--tpt-text-small);
}

.tpt-booking-card__facts {
	margin: 0 0 var(--tpt-space-6);
}

.tpt-booking-card__facts div {
	display: flex;
	justify-content: space-between;
	gap: var(--tpt-space-4);
	padding: var(--tpt-space-2) 0;
	border-bottom: 1px dashed var(--tpt-sand-300);
}

.tpt-booking-card__facts dt {
	color: var(--tpt-ink-600);
	font-size: var(--tpt-text-small);
}

.tpt-booking-card__facts dd {
	margin: 0;
	font-weight: 500;
	font-size: var(--tpt-text-small);
}

.tpt-booking-card__note {
	margin: var(--tpt-space-4) 0 0;
	font-size: var(--tpt-text-small);
	color: var(--tpt-ink-600);
	text-align: center;
}

/* ---------- Gallery ---------- */

.tpt-gallery {
	display: grid;
	grid-template-columns: repeat(3, 1fr);
	grid-auto-rows: 220px;
	gap: var(--tpt-space-4);
}

.tpt-gallery__item {
	margin: 0;
	border-radius: var(--tpt-radius-badge);
	overflow: hidden;
}

.tpt-gallery__item img {
	width: 100%;
	height: 100%;
	object-fit: cover;
}

/* editorial rhythm: alternate spans */
.tpt-gallery__item:nth-child(3n + 1) {
	grid-row: span 2;
}

.tpt-gallery__item--placeholder {
	display: flex;
	align-items: center;
	justify-content: center;
	background: var(--tpt-sand-100);
	border: 1px dashed var(--tpt-sand-300);
	border-radius: var(--tpt-radius-badge);
}

.tpt-gallery--tour {
	grid-auto-rows: 180px;
}

/* ---------- Empty state & placeholders ---------- */

.tpt-empty {
	background: var(--tpt-surface);
	border: 1px solid var(--tpt-sand-300);
	border-radius: var(--tpt-radius-card);
	padding: var(--tpt-space-16) var(--tpt-space-8);
	text-align: center;
	max-width: 560px;
	margin-inline: auto;
}

.tpt-empty h2 {
	font-size: var(--tpt-text-h3);
}

.tpt-empty .tpt-btn {
	margin-top: var(--tpt-space-4);
}

.tpt-placeholder-tag {
	font-size: var(--tpt-text-eyebrow);
	text-transform: uppercase;
	letter-spacing: 0.12em;
	color: var(--tpt-ink-600);
	opacity: 0.7;
}

.tpt-inline-note {
	font-size: var(--tpt-text-small);
	color: var(--tpt-nile-700);
	font-weight: 500;
}
