/* General Styling */
* {
	margin: 0;
	padding: 0;
	box-sizing: border-box;
	font-family: 'Segoe UI', sans-serif;
}

body {
	height: 100vh;
    width: 100vw;
}

.container {
	display: flex;
    width: 100%;
    height: 100%;
}

h1, h2, button{
	font-family: 'Poppins', sans-serif;
}
label, p, li, strong, span{
	font-family: 'Inter', sans-serif;
}

/* Left Section - Form */
.left-section {
    position: relative;
    width: 50%;
	background-color: #fff;
	padding: 40px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: space-between;
    overflow: auto;
}

.left-section::-webkit-scrollbar {
	width: 5px;
}

.left-section::-webkit-scrollbar-thumb {
	background: #D9DCD6;
	border-radius: 3px;
}

/* Right Section - Image */
.right-section {
    position: relative;
    width: 50%;
    display: flex;
    flex-direction: column;
    background-color: #004899; /* Fallback color */
    color: #fff;
    text-align: center;
    justify-content: space-between;
    padding: 20px;
    border-radius: 0 4% 4% 0;
    z-index: 1;
    overflow: hidden;
}

/* Background image with opacity */
.right-section::before {
    content: "";
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: url('../img/banner.webp') no-repeat center center/cover;
    opacity: 0.5; /* Adjust transparency */
    border-radius: 0 4% 4% 0;
    z-index: -1;
}

/* Overlapping Cut Effect - Desktop (Right Side) */
.right-section::after {
    content: "";
    position: absolute;
    right: -40px; /* Moves the cut inside */
    top: 4%;
    bottom: 4%;
    width: 60px; /* Controls how deep the cut is */
    background: #fff;
    border-top-left-radius: 40px; 
    border-bottom-left-radius: 40px;
}

.right-section .logo a img {
    width: 450px;
}

.right-section h2 {
    color: #fff;
    text-align: center;
    font-size: 25px;
    margin: 0 auto;
}

.form {
    margin: auto;
    display: flex;
    flex-direction: column;
    align-items: center;
}

h1 {
	text-align: center;
	font-size: 23px;
	color: #004899;
    padding-bottom: 15px;
}

h2 {
    width: 100%;
    max-width: 400px;
    margin: auto;
    text-align: left;
	font-size: 17px;
	color: #004899;
    padding-top: 10px;
}

.required {
	color: red;
	top: 10%;
}

/* Form Groups */
.form-group {
    width: 100%;
	max-width:500px;
	display: none; /* Hide all steps by default: */
}

/* Field Styling */
select, input {
    box-sizing: border-box; /* Ensures padding and border are included in the width */
}

select {
	width: 100%;
	padding: 8px 10px;
	border: 1px solid #ddd; /* Softer border color */
	border-radius: 5px; /* Slightly more rounded for a modern feel */
	font-size: 16px;
	appearance: none;
	cursor: pointer;
	background-color: #fff;
	color: #333;
	box-shadow: inset 0 1px 3px rgba(0, 0, 0, 0.05); /* Softer shadow for depth */
	transition: border-color 0.3s, box-shadow 0.3s; /* Smooth transitions */
    appearance: none; /* ✅ Remove default browser styling */
    -webkit-appearance: none;
    -moz-appearance: none;
}

/* Fix background for dropdown options */
select option {
    background-color: #fff !important; /* ✅ Background for options */
    color: #333 !important; /* ✅ Ensure text is readable */
}

input {
	width: 100%;
	padding: 8px 10px;
	border: 1px solid #ddd; /* Softer border color */
	border-radius: 5px; /* Slightly more rounded for a modern feel */
	font-size: 16px;
	outline: none; /* Removes the default outline */
	background-color: #fff; /* White background for clarity */
	color: #333; /* Dark text for readability */
	box-shadow: inset 0 1px 3px rgba(0, 0, 0, 0.05); /* Softer shadow for depth */
	transition: border-color 0.3s, box-shadow 0.3s; /* Smooth transitions */
}

select:focus, input:focus {
	border-color: #2F6690; /* Blue border on focus */
	box-shadow: 0 0 0 2px rgba(47, 102, 144, 0.1); /* Soft focus glow */
	outline: none; /* Removes default outline on focus */
}

/* Completely remove the yellow background from autofill */
input:-webkit-autofill,
input:-webkit-autofill:hover,
input:-webkit-autofill:focus,
input:-webkit-autofill:active,
textarea:-webkit-autofill,
textarea:-webkit-autofill:hover,
textarea:-webkit-autofill:focus,
textarea:-webkit-autofill:active {
    background-color: transparent !important;
    -webkit-text-fill-color: #333 !important; /* ✅ Make text white */
    transition: background-color 5000s ease-in-out 0s;
}

.select-container, .input-container {
	position: relative;
	margin: 20px auto;
	display: flex;
    flex-direction: column;
    align-items: center;
	width: 100%;
	gap: 10px;
}

.input-container {
	margin-top: 10px;
}

.PackageWeightErrorContainer {
	margin-top: 20px;
}

.select-container::after {
	content: "⌵";
	position: absolute;
	right: 20px;
	top: 45%;
	font-weight:bold;
	transform: translateY(-50%);
	color: #888;
	pointer-events: none;
}

.select-container label, .input-container label {
	position: absolute;
	left: 10px;
	top: 48%;
	transform: translateY(-50%);
	background: #fff;
	padding: 0 5px;
	color: #888;
	font-size: 13px;
	transition: all 0.3s ease;
	pointer-events: none;
}

