/**
 * استایل پایهٔ ویجت فرم‌ساز صفحه‌ساز (Modules/Elementor/Widgets/FormWidget.php).
 * فقط ساختار و ظاهر خنثی؛ رنگ/تایپوگرافی/کادر از تب استایل خود ویجت می‌آید.
 */

.ee-form {
    display: flex;
    flex-wrap: wrap;
    gap: 14px;
    align-items: flex-start;
}

.ee-form-field {
    display: flex;
    flex-direction: column;
    min-width: 0;
}

/* عرض ستونی فیلدها – gap با calc از عرض کم می‌شود تا سطر نشکند */
.ee-form-col-100 { flex: 0 0 100%; max-width: 100%; }
.ee-form-col-75  { flex: 0 0 calc(75% - var(--ee-form-gap, 14px) / 2); max-width: calc(75% - var(--ee-form-gap, 14px) / 2); }
.ee-form-col-66  { flex: 0 0 calc(66.66% - var(--ee-form-gap, 14px) / 2); max-width: calc(66.66% - var(--ee-form-gap, 14px) / 2); }
.ee-form-col-50  { flex: 0 0 calc(50% - var(--ee-form-gap, 14px) / 2); max-width: calc(50% - var(--ee-form-gap, 14px) / 2); }
.ee-form-col-33  { flex: 0 0 calc(33.33% - var(--ee-form-gap, 14px) * 2 / 3); max-width: calc(33.33% - var(--ee-form-gap, 14px) * 2 / 3); }
.ee-form-col-25  { flex: 0 0 calc(25% - var(--ee-form-gap, 14px) * 3 / 4); max-width: calc(25% - var(--ee-form-gap, 14px) * 3 / 4); }

@media (max-width: 767px) {
    .ee-form-field[class*="ee-form-col-"] {
        flex: 0 0 100%;
        max-width: 100%;
    }
}

.ee-form-label {
    display: block;
    margin-bottom: 6px;
    font-size: 14px;
    font-weight: 600;
    line-height: 1.6;
}

.ee-form-required {
    color: #d64545;
    margin-inline-start: 3px;
}

.ee-form-input {
    width: 100%;
    padding: 10px 12px;
    font: inherit;
    font-size: 14px;
    line-height: 1.8;
    color: inherit;
    background-color: #fff;
    border: 1px solid #d5dadf;
    border-radius: 4px;
    transition: border-color .15s, box-shadow .15s;
}

.ee-form-input:focus {
    outline: 2px solid transparent;
    border-color: #6ea8fe;
    box-shadow: 0 0 0 3px rgba(110, 168, 254, .18);
}

textarea.ee-form-input {
    resize: vertical;
    min-height: 90px;
}

select.ee-form-input[multiple] {
    min-height: 120px;
}

.ee-form-file {
    padding: 8px 10px;
    background: #fafbfc;
}

/* رادیو و چک‌باکس */
.ee-form-choices {
    display: flex;
    flex-wrap: wrap;
    gap: 8px 18px;
    padding-top: 4px;
}

.ee-form-choice {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    font-size: 14px;
    line-height: 1.8;
    cursor: pointer;
}

.ee-form-choice input {
    width: 16px;
    height: 16px;
    margin: 0;
    accent-color: currentColor;
    cursor: pointer;
}

.ee-form-acceptance {
    align-items: flex-start;
}

.ee-form-acceptance input {
    margin-top: 5px;
}

/* بلوک متن/HTML بین فیلدها */
.ee-form-html {
    font-size: 14px;
    line-height: 2;
}

/* دکمه */
.ee-form-actions {
    display: flex;
    flex: 0 0 100%;
    max-width: 100%;
}

.ee-form-submit {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 11px 26px;
    font: inherit;
    font-size: 15px;
    font-weight: 600;
    color: #fff;
    background-color: #2f6fed;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    transition: background-color .15s, opacity .15s;
}

.ee-form-submit:hover {
    background-color: #2559c4;
}

.ee-form-submit:disabled {
    opacity: .65;
    cursor: default;
}

.ee-form-submit-w100 { width: 100%; }
.ee-form-submit-w50 { width: 50%; }

/* پیام‌ها */
.ee-form-message {
    flex: 0 0 100%;
    max-width: 100%;
    padding: 11px 14px;
    font-size: 14px;
    line-height: 1.9;
    border: 1px solid;
    border-radius: 4px;
}

.ee-form-message[hidden] { display: none; }

.ee-form-message.is-success {
    color: #1f7a4d;
    border-color: #1f7a4d;
    background: rgba(31, 122, 77, .07);
}

.ee-form-message.is-error {
    color: #c02f2f;
    border-color: #c02f2f;
    background: rgba(192, 47, 47, .06);
}

.ee-form-field-error {
    display: block;
    min-height: 0;
    margin-top: 5px;
    font-size: 12px;
    line-height: 1.8;
    color: #c02f2f;
}

.ee-form-field-error:empty { display: none; }

.ee-form-invalid .ee-form-input {
    border-color: #c02f2f;
}

/* حالت ارسال */
.ee-form-loading {
    opacity: .75;
    pointer-events: none;
}

/* تلهٔ ربات – برای کاربر واقعی نامرئی است */
.ee-form-hp {
    position: absolute !important;
    width: 1px;
    height: 1px;
    overflow: hidden;
    clip: rect(0 0 0 0);
    clip-path: inset(50%);
    white-space: nowrap;
}
