/**
 * MeetPress booking widget, in the Affineur Voyages identity.
 *
 * Tokens are scoped to .mp-widget rather than :root so the widget carries its
 * own identity into any template without leaking variables into the theme.
 * A journey is composed, so the booking reads as a composition: three
 * movements, numbered in Roman, set in bone on forest black.
 */

.mp-widget {
	/* Dark surfaces */
	--bone: #1a1e14;
	--bone-2: #22261a;
	--footer: #0f1209;

	/* Warm neutrals */
	--ink: #f3efe6;
	--ink-soft: rgba(243, 239, 230, .82);
	--ink-mute: rgba(243, 239, 230, .55);

	/* Gold accents */
	--gold: #a88553;
	--gold-soft: #c8a877;

	/* Lines */
	--line: rgba(243, 239, 230, .18);
	--line-soft: rgba(243, 239, 230, .08);

	/* Motion */
	--ease: cubic-bezier(.2, .7, .2, 1);
	--ease-out: cubic-bezier(.16, 1, .3, 1);

	position: relative;
	display: flex;
	flex-wrap: wrap;
	align-items: stretch;
	box-sizing: border-box;
	max-width: 1100px;
	margin: 0 auto;
	font-family: 'Jost', sans-serif;
	font-weight: 300;
	font-size: 16px;
	line-height: 29px;
	color: var(--ink);
	background: var(--bone);
	border: 1px solid var(--line-soft);
}

.mp-widget *,
.mp-widget *::before,
.mp-widget *::after {
	box-sizing: border-box;
}

.mp-widget ::selection {
	background: var(--ink);
	color: var(--bone);
}

/* Soft-light noise, scoped to the widget so it survives an unbranded theme. */
.mp-widget::before {
	content: "";
	position: absolute;
	inset: 0;
	pointer-events: none;
	z-index: 1;
	mix-blend-mode: soft-light;
	opacity: .25;
	background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='250' height='250'><filter id='n'><feTurbulence type='fractalNoise' baseFrequency='.78' numOctaves='3' seed='7'/><feColorMatrix values='0 0 0 0 .9 0 0 0 0 .88 0 0 0 0 .82 0 0 0 .18 0'/></filter><rect width='100%25' height='100%25' filter='url(%23n)'/></svg>");
}

.mp-pane {
	position: relative;
	z-index: 2;
	padding: 56px 48px;
}

.mp-pane--about {
	flex: 1 1 300px;
	min-width: 280px;
	background: var(--bone-2);
	border-right: 1px solid var(--line-soft);
}

.mp-pane--pick {
	flex: 2 1 520px;
	min-width: 320px;
}

/* Eyebrow ---------------------------------------------------------------- */

.mp-eyebrow {
	display: flex;
	align-items: center;
	gap: 14px;
	margin: 0 0 28px;
	font-family: 'Jost', sans-serif;
	font-weight: 400;
	font-size: 11px;
	line-height: 1.9;
	letter-spacing: .4em;
	text-transform: uppercase;
	color: var(--gold);
}

/*
 * The rules hold their 32px whatever the brand line's length. Without this
 * they shrink as flex items and the motif quietly loses its proportion.
 */
.mp-eyebrow::before,
.mp-eyebrow::after {
	content: "";
	flex: 0 0 32px;
	width: 32px;
	height: 1px;
	background: var(--gold);
}

/* Title, facts, lede ----------------------------------------------------- */

.mp-title {
	margin: 0 0 28px;
	font-family: 'Fraunces', serif;
	font-weight: 300;
	font-variation-settings: "SOFT" 30, "WONK" 1;
	font-size: clamp(32px, 3.6vw, 46px);
	line-height: 1.05;
	letter-spacing: -.025em;
	color: var(--ink);
}

.mp-title em,
.mp-title i {
	font-style: italic;
	font-variation-settings: "SOFT" 65, "WONK" 1;
	color: var(--gold);
}

.mp-facts {
	margin: 0 0 28px;
	padding: 0;
	list-style: none;
}

.mp-fact {
	display: flex;
	gap: 16px;
	padding: 12px 0;
	font-size: 13px;
	line-height: 1.5;
	border-top: 1px solid var(--line-soft);
}

.mp-fact:last-child {
	border-bottom: 1px solid var(--line-soft);
}

.mp-fact__key {
	flex: 0 0 96px;
	font-size: 11px;
	letter-spacing: .28em;
	text-transform: uppercase;
	color: var(--gold);
	line-height: 2;
}

.mp-fact__value {
	color: var(--ink);
	letter-spacing: .02em;
}

