/* Moving Quote Form Styles */

/* Initial form (trigger) styles */
.mqf-initial-form {
    border-radius: 12px;
    text-align: center;
}

#mqf-initial-form {
    display: flex;
    gap: 20px;
    align-items: center;
}

/* API Error notice */
.mqf-api-notice {
    background: #fff3cd;
    border: 1px solid #ffeaa7;
    color: #856404;
    padding: 10px 15px;
    border-radius: 8px;
    margin-bottom: 20px;
    font-size: 14px;
    text-align: left;
}

.mqf-api-notice.error {
    background: #f8d7da;
    border: 1px solid #f5c6cb;
    color: #721c24;
}

/* Input states for API feedback */
.mqf-input-group input.success,
.mqf-form-group input.success {
    border-color: #e80000 !important;
}

.mqf-input-group input.warning,
.mqf-form-group input.warning {
    border-color: #ffc107 !important;
}

.mqf-input-group input.error,
.mqf-form-group input.error {
    border-color: #dc3545 !important;
}

/* Code styling in notices */
.mqf-api-notice code {
    background: rgba(0, 0, 0, 0.1);
    padding: 2px 6px;
    border-radius: 3px;
    font-family: 'Courier New', monospace;
    font-size: 13px;
}

.mqf-initial-form p {
    color: #6c757d;
    margin-bottom: 25px;
    font-size: 16px;
}

.mqf-input-group {
    text-align: left;
}

/* Original input group styles for backwards compatibility */
.mqf-input-group label {
    display: block;
    margin-bottom: 8px;
    font-weight: 600;
    color: #495057;
}

.mqf-input-group input {
    width: 100%;
    padding: 12px 16px;
    border: 1px solid #e5e5e5;
    border-radius: 8px;
    font-size: 16px;
    transition: all 0.2s cubic-bezier(0.25, 0.8, 0.25, 1);
    box-sizing: border-box;
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.05);
}

.mqf-input-group input:focus {
    outline: none;
    border-color: var(--bricks-color-5b84a3);
    box-shadow: 0 0 0 3px rgba(91, 132, 163, 0.1);
}

/* New integrated input styles with icon */
.mqf-input-with-icon .mqf-input-container {
    display: flex;
    align-items: center;
    background: #fff;
    border: 1px solid #b9b9b9;
    border-radius: 8px;
    padding: 12px 16px;
    gap: 16px;
    transition: all 0.2s cubic-bezier(0.25, 0.8, 0.25, 1);
    min-height: 54px;
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.05);
}

.mqf-input-with-icon .mqf-input-container:hover {
    border-color: var(--bricks-color-5b84a3);
}

.mqf-input-with-icon .mqf-input-container:focus-within {
    border-color: var(--bricks-color-5b84a3);
    box-shadow: 0 0 0 3px rgba(91, 132, 163, 0.1);
}

.mqf-input-icon {
    flex-shrink: 0;
    display: flex;
    align-items: center;
    margin-top: 2px;
    opacity: 0.7;
    transition: opacity 0.2s ease;
}

.mqf-input-with-icon .mqf-input-container:focus-within .mqf-input-icon {
    opacity: 1;
}

.mqf-input-icon svg {
    width: 24px;
    height: 24px;
}

.mqf-input-content {
    flex: 1;
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.mqf-input-with-icon .mqf-input-content input {
    border: none;
    background: transparent;
    padding: 0;
    font-size: 16px;
    color: #333;
    outline: none;
    width: 100%;
    font-weight: 500;
}

.mqf-input-with-icon .mqf-input-content input::placeholder {
    color: #999;
    font-size: 16px;
    font-weight: 400;
}

.mqf-btn {
    background: var(--bricks-color-5b84a3);
    color: #fff;
    padding: 16px 32px;
    border: none;
    border-radius: 50px;
    font-size: 15px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.25, 0.8, 0.25, 1);
    letter-spacing: 0.5px;
    box-shadow: 0 4px 6px rgba(91, 132, 163, 0.2);
}

.mqf-btn:hover {
    background: var(--bricks-color-5b84a3);
    filter: brightness(0.9);
    transform: translateY(-1px);
    box-shadow: 0 6px 12px rgba(91, 132, 163, 0.25);
}

.mqf-btn:active {
    transform: translateY(0);
    box-shadow: 0 2px 4px rgba(91, 132, 163, 0.2);
}

.mqf-btn:disabled {
    background: #c5c5c5;
    cursor: not-allowed;
    transform: none;
    box-shadow: none;
}

/* Modal/Popup styles */
.mqf-modal {
    display: none;
    position: fixed;
    z-index: 10000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.65);
    backdrop-filter: blur(8px);
}

.mqf-modal-content {
    background-color: #fff;
    margin: 0;
    padding: 0;
    border-radius: 16px;
    width: 90%;
    max-width: 600px;
    max-height: 90vh;
    overflow-y: auto;
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.2);
    animation: modalSlideUp 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}

