/* H.E WEB Studio — formulaires publics. Hérite des variables du thème H.E WEB (sinon valeurs de repli). */
.hews {
	--h-ink: var(--ink, #121211);
	--h-ink-2: var(--ink-2, #5a5852);
	--h-ink-3: var(--ink-3, #8f8c84);
	--h-paper: var(--paper, #f4f2ed);
	--h-paper-2: var(--paper-2, #ebe8e0);
	--h-card: var(--card, #fbfaf7);
	--h-line: var(--line, rgba(18, 18, 17, .12));
	--h-signal: var(--signal, #ff4f1a);
	--h-serif: var(--serif, Georgia, serif);
	--h-mono: var(--mono, ui-monospace, monospace);
	--h-ease: cubic-bezier(.16, 1, .3, 1);
	color: var(--h-ink);
	font-size: 16px;
}
.hews *, .hews *::before, .hews *::after { box-sizing: border-box; }
.hews-hp { position: absolute !important; left: -9999px; width: 1px; height: 1px; overflow: hidden; }
.hews-muted { color: var(--h-ink-2); }
.hews-small { font-size: 13px; margin-top: 18px; }
.hews-step { font: 400 12px var(--h-mono); text-transform: uppercase; letter-spacing: .07em; color: var(--h-ink-2); margin: 0 0 18px; }
.hews-step span { color: var(--h-signal); margin-right: 6px; }

/* Mise en page */
.hews-grid { display: grid; grid-template-columns: 260px 1fr; gap: 40px; padding: 40px 0; border-top: 1px solid var(--h-line); }
.hews-aside .hews-muted { font-size: 15px; max-width: 30ch; }
.hews-fields { display: flex; flex-direction: column; gap: 26px; }
.hews-two { display: grid; grid-template-columns: 1fr 1fr; gap: 26px 22px; }
.hews-two .hews-consent, .hews-two .hews-submit, .hews-two > .hews-err { grid-column: 1 / -1; }

/* Champs à libellé flottant */
.hews-field { position: relative; }
.hews-field input, .hews-field textarea {
	width: 100%; font: inherit; font-size: 17px; color: inherit; background: transparent;
	border: 0; border-bottom: 1px solid var(--h-line); border-radius: 0; padding: 26px 0 10px; outline: none;
	transition: border-color .8s var(--h-ease);
}
.hews-field textarea { resize: vertical; min-height: 120px; }
.hews-field label { position: absolute; left: 0; top: 26px; color: var(--h-ink-3); pointer-events: none; transform-origin: left top; transition: transform .8s var(--h-ease), color .8s var(--h-ease); }
.hews-field input:focus, .hews-field textarea:focus { border-color: var(--h-ink); }
.hews-field input:focus + label, .hews-field textarea:focus + label,
.hews-field input:not(:placeholder-shown) + label, .hews-field textarea:not(:placeholder-shown) + label { transform: translateY(-22px) scale(.78); color: var(--h-ink-2); }
.hews-field::after { content: ""; position: absolute; left: 0; right: 0; bottom: 0; height: 1px; background: var(--h-ink); transform: scaleX(0); transform-origin: left; transition: transform 1.1s var(--h-ease); }
.hews-field:focus-within::after { transform: scaleX(1); }
.hews-field.is-invalid input, .hews-field.is-invalid textarea { border-color: var(--h-signal); }
.hews-err { display: block; color: #c4320b; font-size: 13px; min-height: 0; margin-top: 6px; }
.hews-err:empty { display: none; }

/* Choix en pastilles */
.hews-chips { border: 0; padding: 0; margin: 0; display: flex; flex-wrap: wrap; gap: 8px; }
.hews-chips legend { font-size: 14px; color: var(--h-ink-2); margin-bottom: 12px; padding: 0; }
.hews-chips label { position: relative; cursor: pointer; }
.hews-chips input { position: absolute; opacity: 0; pointer-events: none; }
.hews-chips span { display: inline-block; padding: 10px 16px; border: 1px solid var(--h-line); border-radius: 99px; font-size: 14px; transition: background .7s var(--h-ease), color .7s var(--h-ease), border-color .7s var(--h-ease); }
.hews-chips label:hover span { border-color: var(--h-ink); }
.hews-chips input:checked + span { background: var(--h-ink); color: var(--h-paper); border-color: var(--h-ink); }
.hews-chips input:focus-visible + span { outline: 2px solid var(--h-signal); outline-offset: 2px; }

.hews-consent { display: flex; gap: 12px; align-items: flex-start; font-size: 14px; color: var(--h-ink-2); cursor: pointer; }
.hews-consent input { width: 18px; height: 18px; margin: 2px 0 0; accent-color: var(--h-ink); flex: none; }
.hews-consent a { color: inherit; text-decoration: underline; }
.hews-consent.is-invalid { color: #c4320b; }

/* Bouton */
.hews-submit { display: flex; align-items: center; gap: 20px; flex-wrap: wrap; margin-top: 10px; }
.hews-btn { position: relative; display: inline-flex; align-items: center; gap: 14px; height: 56px; padding: 0 28px; border: 0; border-radius: 99px; background: var(--h-ink); color: var(--h-paper); font: inherit; font-weight: 500; font-size: 15px; cursor: pointer; overflow: hidden; isolation: isolate; transition: opacity .4s; }
.hews-btn::before { content: ""; position: absolute; inset: 0; background: var(--h-signal); transform: translateY(101%); transition: transform .9s var(--h-ease); z-index: -1; }
.hews-btn:hover:not(:disabled)::before { transform: none; }
.hews-btn i { width: 16px; height: 1px; background: currentColor; position: relative; transition: width .8s var(--h-ease); }
.hews-btn i::after { content: ""; position: absolute; right: 0; top: -4px; width: 8px; height: 8px; border: solid currentColor; border-width: 1px 1px 0 0; transform: rotate(45deg); }
.hews-btn:hover:not(:disabled) i { width: 26px; }
.hews-btn:disabled { opacity: .35; cursor: not-allowed; }
.hews-btn.is-loading i { animation: hews-dash 1s linear infinite; }
@keyframes hews-dash { 50% { width: 4px; } }
.hews-status { margin: 0; font-size: 14px; color: var(--h-ink-2); }

/* Confirmation */
[data-hews-contact], .hews-book { transition: opacity .7s var(--h-ease), transform .7s var(--h-ease), filter .7s; }
.is-leaving { opacity: 0; transform: translateY(-20px); filter: blur(6px); }
.hews-done { text-align: center; padding: 80px 0 40px; opacity: 0; transform: translateY(30px); transition: opacity 1.4s var(--h-ease), transform 1.4s var(--h-ease); }
.hews-done.is-in { opacity: 1; transform: none; }
.hews-done h2 { font: 400 clamp(36px, 5vw, 64px)/1 var(--h-serif); margin: 26px 0 14px; }
.hews-done p { color: var(--h-ink-2); max-width: 46ch; margin: 0 auto; }
.hews-check { width: 72px; height: 72px; margin: 0 auto; }
.hews-check svg { width: 100%; height: 100%; fill: none; stroke: var(--h-ink); stroke-width: 1.4; stroke-linecap: round; }
.hews-check circle { stroke-dasharray: 151; stroke-dashoffset: 151; }
.hews-check path { stroke: var(--h-signal); stroke-width: 2; stroke-dasharray: 40; stroke-dashoffset: 40; }
.hews-done.is-in circle { animation: hews-draw 1.6s var(--h-ease) .2s forwards; }
.hews-done.is-in path { animation: hews-draw 1.2s var(--h-ease) 1s forwards; }
@keyframes hews-draw { to { stroke-dashoffset: 0; } }

/* ---------- Rendez-vous ---------- */
.hews-book { display: grid; grid-template-columns: minmax(0, 1.05fr) minmax(0, .8fr) minmax(0, 1.15fr); border: 1px solid var(--h-line); border-radius: 22px; background: var(--h-card); overflow: hidden; }
.hews-book > section { padding: 34px 30px; }
.hews-book > section + section { border-left: 1px solid var(--h-line); }
.hews-cal-head { display: flex; align-items: center; justify-content: space-between; margin-bottom: 18px; }
.hews-cal-title { margin: 0; font: 400 30px/1 var(--h-serif); text-transform: capitalize; }
.hews-cal-nav { width: 40px; height: 40px; border-radius: 50%; border: 1px solid var(--h-line); background: none; font: inherit; cursor: pointer; transition: background .5s; }
.hews-cal-nav:hover:not(:disabled) { background: var(--h-paper-2); }
.hews-cal-nav:disabled { opacity: .25; cursor: default; }
.hews-cal-dow, .hews-cal-grid { display: grid; grid-template-columns: repeat(7, 1fr); gap: 4px; }
.hews-cal-dow span { text-align: center; font: 400 11px var(--h-mono); color: var(--h-ink-3); padding-bottom: 8px; }
.hews-cal-grid { min-height: 260px; }
.hews-cal-grid.is-loading { opacity: .4; }
.hews-cal-grid button { aspect-ratio: 1; border: 0; border-radius: 50%; background: none; font: inherit; font-size: 15px; color: var(--h-ink-3); cursor: default; position: relative; animation: hews-pop .9s var(--h-ease) both; animation-delay: calc(var(--i) * 12ms); }
.hews-cal-grid button.is-open { color: var(--h-ink); cursor: pointer; font-weight: 500; }
.hews-cal-grid button.is-open::after { content: ""; position: absolute; left: 50%; bottom: 14%; width: 4px; height: 4px; margin-left: -2px; border-radius: 50%; background: var(--h-signal); }
.hews-cal-grid button.is-open:hover { background: var(--h-paper-2); }
.hews-cal-grid button.is-today { box-shadow: inset 0 0 0 1px var(--h-line); }
.hews-cal-grid button.is-sel, .hews-cal-grid button.is-sel:hover { background: var(--h-ink); color: var(--h-paper); }
.hews-cal-grid button.is-sel::after { background: var(--h-paper); }
@keyframes hews-pop { from { opacity: 0; transform: scale(.7); } }
.hews-slot-day { font: 400 26px/1.1 var(--h-serif); margin: 0 0 20px; }
.hews-slot-day::first-letter { text-transform: uppercase; }
.hews-slots { display: grid; grid-template-columns: repeat(2, 1fr); gap: 8px; max-height: 420px; overflow: auto; padding: 2px; }
.hews-slots.is-loading { opacity: .4; }
.hews-slots button { height: 46px; border: 1px solid var(--h-line); border-radius: 12px; background: var(--h-paper); font: 400 15px var(--h-mono); cursor: pointer; transition: background .6s var(--h-ease), color .6s var(--h-ease), border-color .6s var(--h-ease); animation: hews-rise .9s var(--h-ease) both; animation-delay: calc(var(--i) * 40ms); }
.hews-slots button:hover { border-color: var(--h-ink); }
.hews-slots button.is-sel { background: var(--h-ink); color: var(--h-paper); border-color: var(--h-ink); }
@keyframes hews-rise { from { opacity: 0; transform: translateY(14px); } }
.hews-book-form .hews-form { display: flex; flex-direction: column; gap: 20px; }
.hews-book-form .hews-field input, .hews-book-form .hews-field textarea { font-size: 16px; padding-top: 22px; }
.hews-book-form .hews-field label { top: 22px; }
.hews-book-form .hews-field textarea { min-height: 80px; }
.hews-picked { margin: 0; padding: 12px 16px; border-radius: 12px; background: var(--h-paper-2); font-weight: 500; }
.hews-picked::first-letter { text-transform: uppercase; }
.hews-book-slots, .hews-book-form { transition: opacity 1s var(--h-ease); }
.hews-booking:not(.has-day) .hews-book-slots { opacity: .45; }
.hews-booking:not(.has-time) .hews-book-form { opacity: .55; }

@media (max-width: 1100px) {
	.hews-book { grid-template-columns: 1fr 1fr; }
	.hews-book-form { grid-column: 1 / -1; border-left: 0 !important; border-top: 1px solid var(--h-line); }
}
@media (max-width: 760px) {
	.hews-grid { grid-template-columns: 1fr; gap: 10px; }
	.hews-two { grid-template-columns: 1fr; }
	.hews-book { grid-template-columns: 1fr; border-radius: 16px; }
	.hews-book > section { padding: 26px 18px; }
	.hews-book > section + section { border-left: 0; border-top: 1px solid var(--h-line); }
	.hews-slots { grid-template-columns: repeat(3, 1fr); }
}
@media (prefers-reduced-motion: reduce) {
	.hews *, .hews *::before, .hews *::after { animation-duration: .01ms !important; transition-duration: .01ms !important; }
}