.mp-description {
	font-size: 16px;
	line-height: 29px;
	color: var(--ink);
}

.mp-description p {
	margin: 0 0 16px;
}

.mp-description p:last-child {
	margin-bottom: 0;
}

.mp-description em,
.mp-description i {
	font-family: 'Fraunces', serif;
	font-style: italic;
	font-weight: 300;
	font-variation-settings: "SOFT" 60, "WONK" 1;
	color: var(--gold-soft);
}

/* The rail: three movements, numbered in Roman --------------------------- */

.mp-rail {
	display: flex;
	flex-wrap: wrap;
	gap: 32px;
	margin: 0 0 40px;
	padding: 0 0 20px;
	list-style: none;
	border-bottom: 1px solid var(--line-soft);
}

.mp-rail__item {
	display: inline-flex;
	align-items: baseline;
	gap: 10px;
	font-size: 11px;
	letter-spacing: .28em;
	text-transform: uppercase;
	color: var(--ink-mute);
	transition: color .5s var(--ease);
}

.mp-rail__item .mp-roman {
	font-family: 'Fraunces', serif;
	font-style: italic;
	font-weight: 200;
	font-size: 15px;
	letter-spacing: 0;
	text-transform: none;
	color: var(--gold);
	opacity: .45;
	transition: opacity .5s var(--ease);
}

.mp-rail__item.is-current {
	color: var(--ink);
}

.mp-rail__item.is-current .mp-roman {
	opacity: 1;
}

/* Calendar --------------------------------------------------------------- */

.mp-step--calendar {
	display: grid;
	grid-template-columns: minmax(260px, 1fr) minmax(170px, 220px);
	gap: 44px;
}

.mp-cal__head {
	display: flex;
	align-items: center;
	justify-content: space-between;
	margin-bottom: 24px;
}

.mp-cal__month {
	margin: 0;
	font-family: 'Fraunces', serif;
	font-weight: 300;
	font-variation-settings: "SOFT" 30, "WONK" 1;
	font-size: 21px;
	line-height: 1;
	letter-spacing: -.01em;
	color: var(--ink);
}

.mp-nav {
	width: 34px;
	height: 34px;
	padding: 0;
	font-size: 15px;
	line-height: 1;
	color: var(--gold);
	background: none;
	border: 1px solid var(--line);
	border-radius: 0;
	cursor: pointer;
	transition: background .5s var(--ease), border-color .5s var(--ease), color .5s var(--ease);
}

.mp-nav:hover:not(:disabled) {
	background: rgba(168, 133, 83, .08);
	border-color: var(--gold);
}

.mp-nav:disabled {
	color: var(--ink-mute);
	opacity: .3;
	cursor: default;
}

.mp-cal__weekdays,
.mp-cal__grid {
	display: grid;
	grid-template-columns: repeat(7, 1fr);
	gap: 2px;
}

.mp-cal__weekdays {
	margin-bottom: 10px;
}

.mp-cal__weekdays span {
	padding: 6px 0;
	font-size: 10px;
	font-weight: 400;
	text-align: center;
	text-transform: uppercase;
	letter-spacing: .24em;
	color: var(--gold);
}

.mp-cell {
	aspect-ratio: 1 / 1;
	display: flex;
	align-items: center;
	justify-content: center;
	font-family: 'Jost', sans-serif;
	font-weight: 300;
	font-size: 14px;
	font-variant-numeric: tabular-nums;
	border: 1px solid transparent;
	border-radius: 0;
	background: none;
	transition: background .5s var(--ease), border-color .5s var(--ease), color .5s var(--ease);
}

.mp-day.is-open {
	color: var(--ink);
	background: rgba(168, 133, 83, .04);
	border-color: var(--line-soft);
	cursor: pointer;
}

.mp-day.is-open:hover {
	background: rgba(168, 133, 83, .08);
	border-color: var(--line);
}

.mp-day.is-closed {
	color: rgba(243, 239, 230, .22);
	cursor: default;
}

.mp-day.is-selected,
.mp-day.is-selected:hover {
	color: var(--bone);
	background: var(--gold);
	border-color: var(--gold);
}

/* Times ------------------------------------------------------------------ */

.mp-times__title {
	margin: 0 0 18px;
	font-family: 'Fraunces', serif;
	font-style: italic;
	font-weight: 300;
	font-variation-settings: "SOFT" 60, "WONK" 1;
	font-size: 18px;
	line-height: 1.35;
	color: var(--ink);
}

.mp-times__list {
	display: grid;
	gap: 6px;
	max-height: 380px;
	overflow-y: auto;
	scrollbar-width: thin;
	scrollbar-color: var(--line) transparent;
}

