/* Generic booking popup (header / join-our-team trigger) */

.booking-popup {
    position: fixed;
    inset: 0;
    z-index: 9999;
    display: none;
    align-items: center;
    justify-content: center;
    padding: 24px 16px;
    direction: var(--page-direction);
}

.booking-popup.is-open {
    display: flex;
}

body.booking-popup-open {
    overflow: hidden;
}

.booking-popup__overlay {
    position: absolute;
    inset: 0;
    background-color: rgba(0, 0, 0, 0.7);
    cursor: pointer;
}

.booking-popup__dialog {
    position: relative;
    width: 100%;
    max-width: 480px;
    max-height: calc(100vh - 48px);
    overflow-y: auto;
    background-color: var(--background-bg-primary, #ffffff);
    border-radius: var(--radius-2xl, 16px);
    box-shadow:
        0 4px 6px -1px rgba(10, 13, 18, 0.1),
        0 2px 4px -2px rgba(10, 13, 18, 0.06);
    padding: 32px 28px;
}

.booking-popup__close {
    position: absolute;
    top: 12px;
    right: 12px;
    width: 32px;
    height: 32px;
    padding: 0;
    background: transparent;
    border: 0;
    cursor: pointer;
    opacity: 0.6;
    transition: opacity 0.2s ease;
    z-index: 2;
}

[lang="ar"] .booking-popup__close {
    right: auto;
    left: 12px;
}

.booking-popup__close:hover {
    opacity: 1;
}

.booking-popup__close svg {
    display: block;
    width: 100%;
    height: 100%;
}

.booking-popup__form {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

[lang="ar"] .booking-popup__form {
    direction: rtl;
    text-align: right;
}

.booking-popup__title {
    margin: 0 0 4px;
    color: var(--text-text-primary-900, #181d27);
    font-family: var(--font-family-font-family-display, 'Poppins', sans-serif);
    font-size: 22px;
    font-weight: 600;
    line-height: 30px;
    letter-spacing: -0.5px;
}

.booking-popup__field {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.booking-popup__label {
    display: inline-flex;
    align-items: baseline;
    gap: 4px;
    color: var(--text-text-primary-900, #181d27);
    font-family: var(--font-family-font-family-body, 'Poppins', sans-serif);
    font-size: var(--font-size-text-md, 16px);
    font-weight: 500;
    line-height: var(--line-height-text-md, 24px);
    letter-spacing: var(--letter-spacing-xxs, -0.2px);
}

.booking-popup__required {
    color: var(--text-text-secondary-700, #414651);
    font-size: var(--font-size-text-sm, 14px);
    line-height: var(--line-height-text-sm, 20px);
    font-weight: 400;
}

.booking-popup__optional {
    color: var(--text-text-placeholder, #717680);
    font-size: var(--font-size-text-sm, 14px);
    font-weight: 400;
    line-height: var(--line-height-text-sm, 20px);
}

.booking-popup__input {
    width: 100%;
    height: 44px;
    padding: 8px 16px;
    background-color: var(--background-bg-primary, #ffffff);
    border: 1.5px solid rgba(0, 0, 0, 0.2);
    border-radius: var(--radius-sm, 6px);
    color: var(--text-text-primary-900, #181d27);
    font-family: var(--font-family-font-family-body, 'Poppins', sans-serif);
    font-size: 16px;
    line-height: 24px;
    letter-spacing: var(--letter-spacing-xxs, -0.2px);
    box-sizing: border-box;
    transition: border-color 0.15s ease, box-shadow 0.15s ease;
}

.booking-popup__input::placeholder {
    color: var(--text-text-placeholder, #717680);
}

.booking-popup__input:focus {
    outline: none;
    border-color: var(--colors-brand-2-600, #df7d04);
    box-shadow: 0 0 0 3px rgba(248, 154, 22, 0.15);
}

.booking-popup__form.is-validated .booking-popup__input:invalid {
    border-color: #d92d20;
    box-shadow: 0 0 0 3px rgba(217, 45, 32, 0.12);
}

.booking-popup__form.is-validated .booking-popup__phone:has(.booking-popup__input--phone:invalid) {
    border-color: #d92d20;
    box-shadow: 0 0 0 3px rgba(217, 45, 32, 0.12);
}

.booking-popup__input--textarea {
    height: 108px;
    padding-top: 10px;
    padding-bottom: 10px;
    resize: vertical;
    line-height: 24px;
    font-family: var(--font-family-font-family-body, 'Poppins', sans-serif);
}

.booking-popup__phone {
    display: flex;
    align-items: stretch;
    height: 44px;
    background-color: var(--background-bg-primary, #ffffff);
    border: 1.5px solid rgba(0, 0, 0, 0.2);
    border-radius: var(--radius-sm, 6px);
    overflow: hidden;
    transition: border-color 0.15s ease, box-shadow 0.15s ease;
}

.booking-popup__phone:focus-within {
    border-color: var(--colors-brand-2-600, #df7d04);
    box-shadow: 0 0 0 3px rgba(248, 154, 22, 0.15);
}

.booking-popup__phone-prefix {
    display: inline-flex;
    align-items: center;
    padding: 0 12px;
    background-color: var(--background-bg-tertiary, #f5f5f5);
    border-inline-end: 1px solid var(--border-border-primary, #d5d7da);
    color: var(--text-text-primary-900, #181d27);
    font-family: var(--font-family-font-family-body, 'Poppins', sans-serif);
    font-size: 16px;
    font-weight: 400;
    line-height: 24px;
}

.booking-popup__input--phone {
    flex: 1;
    height: 100%;
    border: 0;
    border-radius: 0;
    box-shadow: none;
}

.booking-popup__input--phone:focus {
    box-shadow: none;
    border: 0;
}

.booking-popup__hint {
    margin: 0;
    color: var(--text-text-placeholder, #717680);
    font-family: var(--font-family-font-family-body, 'Poppins', sans-serif);
    font-size: var(--font-size-text-sm, 14px);
    font-weight: 400;
    line-height: var(--line-height-text-sm, 20px);
    letter-spacing: var(--letter-spacing-xxs, -0.2px);
}

.booking-popup__submit {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    width: 100%;
    margin-top: 4px;
    padding: 14px 18px;
    background: linear-gradient(180deg, var(--colors-brand-2-500-base, #f89a16) 0%, var(--colors-brand-2-600, #df7d04) 100%);
    border: 2px solid rgba(255, 255, 255, 0.12);
    border-radius: var(--radius-md, 8px);
    box-shadow:
        0 1px 3px 0 rgba(10, 13, 18, 0.1),
        0 1px 2px -1px rgba(10, 13, 18, 0.1);
    color: var(--text-text-primary_on-brand-2, #6F4101);
    font-family: var(--font-family-font-family-body, 'Poppins', sans-serif);
    font-size: 16px;
    font-weight: 600;
    line-height: 24px;
    letter-spacing: var(--letter-spacing-xxs, -0.2px);
    cursor: pointer;
    transition: transform 0.15s ease, filter 0.15s ease;
}
[lang="en-GB"] .booking-popup__submit svg{
    transform: rotate(360deg) !important;
}

.booking-popup__submit:hover,
.booking-popup__submit:focus {
    transform: translateY(-1px);
    filter: brightness(1.03);
}

.booking-popup__submit svg path {
    stroke: #6F4101;
}

[lang="ar"] .booking-popup__submit svg {
    transform: rotate(180deg);
}

/* Tablet */
@media (max-width: 767px) {
    .booking-popup {
        padding: 16px 12px;
    }

    .booking-popup__dialog {
        padding: 28px 20px;
        border-radius: 12px;
    }

    .booking-popup__title {
        font-size: 20px;
        line-height: 28px;
    }

    .booking-popup__form {
        gap: 16px;
    }
}

/* Mobile */
@media (max-width: 480px) {
    .booking-popup {
        padding: 12px 8px;
    }

    .booking-popup__dialog {
        padding: 44px 16px 20px;
        max-height: calc(100vh - 24px);
    }

    .booking-popup__close {
        top: 8px;
        right: 8px;
        width: 28px;
        height: 28px;
    }

    [lang="ar"] .booking-popup__close {
        right: auto;
        left: 8px;
    }

    .booking-popup__title {
        font-size: 18px;
        line-height: 26px;
    }

    .booking-popup__submit {
        padding: 12px 14px;
    }
}