/* Move label to top when select/input is focused or has a valid option selected or content */
select:focus + label,
select:valid + label,
.input-container input:focus + label,
.input-container input:not(:placeholder-shown) + label {
	top: 0;
	font-size: 12px;
	color: #ff9800;
}

/* Mark select boxes that gets an error on validation: */
select.invalid, input.invalid {
	border: 1px solid red;
}

#shipmentType, .carrier-card {
    width: 30vw;
	max-width: 100%;
}


.custom-select-input {
    width: 100%;
    padding: 10px;
    font-size: 14px;
    border: 1px solid #ccc;
    border-radius: 4px;
}

.custom-select-input:focus + .custom-select-dropdown,
.custom-select-input.open + .custom-select-dropdown {
    display: block;
}

.custom-select-dropdown {
    position: absolute;
    z-index: 1000;
    top: 100%;
    left: 0;
    right: 0;
    background: white;
    border: 1px solid #ccc;
    border-top: none;
    max-height: 180px;
    overflow-y: auto;
    display: none;
}

.custom-select-dropdown li {
    padding: 10px;
    cursor: pointer;
}

.custom-select-dropdown li:hover {
    background-color: #f0f0f0;
}

/* Floating label behavior */
.custom-select-input:focus ~ label,
.custom-select-input:not(:placeholder-shown) ~ label {
    top: 0px;
    font-size: 12px;
    color: #ff9800;
    background: white;
}

.select-container .spinner {
	position: absolute;
	top: 50%;
	right: 3rem;
	width: 1.5rem;
	height: 1.5rem;
	border: 2px solid #ccc;
	border-top-color: #333;
	border-radius: 50%;
	animation: spin 0.6s linear infinite;
	transform: translateY(-50%);
	display: none; /* hidden by default */
}

@keyframes spin {
	to {
		transform: translateY(-50%) rotate(360deg);
	}
}

.rateLoadingSpinner {
    display: none;
    text-align: center;
}

.cardSpinner {
    border: 4px solid #f3f3f3;
    border-top: 4px solid #ff9800;
    border-radius: 50%;
    width: 50px;
    height: 50px;
    margin: 10px auto;
    animation: cardSpin 1s linear infinite;
}

@keyframes cardSpin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}


.carrier-card {
    border: 1px solid #ddd;
    border-radius: 10px;
    padding: 15px;
    margin: 0 auto;
    margin-bottom: 15px;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.carrier-logo {
    width: 60px;
    height: 60px;
    object-fit: contain;
    margin-right: 15px;
    flex-shrink: 0; /* ensure logo stays fixed size */
}

.carrier-info {
    flex: 1;
}

.carrier-name {
    font-size: 16px;
    font-weight: bold;
    margin: 0;
}

.carrier-service {
    font-size: 14px;
    color: #555;
    margin: 3px 0;
}

.carrier-price {
    font-size: 18px;
    font-weight: bold;
    color: #333;
}

.carrier-pickup,
.carrier-delivery {
    font-size: 12px;
    color: #666;
}


.valueDisplay {
    display: none;
}
.valueDisplay.visible {
    display: block;
}


/* Button Styling */
button {
    color: #fff;
    font-size: 14px;
    font-weight: 500;
    text-transform: uppercase;
    padding: 8px 20px;
    border: none;
    border-radius: 3px;
    cursor: pointer;
    transition: background 0.3s ease;
    width: 100%;
}


.formNavTab {
    display: flex;
	justify-content: center; /* ✅ Centers the button */
    width: 100%;
    max-width: 400px;
    gap: 10px; /* ✅ Adds spacing between buttons */
    padding-top: 20px;
    padding-bottom: 5px;
    visibility: hidden; /* Hide buttons on page load */
}

.formNavPre, .formNavNext {
    flex: 1; /* ✅ Ensures both buttons have equal width */
	transition: all 0.5s ease;
}

.formNavPre {
    background: #F5F5DC;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2); /* Added shadow for more pop */
    color: #ff9800;
}

.formNavNext {
    background: #ff9800;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2); /* Added shadow for more pop */
}

.formNavPre:hover, .formNavNext:hover {
    box-shadow: 0 6px 12px rgba(0, 0, 0, 0.3); /* Enhanced shadow on hover */
	transform: translateY(-1px); /* ✅ Lift effect on hover */
}














/*------------------------- Use a media query to add a breakpoint at 800px: -------------------------*/
/* Responsive Design */

@media screen and (max-width: 982px) {
	.container {
        display: flex;
        flex-direction: column;
        overflow: auto;
    }
    .left-section, .right-section {
        width: 100%;
        overflow: visible;

    }
    .right-section {
        border-radius: 0 0 6% 6%;
        justify-content: center;
        padding: 0 0 15px 0;
        min-height: 230px;
    }
    .right-section::after {
        right: auto;
        left: 50%;
        bottom: -40px;
        top: auto;
        transform: translateX(-50%);
        width: 90%;
        height: 50px;
        background: white;
        border-top-left-radius: 40px;
        border-top-right-radius: 40px;
        border-bottom-right-radius: 0;
        border-bottom-left-radius: 0;
    }
    .right-section h2 {
        display: none;
    }
    .right-section .logo a img {
        width: 350px;
    }
    .right-section p {
        font-size: 12px;
    }
    #shipmentType, .carrier-card {
		width: 45vw;
	}
    .form-group h1 {
        font-size: 21px;
    }
}

@media (max-width: 768px) {
	.select-container label, .input-container label {
		left: 5px;
		top: 50%;
	}
	#shipmentType, .carrier-card {
		width: 80vw;
	}
	/* Summary Section */
	.review-section {
		width: 100%;
	}
	.price-section {
		width: 100%;
	}
	
}