/* NWE Prenotazioni – modulo di prenotazione */
.nwe-pren {
	--nwe-accent: #fdc903;
	--nwe-accent-ink: #1d1d1b;
	--nwe-ink: #1d2a33;
	--nwe-muted: #6b7780;
	--nwe-line: #dfe5ea;
	--nwe-bg: #ffffff;
	--nwe-soft: #f4f7f9;
	--nwe-ok: #0f7b5f;
	display: block;
	max-width: 520px;
	margin: 0 0 1.5em;
	color: var(--nwe-ink);
	font-size: 15px;
	line-height: 1.45;
}
.nwe-pren * { box-sizing: border-box; }
.nwe-pren [hidden] { display: none !important; }
.nwe-step { margin: 0 0 18px; }
.nwe-step-title { display: block; font-weight: 700; margin: 0 0 8px; font-size: 15px; }

/* Calendario */
.nwe-cal { border: 1px solid var(--nwe-line); border-radius: 12px; background: var(--nwe-bg); padding: 12px; }
.nwe-cal-head { display: flex; align-items: center; justify-content: space-between; margin-bottom: 8px; }
.nwe-cal-title { font-weight: 700; text-transform: capitalize; }
.nwe-cal-prev, .nwe-cal-next {
	width: 36px; height: 36px; border-radius: 50%; border: 1px solid var(--nwe-line);
	background: var(--nwe-bg); color: var(--nwe-ink); font-size: 22px; line-height: 1; cursor: pointer; padding: 0;
}
.nwe-cal-prev:disabled, .nwe-cal-next:disabled { opacity: .3; cursor: default; }
.nwe-cal-grid { display: grid; grid-template-columns: repeat(7, 1fr); gap: 4px; transition: opacity .15s; }
.nwe-cal-grid.is-loading { opacity: .35; pointer-events: none; }
.nwe-cal-dow { text-align: center; font-size: 12px; color: var(--nwe-muted); text-transform: capitalize; padding: 4px 0; }
.nwe-cal-day {
	aspect-ratio: 1 / 1; min-height: 36px; border: 0; border-radius: 8px; background: transparent;
	color: #b7c0c7; font-size: 14px; font-weight: 600; cursor: default; padding: 0;
}
.nwe-cal-day.is-open { background: var(--nwe-soft); color: var(--nwe-ink); cursor: pointer; }
.nwe-cal-day.is-open:hover { background: #e7edf1; }
.nwe-cal-day.is-full { text-decoration: line-through; color: #c9a9a9; }
.nwe-cal-day.is-selected, .nwe-cal-day.is-selected:hover { background: var(--nwe-accent); color: var(--nwe-accent-ink); }
.nwe-cal-day:focus-visible, .nwe-slot:focus-visible, .nwe-counter button:focus-visible { outline: 2px solid var(--nwe-ink); outline-offset: 2px; }
.nwe-cal-msg:not(:empty) { margin-top: 8px; font-size: 13px; color: var(--nwe-muted); }

/* Fasce orarie */
.nwe-slots { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 8px; }
.nwe-slot {
	display: flex; flex-direction: column; align-items: flex-start; gap: 2px; text-align: left;
	border: 1px solid var(--nwe-line); border-radius: 10px; background: var(--nwe-bg); color: var(--nwe-ink);
	padding: 10px 12px; cursor: pointer; font-size: 14px;
}
.nwe-slot strong { font-size: 15px; }
.nwe-slot-time { color: var(--nwe-muted); }
.nwe-slot-free { font-size: 12px; color: var(--nwe-ok); font-weight: 600; }
.nwe-slot:disabled { opacity: .5; cursor: default; }
.nwe-slot:disabled .nwe-slot-free { color: #b04a4a; }
.nwe-slot.is-selected { border-color: var(--nwe-ink); box-shadow: inset 0 0 0 1px var(--nwe-ink); background: #fffbe6; }

/* Persone */
.nwe-people { border: 1px solid var(--nwe-line); border-radius: 12px; padding: 4px 12px; }
.nwe-counter { display: grid; grid-template-columns: 1fr auto; grid-template-areas: "label ctrl" "price ctrl"; align-items: center; padding: 10px 0; border-bottom: 1px solid var(--nwe-line); }
.nwe-counter:last-of-type { border-bottom: 0; }
.nwe-counter-label { grid-area: label; font-weight: 600; }
.nwe-counter-price { grid-area: price; font-size: 13px; color: var(--nwe-muted); }
.nwe-counter-ctrl { grid-area: ctrl; display: flex; align-items: center; gap: 6px; }
.nwe-counter button {
	width: 34px; height: 34px; border-radius: 50%; border: 1px solid var(--nwe-line); background: var(--nwe-bg);
	color: var(--nwe-ink); font-size: 18px; line-height: 1; cursor: pointer; padding: 0;
}
.nwe-counter button:disabled { opacity: .3; cursor: default; }
.nwe-counter input {
	width: 36px; text-align: center; border: 0; background: transparent; font-weight: 700; font-size: 16px;
	color: var(--nwe-ink); padding: 0; -moz-appearance: textfield; box-shadow: none;
}
.nwe-counter input::-webkit-outer-spin-button, .nwe-counter input::-webkit-inner-spin-button { -webkit-appearance: none; margin: 0; }
.nwe-people-hint:not(:empty) { font-size: 13px; color: var(--nwe-muted); padding: 0 0 8px; }

.nwe-step-note textarea { width: 100%; border: 1px solid var(--nwe-line); border-radius: 10px; padding: 10px; font: inherit; }

/* Riepilogo */
.nwe-summary { background: var(--nwe-soft); border-radius: 12px; padding: 12px 14px; margin: 0 0 12px; }
.nwe-summary-text { font-size: 14px; color: var(--nwe-muted); }
.nwe-summary-text::first-letter { text-transform: uppercase; }
.nwe-total { display: flex; justify-content: space-between; align-items: baseline; margin-top: 6px; font-size: 16px; }
.nwe-total strong { font-size: 22px; }
.nwe-pren .nwe-submit { width: 100%; }
.nwe-pren .nwe-submit:disabled { opacity: .45; cursor: not-allowed; }
.nwe-prezzo-da small { font-size: .7em; font-weight: 400; opacity: .8; }

/* Telefono e tablet: nel modello Divi del prodotto la galleria foto sta sopra la prenotazione.
   Nella colonna che contiene il calendario spostiamo la galleria in fondo, così il calendario si vede subito. */
@media (max-width: 980px) {
	.et_pb_column:has(form.nwe-pren) { display: flex; flex-direction: column; }
	.et_pb_column:has(form.nwe-pren) > .et_pb_wc_gallery,
	.et_pb_column:has(form.nwe-pren) > .et_pb_wc_images { order: 10; margin-top: 24px; }
}
