/* ============================================================
   SCHEDULER — customer facing
   Mobile first. Everything below is written for a phone; the
   media queries only relax things once there is room.
   Palette and type follow the main site.
   ============================================================ */

.sched-container { max-width: 720px; }

/* Tap targets stay at least 44px everywhere in this flow. */
.sched-form input[type="text"],
.sched-form input[type="tel"],
.sched-form input[type="email"],
.sched-form input[type="date"],
.sched-form textarea {
	width: 100%;
	min-height: 48px;
	padding: 12px 14px;
	background: rgba(0, 0, 0, 0.25);
	border: 1px solid rgba(255, 255, 255, 0.16);
	border-radius: 6px;
	color: var(--white);
	font: inherit;
	font-size: 16px; /* stops iOS zooming the page on focus */
}
.sched-form textarea { min-height: 110px; resize: vertical; line-height: 1.6; }

.sched-form input:focus, .sched-form textarea:focus {
	outline: none;
	border-color: var(--blue-accent);
	box-shadow: 0 0 0 3px rgba(59, 125, 221, 0.25);
}

.sched-form label { display: block; }

.sched-field { margin-bottom: 20px; }
.sched-field > label {
	font-size: 0.78rem;
	text-transform: uppercase;
	letter-spacing: 0.12em;
	font-weight: 600;
	color: rgba(255, 255, 255, 0.65);
	margin-bottom: 7px;
}
.sched-optional { text-transform: none; letter-spacing: 0; opacity: 0.6; font-weight: 400; }

.sched-row { display: grid; grid-template-columns: 1fr; gap: 0; }
@media (min-width: 520px) {
	.sched-row { grid-template-columns: 2fr 1fr; gap: 16px; }
}

.sched-hint { font-size: 0.85rem; color: rgba(255, 255, 255, 0.6); margin: 8px 0 0; line-height: 1.5; }
.sched-label {
	font-size: 0.78rem; text-transform: uppercase; letter-spacing: 0.12em;
	font-weight: 600; color: rgba(255, 255, 255, 0.65); margin: 0 0 10px;
}

.sched-error {
	color: #FF8FA8; font-size: 0.85rem; margin: 8px 0 0; font-weight: 500;
}
.sched-error-banner {
	background: rgba(165, 29, 69, 0.2);
	border-left: 3px solid var(--red-light);
	padding: 14px 16px; border-radius: 6px; margin-bottom: 24px; font-size: 0.92rem;
}

/* Honeypot — off-screen rather than display:none, which some bots skip. */
.sched-hp {
	position: absolute; left: -9999px; width: 1px; height: 1px;
	overflow: hidden; opacity: 0;
}

/* ------------------------------------------------------------- steps --- */

.sched-step { border: 0; padding: 0; margin: 0 0 8px; min-width: 0; }
.sched-step legend {
	font-family: 'Bebas Neue', sans-serif;
	font-size: clamp(1.6rem, 6vw, 2.2rem);
	letter-spacing: 2px; color: var(--white);
	padding: 0; margin-bottom: 20px;
}
/* Without JS every step is visible and numbered progress is meaningless. */
.sched-form:not(.is-stepped) .sched-step { margin-bottom: 44px; }
.sched-progress { display: none; }

