/**
 * Frontend styles with premium aesthetics and transitions.
 *
 * @package Beauty_Consultancy_Booking
 */

:root {
	--beauty-primary: #e04f00; /* Premium Orange */
	--beauty-primary-hover: #c44100; /* Darker Orange */
	--beauty-accent: #84BD00; /* Lime Green */
	--beauty-text: #222222;
	--beauty-text-muted: #666666;
	--beauty-bg-light: #faf8f7; /* Soft orange-tinted light background */
	--beauty-border: #f5eae2; /* Soft border */
	--beauty-border-radius: 16px;
	--beauty-shadow: 0 10px 30px rgba(224, 79, 0, 0.08);
	--beauty-shadow-lg: 0 20px 50px rgba(224, 79, 0, 0.15);
	--beauty-transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

/* Button to Open Calendar */
.beauty-booking-btn-primary {
	display: inline-flex;
	align-items: center;
	gap: 8px;
	background: linear-gradient(135deg, var(--beauty-primary), #ff8235);
	color: #fff !important;
	border: none;
	padding: 12px 24px;
	border-radius: 30px;
	font-family: 'Outfit', sans-serif;
	font-size: 16px;
	font-weight: 500;
	cursor: pointer;
	box-shadow: 0 4px 15px rgba(224, 79, 0, 0.25);
	transition: var(--beauty-transition);
}
.beauty-booking-btn-primary:hover {
	transform: translateY(-2px);
	box-shadow: 0 6px 20px rgba(224, 79, 0, 0.35);
}
.beauty-booking-btn-primary:active {
	transform: translateY(0);
}
.beauty-booking-btn-primary:disabled {
	background: #ccc;
	box-shadow: none;
	cursor: not-allowed;
	transform: none;
}

/* Modal Overlay with Glassmorphism */
.beauty-booking-modal-overlay {
	position: fixed;
	top: 0;
	left: 0;
	width: 100%;
	height: 100%;
	background: rgba(35, 20, 15, 0.4);
	backdrop-filter: blur(8px);
	-webkit-backdrop-filter: blur(8px);
	z-index: 999999;
	display: flex;
	align-items: center;
	justify-content: center;
	padding: 20px;
	opacity: 0;
	animation: beautyFadeIn 0.3s forwards;
}

/* Modal Container */
.beauty-booking-modal-container {
	background: #ffffff;
	width: 100%;
	max-width: 850px;
	max-height: 90vh;
	border-radius: var(--beauty-border-radius);
	box-shadow: var(--beauty-shadow-lg);
	border: 1px solid rgba(255, 255, 255, 0.5);
	overflow-y: auto;
	position: relative;
	padding: 40px;
	font-family: 'Outfit', sans-serif;
	color: var(--beauty-text);
	transform: scale(0.95);
	opacity: 0;
	animation: beautyScaleIn 0.3s cubic-bezier(0.34, 1.56, 0.64, 1) forwards;
}

/* Close Button */
.beauty-booking-modal-close {
	position: absolute;
	top: 20px;
	right: 20px;
	background: none;
	border: none;
	font-size: 32px;
	color: var(--beauty-text-muted);
	cursor: pointer;
	line-height: 1;
	transition: var(--beauty-transition);
}
.beauty-booking-modal-close:hover {
	color: var(--beauty-primary);
	transform: rotate(90deg);
}

/* Header */
.beauty-booking-modal-header h2 {
	font-size: 28px;
	font-weight: 600;
	margin: 0 0 8px 0;
	color: var(--beauty-text);
}
.beauty-booking-modal-header p {
	font-size: 15px;
	color: var(--beauty-text-muted);
	margin: 0;
}

/* Stepper */
.beauty-booking-steps {
	display: flex;
	justify-content: space-between;
	align-items: center;
	margin: 30px 0;
	position: relative;
}
.beauty-booking-steps::before {
	content: '';
	position: absolute;
	top: 18px;
	left: 0;
	width: 100%;
	height: 2px;
	background: var(--beauty-border);
	z-index: 1;
}
.booking-step {
	position: relative;
	z-index: 2;
	background: #fff;
	padding: 0 15px;
	display: flex;
	flex-direction: column;
	align-items: center;
	gap: 6px;
}
.step-num {
	width: 36px;
	height: 36px;
	border-radius: 50%;
	background: #fff;
	border: 2px solid var(--beauty-border);
	display: flex;
	align-items: center;
	justify-content: center;
	font-weight: 600;
	color: var(--beauty-text-muted);
	transition: var(--beauty-transition);
}
.booking-step span {
	font-size: 13px;
	font-weight: 500;
	color: var(--beauty-text-muted);
}
.booking-step.active .step-num {
	background: var(--beauty-primary);
	border-color: var(--beauty-primary);
	color: #fff;
	box-shadow: 0 0 10px rgba(224, 79, 0, 0.3);
}
.booking-step.active span {
	color: var(--beauty-primary);
	font-weight: 600;
}
.booking-step.completed .step-num {
	background: var(--beauty-accent);
	border-color: var(--beauty-accent);
	color: #fff;
}

/* Step Content Panels */
.booking-step-content {
	animation: beautyFadeIn 0.4s ease;
}

/* Grid Layout for Step 1 */
.beauty-booking-datetime-grid {
	display: grid;
	grid-template-columns: 1.2fr 1fr;
	gap: 40px;
	margin-bottom: 30px;
}

@media (max-width: 768px) {
	.beauty-booking-datetime-grid {
		grid-template-columns: 1fr;
		gap: 30px;
	}
	.beauty-booking-modal-container {
		padding: 24px;
	}
	.beauty-booking-steps::before {
		display: none;
	}
	.beauty-booking-steps {
		flex-direction: row;
		justify-content: space-around;
	}
	.booking-step {
		padding: 0;
	}
}

/* Calendar styling */
.beauty-booking-calendar-wrapper {
	background: var(--beauty-bg-light);
	border: 1px solid var(--beauty-border);
	border-radius: var(--beauty-border-radius);
	padding: 20px;
}
.beauty-booking-calendar-header {
	display: flex;
	justify-content: space-between;
	align-items: center;
	margin-bottom: 20px;
	font-weight: 600;
	font-size: 17px;
}
.calendar-nav-btn {
	background: none;
	border: 1px solid var(--beauty-border);
	width: 32px;
	height: 32px;
	border-radius: 50%;
	cursor: pointer;
	font-size: 14px;
	display: flex;
	align-items: center;
	justify-content: center;
	transition: var(--beauty-transition);
}
.calendar-nav-btn:hover {
	background: var(--beauty-primary);
	color: #fff;
	border-color: var(--beauty-primary);
}

.beauty-booking-calendar-grid {
	display: grid;
	grid-template-columns: repeat(7, 1fr);
	gap: 6px;
	text-align: center;
}
.calendar-day-header {
	font-size: 12px;
	text-transform: uppercase;
	color: var(--beauty-text-muted);
	font-weight: 600;
	padding-bottom: 10px;
}

.beauty-booking-calendar-days-grid {
	display: grid;
	grid-template-columns: repeat(7, 1fr);
	gap: 6px;
}

.calendar-day-cell {
	aspect-ratio: 1;
	display: flex;
	align-items: center;
	justify-content: center;
	font-size: 14px;
	font-weight: 500;
	border-radius: 50%;
	cursor: pointer;
	transition: var(--beauty-transition);
	background: transparent;
	border: none;
}
.calendar-day-cell:hover:not(:disabled) {
	background: #fdf2eb;
	color: var(--beauty-primary);
	transform: scale(1.1);
}
.calendar-day-cell:disabled {
	color: #ccc;
	cursor: not-allowed;
	font-weight: 300;
}
.calendar-day-cell.today:not(.selected) {
	color: var(--beauty-primary);
	font-weight: 700;
	border: 1.5px solid var(--beauty-primary);
}
.calendar-day-cell.selected {
	background: var(--beauty-primary);
	color: #fff !important;
	font-weight: 600;
	box-shadow: 0 4px 10px rgba(224, 79, 0, 0.3);
}

/* Slots Section */
.beauty-booking-slots-wrapper {
	display: flex;
	flex-direction: column;
}
.beauty-booking-slots-wrapper h3 {
	font-size: 18px;
	font-weight: 600;
	margin: 0 0 15px 0;
}
.slots-info-text {
	color: var(--beauty-text-muted);
	font-size: 14px;
	line-height: 1.5;
}
.beauty-booking-slots-grid {
	display: grid;
	grid-template-columns: repeat(2, 1fr);
	gap: 12px;
	max-height: 280px;
	overflow-y: auto;
	padding-right: 5px;
}
.beauty-booking-slot-btn {
	background: #fff;
	border: 1px solid var(--beauty-border);
	padding: 12px 10px;
	border-radius: 10px;
	font-family: 'Outfit', sans-serif;
	font-size: 14px;
	font-weight: 500;
	color: var(--beauty-text);
	cursor: pointer;
	transition: var(--beauty-transition);
	text-align: center;
}
.beauty-booking-slot-btn:hover:not(:disabled) {
	border-color: var(--beauty-primary);
	color: var(--beauty-primary);
	background: var(--beauty-bg-light);
	transform: translateY(-2px);
}
.beauty-booking-slot-btn:disabled {
	background: #f7f7f7;
	color: #bbb;
	border-color: #eee;
	text-decoration: line-through;
	cursor: not-allowed;
}
.beauty-booking-slot-btn.selected {
	background: var(--beauty-primary);
	color: #fff;
	border-color: var(--beauty-primary);
	box-shadow: 0 4px 10px rgba(224, 79, 0, 0.2);
}

/* Spinner Loader */
.beauty-booking-spinner-wrapper {
	display: flex;
	justify-content: center;
	align-items: center;
	padding: 40px 0;
}
.beauty-booking-spinner {
	width: 32px;
	height: 32px;
	border: 3px solid rgba(224, 79, 0, 0.1);
	border-top-color: var(--beauty-primary);
	border-radius: 50%;
	animation: beautySpin 0.8s linear infinite;
}

/* Form Styling */
.beauty-booking-form-summary {
	background: var(--beauty-bg-light);
	border-left: 4px solid var(--beauty-primary);
	padding: 15px;
	border-radius: 0 8px 8px 0;
	margin-bottom: 25px;
	font-weight: 500;
	display: flex;
	align-items: center;
	gap: 10px;
}
.beauty-booking-form-group {
	margin-bottom: 20px;
	display: flex;
	flex-direction: column;
	gap: 6px;
}
.beauty-booking-form-group label {
	font-size: 14px;
	font-weight: 600;
	color: var(--beauty-text);
}
.beauty-booking-field-desc {
	display: block;
	font-size: 13px;
	font-weight: 400;
	font-style: italic;
	color: var(--beauty-text-muted);
	margin-top: 3px;
	line-height: 1.4;
}
.beauty-booking-modal-container .beauty-booking-input {
	padding: 12px 16px !important;
	border: 1px solid #decac0 !important;
	border-radius: 10px !important;
	font-family: 'Outfit', sans-serif !important;
	font-size: 15px !important;
	transition: var(--beauty-transition) !important;
	background: #ffffff !important;
	color: #222222 !important;
	box-shadow: none !important;
	display: block !important;
	width: 100% !important;
	box-sizing: border-box !important;
}
.beauty-booking-modal-container textarea.beauty-booking-input {
	min-height: 85px;
	resize: vertical;
	line-height: 1.5;
}
.beauty-booking-modal-container .beauty-booking-input:focus {
	outline: none !important;
	border-color: var(--beauty-primary) !important;
	background: #ffffff !important;
	box-shadow: 0 0 0 3px rgba(224, 79, 0, 0.15) !important;
}
.beauty-booking-modal-container .beauty-booking-input::placeholder {
	color: #888888 !important;
	opacity: 1 !important;
}

/* Actions panel styling */
.beauty-booking-step-actions {
	display: flex;
	justify-content: flex-end;
	gap: 15px;
	margin-top: 30px;
	padding-top: 20px;
	border-top: 1px solid var(--beauty-border);
}
.beauty-booking-btn-secondary {
	display: inline-flex;
	align-items: center;
	gap: 8px;
	background: #fff;
	color: var(--beauty-text-muted) !important;
	border: 1px solid var(--beauty-border);
	padding: 12px 24px;
	border-radius: 30px;
	font-family: 'Outfit', sans-serif;
	font-size: 16px;
	font-weight: 500;
	cursor: pointer;
	transition: var(--beauty-transition);
}
.beauty-booking-btn-secondary:hover {
	border-color: var(--beauty-text);
	color: var(--beauty-text) !important;
	background: #fafafa;
}

/* Error message styling */
.beauty-booking-error-message {
	background: #fff2f5;
	border: 1px solid #ffccd6;
	color: #cc0033;
	padding: 12px 16px;
	border-radius: 8px;
	font-size: 14px;
	margin-bottom: 20px;
}

/* Success View */
.beauty-booking-success-wrapper {
	text-align: center;
	padding: 15px 5px 5px 5px;
	max-width: 500px;
	margin: 0 auto;
}
.beauty-booking-success-wrapper h3 {
	font-size: 22px;
	font-weight: 700;
	color: #111827;
	margin: 18px 0 10px 0;
	line-height: 1.3;
}
.beauty-booking-success-subtitle {
	color: #4b5563;
	font-size: 15px;
	line-height: 1.5;
	margin: 0 0 22px 0;
}
.beauty-booking-success-summary {
	background: #faf8f7;
	border: 1px solid #f0e6de;
	border-radius: 14px;
	padding: 16px 20px;
	margin: 0 0 20px 0;
	text-align: left;
}
.beauty-booking-summary-row {
	display: flex;
	align-items: center;
	gap: 12px;
	font-size: 15px;
	color: #1f2937;
}
.beauty-booking-summary-row:first-child {
	border-bottom: 1px solid #ede4dc;
	padding-bottom: 12px;
	margin-bottom: 12px;
}
.beauty-summary-icon {
	color: #84BD00;
	flex-shrink: 0;
	stroke-width: 2.2;
}
.beauty-booking-success-note {
	display: flex;
	align-items: center;
	justify-content: center;
	gap: 12px;
	margin: 18px 0 14px 0;
	text-align: left;
}
.beauty-note-icon {
	color: #E04F00;
	flex-shrink: 0;
	stroke-width: 2;
}
.beauty-booking-note-text {
	font-size: 13.5px;
	color: #4b5563;
	line-height: 1.4;
}
.beauty-booking-success-tagline {
	font-size: 17px;
	font-weight: 700;
	color: #111827;
	margin: 14px 0 22px 0;
	text-align: center;
}
#booking-success-close {
	width: 100%;
	justify-content: center;
	padding: 14px 20px;
	font-size: 16px;
	font-weight: 600;
	border-radius: 12px;
}

/* Checkmark SVG Animation */
.success-animation-container {
	display: block;
	margin: 0 auto;
	width: 76px;
	height: 76px;
}
.checkmark-circle {
	stroke-dasharray: 166;
	stroke-dashoffset: 166;
	stroke-width: 3;
	stroke-miterlimit: 10;
	stroke: #84BD00;
	fill: none;
	animation: stroke-circle 0.6s cubic-bezier(0.65, 0, 0.45, 1) forwards;
}
.checkmark-svg {
	width: 76px;
	height: 76px;
	border-radius: 50%;
	display: block;
	stroke-width: 3.5;
	stroke: #84BD00;
	stroke-miterlimit: 10;
	background: transparent;
	animation: scale-checkmark .3s ease-in-out .6s cubic-bezier(0.165, 0.84, 0.44, 1) alternate;
}
.checkmark-check {
	transform-origin: 50% 50%;
	stroke-dasharray: 48;
	stroke-dashoffset: 48;
	stroke: #84BD00;
	stroke-width: 3.5;
	animation: stroke-check 0.3s cubic-bezier(0.65, 0, 0.45, 1) 0.5s forwards;
}

/* Button Spinner */
.btn-spinner {
	width: 16px;
	height: 16px;
	border: 2px solid rgba(255, 255, 255, 0.3);
	border-top-color: #fff;
	border-radius: 50%;
	animation: beautySpin 0.6s linear infinite;
	display: inline-block;
	vertical-align: middle;
	margin-left: 8px;
}

/* Animations */
@keyframes beautySpin {
	to { transform: rotate(360deg); }
}
@keyframes beautyFadeIn {
	from { opacity: 0; }
	to { opacity: 1; }
}
@keyframes beautyScaleIn {
	from { transform: scale(0.95); opacity: 0; }
	to { transform: scale(1); opacity: 1; }
}
@keyframes stroke-circle {
	100% { stroke-dashoffset: 0; }
}
@keyframes stroke-check {
	100% { stroke-dashoffset: 0; }
}
@keyframes fill-checkmark {
	100% { box-shadow: inset 0px 0px 0px 40px var(--beauty-accent); }
}
@keyframes scale-checkmark {
	0% { transform: none; }
	50% { transform: scale3d(1.1, 1.1, 1); }
	100% { transform: none; }
}

/* Responsive adjustments for Mobile Screens */
@media (max-width: 480px) {
	.beauty-booking-modal-overlay {
		padding: 10px;
	}
	.beauty-booking-modal-container {
		padding: 20px 16px;
		max-height: 95vh;
		border-radius: 12px;
	}
	.beauty-booking-modal-close {
		top: 15px;
		right: 15px;
		font-size: 28px;
	}
	.beauty-booking-modal-header h2 {
		font-size: 20px;
		padding-right: 25px; /* Leave space for close button */
	}
	.beauty-booking-modal-header p {
		font-size: 13px;
	}
	.beauty-booking-steps {
		margin: 20px 0;
	}
	.booking-step span {
		display: none; /* Hide labels on small mobile screens to prevent overflow */
	}
	.step-num {
		width: 32px;
		height: 32px;
		font-size: 14px;
	}
	.beauty-booking-calendar-wrapper {
		padding: 12px 8px;
	}
	.beauty-booking-calendar-header {
		font-size: 15px;
		margin-bottom: 12px;
	}
	.calendar-nav-btn {
		width: 28px;
		height: 28px;
	}
	.calendar-day-header {
		font-size: 11px;
		padding-bottom: 6px;
	}
	.calendar-day-cell {
		font-size: 13px;
	}
	.beauty-booking-slots-grid {
		grid-template-columns: repeat(2, 1fr);
		gap: 8px;
	}
	.beauty-booking-slot-btn {
		padding: 10px 6px;
		font-size: 13px;
	}
	.beauty-booking-step-actions {
		flex-direction: column-reverse;
		gap: 10px;
		margin-top: 20px;
		padding-top: 15px;
	}
	.beauty-booking-step-actions button {
		width: 100% !important;
		justify-content: center;
	}
	.beauty-booking-form-summary {
		padding: 12px;
		font-size: 14px;
	}
}

/* Extra small mobile adjustments */
@media (max-width: 350px) {
	.beauty-booking-slots-grid {
		grid-template-columns: 1fr;
	}
}
