/* Morocco Planet Experiences: journey layout
   Light, sand-toned look to sit on the site's patterned cream background.
   Re-theme by overriding the variables, e.g.  .mpxj { --mpxj-accent: #9c3f1b; } */

.mpxj {
	--mpxj-ink: #1a1210;
	--mpxj-dim: rgba(26, 18, 16, .64);
	--mpxj-line: rgba(26, 18, 16, .1);
	--mpxj-sand: #efe3d3;
	--mpxj-sand-deep: #e3d0b8;
	--mpxj-accent: #b5532b;
	--mpxj-radius: 18px;
	max-width: 1280px;
	margin: 0 auto;
	padding: clamp(32px, 6vw, 80px) clamp(16px, 4vw, 40px);
	color: var(--mpxj-ink);
	box-sizing: border-box;
}
.mpxj *, .mpxj *::before, .mpxj *::after { box-sizing: border-box; }
.mpxj a { color: inherit; text-decoration: none; }
.mpxj h2, .mpxj h3, .mpxj h4, .mpxj p, .mpxj ol { margin: 0; padding: 0; }
.mpxj svg { display: block; }

/* ---------- Intro ---------- */
.mpxj-head {
	display: grid;
	grid-template-columns: minmax(0, 1.3fr) minmax(0, 1fr);
	gap: 24px clamp(24px, 6vw, 90px);
	align-items: end;
}
.mpxj-eyebrow {
	margin-bottom: 14px !important;
	font-size: 13px;
	font-weight: 600;
	letter-spacing: .14em;
	text-transform: uppercase;
	color: var(--mpxj-accent);
}
.mpxj-h {
	font-size: clamp(38px, 5.4vw, 72px);
	line-height: 1.02;
	font-weight: 700;
	letter-spacing: -.045em;
	color: var(--mpxj-ink);
}
.mpxj-h em {
	font-style: italic;
	font-weight: 500;
	color: var(--mpxj-accent);
}
.mpxj-intro {
	font-size: clamp(16px, 1.3vw, 18px);
	line-height: 1.65;
	color: var(--mpxj-dim);
	max-width: 46ch;
	padding-bottom: 8px;
}

/* ---------- Journey rail ---------- */
.mpxj-rail {
	list-style: none;
	display: flex;
	margin-top: clamp(32px, 5vw, 56px) !important;
	overflow-x: auto;
	scrollbar-width: none;
	padding-bottom: 4px;
}
.mpxj-rail::-webkit-scrollbar { display: none; }
.mpxj-rail li { flex: 1 0 150px; position: relative; }
.mpxj-rail li::before {
	content: "";
	position: absolute;
	top: 6px;
	left: 14px;
	right: 0;
	height: 2px;
	background: var(--mpxj-sand-deep);
}
.mpxj-rail li:last-child::before { right: 50%; opacity: .5; }
.mpxj-rail a {
	position: relative;
	display: grid;
	gap: 2px;
	padding-right: 16px;
	font-size: 14px;
	color: var(--mpxj-dim);
}
.mpxj-rail strong {
	margin-top: 14px;
	font-size: 18px;
	font-weight: 700;
	letter-spacing: -.02em;
	color: var(--mpxj-ink);
}
.mpxj-dot {
	position: relative;
	z-index: 1;
	width: 14px;
	height: 14px;
	border-radius: 50%;
	background: var(--mpxj-accent);
	box-shadow: 0 0 0 4px var(--mpxj-sand);
	transition: transform .2s ease;
}
.mpxj-rail a:hover .mpxj-dot { transform: scale(1.25); }
.mpxj-rail a:hover strong { color: var(--mpxj-accent); }

/* ---------- Chapters ---------- */
.mpxj-chapter {
	display: grid;
	grid-template-columns: minmax(220px, 280px) minmax(0, 1fr);
	gap: 28px clamp(24px, 4vw, 56px);
	margin-top: clamp(40px, 6vw, 72px);
	padding-top: clamp(32px, 5vw, 56px);
	border-top: 1px solid var(--mpxj-line);
	scroll-margin-top: 90px;
}
.mpxj-ch-head { align-self: start; position: sticky; top: 110px; }
.mpxj-no {
	display: block;
	margin-bottom: 18px;
	font-size: 14px;
	font-weight: 600;
	letter-spacing: .1em;
	color: var(--mpxj-accent);
}
.mpxj-range {
	display: inline-block;
	margin-bottom: 14px !important;
	padding: 8px 16px;
	border-radius: 14px;
	background: var(--mpxj-sand);
	font-size: 15px;
	font-weight: 600;
}
.mpxj-ch-title {
	font-size: clamp(30px, 3.2vw, 44px);
	line-height: 1.05;
	font-weight: 700;
	letter-spacing: -.04em;
}
.mpxj-story {
	margin-top: 14px !important;
	font-size: 16px;
	line-height: 1.7;
	color: var(--mpxj-dim);
}

/* ---------- Cards ---------- */
.mpxj-grid {
	display: grid;
	grid-template-columns: repeat(auto-fill, minmax(230px, 1fr));
	gap: 28px 20px;
}
.mpxj-card { min-width: 0; }