.sched-form.is-stepped .sched-progress {
	display: flex; list-style: none; padding: 0;
	margin: 0 0 28px; gap: 6px; font-size: 0.72rem;
	text-transform: uppercase; letter-spacing: 0.1em;
}
.sched-progress li {
	flex: 1; display: flex; align-items: center; gap: 7px;
	color: rgba(255, 255, 255, 0.4); padding-bottom: 10px;
	border-bottom: 2px solid rgba(255, 255, 255, 0.12);
	font-weight: 600;
}
.sched-progress li span {
	width: 22px; height: 22px; flex: none; border-radius: 50%;
	background: rgba(255, 255, 255, 0.12); color: inherit;
	display: grid; place-items: center; font-size: 0.7rem;
}
.sched-progress li.is-current { color: var(--white); border-bottom-color: var(--red-primary); }
.sched-progress li.is-current span { background: var(--red-primary); color: #fff; }
.sched-progress li.is-done { color: rgba(255, 255, 255, 0.75); border-bottom-color: var(--blue-accent); }
.sched-progress li.is-done span { background: var(--blue-accent); color: #fff; }
@media (max-width: 420px) {
	.sched-progress li { font-size: 0; gap: 0; justify-content: center; }
	.sched-progress li span { font-size: 0.7rem; }
}

.sched-nav { display: flex; gap: 12px; margin-top: 28px; }
.sched-nav .btn { flex: 1; text-align: center; min-height: 50px; line-height: 1.2;
	display: inline-flex; align-items: center; justify-content: center; }
@media (min-width: 560px) {
	.sched-nav { justify-content: flex-end; }
	.sched-nav .btn { flex: 0 0 auto; min-width: 150px; }
	.sched-nav .btn[data-back] { margin-right: auto; }
}

/* ---------------------------------------------------------- services --- */

.sched-services { display: grid; gap: 12px; }

.sched-service { position: relative; cursor: pointer; }
.sched-service input {
	position: absolute; opacity: 0; width: 0; height: 0;
}
.sched-service-body {
	display: block; padding: 18px;
	background: rgba(255, 255, 255, 0.04);
	border: 2px solid rgba(255, 255, 255, 0.14);
	border-radius: 8px; transition: border-color 0.2s, background 0.2s;
}
.sched-service:hover .sched-service-body { background: rgba(255, 255, 255, 0.07); }
.sched-service input:checked + .sched-service-body {
	border-color: var(--red-primary); background: rgba(139, 21, 56, 0.16);
}
.sched-service input:focus-visible + .sched-service-body {
	box-shadow: 0 0 0 3px rgba(59, 125, 221, 0.4);
}
.sched-service-name {
	display: block; font-weight: 600; font-size: 1.05rem; color: var(--white); margin-bottom: 5px;
}
.sched-service-blurb {
	display: block; font-size: 0.9rem; color: rgba(255, 255, 255, 0.7); line-height: 1.5;
}
.sched-service-len {
	display: block; font-size: 0.78rem; color: rgba(255, 255, 255, 0.45); margin-top: 8px;
}

.sched-check {
	display: flex; align-items: flex-start; gap: 11px;
	margin-top: 18px; font-size: 0.92rem; cursor: pointer; line-height: 1.45;
}
.sched-check input { width: 22px; height: 22px; flex: none; margin-top: 1px; accent-color: var(--red-primary); }
.sched-urgent {
	padding: 14px; border-radius: 8px;
	background: rgba(139, 21, 56, 0.14);
	border: 1px solid rgba(165, 29, 69, 0.4);
}

/* ---------------------------------------------------------- calendar --- */

.sched-calendar[data-enhanced="false"] label {
	font-size: 0.78rem; text-transform: uppercase; letter-spacing: 0.12em;
	font-weight: 600; color: rgba(255, 255, 255, 0.65); margin-bottom: 7px;
}
.sched-calendar[aria-busy="true"] { opacity: 0.5; }

.sched-cal-head {
	display: flex; align-items: center; justify-content: space-between; margin-bottom: 12px;
}
.sched-cal-title { font-weight: 600; font-size: 1.02rem; color: var(--white); }
.sched-cal-nav {
	width: 44px; height: 44px; border-radius: 8px;
	background: rgba(255, 255, 255, 0.08);
	border: 1px solid rgba(255, 255, 255, 0.14);
	color: var(--white); font-size: 1.5rem; line-height: 1; cursor: pointer;
}
.sched-cal-nav:hover:not(:disabled) { background: rgba(255, 255, 255, 0.16); }
.sched-cal-nav:disabled { opacity: 0.25; cursor: not-allowed; }

.sched-cal-grid {
	display: grid; grid-template-columns: repeat(7, 1fr); gap: 5px;
}
.sched-cal-dow {
	text-align: center; font-size: 0.68rem; font-weight: 700;
	color: rgba(255, 255, 255, 0.4); padding-bottom: 6px;
	text-transform: uppercase; letter-spacing: 0.05em;
}
.sched-cal-pad { aspect-ratio: 1; }

.sched-cal-day {
	aspect-ratio: 1; min-height: 42px;
	display: grid; place-items: center;
	border-radius: 8px; border: 1px solid transparent;
	background: rgba(255, 255, 255, 0.05);
	color: rgba(255, 255, 255, 0.35);
	font: inherit; font-size: 0.92rem; font-weight: 500;
	cursor: not-allowed; padding: 0;
}
.sched-cal-day.is-open {
	background: rgba(59, 125, 221, 0.16);
	border-color: rgba(59, 125, 221, 0.45);
	color: var(--white); cursor: pointer; font-weight: 600;
}
.sched-cal-day.is-open:hover { background: rgba(59, 125, 221, 0.32); }
.sched-cal-day.is-full, .sched-cal-day.is-closed { text-decoration: line-through; opacity: 0.55; }
.sched-cal-day.is-out { opacity: 0.2; }
.sched-cal-day.is-chosen {
	background: var(--red-primary); border-color: var(--red-light); color: #fff;
}

.sched-cal-key {
	display: flex; align-items: center; gap: 7px; flex-wrap: wrap;
	font-size: 0.75rem; color: rgba(255, 255, 255, 0.5); margin: 14px 0 0;
}
.sched-key-open, .sched-key-full {
	width: 13px; height: 13px; border-radius: 4px; display: inline-block;
}
.sched-key-open { background: rgba(59, 125, 221, 0.4); border: 1px solid rgba(59, 125, 221, 0.6); }
.sched-key-full { background: rgba(255, 255, 255, 0.07); margin-left: 12px; }

/* ----------------------------------------------------------- windows --- */

.sched-windows { margin-top: 26px; }
.sched-window-choices { display: grid; gap: 11px; }
@media (min-width: 520px) { .sched-window-choices { grid-template-columns: 1fr 1fr; } }

.sched-window { position: relative; cursor: pointer; }
.sched-window input { position: absolute; opacity: 0; width: 0; height: 0; }
.sched-window-body {
	display: block; padding: 16px; text-align: center;
	background: rgba(255, 255, 255, 0.04);
	border: 2px solid rgba(255, 255, 255, 0.14);
	border-radius: 8px; transition: border-color 0.2s, background 0.2s;
}
.sched-window input:checked + .sched-window-body {
	border-color: var(--red-primary); background: rgba(139, 21, 56, 0.16);
}
.sched-window.is-unavailable { cursor: not-allowed; }
.sched-window.is-unavailable .sched-window-body { opacity: 0.4; }
.sched-window-name { display: block; font-weight: 600; color: var(--white); font-size: 1rem; }
.sched-window-hours { display: block; font-size: 0.85rem; color: rgba(255, 255, 255, 0.6); margin-top: 3px; }
.sched-window-state { display: block; font-size: 0.75rem; color: #FF8FA8; margin-top: 5px; }

/* ------------------------------------------------------------ review --- */

.sched-review {
	margin: 26px 0 0; padding: 16px 18px; border-radius: 8px;
	background: rgba(59, 125, 221, 0.12);
	border-left: 3px solid var(--blue-accent);
}
.sched-review-title {
	font-size: 0.7rem; text-transform: uppercase; letter-spacing: 0.14em;
	color: rgba(255, 255, 255, 0.55); margin: 0 0 7px; font-weight: 700;
}
.sched-review-line { margin: 0 0 3px; font-size: 1rem; }

/* ------------------------------------------------------ confirmation --- */

.sched-done { text-align: center; padding: 8px 0 20px; }
.sched-done-mark {
	width: 66px; height: 66px; margin: 0 auto 22px;
	border-radius: 50%; display: grid; place-items: center;
	background: rgba(46, 125, 83, 0.2); color: #5FD39B;
	border: 2px solid rgba(46, 125, 83, 0.5);
}
.sched-done-mark svg { width: 32px; height: 32px; }
.sched-done h2 {
	font-family: 'Bebas Neue', sans-serif; font-size: clamp(1.8rem, 7vw, 2.6rem);
	letter-spacing: 2px; margin-bottom: 14px;
}
.sched-done-lead { font-size: 1.08rem; line-height: 1.6; margin-bottom: 26px; }
.sched-muted { color: rgba(255, 255, 255, 0.6); font-size: 0.9rem; }

.sched-summary {
	display: grid; grid-template-columns: max-content 1fr;
	gap: 10px 20px; text-align: left; max-width: 400px;
	margin: 0 auto 28px; padding: 20px;
	background: rgba(255, 255, 255, 0.05); border-radius: 8px;
	font-size: 0.95rem;
}
.sched-summary dt { color: rgba(255, 255, 255, 0.55); }
.sched-summary dd { margin: 0; font-weight: 600; }
.sched-ref { font-family: ui-monospace, SFMono-Regular, Menlo, monospace; letter-spacing: 0.05em; }

.sched-actions {
	display: flex; flex-direction: column; gap: 11px; align-items: stretch;
	max-width: 400px; margin: 28px auto 0;
}
@media (min-width: 520px) { .sched-actions { flex-direction: row; justify-content: center; } }

/* ------------------------------------------------------------ notice --- */

.sched-notice { text-align: center; padding: 36px 22px; border-radius: 8px;
	background: rgba(255, 255, 255, 0.05); border: 1px solid rgba(255, 255, 255, 0.12); }
.sched-notice h2 { font-family: 'Bebas Neue', sans-serif; letter-spacing: 2px; margin-bottom: 14px; }
.sched-notice-warn { border-left: 3px solid var(--red-light); }

.sched-fallback {
	text-align: center; margin-top: 32px; font-size: 0.9rem;
	color: rgba(255, 255, 255, 0.55);
}

/* ------------------------------------------------------------- manage -- */

.sched-manage-card {
	background: rgba(255, 255, 255, 0.05);
	border: 1px solid rgba(255, 255, 255, 0.12);
	border-radius: 8px; padding: 24px; margin-bottom: 22px;
}
.sched-status {
	display: inline-block; font-size: 0.7rem; font-weight: 700;
	text-transform: uppercase; letter-spacing: 0.12em;
	padding: 5px 12px; border-radius: 20px; margin-bottom: 14px;
}
.sched-status-requested { background: rgba(200, 135, 27, 0.22); color: #F0C070; }
.sched-status-confirmed { background: rgba(46, 125, 83, 0.22); color: #5FD39B; }
.sched-status-cancelled, .sched-status-declined { background: rgba(255, 255, 255, 0.1); color: rgba(255, 255, 255, 0.6); }
.sched-status-completed { background: rgba(59, 125, 221, 0.22); color: #8FBBF5; }
.sched-status-no_show { background: rgba(255, 255, 255, 0.1); color: rgba(255, 255, 255, 0.6); }
