/* Paultech Booking System — self-contained UI styles.
   Values mirror the original design 1:1 (card 720px / 40px pad / 20px radius,
   24px-800 headings, 2px borders, 18px-700 buttons, #162F62 navy, #EEF4FF
   summary, pill radius 50px). */

.mb-wrap {
	font-family: 'Roboto', 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
	/* !important so the widget keeps its width on any host theme. Card = 720px. */
	max-width: 752px !important;
	margin-left: auto !important;
	margin-right: auto !important;
	margin-top: 40px;
	margin-bottom: 40px;
	padding: 0 16px;
	width: 100%;
	color: #333;
	box-sizing: border-box;
}
.mb-wrap *, .mb-wrap *::before, .mb-wrap *::after { box-sizing: border-box; }

/* Progress steps */
.mb-steps {
	display: flex;
	align-items: center;
	justify-content: center;
	gap: 10px;
	margin-bottom: 28px;
}
.mb-step {
	display: inline-flex;
	align-items: center;
	gap: 9px;
	font-size: 13px;
	font-weight: 600;
	color: #9aa7c2;
	background: #eef2fb;
	padding: 10px 24px;
	border-radius: 50px;
	white-space: nowrap;
}
.mb-step.active { color: #fff; background: #4D7DE1; }
.mb-step.done { color: #1f9d57; background: #e4f6ec; }
.mb-step-num, .mb-step-check {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 22px; height: 22px;
	border-radius: 50%;
	font-size: 12px;
	background: rgba(255,255,255,.35);
}
.mb-step.active .mb-step-num { background: rgba(255,255,255,.3); color:#fff; }
.mb-step.done .mb-step-check { background: #1f9d57; color: #fff; }
.mb-step:not(.active):not(.done) .mb-step-num { background: #d6deef; color: #fff; }
.mb-step-line { flex: 1; height: 2px; background: #d9e1f2; }
.mb-step-line.done { background: #1f9d57; }

/* Card */
.mb-card {
	background: #fff;
	border-radius: 20px;
	box-shadow: 0 4px 24px rgba(77,125,225,.08);
	padding: 40px;
}
.mb-title { font-size: 24px; font-weight: 800; color: #162F62; margin: 0 0 6px; }
.mb-sub { font-size: 15px; color: #888; margin: 0 0 32px; }

/* Step 1 intro / practitioner card (photo + details row, optional full-width row below) */
.mb-intro {
	padding: 22px 26px;
	margin-bottom: 20px;
}
.mb-intro-top {
	display: flex;
	align-items: center;
	gap: 20px;
}
.mb-intro-photo { flex: none; }
.mb-intro-photo img {
	width: 96px; height: 96px;
	border-radius: 14px;
	object-fit: cover;
	display: block;
}
.mb-intro-body { min-width: 0; }
.mb-intro-name { font-size: 18px; font-weight: 800; color: #162F62; }
.mb-intro-title { font-size: 14px; font-weight: 600; color: #4D7DE1; margin-top: 2px; }
.mb-intro-desc { font-size: 13px; color: #666; line-height: 1.55; margin-top: 8px; }
.mb-intro-desc2 {
	font-size: 13px; color: #666; line-height: 1.6;
	margin-top: 16px; padding-top: 16px;
	border-top: 1px solid #EEF4FF;
}

.mb-label {
	display: block;
	font-size: 14px;
	font-weight: 600;
	color: #162F62;
	margin: 0 0 10px;
}

/* Select */
.mb-select-wrap { position: relative; margin-bottom: 24px; }
.mb-select {
	width: 100%;
	appearance: none; -webkit-appearance: none;
	border: 2px solid #E8EEF9;
	border-radius: 10px;
	padding: 14px 48px 14px 16px;
	font-size: 15px;
	line-height: 1.5;
	height: auto !important; /* override themes that force a fixed select height */
	min-height: 0;
	color: #333;
	background: #fff;
	cursor: pointer;
	font-family: inherit;
}
.mb-select-wrap::after {
	content: "";
	position: absolute; right: 16px; top: 50%;
	width: 13px; height: 9px;
	transform: translateY(-50%);
	background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='14' height='9' viewBox='0 0 14 9' fill='none'%3E%3Cpath d='M1 1L7 7L13 1' stroke='%234D7DE1' stroke-width='2.5' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") no-repeat center/contain;
	pointer-events: none;
	transition: transform .2s;
}
.mb-dd-wrap.open::after { transform: translateY(-50%) rotate(180deg); }

/* Custom consultation dropdown — matched to the date trigger + calendar popup */
.mb-dd-native { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0 0 0 0); border: 0; }
.mb-dd-btn {
	width: 100%;
	display: flex; align-items: center; gap: 10px;
	-webkit-appearance: none; appearance: none;
	border: 2px solid #E8EEF9;
	border-radius: 10px;
	padding: 14px 48px 14px 16px;
	font-size: 15px;
	line-height: 1.5;
	color: #333;
	background: #fff;
	cursor: pointer;
	font-family: inherit;
	font-weight: 400;
	text-align: left;
	text-transform: none;
	letter-spacing: normal;
	box-shadow: none;
	margin: 0;
}
/* Neutralize theme button hover/focus so it stays visually identical to the date field */
.mb-dd-btn:hover, .mb-dd-btn:focus, .mb-dd-btn:active {
	background: #fff; color: #333; box-shadow: none; outline: none;
}
/* When open, turn blue and square the bottom corners so the list merges seamlessly (same as the date field) */
.mb-dd-wrap.open .mb-dd-btn {
	border-color: #4D7DE1;
	border-bottom-left-radius: 0; border-bottom-right-radius: 0;
}
.mb-dd-btn-label { flex: 1 1 auto; }
.mb-dd-btn-label.is-placeholder { color: #aaa; }
/* Popup attaches under the field with the same blue border as the calendar */
.mb-dd-list {
	display: none;
	position: absolute; left: 0; right: 0; top: 100%;
	z-index: 30;
	margin: 0 !important; padding: 8px !important; list-style: none;
	background: #fff;
	border: 2px solid #4D7DE1; border-top: none;
	border-radius: 0 0 10px 10px;
	box-shadow: 0 12px 30px rgba(40,67,123,.12);
	max-height: 320px; overflow-y: auto;
}
.mb-dd-wrap.open .mb-dd-list { display: block; }
.mb-dd-item {
	display: flex; align-items: center; gap: 10px;
	margin: 0 !important;
	padding: 11px 12px;
	border-radius: 8px;
	cursor: pointer;
	color: #333;
	list-style: none;
}
.mb-dd-item:hover { background: #eef2fb; }
.mb-dd-item.is-active { background: #eef2fb; }
.mb-dd-item.is-active .mb-dd-item-label { color: #162F62; font-weight: 600; }
.mb-dd-item-label { flex: 1 1 auto; font-size: 15px; }
.mb-dd-badge, .mb-dd-btn-badge {
	flex: none;
	font-size: 12px; font-weight: 700;
	padding: 4px 11px;
	border-radius: 50px;
	white-space: nowrap;
}
.mb-dd-badge-tele { background: #E8F0FE; color: #1967D2; }
.mb-dd-badge-presentiel { background: #E6F4EA; color: #1E8E3E; }

/* Conditional follow-up question */
.mb-followup { margin-bottom: 24px; }
/* Description + answers are one panel: grey description head, dropdown body. No
   overflow:hidden here — .mb-dd-list is absolutely positioned and would be clipped. */
.mb-fu-panel { position: relative; }
.mb-fu-desc {
	padding: 14px 16px;
	border: 2px solid #E8EEF9;
	border-bottom: 0;
	border-radius: 10px 10px 0 0;
	background: #F4F6FA;
	font-size: 13.5px;
	line-height: 1.6;
	color: #222;                 /* body copy, not muted: this is content the client must read */
	/* Long consent lists scroll inside the block instead of pushing the form down.
	   Sized to fit a long consent list (8 single-line conditions measure 273px) with room
	   for wrapped lines. Safe to scroll here: the answers dropdown is a sibling of this
	   block, not a child. */
	max-height: 500px;
	overflow-y: auto;
	overscroll-behavior: contain;
}
/* Square the shared edge so head and dropdown read as one control */
.mb-fu-panel.has-desc .mb-select-wrap { margin-bottom: 0; }
.mb-fu-panel.has-desc .mb-dd-btn { border-top-left-radius: 0; border-top-right-radius: 0; }
.mb-fu-panel.has-desc.is-open-desc .mb-fu-desc { border-color: #4D7DE1; }
/* Rich text inside the description */
.mb-fu-desc > *:first-child { margin-top: 0; }
.mb-fu-desc > *:last-child { margin-bottom: 0; }
/* Zero inter-block margin, matching .mb-rte .ql-editor in MB_RTE::assets(): the editor
   turns EVERY line break into its own <p> (Quill 1.x has no soft break), so a bottom
   margin here is charged to each line rather than only to real paragraph changes — that
   was the gap between consecutive lines. Spacing comes from line-height alone. */
.mb-fu-desc p { margin: 0; }
.mb-fu-desc ul, .mb-fu-desc ol { margin: 0; padding-left: 22px; }
.mb-fu-desc ul { list-style: disc; }
.mb-fu-desc ol { list-style: decimal; }
.mb-fu-desc li { margin: 0; }
.mb-fu-desc a { color: #2C58B0; text-decoration: underline; }
.mb-fu-desc a:hover { color: #16336E; }
.mb-fu-desc strong, .mb-fu-desc b { font-weight: 700; }   /* weight only: description text stays black */
/* Emphasis + quote: stated explicitly rather than left to browser defaults so the public
   page matches what the editor showed. blockquote's default is margin:1em 40px with no
   visual marker; the editor renders it as a left accent bar (same treatment as
   .mb-rte .ql-editor blockquote in MB_RTE::assets()), so mirror that here or a saved
   quote silently looks like a plain indented paragraph to the client. Any inline
   color/font/size the author applied still wins over these — inline style beats a
   stylesheet rule, which is exactly why these can be safe blanket defaults. */
.mb-fu-desc em, .mb-fu-desc i { font-style: italic; }
/* A background-colour run reads as a highlight. The panel itself is #F4F6FA, so a light
   swatch would otherwise sit almost invisibly on it; the tiny inline padding gives the
   fill an edge without changing line height (padding-block would overlap the line above
   on wrapped text). Mirrored in the editor so both sides look the same. */
.mb-fu-desc [style*="background-color"] { padding: 0 2px; border-radius: 2px; }
.mb-fu-desc u { text-decoration: underline; }
.mb-fu-desc blockquote { margin: 0; padding: 4px 0 4px 14px; border-left: 3px solid #C8CCD8; color: #50575E; }
option.mb-opt-hidden, .mb-select option[hidden] { display: none; }

/* Date trigger + calendar */
.mb-date { position: relative; margin-bottom: 24px; }
.mb-date-trigger {
	display: flex; align-items: center; justify-content: space-between;
	border: 2px solid #E8EEF9;
	border-radius: 10px;
	padding: 14px 16px;
	font-size: 15px;
	cursor: pointer;
	background: #fff;
}
/* 1.1.0-glif.3 — the open look, set by step1.js as a class (was inline styles), so a skin can restyle it. */
.mb-date-trigger.is-open { border-color: #4D7DE1; border-bottom-left-radius: 0; border-bottom-right-radius: 0; }
.mb-date-placeholder { color: #aaa; }
.mb-chevron { transition: transform .2s; flex: none; }

.mb-cal-popup {
	display: none;
	position: absolute; left: 0; right: 0; top: 100%;
	z-index: 30;
	background: #fff;
	border: 2px solid #4D7DE1;
	border-top: none;
	border-radius: 0 0 10px 10px;
	padding: 16px;
	box-shadow: 0 12px 30px rgba(40,67,123,.12);
}
.mb-cal-head { display: flex; align-items: center; justify-content: space-between; margin-bottom: 12px; }
.mb-cal-month { font-weight: 700; color: #162F62; font-size: 15px; }
.mb-cal-nav {
	-webkit-appearance: none; appearance: none;
	display: flex; align-items: center; justify-content: center;
	border: none; background: #eef2fb; color: #4D7DE1;
	width: 32px; height: 32px; padding: 0; margin: 0; border-radius: 8px;
	font-size: 18px; font-weight: 700; line-height: 1; cursor: pointer;
	box-shadow: none; transition: background .15s;
}
.mb-cal-nav:hover { background: #e0e8fa; }
.mb-cal-nav:focus, .mb-cal-nav:active { background: #e0e8fa; outline: none; box-shadow: none; }
.mb-cal-weekdays, .mb-cal-days { display: grid; grid-template-columns: repeat(7,1fr); }
.mb-cal-weekdays span {
	text-align: center; font-size: 11px; color: #9aa7c2;
	padding: 6px 0; font-weight: 600;
}
.mb-cal-days { gap: 2px; }
.cal-day {
	text-align: center; padding: 9px 0; font-size: 13px;
	border-radius: 8px; cursor: pointer; color: #333;
}
.cal-day:hover:not(.disabled):not(.empty) { background: #eef2fb; }
.cal-day.empty { cursor: default; }
.cal-day.disabled { color: #cfd6e4; cursor: default; }
.cal-day.today { border: 2px solid #4D7DE1; color: #4D7DE1; font-weight: 700; }
.cal-day.selected { background: #4D7DE1; color: #fff; font-weight: 700; }

/* Time slots */
.mb-slots {
	display: grid; grid-template-columns: repeat(4, 1fr); gap: 10px;
	margin-bottom: 8px;
}
.time-slot {
	text-align: center;
	border: 2px solid #E8EEF9;
	border-radius: 10px;
	padding: 12px 0;
	font-size: 14px;
	cursor: pointer;
	background: #fff;
	transition: all .15s;
	user-select: none;
}
.time-slot:hover:not(.unavailable) { border-color: #4D7DE1; }
.time-slot.selected { background: #4D7DE1; color: #fff; border-color: #4D7DE1; }
.time-slot.unavailable { color: #cfd6e4; background: #f6f8fc; cursor: not-allowed; border-color: #eef2fb; }
.mb-time-error { display: none; color: #e0524d; font-size: 13px; margin: 6px 0 0; }

/* Continue / submit button */
.mb-btn {
	width: 100%;
	margin-top: 28px;
	background: #4D7DE1;
	color: #fff;
	border: none;
	border-radius: 12px;
	padding: 18px;
	font-size: 16px;
	font-weight: 700;
	cursor: pointer;
	font-family: inherit;
	display: inline-flex; align-items: center; justify-content: center; gap: 10px;
}
.mb-btn:hover { background: #3f6cd0; }
.mb-btn:disabled { opacity: .7; cursor: default; }

/* Step 2 */
.mb-back { display: inline-block; color: #4D7DE1; text-decoration: none; font-size: 14px; margin-bottom: 18px; }
.mb-back:hover { text-decoration: underline; }

/* Language switcher (FR | EN), printed only when the bilingual setting is on. */
.mb-lang-switch { display: flex; justify-content: flex-end; align-items: center; font-size: 13px; margin-bottom: 12px; color: #9aa7c2; }
.mb-lang-switch a { color: #4D7DE1; text-decoration: none; font-weight: 500; padding: 2px 4px; }
.mb-lang-switch a + a::before { content: "|"; display: inline-block; text-decoration: none; color: #9aa7c2; font-weight: 400; margin-right: 8px; margin-left: -4px; }
.mb-lang-switch a:hover { text-decoration: underline; }
.mb-lang-switch a.is-current { color: #162F62; font-weight: 700; }
.mb-summary {
	display: flex; align-items: center; justify-content: space-between;
	background: #EEF4FF; border-radius: 12px; padding: 16px 20px; margin-bottom: 20px;
}
.mb-summary-left { display: flex; align-items: center; gap: 12px; }
.mb-summary-icon { font-size: 22px; }
.mb-summary-title { font-weight: 700; color: #162F62; font-size: 15px; }
.mb-summary-detail { font-size: 13px; color: #888; margin-top: 2px; }
.mb-summary-price { font-size: 22px; font-weight: 800; color: #4D7DE1; }
/* 1.1.0-glif.1 — a price TEXT (« À partir de 11 $ / unité ») is longer than an amount: smaller, and
   allowed to wrap instead of pushing against the service and date. */
.mb-summary-price.mb-summary-price-text { font-size: 17px; font-weight: 700; text-align: right; max-width: 45%; flex: 0 1 auto; margin-left: 16px; line-height: 1.3; }

.mb-note {
	background: #fff8e6; border: 1px solid #ffe7a8; border-left: 4px solid #f3c64d;
	border-radius: 12px; padding: 16px 18px; margin-bottom: 24px; font-size: 13px; color: #7a6a3a;
}
.mb-note strong { display: block; margin-bottom: 3px; color: #6a5a2a; }
/* 1.1.0-glif.2 — the deposit notice is one sentence (« Dépôt de 50 $ prélevé aujourd'hui, déduit… »):
   its bold opening stays on the same line as the rest. */
.mb-note.mb-note-deposit strong { display: inline; margin-bottom: 0; }

.mb-section {
	font-size: 16px; font-weight: 700; color: #162F62;
	margin: 24px 0 16px;
	padding-bottom: 10px;
	border-bottom: 2px solid #EEF4FF; /* sleek divider, matches original */
}
.mb-grid2 { display: grid; grid-template-columns: 1fr 1fr; gap: 16px 16px; }
.mb-input {
	width: 100%;
	border: 2px solid #E8EEF9; border-radius: 10px;
	padding: 14px 16px; font-size: 15px; line-height: 1.5; font-family: inherit; color: #333;
	height: auto !important;
	min-height: 0;
}
.mb-input:focus { outline: none; border-color: #4D7DE1; }

.mb-card-element {
	border: 2px solid #E8EEF9; border-radius: 10px;
	padding: 14px 16px; background: #fff;
}
.mb-card-errors { color: #e0524d; font-size: 13px; margin-top: 8px; min-height: 16px; }
.mb-secure { font-size: 12px; color: #888; margin: 16px 0 0; }

.mb-spinner {
	width: 16px; height: 16px; border-radius: 50%;
	border: 2px solid rgba(255,255,255,.5); border-top-color: #fff;
	animation: mb-spin .7s linear infinite;
}
@keyframes mb-spin { to { transform: rotate(360deg); } }

/* Confirmation / transition screen */
.mb-confirm { text-align: center; }
.mb-confirm-icon {
	width: 64px; height: 64px; border-radius: 50%;
	background: #e4f6ec; color: #1f9d57;
	font-size: 34px; line-height: 64px;
	margin: 4px auto 18px;
}
.mb-confirm-title { font-size: 22px; font-weight: 800; color: #162F62; margin: 0 0 16px; }
.mb-confirm-appt {
	display: inline-block; background: #EEF4FF; color: #162F62; font-weight: 700;
	border-radius: 10px; padding: 12px 18px; margin-bottom: 18px; font-size: 15px;
}
.mb-confirm-msg { font-size: 14px; color: #555; line-height: 1.6; margin: 0 auto 20px; max-width: 460px; }
.mb-confirm-count { font-size: 13px; color: #888; margin: 0 0 20px; }
.mb-confirm .mb-btn { max-width: 340px; margin: 0 auto; }

@media (max-width: 560px) {
	.mb-wrap { margin-top: 20px; margin-bottom: 20px; }
	.mb-card { padding: 22px; border-radius: 16px; }
	.mb-title { font-size: 21px; }
	.mb-sub { margin-bottom: 24px; }
	.mb-slots { grid-template-columns: repeat(3, 1fr); gap: 8px; }
	.mb-grid2 { grid-template-columns: 1fr; }

	/* Compact stepper: show only the active step's label; the other collapses to
	   just its number/check circle, so the row fits a phone width. */
	.mb-steps { gap: 6px; }
	.mb-step { font-size: 12px; padding: 7px 12px; gap: 6px; white-space: normal; }
	.mb-step:not(.active) .mb-step-label { display: none; }
	.mb-step:not(.active) { padding: 7px; }
	.mb-step-num, .mb-step-check { width: 18px; height: 18px; font-size: 11px; }
	.mb-step-line { max-width: 28px; }

	/* Stack the Step 2 summary so the date and price never get squished. */
	.mb-summary { flex-direction: column; align-items: flex-start; gap: 8px; }
	.mb-summary-price.mb-summary-price-text { text-align: left; max-width: none; margin-left: 0; }

	/* Intro card: smaller photo + tighter padding on phones. */
	.mb-intro { padding: 16px; gap: 14px; }
	.mb-intro-photo img { width: 72px; height: 72px; border-radius: 12px; }
	.mb-intro-name { font-size: 16px; }
}

/* Window model: shown when a date has no bookable slots */
.mb-no-slots { grid-column: 1 / -1; text-align: center; color: #8A8F98; font-size: 14px; padding: 20px 4px; }

/* ============================================================================
   Booking dialog (mbModal) — shared by Step 1 and Step 2.
   One layout for every case: icon + left-aligned text, then the same full-width
   action button the booking pages already use (.mb-btn), so the dialog reads as
   part of the flow rather than a system alert.
   ========================================================================== */
.mb-modal-overlay {
	position: fixed;
	inset: 0;
	background: rgba(22, 48, 92, .45);
	display: flex;
	align-items: center;
	justify-content: center;
	padding: 20px;
	z-index: 9999;
}
.mb-modal {
	background: #fff;
	border-radius: 16px;
	box-shadow: 0 18px 48px rgba(22, 48, 92, .22);
	max-width: 420px;
	width: 100%;
	padding: 24px;
}
.mb-modal-head { display: flex; align-items: center; gap: 12px; }
.mb-modal-ic {
	flex: none;
	width: 34px;
	height: 34px;
	border-radius: 50%;
	background: #FAEEDA;
	color: #854F0B;
	display: flex;
	align-items: center;
	justify-content: center;
}
.mb-modal-title {
	margin: 0;
	font-size: 17px;
	font-weight: 700;
	color: #16305C;
	line-height: 1.35;
}
.mb-modal-sep {
	border: 0;
	border-top: 1px solid #E8ECF3;
	margin: 15px 0;
}
.mb-modal-body {
	margin: 0;
	font-size: 14px;
	line-height: 1.55;
	color: #5a5a5a;
}
.mb-modal .mb-modal-btn { margin-top: 20px; }
.mb-modal-btn:focus-visible { outline: 3px solid #16305C; outline-offset: 2px; }

@media (max-width: 560px) {
	.mb-modal { padding: 20px; }
	.mb-modal-title { font-size: 16px; }
	.mb-modal-body { font-size: 13.5px; }
	.mb-modal .mb-modal-btn { padding: 16px; }
}
