/* =========================================================
   Travel Lead Form — Styles
   Espejo visual de Form Engine Core (acf-fe-core-pro)
   Selectores tlf- para evitar conflictos.
   ========================================================= */

/* ── Form Base ─────────────────────────────────────────── */
.tfb-travel-lead-form {
    display: flex;
    flex-direction: column;
    gap: 25px;
    font-family: "Poppins", sans-serif;
    color: #2a2a2a;
}

@media (max-width: 768px) {
    .tfb-travel-lead-form {
        gap: 15px;
    }
}

/* ── Groups (= acf-fecp-form__group) ────────────────────── */
.tlf-group {
    display: flex;
    flex-wrap: wrap;
    gap: 1rem;
    padding-inline: 0.25rem;
}

/* ── Fields (= acf-fecp-form__field) ────────────────────── */
.tlf-field {
    display: flex;
    flex-direction: column;
    flex: 1;
    min-width: 240px;
    position: relative;
}

/* ── Inputs / Select nativo / Textarea ─────────────────── */
.tfb-travel-lead-form .tlf-input,
.tfb-travel-lead-form .tlf-select-native,
.tfb-travel-lead-form .tlf-textarea {
    width: 100%;
    padding: 13px;
    text-align: center;
    border: 1px solid #C66E65 !important;
    border-radius: 12px;
    background-color: #fff;
    font-size: 0.95rem;
    color: #898989;
    font-weight: 700;
    transition: all 0.25s ease;
    box-shadow: 0px 4px 4px 0px #00000040;
    box-sizing: border-box;
    font-family: "Poppins", sans-serif;
    outline: none;
}

.tfb-travel-lead-form .tlf-textarea {
    min-height: 100px;
    max-height: 100px;
    min-width: 100%;
    max-width: 100%;
    resize: none;
}

/* ── Focus ─────────────────────────────────────────────── */
.tfb-travel-lead-form .tlf-input:focus,
.tfb-travel-lead-form .tlf-select-native:focus,
.tfb-travel-lead-form .tlf-textarea:focus {
    border-color: #a54f47 !important;
    box-shadow: 0 0 0 3px rgba(198, 110, 101, 0.25);
}

/* ── Select nativo: flecha personalizada ────────────────── */
.tfb-travel-lead-form .tlf-select-native {
    appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg width='14' height='8' viewBox='0 0 12 8' fill='none' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M1 1L6 6L11 1' stroke='%23C66E65' stroke-width='2' stroke-linecap='round'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 1rem center;
    background-size: 14px;
    cursor: pointer;
}

/* ── Select2 overrides ─────────────────────────────────── */
.tfb-travel-lead-form .select2-container--default .select2-selection--single {
    height: 46px;
    border: 1px solid #C66E65 !important;
    border-radius: 12px;
    padding: 0 14px;
    display: flex;
    align-items: center;
    box-shadow: 0px 4px 4px 0px #00000040;
    background-color: #fff;
}

.tfb-travel-lead-form .select2-container--default .select2-selection--single .select2-selection__rendered {
    line-height: 46px;
    padding-left: 0;
    color: #898989;
    font-size: 0.95rem;
    font-weight: 700;
    text-align: center;
    width: 100%;
    font-family: "Poppins", sans-serif;
}

.tfb-travel-lead-form .select2-container--default .select2-selection--single .select2-selection__arrow {
    height: 46px;
}

.tfb-travel-lead-form .select2-container--default .select2-selection--single .select2-selection__arrow b {
    border-color: #C66E65 transparent transparent transparent;
}

.tfb-travel-lead-form .select2-container--default.select2-container--focus .select2-selection--single,
.tfb-travel-lead-form .select2-container--default.select2-container--open .select2-selection--single {
    border-color: #a54f47 !important;
    box-shadow: 0 0 0 3px rgba(198, 110, 101, 0.25);
}

/* ── Select2: dropdown (lista desplegable) ──────────────── */
.tfb-travel-lead-form + .select2-container,
.travel-lead-form .select2-dropdown {
    font-family: "Poppins", sans-serif;
    border-color: #C66E65;
    border-radius: 12px;
}

.travel-lead-form .select2-results__option {
    font-family: "Poppins", sans-serif;
    font-size: 0.9rem;
    font-weight: 600;
    color: #898989;
    text-align: center;
}

.travel-lead-form .select2-results__option--highlighted[aria-selected] {
    background-color: #C66E65;
    color: #fff;
}

.travel-lead-form .select2-container--default .select2-search--dropdown .select2-search__field {
    border-color: #C66E65;
    border-radius: 8px;
    font-family: "Poppins", sans-serif;
    font-size: 0.9rem;
    outline: none;
}

.travel-lead-form .select2-container--default .select2-search--dropdown .select2-search__field:focus {
    border-color: #a54f47;
    box-shadow: 0 0 0 2px rgba(198, 110, 101, 0.2);
}

/* ── Radio Group (= acf-fecp-form__radio-group) ─────────── */
.tlf-field.tlf-radio-group {
    display: flex;
    flex-direction: column;
    gap: 0;
    padding-top: 0.5rem;
    margin-top: -15px;
}

@media (max-width: 768px) {
    .tlf-field.tlf-radio-group {
        padding-top: 15px;
        margin-top: 0;
    }
}

