

/* 2. THE MAIN WHITE MODAL */
.booking-container {
    background-color: #ffffff;
    width: 100%;
    max-width: 650px;
    border-radius: 12px;
    padding: 50px;
    box-shadow: 0 15px 45px rgba(0, 0, 0, 0.1);
    margin: 40px auto;
    font-family: 'Inter', sans-serif;
    overflow-x: hidden;
    isolation: isolate;
    

}

/* 3. PROGRESS BAR */
.progress-bar {
    width: 100%; 
    height: 10px;
    background-color: #f1f1f1;
    border-radius: 10px;
    margin: 0 auto 35px auto;
    overflow: hidden;
}

.progress-fill {
    height: 100%;
    background-color: #28c76f;
    transition: width 0.4s ease;
}

.booking-steps { display: none; }

/* 4. SERVICE CARD STYLING */
.service-list {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.service-card {
    background-color: #ffffff;
    border: 1px solid #eeeeee;
    border-radius: 8px;
    padding: 25px;
    cursor: pointer;
    transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: 0 2px 4px rgba(0,0,0,0.02);
}

.service-card:hover {
    background-color: #f0f7ff; 
    border-color: #c2d9ff;     
    transform: translateY(-4px);
    box-shadow: 0 8px 20px rgba(0,0,0,0.08);
}

.service-card.selected {
    background-color: #f0f7ff;
    border-color: #007bff;
    border-width: 2px;
}

/* 5. TYPOGRAPHY */
.booking-heading {
    font-size: 28px;
    font-weight: 700;
    color: #333;
    margin-bottom: 30px;
    text-align: center;
}

.service-card-info h3 {
    font-size: 18px;
    font-weight: 600;
    color: #444;
    margin: 0 0 8px 0;
    transition: color 0.2s ease;
}

.service-card:hover h3, .service-card.selected h3 {
    color: #007bff;
}

.service-card-info p {
    font-size: 14px;
    color: #777;
    line-height: 1.6;
    margin: 0;
}

/* --- STEP 2: FLOATING LABELS & GRID (Refined) --- */

.selected-service-banner {
    padding: 10px 0;
    border-bottom: 1px solid #eee;
    margin-bottom: 15px;
    font-size: 14px;
    font-weight: 600;
    color: #333;
    display: flex;
    align-items: center;
    gap: 8px;
}

.selected-service-banner::before {
    content: '🛒';
    font-size: 14px;
}

.nav-links {
    margin-bottom: 20px;
}

.back-btn-link {
    text-decoration: none;
    color: #555;
    font-size: 14px;
    font-weight: 500;
    display: inline-block;
    transition: color 0.2s;
}

.back-btn-link:hover {
    color: #0070ba;
}

.step-title {
    font-size: 24px;
    font-weight: 700;
    margin-bottom: 25px;
    color: #222;
}

.floating-group {
    position: relative;
    border: 1px solid #ced4da;
    border-radius: 8px;
    background-color: #fff;
    transition: all 0.2s ease;
    height: 56px; 
    margin-bottom: 22px; 
    display: flex;
    flex-direction: column;
    justify-content: center;
    overflow: visible; /* Crucial for absolute error visibility */
}

.floating-group label {
    position: absolute;
    left: 15px;
    top: 50%;
    transform: translateY(-50%);
    font-size: 15px;
    color: #6c757d;
    transition: all 0.2s ease;
    pointer-events: none;
    z-index: 3;
}

.floating-group input, 
.floating-group select {
    width: 100%;
    height: 100%;
    border: none;
    outline: none;
    font-size: 15px;
    background: transparent;
    color: #333;
    padding: 20px 15px 6px 15px; 
    box-sizing: border-box;
    z-index: 2;
    display: block;
}

/* Shrink Logic: Optimized for "Housecall Pro" spacing */
.floating-group input:focus + label,
.floating-group input:not(:placeholder-shown) + label,
.floating-group select:focus + .static-label,
.floating-group select:not([value=""]) + .static-label {
    top: 10px;
    transform: translateY(0);
    font-size: 11px;
    color: #0070ba;
    font-weight: 600;
}

.floating-group .static-label {
    top: 10px;
    transform: translateY(0);
    font-size: 11px;
    color: #6c757d;
}

.floating-group:focus-within {
    border-color: #0070ba;
    box-shadow: 0 0 0 1px #0070ba;
}

/* --- GRID SYSTEM --- */
.input-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 12px;
    margin-bottom: 0; /* Handled by floating-group margin */
}

.full-width {
    grid-column: span 2;
}

.address-instruction {
    font-size: 15px;
    color: #444;
    margin: 15px 0 15px 0;
}

