/**
 * Booking Form Phone Verification Styles
 * 
 * Matches gallery verification (mms.css) UI/UX
 * Updated: Jan 06, 2026
 * 
 * Brand Colors:
 * - Yellow #ffd100 = Default/Ready
 * - Blue #567BD2 = Active/Focus/Has Value
 * - Red #ef4444 = Error
 * - Gray #9ca3af = Disabled
 * - Green #22c55e = Success
 */

/* ==========================================================================
   VERIFICATION CONTAINER
   ========================================================================== */

.bkinq_verify_section {
    width: 100%;
    max-width: 400px;
    margin: 0 auto;
    padding: 20px;
    box-sizing: border-box;
}

.bkinq_verify_wrap {
    display: flex;
    flex-direction: column;
    align-items: center;
}

/* ==========================================================================
   PHASE 1: PHONE ENTRY
   ========================================================================== */

#bkinq_verify_phase1 {
    width: 100%;
}

/* Floating Label Container */
.bkinq_verify_float_label {
    position: relative;
    width: 100%;
    max-width: 320px;
    margin: 0 auto 16px auto;
}

/* Phone Input */
.bkinq_verify_input {
    width: 100%;
    height: 48px;
    padding: 12px 16px;
    font-size: 16px;
    font-family: inherit;
    border: 2px solid #ffd100;
    border-radius: 8px;
    outline: none;
    background: #fff;
    box-sizing: border-box;
    transition: border-color 0.2s ease;
}

.bkinq_verify_input:focus {
    border-color: #567bd2;
}

.bkinq_verify_input.has-value {
    border-color: #567bd2;
}

.bkinq_verify_input.error {
    border-color: #ef4444;
}

.bkinq_verify_input::placeholder {
    color: transparent;
}

.bkinq_verify_input:focus::placeholder {
    color: #9ca3af;
}

/* Floating Label */
.bkinq_verify_label {
    position: absolute;
    left: 16px;
    top: 50%;
    transform: translateY(-50%);
    font-size: 16px;
    color: #6b7280;
    background: #fff;
    padding: 0 4px;
    transition: all 0.2s ease;
    pointer-events: none;
}

.bkinq_verify_input:focus ~ .bkinq_verify_label,
.bkinq_verify_input:not(:placeholder-shown) ~ .bkinq_verify_label {
    top: 0;
    font-size: 12px;
    color: #567bd2;
}

/* Phone Error Message */
.bkinq_verify_phone_error {
    width: 100%;
    max-width: 320px;
    margin: 0 auto 16px auto;
    font-size: 13px;
    color: #ef4444;
    text-align: left;
    display: none;
}

.bkinq_verify_phone_error.show {
    display: block;
}

/* ==========================================================================
   PHASE 2: CODE ENTRY
   ========================================================================== */

#bkinq_verify_phase2 {
    width: 100%;
    display: none;
}

/* Status Bar - Blue (default info) */
.bkinq_verify_status {
    width: 100%;
    max-width: 320px;
    background: #dbeafe;
    border-left: 4px solid #567bd2;
    padding: 12px 16px;
    margin: 0 auto 16px auto;
    text-align: left;
    font-size: 14px;
    color: #1e40af;
    border-radius: 0 4px 4px 0;
    box-sizing: border-box;
}

/* Status Bar - Green (success) */
.bkinq_verify_status.success {
    background: #d1fae5;
    border-left-color: #22c55e;
    color: #166534;
}

/* Status Bar - Red (error) */
.bkinq_verify_status.error {
    background: #fee2e2;
    border-left-color: #ef4444;
    color: #991b1b;
}

/* 6-Digit Box Container */
.bkinq_verify_digit_wrap {
    display: flex;
    gap: 8px;
    justify-content: center;
    margin: 0 auto 16px auto;
    width: 100%;
    max-width: 320px;
}

/* Individual Digit Box */
.bkinq_verify_digit {
    width: 44px;
    height: 52px;
    text-align: center;
    font-size: 20px;
    font-weight: 600;
    font-family: inherit;
    border: 2px solid #d1d5db;
    border-radius: 8px;
    outline: none;
    background: #fff;
    box-sizing: border-box;
    transition: border-color 0.2s ease;
}