.mpxj-img {
	position: relative;
	display: block;
	aspect-ratio: 3 / 4;
	overflow: hidden;
	border-radius: var(--mpxj-radius);
	background: var(--mpxj-sand);
	box-shadow: 0 18px 34px -18px rgba(26, 18, 16, .35);
	transition: transform .35s ease, box-shadow .35s ease;
}
.mpxj-img img {
	position: absolute;
	inset: 0;
	width: 100%;
	height: 100%;
	object-fit: cover;
	transition: transform .7s ease;
}
/* thin inner frame, echoing the site's destination cards */
.mpxj-img::after {
	content: "";
	position: absolute;
	inset: 10px;
	border: 1px solid rgba(255, 255, 255, .45);
	border-radius: calc(var(--mpxj-radius) - 6px);
	pointer-events: none;
}
.mpxj-card:hover .mpxj-img {
	transform: translateY(-4px);
	box-shadow: 0 26px 40px -18px rgba(26, 18, 16, .42);
}
.mpxj-card:hover .mpxj-img img { transform: scale(1.05); }
.mpxj-noimg { position: absolute; inset: 0; background: linear-gradient(160deg, var(--mpxj-sand-deep), var(--mpxj-sand)); }

.mpxj-days {
	position: absolute;
	z-index: 1;
	top: 20px;
	left: 20px;
	display: inline-flex;
	align-items: baseline;
	gap: 5px;
	padding: 7px 14px;
	border-radius: 999px;
	background: rgba(250, 246, 239, .94);
	font-size: 13px;
	font-weight: 600;
	color: var(--mpxj-ink);
	backdrop-filter: blur(4px);
}
.mpxj-days b { font-size: 20px; line-height: 1; letter-spacing: -.03em; }
.mpxj-badge {
	position: absolute;
	z-index: 1;
	top: 20px;
	right: 20px;
	padding: 6px 12px;
	border-radius: 999px;
	background: var(--mpxj-ink);
	font-size: 12px;
	font-weight: 600;
	color: #faf6ef;
}

.mpxj-info {
	display: flex;
	align-items: flex-start;
	justify-content: space-between;
	gap: 14px;
	padding: 18px 2px 0;
}
.mpxj-text { min-width: 0; }
.mpxj-title {
	font-size: 20px;
	line-height: 1.2;
	font-weight: 700;
	letter-spacing: -.03em;
}
.mpxj-title a:hover { color: var(--mpxj-accent); }
.mpxj-sub {
	margin-top: 6px !important;
	font-size: 14px;
	line-height: 1.45;
	color: var(--mpxj-dim);
}
.mpxj-meta {
	display: flex;
	flex-wrap: wrap;
	gap: 6px 14px;
	margin-top: 10px !important;
	font-size: 13px;
	color: var(--mpxj-dim);
}
.mpxj-meta span { display: inline-flex; align-items: center; gap: 5px; }
.mpxj-meta .mpx-ico { width: 14px; height: 14px; }
.mpxj-price strong { color: var(--mpxj-ink); font-weight: 700; }

.mpxj-go {
	flex: none;
	display: grid;
	place-items: center;
	width: 48px;
	height: 48px;
	border-radius: 16px;
	background: var(--mpxj-sand);
	color: var(--mpxj-ink);
	transition: background .2s ease, color .2s ease, transform .2s ease;
}
.mpxj-go svg { width: 18px; height: 18px; }
.mpxj-card:hover .mpxj-go, .mpxj-go:hover { background: var(--mpxj-ink); color: var(--mpxj-sand); }
.mpxj-card:hover .mpxj-go { transform: translateX(2px); }

/* ---------- Footer link ---------- */
.mpxj-more { margin-top: clamp(36px, 5vw, 56px) !important; }
.mpxj-more a {
	display: inline-flex;
	align-items: center;
	gap: 12px;
	padding: 16px 28px;
	border-radius: 999px;
	background: var(--mpxj-sand);
	font-size: 16px;
	font-weight: 600;
	transition: background .2s ease, color .2s ease;
}
.mpxj-more a:hover { background: var(--mpxj-ink); color: var(--mpxj-sand); }
.mpxj-more svg { width: 18px; height: 18px; }

.mpxj a:focus-visible { outline: 2px solid var(--mpxj-accent); outline-offset: 3px; border-radius: 6px; }

/* ---------- Responsive ---------- */
@media (max-width: 1024px) {
	.mpxj-chapter { grid-template-columns: 1fr; }
	.mpxj-ch-head { position: static; max-width: 560px; }
}
@media (max-width: 760px) {
	.mpxj-head { grid-template-columns: 1fr; }
	.mpxj-grid { grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); gap: 24px 14px; }
}
@media (max-width: 480px) {
	.mpxj-grid { grid-template-columns: 1fr; }
	.mpxj-img { aspect-ratio: 4 / 5; }
}
@media (prefers-reduced-motion: reduce) {
	.mpxj *, .mpxj *::before, .mpxj *::after { transition: none !important; }
}