/* --- CONSENT & BUTTON UPDATED --- */
.consent-wrapper {
    margin: 30px 0; /* Give it more space from the summary card */
}

.consent-label {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    cursor: pointer;
    margin-bottom: 15px; /* More space between the two checkboxes */
}

.consent-label input[type="checkbox"] {
    width: 18px;
    height: 18px;
    margin-top: 2px;
    accent-color: #0070ba;
    flex-shrink: 0;
    cursor: pointer;
}



.consent-text {
    font-size: 15px; /* Increased from 13px for better readability */
    color: #444;
    line-height: 1.5;
}

/* --- LEGAL TEXT UPDATED --- */
.legal-text {
    font-size: 14px; /* Increased for better visibility */
    color: #666;
    border-top: 1px solid #eee;
    padding-top: 20px;
    margin-top: 20px;
    line-height: 1.6;
}

.legal-text a {
    color: #007bff; /* Standard blue link color to show it's clickable */
    text-decoration: none; 
    font-weight: 500;
}

.legal-text a:hover {
    text-decoration: underline; /* Shows interaction when hovering */
    color: #0056b3; /* Darker blue on hover */
}

.next-btn-pill {
    width: 100%;
    background-color: #0070ba;
    color: white;
    border: none;
    padding: 16px;
    border-radius: 50px;
    font-size: 16px;
    font-weight: 700;
    cursor: pointer;
    transition: background 0.3s ease;
    margin-top: 10px;
}

.next-btn-pill:hover {
    background-color: #005a9e;
}

/* --- STEP 3 & 4 UPDATED --- */
input[type="date"] {
    font-size: 16px;
    color: #495057;
    cursor: pointer;
}

/* FIX: This forces the "Select Date" label UP so it doesn't overlap mm/dd/yyyy */
.floating-group input[type="date"] + label,
.floating-group input[type="date"]:focus + label {
    top: -10px !important;
    left: 12px;
    font-size: 12px;
    background: white;
    padding: 0 5px;
    color: #007bff;
    z-index: 10;
}

input[type="date"]::-webkit-calendar-picker-indicator {
    filter: invert(48%) sepia(13%) saturate(3207%) hue-rotate(167deg) brightness(95%) contrast(80%);
    cursor: pointer;
}

select#time {
    cursor: pointer;
    /* FIX: Removes the browser's default arrow so only your SVG shows */
    -webkit-appearance: none;
    -moz-appearance: none;
    appearance: none;
    
    background-image: url("data:image/svg+xml;charset=US-ASCII,%3Csvg%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%20width%3D%2224%22%20height%3D%2224%22%20viewBox%3D%220%200%2024%2024%22%20fill%3D%22none%22%20stroke%3D%22%236c757d%22%20stroke-width%3D%222%22%20stroke-linecap%3D%22round%22%20stroke-linejoin%3D%22round%22%3E%3Cpolyline%20points%3D%226%209%2012%2015%2018%209%22%3E%3C%2Fpolyline%3E%3C%2Fsvg%3E");
    background-repeat: no-repeat;
    background-position: right 15px center;
    background-size: 18px;
    padding: 20px 40px 10px 15px; /* Matched padding with date input */
}

/* FIX: Moves "Arrival Time" label UP as well */
.floating-group select#time + label {
    top: -10px !important;
    left: 12px;
    font-size: 12px;
    background: white;
    padding: 0 5px;
    z-index: 10;
}
.summary-card {
    background: #f8f9fa;
    border: 1px solid #e9ecef;
    border-radius: 12px;
    padding: 25px;
    margin-top: 20px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.02);
}

.summary-card p {
    margin-bottom: 12px;
    font-size: 15px;
    color: #333;
    display: flex;
    justify-content: space-between;
    border-bottom: 1px solid #eee;
    padding-bottom: 8px;
}

.summary-card p:last-child {
    border-bottom: none;
}

.summary-card p strong {
    color: #6c757d;
    font-weight: 500;
    text-transform: uppercase;
    font-size: 12px;
    letter-spacing: 0.5px;
}

/* --- VALIDATION STYLES (Fixed) --- */
.floating-group.input-error {
    border-color: #e74c3c !important;
    background-color: #fffcfc; 
    box-shadow: 0 0 0 1px #e74c3c !important;
}

.error-message {
    position: absolute;
    bottom: -18px; 
    left: 4px;
    color: #e74c3c;
    font-size: 11px;
    font-weight: 500;
    display: block;
    white-space: normal;
    max-width: 100%;
}

/* Responsive adjustment */
@media (max-width: 600px) {
    .input-grid {
        grid-template-columns: 1fr;
    }
    .full-width, .input-grid > div {
        grid-column: span 1;
    }
    .summary-card p {
        flex-direction: column;
        gap: 4px;
    }
}