.bkinq_verify_digit:focus {
    border-color: #567bd2;
}

.bkinq_verify_digit.has-value {
    border-color: #567bd2;
}

.bkinq_verify_digit.error {
    border-color: #ef4444;
}

/* Code Expiry Text */
.bkinq_verify_expiry {
    width: 100%;
    max-width: 320px;
    font-size: 13px;
    color: #6b7280;
    margin: 0 auto 8px auto;
    text-align: center;
}

/* Resend Timer / Link */
.bkinq_verify_resend {
    width: 100%;
    max-width: 320px;
    font-size: 13px;
    color: #6b7280;
    margin: 0 auto 16px auto;
    text-align: center;
}

#bkinq_resend_timer {
    color: #6b7280;
}

#bkinq_resend_link {
    color: #567bd2;
    text-decoration: underline;
    cursor: pointer;
    display: none;
}

#bkinq_resend_link:hover {
    color: #3b5998;
}

#bkinq_resend_link.disabled {
    color: #9ca3af;
    cursor: not-allowed;
}

/* ==========================================================================
   PHASE 3: SUCCESS
   ========================================================================== */

#bkinq_verify_phase3 {
    width: 100%;
    display: none;
}

.bkinq_verify_success {
    width: 100%;
    max-width: 320px;
    margin: 0 auto;
    text-align: center;
    padding: 20px;
}

.bkinq_verify_success_icon {
    width: 64px;
    height: 64px;
    margin: 0 auto 16px auto;
    background: #d1fae5;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
}

.bkinq_verify_success_icon::after {
    content: '✓';
    font-size: 32px;
    color: #22c55e;
    font-weight: bold;
}

.bkinq_verify_success_text {
    font-size: 18px;
    font-weight: 600;
    color: #166534;
    margin-bottom: 8px;
}

.bkinq_verify_success_sub {
    font-size: 14px;
    color: #6b7280;
}

/* ==========================================================================
   BUTTONS
   ========================================================================== */

#bookingForm .bkinq_verify_btn {
    width: 100%;
    max-width: 320px;
    height: 48px;
    padding: 12px 16px;
    font-size: 16px;
    font-family: inherit;
    font-weight: 500;
    background: #ffd100;
    color: #333;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    box-sizing: border-box;
    margin: 0 auto;
    display: block;
    transition: background-color 0.2s ease, color 0.2s ease;
}

#bookingForm .bkinq_verify_btn:hover:not(:disabled) {
    background: #567bd2;
    color: #fff;
}

#bookingForm .bkinq_verify_btn:disabled,
#bookingForm .bkinq_verify_btn.disabled {
    background: #9ca3af;
    color: #fff;
    cursor: not-allowed;
}

/* Back Link */
.bkinq_verify_back {
    width: 100%;
    max-width: 320px;
    margin: 16px auto 0 auto;
    text-align: center;
}

#bkinq_back_to_phone {
    font-size: 14px;
    color: #567bd2;
    text-decoration: underline;
    cursor: pointer;
}

#bkinq_back_to_phone:hover {
    color: #3b5998;
}

/* ==========================================================================
   ACTIVE STATE (during AJAX)
   ========================================================================== */

.bkinq_verify_section.active input,
.bkinq_verify_section.active button {
    cursor: default;
    pointer-events: none;
}

.bkinq_verify_section.active .bkinq_verify_btn {
    background: #9ca3af;
    color: #fff;
}

/* ==========================================================================
   MOBILE RESPONSIVE
   ========================================================================== */

@media (max-width: 480px) {
    .bkinq_verify_section {
        padding: 16px;
    }

    .bkinq_verify_digit {
        width: 40px;
        height: 48px;
        font-size: 18px;
    }

    .bkinq_verify_digit_wrap {
        gap: 6px;
    }
}

@media (max-width: 360px) {
    .bkinq_verify_digit {
        width: 36px;
        height: 44px;
        font-size: 16px;
    }

    .bkinq_verify_digit_wrap {
        gap: 4px;
    }
}