/*
 * Slots take the house CTA motion: gold rises from below and the time inverts
 * to bone. Choosing an hour should feel like every other commitment on the
 * site, not like a form control.
 */
.mp-slot {
	position: relative;
	display: block;
	width: 100%;
	padding: 13px 8px;
	font-family: 'Jost', sans-serif;
	font-weight: 400;
	font-size: 12px;
	letter-spacing: .18em;
	font-variant-numeric: tabular-nums;
	color: var(--gold);
	background: none;
	border: 1px solid var(--line);
	border-radius: 0;
	cursor: pointer;
	overflow: hidden;
	transition: color .5s var(--ease), border-color .5s var(--ease);
}

.mp-slot::before {
	content: "";
	position: absolute;
	inset: 0;
	z-index: 0;
	background: var(--gold);
	transform: translateY(101%);
	transition: transform .5s var(--ease);
}

.mp-slot__time {
	position: relative;
	z-index: 1;
}

.mp-slot:hover,
.mp-slot:focus-visible {
	color: var(--bone);
	border-color: var(--gold);
}

.mp-slot:hover::before,
.mp-slot:focus-visible::before {
	transform: translateY(0);
}

.mp-empty {
	margin: 0;
	font-size: 14px;
	line-height: 1.6;
	color: var(--ink-mute);
}

/* Timezone --------------------------------------------------------------- */

.mp-tz {
	grid-column: 1 / -1;
	padding-top: 28px;
	border-top: 1px solid var(--line-soft);
}

.mp-tz label {
	display: block;
	margin-bottom: 10px;
	font-size: 11px;
	letter-spacing: .28em;
	text-transform: uppercase;
	color: var(--gold);
}

.mp-tz__select {
	width: 100%;
	max-width: 320px;
	padding: 11px 12px;
	font-family: 'Jost', sans-serif;
	font-weight: 300;
	font-size: 14px;
	color: var(--ink);
	background: var(--bone-2);
	border: 1px solid var(--line);
	border-radius: 0;
	transition: border-color .5s var(--ease);
}

.mp-tz__select:hover {
	border-color: var(--gold);
}

/* Form ------------------------------------------------------------------- */

.mp-back {
	display: inline-flex;
	align-items: center;
	gap: 10px;
	margin-bottom: 24px;
	padding: 0;
	font-family: 'Jost', sans-serif;
	font-weight: 400;
	font-size: 11px;
	letter-spacing: .28em;
	text-transform: uppercase;
	color: var(--ink-mute);
	background: none;
	border: 0;
	cursor: pointer;
	transition: color .5s var(--ease);
}

.mp-back:hover {
	color: var(--gold);
}

.mp-chosen {
	margin: 0 0 36px;
	padding-bottom: 28px;
	font-family: 'Fraunces', serif;
	font-style: italic;
	font-weight: 300;
	font-variation-settings: "SOFT" 60, "WONK" 1;
	font-size: clamp(18px, 2.2vw, 24px);
	line-height: 1.5;
	color: var(--ink);
	border-bottom: 1px solid var(--line-soft);
}

.mp-field {
	margin-bottom: 26px;
	max-width: 520px;
}

.mp-field label {
	display: block;
	margin-bottom: 10px;
	font-family: 'Jost', sans-serif;
	font-weight: 400;
	font-size: 11px;
	letter-spacing: .28em;
	text-transform: uppercase;
	color: var(--gold);
}

/* Quietly marks a field nobody has to fill in. */
.mp-optional {
	margin-left: 8px;
	font-family: 'Fraunces', serif;
	font-style: italic;
	font-weight: 200;
	font-size: 13px;
	letter-spacing: 0;
	text-transform: none;
	color: var(--ink-mute);
}

.mp-input {
	width: 100%;
	padding: 13px 14px;
	font-family: 'Jost', sans-serif;
	font-weight: 300;
	font-size: 16px;
	line-height: 1.6;
	color: var(--ink);
	background: rgba(168, 133, 83, .04);
	border: 1px solid var(--line-soft);
	border-radius: 0;
	transition: background .5s var(--ease), border-color .5s var(--ease);
}

.mp-input::placeholder {
	color: var(--ink-mute);
}

.mp-input:hover {
	background: rgba(168, 133, 83, .08);
}

.mp-input:focus {
	outline: none;
	background: rgba(168, 133, 83, .08);
	border-color: var(--gold);
}

textarea.mp-input {
	resize: vertical;
}

.mp-honey {
	position: absolute;
	left: -9999px;
	width: 1px;
	height: 1px;
	overflow: hidden;
}