.tlf-label {
    font-weight: 700;
    color: #898989;
    margin-right: 0.5rem;
    font-family: "Poppins", sans-serif;
    font-size: 15px;
}

.tlf-radio-group__content {
    display: flex;
    align-items: center;
    gap: 1rem;
    flex-wrap: wrap;
    padding-top: 0.5rem;
}

.tlf-radio-group__content label {
    font-weight: 700;
    color: #898989;
    font-size: 16px;
    font-family: "Poppins", sans-serif;
}

/* Radio (= acf-fecp-form__radio) */
.tlf-radio {
    display: flex;
    align-items: center;
    gap: 0.4rem;
    cursor: pointer;
}

.tlf-radio input[type="radio"] {
    appearance: none;
    width: 16px;
    height: 16px;
    border: 1.8px solid #C66E65;
    border-radius: 50%;
    position: relative;
    cursor: pointer;
    transition: all 0.2s ease;
    flex-shrink: 0;
}

.tlf-radio input[type="radio"]:checked::after {
    content: "";
    position: absolute;
    top: 3px;
    left: 3px;
    width: 7px;
    height: 7px;
    background-color: #C66E65;
    border-radius: 50%;
}

/* ── Validation (= .valid / .error / .fecp-error) ────────── */
.tfb-travel-lead-form .tlf-input.valid,
.tfb-travel-lead-form .tlf-select-native.valid,
.tfb-travel-lead-form .tlf-textarea.valid {
    border-color: #3cb371 !important;
    background-color: #f9fff9 !important;
}

.tfb-travel-lead-form .tlf-input.error,
.tfb-travel-lead-form .tlf-select-native.error,
.tfb-travel-lead-form .tlf-textarea.error {
    border-color: #dc143c !important;
    background-color: #fff7f7 !important;
}

.tlf-error-msg {
    color: #dc143c;
    font-size: 0.85rem;
    margin-top: 4px;
    display: block;
    font-family: "Poppins", sans-serif;
}

/* ── Checkbox privacidad (= acf-fecp-form__checkbox-group) ─ */
.tlf-privacy-row {
    display: flex;
    justify-content: center;
    padding-inline: 0.25rem;
}

.tlf-privacy-label {
    display: flex;
    align-items: center;
    gap: 0.4rem;
    cursor: pointer;
    font-size: 12px;
    font-weight: 700;
    text-align: center;
    color: #898989;
    font-family: "Poppins", sans-serif;
}

.tlf-privacy-label input[type="checkbox"] {
    width: 16px;
    height: 16px;
    border: 1.8px solid #C66E65;
    border-radius: 4px;
    accent-color: #C66E65;
    cursor: pointer;
    flex-shrink: 0;
}

.tlf-privacy-label a {
    color: #C66E65;
    text-decoration: underline;
}

/* ── Submit Button (= acf-fecp-form__button) ─────────────── */
.tlf-actions {
    display: flex;
    justify-content: center;
    padding-inline: 0.25rem;
}

.tlf-actions button {
    background-color: #C66E65;
    color: #fff;
    font-weight: 600;
    border: none;
    border-radius: 25px;
    padding: 0.9rem 2rem;
    cursor: pointer;
    transition: all 0.3s ease;
    min-width: 180px;
    font-size: 16px;
    font-family: "Poppins", sans-serif;
    align-self: center;
}

.tlf-actions button:hover:not(:disabled) {
    background-color: #a54f47;
}

.tlf-actions button:disabled {
    opacity: 0.7;
    cursor: not-allowed;
}

/* ── Messages ──────────────────────────────────────────── */
.tfb-travel-lead-form .tfb-message {
    padding: 12px 16px;
    border-radius: 12px;
    font-size: 14px;
    line-height: 1.5;
    text-align: center;
    font-family: "Poppins", sans-serif;
}

.tfb-travel-lead-form .tfb-message--success {
    background: #f2fff7;
    border: 1px solid #3cb371;
    color: #1a6b38;
}

.tfb-travel-lead-form .tfb-message--error {
    background: #fff7f7;
    border: 1px solid #dc143c;
    color: #dc143c;
}

/* ── Thank You State ────────────────────────────────────── */
.tlf-thanks-state {
    padding: 2rem 1rem;
}

.tlf-thanks-inner {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    gap: 1rem;
    font-family: "Poppins", sans-serif;
}

.tlf-thanks-icon {
    margin-bottom: 0.5rem;
}

.tlf-thanks-title {
    font-size: 1.4rem;
    font-weight: 700;
    color: #2a2a2a;
    margin: 0;
}

.tlf-thanks-subtitle {
    font-size: 1rem;
    font-weight: 600;
    color: #C66E65;
    margin: 0;
}

.tlf-thanks-body {
    font-size: 0.9rem;
    color: #898989;
    font-weight: 500;
    line-height: 1.7;
    max-width: 520px;
    margin: 0;
}

.tlf-thanks-body a {
    color: #C66E65;
    text-decoration: underline;
}

/* ── Responsive ─────────────────────────────────────────── */
@media (max-width: 768px) {
    .tlf-group {
        flex-direction: column;
    }

    .tlf-field {
        min-width: unset;
    }

    .tlf-actions button {
        width: 100%;
    }
}