@keyframes modalSlideUp {
    from {
        opacity: 0;
        transform: translate(-50%, -40%) scale(0.98);
    }

    to {
        opacity: 1;
        transform: translate(-50%, -50%) scale(1);
    }
}

.mqf-modal-header {
    background: #fff;
    color: #000;
    padding: 24px 32px;
    border-radius: 16px 16px 0 0;
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-bottom: 1px solid #f0f0f0;
    gap: 20px;
}

/* Steps counter */
.mqf-steps-counter {
    flex: 0 0 auto;
    font-size: 13px;
    font-weight: 600;
    color: var(--bricks-color-5b84a3);
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

/* Header center section */
.mqf-header-center {
    display: flex;
    flex-direction: row;
    align-items: center;
    justify-content: center;
    gap: 15px;
    width: 100%;
}

/* Progress bar in header */
.mqf-header-center .mqf-progress-bar {
    width: 100%;
    height: 6px;
    background-color: #f0f0f0;
    border-radius: 30px;
    overflow: hidden;
}

.mqf-header-center .mqf-progress-fill {
    height: 100%;
    background: var(--bricks-color-5b84a3);
    border-radius: 3px;
    transition: width 0.4s ease;
}

/* Current step title */
.mqf-current-step-title {
    font-size: 15px;
    font-weight: 600;
    color: #1a1a1a;
    text-align: center;
    flex-shrink: 0;
}

/* Close button */
.mqf-close {
    color: #666;
    cursor: pointer;
    padding: 0;
    background: #f5f5f5;
    border: none;
    width: 36px;
    height: 36px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    transition: all 0.2s ease;
    flex: 0 0 auto;
}

.mqf-close svg {
    width: 20px;
    height: 20px;
    stroke: currentColor;
    stroke-width: 2.5;
}

.mqf-close:hover {
    background-color: var(--bricks-color-5b84a3);
    color: #fff;
    transform: rotate(90deg);
}

.mqf-modal-body {
    padding: 40px;
}

/* Remove old progress indicator styles - now in header */

/* Form step styles */
.mqf-step-content {
    display: none;
    animation: stepFadeIn 0.4s ease;
}

.mqf-step-content.active {
    display: block;
}

@keyframes stepFadeIn {
    from {
        opacity: 0;
        transform: translateY(10px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.mqf-step-title {
    color: #111;
    margin-bottom: 25px;
    font-size: 20px;
    font-weight: 600;
    text-align: center;
    letter-spacing: -0.5px;
}

.mqf-form-group {
    margin-bottom: 28px;
}

.mqf-form-group label {
    display: block;
    margin-bottom: 10px;
    font-weight: 600;
    color: #333;
    font-size: 14px;
}

.mqf-form-group input,
.mqf-form-group select {
    width: 100%;
    padding: 14px 16px;
    border: 1px solid #e0e0e0;
    border-radius: 10px;
    font-size: 15px;
    transition: all 0.2s cubic-bezier(0.25, 0.8, 0.25, 1);
    box-sizing: border-box;
    background: #fff;
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.03);
    color: #333;
}

/* Custom select dropdown styling */
.mqf-form-group select {
    padding-right: 45px;
    background-image: url('../svg/arrow-down.svg');
    background-repeat: no-repeat;
    background-position: right 14px center;
    background-size: 16px 16px;
    -webkit-appearance: none;
    -moz-appearance: none;
    appearance: none;
    cursor: pointer;
}

.mqf-form-group select::-ms-expand {
    display: none;
    /* Hide default arrow in IE */
}

.mqf-form-group input:focus,
.mqf-form-group select:focus {
    outline: none;
    border-color: var(--bricks-color-5b84a3);
    box-shadow: 0 0 0 3px rgba(91, 132, 163, 0.1);
}

/* Select focus state with custom arrow */
.mqf-form-group select:focus {
    background-image: url('../svg/arrow-down.svg');
}

/* Select hover state */
.mqf-form-group select:hover {
    border-color: var(--bricks-color-5b84a3);
}

/* Option buttons */
.mqf-options {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(120px, 1fr));
    gap: 15px;
    margin-top: 15px;
}

.mqf-option {
    position: relative;
}

.mqf-option input[type="radio"],
.mqf-option input[type="checkbox"] {
    position: absolute;
    opacity: 0;
    width: 0;
    height: 0;
}

.mqf-option label {
    display: block;
    padding: 16px 20px;
    background-color: #efefef;
    border: 1px solid #b9b9b9;
    border-radius: 8px;
    text-align: center;
    cursor: pointer;
    transition: all 0.3s ease;
    font-weight: 500;
    font-size: 14px;
    margin-bottom: 0;
}

.mqf-option label:hover {
    background-color: #f8f9fa;
    border-color: #e80000;
}

.mqf-option input:checked+label {
    background-color: #e80000;
    border-color: #e80000;
    color: #fff;
}

/* Date options specific styles - Removed as we use native date input now */

/* Property sections - Removed */

/* Success State */
.mqf-success-state {
    text-align: center;
    padding: 40px 20px;
    animation: fadeIn 0.5s ease;
}

.mqf-success-state svg {
    margin-bottom: 20px;
    width: 64px;
    height: 64px;
}

.mqf-success-state h3 {
    color: #000;
    font-size: 24px;
    margin-bottom: 10px;
    font-weight: 600;
}

.mqf-success-state p {
    color: #666;
    font-size: 16px;
    margin-bottom: 30px;
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(10px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Navigation buttons */
.mqf-navigation {
    display: flex;
    justify-content: space-between;
    margin-top: 20px;
    padding-top: 20px;
    border-top: 1px solid #d5d5d5;
    gap: 15px;
}

.mqf-navigation .mqf-btn-back {
    width: 100%;
    text-align: center;
}

.mqf-navigation .mqf-btn-next,
.mqf-navigation .mqf-btn-submit {
    width: 100%;
    text-align: center;
}

#mqf-navigation-buttons {
    width: 100%;
    display: flex;
    justify-content: flex-end;
}

/* Step 2 specific - Next button takes full width when back button is hidden */
.mqf-navigation.step-2-nav .mqf-btn-next {
    flex: 0 0 100%;
}

.mqf-btn-back {
    background: #fff;
    color: #7b7b7b;
    padding: 12px 24px;
    border: 1px solid #d5d5d5;
    border-radius: 50px;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.mqf-btn-back:hover {
    background: #000;
    color: #fff;
}

.mqf-btn-next,
.mqf-btn-submit {
    background: var(--bricks-color-5b84a3);
    color: #fff;
    padding: 12px 24px;
    border: none;
    border-radius: 60px;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    width: 100%;
}

.mqf-btn-next:hover {
    background: var(--bricks-color-5b84a3);
    filter: brightness(0.9);
}

.mqf-btn-submit {
    background: var(--bricks-color-5b84a3);
}

.mqf-btn-submit:hover {
    background: var(--bricks-color-5b84a3);
    filter: brightness(0.9);
}

/* Loading state */
.mqf-loading {
    display: none;
    text-align: center;
    padding: 20px;
}

.mqf-spinner {
    border: 3px solid #f3f3f3;
    border-top: 3px solid var(--bricks-color-5b84a3);
    border-radius: 50%;
    width: 40px;
    height: 40px;
    animation: spin 1s linear infinite;
    margin: 0 auto 20px;
}

@keyframes spin {
    0% {
        transform: rotate(0deg);
    }

    100% {
        transform: rotate(360deg);
    }
}

/* Success/Error messages */
.mqf-message {
    padding: 15px 20px;
    border-radius: 8px;
    margin-bottom: 20px;
    font-weight: 500;
    font-size: 14px;
}

.mqf-message.success {
    background-color: #d4edda;
    border: 1px solid #c3e6cb;
    color: #155724;
}

.mqf-message.error {
    background-color: #f8d7da;
    border: 1px solid #f5c6cb;
    color: #721c24;
}

/* Responsive design */
@media (max-width: 768px) {
    .mqf-modal-content {
        width: 95%;
        max-height: 85vh;
    }

    .mqf-modal-header {
        padding: 15px 20px;
        flex-direction: column;
        align-items: stretch;
        gap: 15px;
    }

    .mqf-steps-counter {
        text-align: center;
        font-size: 14px;
    }

    .mqf-header-center {
        margin: 0;
        order: 2;
    }

    .mqf-current-step-title {
        font-size: 14px;
    }

    .mqf-close {
        position: absolute;
        top: 15px;
        right: 20px;
        order: -1;
    }

    .mqf-modal-body {
        padding: 20px;
    }

    .mqf-step-indicator {
        overflow-x: auto;
        padding-bottom: 10px;
        gap: 5px;
    }

    .mqf-step {
        min-width: 40px;
    }

    .mqf-navigation {
        justify-content: space-between;
        gap: 15px;
    }

    .mqf-btn-back,
    .mqf-btn-next,
    .mqf-btn-submit {
        width: auto;
        padding: 14px 24px;
    }

    /* Maintain proportions on mobile */
    .mqf-navigation .mqf-btn-back {
        flex: 0 0 20%;
    }

    .mqf-navigation .mqf-btn-next,
    .mqf-navigation .mqf-btn-submit {
        flex: 0 0 80%;
    }

    /* Step 2 specific on mobile */
    .mqf-navigation.step-2-nav .mqf-btn-next {
        flex: 0 0 100%;
    }

    /* Responsive styles for integrated inputs */
    #mqf-initial-form {
        flex-direction: column;
        gap: 15px;
    }

    .mqf-input-with-icon .mqf-input-container {
        padding: 8px 12px;
        min-height: 52px;
        gap: 12px;
    }

    .mqf-input-with-icon .mqf-input-content input {
        font-size: 16px;
    }

    .mqf-input-with-icon .mqf-input-content input::placeholder {
        font-size: 16px;
    }

    .mqf-btn {
        width: 100%;
    }

    /* Select responsive adjustments */
    .mqf-form-group select {
        padding-right: 40px;
        background-size: 18px 18px;
        background-position: right 10px center;
    }
}