/* House CTA */
.mp-submit {
	display: inline-flex;
	align-items: center;
	gap: 14px;
	padding: 18px 32px;
	position: relative;
	overflow: hidden;
	font-family: 'Jost', sans-serif;
	font-weight: 400;
	font-size: 11px;
	letter-spacing: .32em;
	text-transform: uppercase;
	color: var(--gold);
	background: none;
	border: 1px solid var(--gold);
	border-radius: 0;
	cursor: pointer;
	transition: color .5s var(--ease), border-color .5s var(--ease);
}

.mp-submit::before {
	content: "";
	position: absolute;
	inset: 0;
	z-index: 0;
	background: var(--gold);
	transform: translateY(101%);
	transition: transform .5s var(--ease);
}

.mp-submit > span {
	position: relative;
	z-index: 1;
}

.mp-submit:hover:not(:disabled) {
	color: var(--bone);
}

.mp-submit:hover:not(:disabled)::before {
	transform: translateY(0);
}

.mp-submit:disabled {
	color: var(--ink-mute);
	border-color: var(--line);
	cursor: default;
}

.mp-error {
	margin: 0 0 20px;
	padding-left: 16px;
	font-size: 14px;
	line-height: 1.6;
	color: var(--gold-soft);
	border-left: 1px solid var(--gold);
}

/* Confirmation ----------------------------------------------------------- */

.mp-done__title {
	margin: 0 0 20px;
	font-family: 'Fraunces', serif;
	font-weight: 300;
	font-variation-settings: "SOFT" 30, "WONK" 1;
	font-size: clamp(28px, 3.2vw, 40px);
	line-height: 1.1;
	letter-spacing: -.025em;
	color: var(--ink);
}

.mp-done__title em,
.mp-done__title i {
	font-style: italic;
	font-variation-settings: "SOFT" 65, "WONK" 1;
	color: var(--gold);
}

.mp-done__when {
	margin: 0 0 24px;
	padding-bottom: 24px;
	font-family: 'Fraunces', serif;
	font-style: italic;
	font-weight: 300;
	font-variation-settings: "SOFT" 60, "WONK" 1;
	font-size: clamp(18px, 2.2vw, 24px);
	line-height: 1.5;
	color: var(--ink);
	border-bottom: 1px solid var(--line-soft);
}

.mp-done__note {
	margin: 0 0 28px;
	max-width: 46ch;
	color: var(--ink);
}

.mp-done__manage {
	display: inline-block;
	padding-bottom: 4px;
	font-size: 11px;
	letter-spacing: .28em;
	text-transform: uppercase;
	color: var(--gold);
	text-decoration: none;
	border-bottom: 1px solid var(--line);
	transition: border-color .5s var(--ease);
}

.mp-done__manage:hover {
	border-bottom-color: var(--gold);
}

.mp-notice {
	max-width: 1100px;
	margin: 0 auto;
	padding: 32px 36px;
	font-family: 'Jost', sans-serif;
	font-weight: 300;
	font-size: 16px;
	line-height: 29px;
	color: var(--ink);
	background: var(--bone-2);
	border: 1px solid var(--line-soft);
}

/* Focus and motion ------------------------------------------------------- */

.mp-widget button:focus-visible,
.mp-widget select:focus-visible,
.mp-widget a:focus-visible {
	outline: 1px solid var(--gold);
	outline-offset: 3px;
}

@media (prefers-reduced-motion: reduce) {
	.mp-widget *,
	.mp-widget *::before,
	.mp-widget *::after {
		transition-duration: .01ms !important;
	}
}

/* Narrow ----------------------------------------------------------------- */

@media (max-width: 960px) {
	.mp-step--calendar {
		gap: 32px;
	}
}

@media (max-width: 860px) {
	.mp-pane {
		padding: 40px 32px;
	}

	.mp-pane--about {
		border-right: 0;
		border-bottom: 1px solid var(--line-soft);
	}

	.mp-step--calendar {
		grid-template-columns: 1fr;
	}

	.mp-times__list {
		max-height: none;
	}
}

@media (max-width: 640px) {
	.mp-pane {
		padding: 32px 24px;
	}

	.mp-rail {
		gap: 20px;
	}

	.mp-fact {
		flex-direction: column;
		gap: 4px;
	}

	.mp-fact__key {
		flex: none;
		line-height: 1.5;
	}
}

@media (max-width: 380px) {
	.mp-eyebrow::before,
	.mp-eyebrow::after {
		width: 16px;
	}

	.mp-rail__item {
		letter-spacing: .18em;
	}
}
