/*
 * Booking Form CSS (Contact Form 7 #13221)
 *
 * The parent theme sets `.wpcf7-form input { min-width: 100%; max-width: 100%; padding: 1rem 22px }`,
 * so the checkbox and stepper input reset min-width below.
 */
.booking-form {
    --booking-field-height: 44px;
    --booking-border: 1px solid #8C917E; /* 3:1 contrast against white */
    --booking-focus: 2px solid var(--accent-color);
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 12px;
}
.booking-form .form-label {
    display: block;
    margin: 0;
    min-width: 0;
    font-weight: 400;
}
.booking-form .form-label-text {
    display: block;
    margin: 0 0 4px;
    font-size: 14px;
    font-weight: 600;
    line-height: 1.2;
}
.booking-form .form-label-full {
    grid-column: 1 / -1;
}
.booking-form .wpcf7-form-control-wrap {
    display: block;
    position: relative;
}
@media (max-width: 599px) {
    .booking-form {
        grid-template-columns: 1fr;
    }
}

/* text fields */
.booking-form :is(input[type="text"], input[type="email"], input[type="tel"], input[type="number"]) {
    width: 100%;
    height: var(--booking-field-height);
    box-sizing: border-box;
    margin: 0;
    padding: 0 12px;
    border: var(--booking-border);
    border-radius: 4px;
    background: #FFF;
    font-size: 16px;
    line-height: calc(var(--booking-field-height) - 2px);
}
.booking-form textarea {
    width: 100%;
    height: 80px;
    min-height: 80px;
    max-height: 240px;
    box-sizing: border-box;
    margin: 0;
    padding: 10px 12px;
    border: var(--booking-border);
    border-radius: 4px;
    background: #FFF;
    font-size: 16px;
    line-height: 1.4;
    resize: vertical;
}
.booking-form :is(input, textarea, .nice-select):focus,
.booking-form .nice-select.open {
    outline: var(--booking-focus);
    outline-offset: 1px;
    border-color: var(--accent-color);
}
.booking-form ::placeholder {
    color: #6B6B6B;
    opacity: 1;
}
.booking-form .wpcf7-not-valid {
    border-color: #C0392B;
}
.booking-form .wpcf7-not-valid-tip {
    margin-top: 2px;
    font-size: 12px;
}

/* activities (nice-select2) - the native select is hidden but kept for form submission */
.booking-form select {
    position: absolute;
    top: 0;
    left: 0;
    width: 1px;
    height: 1px;
    margin: 0;
    padding: 0;
    border: 0;
    opacity: 0;
    pointer-events: none;
}
.booking-form .nice-select {
    float: none;
    display: block;
    box-sizing: border-box;
    width: 100%;
    height: auto;
    min-height: var(--booking-field-height);
    margin: 0;
    padding: 0 30px 0 12px;
    border: var(--booking-border);
    border-radius: 4px;
    background: #FFF;
    font-size: 16px;
}
.booking-form .nice-select :is(.current, .multiple-options) {
    display: block;
    overflow: hidden;
    color: #555;
    line-height: calc(var(--booking-field-height) - 2px);
    text-overflow: ellipsis;
    white-space: nowrap;
}
.booking-form .nice-select .nice-select-dropdown {
    width: 100%;
}
.booking-form .nice-select .list {
    max-height: 240px;
    overflow-y: auto;
}
.booking-form .nice-select .list li.selected {
    color: var(--accent-color);
    font-weight: 600;
}

/* date (flatpickr) */
.booking-form input.flatpickr-input[readonly] {
    cursor: pointer;
}

/* number of people stepper */
.booking-stepper {
    display: flex;
    height: var(--booking-field-height);
    border: var(--booking-border);
    border-radius: 4px;
    background: #FFF;
    overflow: hidden;
}
.booking-stepper:focus-within {
    outline: var(--booking-focus);
    outline-offset: 1px;
    border-color: var(--accent-color);
}
.booking-stepper input:focus {
    outline: 0; /* the stepper outline shows focus instead */
}
.booking-stepper .wpcf7-form-control-wrap {
    flex: 1;
    min-width: 0;
}
.booking-stepper input[type="number"] {
    min-width: 0;
    padding: 0;
    border: 0;
    border-radius: 0;
    box-shadow: none;
    text-align: center;
    -moz-appearance: textfield;
}
.booking-stepper input::-webkit-outer-spin-button,
.booking-stepper input::-webkit-inner-spin-button {
    -webkit-appearance: none;
    margin: 0;
}
.booking-stepper button {
    flex: 0 0 var(--booking-field-height);
    padding: 0;
    border: 0;
    background: #F1F2EA;
    color: var(--accent-color);
    font-size: 22px;
    line-height: 1;
    cursor: pointer;
}
.booking-stepper button:is(:hover, :focus-visible) {
    background: var(--accent-color);
    color: #FFF;
}

/* terms checkbox */
.booking-terms {
    grid-column: 1 / -1;
    font-size: 14px;
    line-height: 1.4;
}
.booking-terms .wpcf7-form-control-wrap,
.booking-terms .wpcf7-form-control,
.booking-terms .wpcf7-list-item {
    display: block;
    width: 100%;
    margin: 0;
}
.booking-terms label {
    display: flex;
    align-items: center;
    gap: 8px;
    width: 100%;
    margin: 0;
    font-weight: 400;
    cursor: pointer;
}
.booking-terms input[type="checkbox"] {
    flex: 0 0 18px;
    width: 18px;
    min-width: 0;
    height: 18px;
    margin: 0;
    padding: 0;
    accent-color: var(--accent-color);
    cursor: pointer;
}
.booking-terms a {
    text-decoration: underline;
}

/* keyboard focus for buttons and the checkbox (the parent theme removes outlines) */
.booking-form :is(input[type="checkbox"], button, .wpcf7-submit):focus-visible {
    outline: var(--booking-focus);
    outline-offset: 2px;
}

/* send button and response message */
.booking-form .wpcf7-submit {
    width: 100%;
    height: var(--booking-field-height);
    margin: 4px 0 0;
}
.booking-submit {
    grid-column: 1 / -1;
    margin-bottom: 16px;
}
.booking-form .wpcf7-response-output {
    grid-column: 1 / -1;
    margin: 0 0 16px;
    padding: 8px 12px;
    font-size: 14px;
}
