/* أدوات شذرات — قطعة اختيار السلالم داخل نماذج CFF (القوائم تأخذ تنسيق حقول النماذج من wp.css في القالب) */
html #fbuilder .sht-picker { width: 100%; }
/* حقل HTML الذي يحمل القطعة يأخذ عرض الصف كاملًا داخل الحاويات */
html #fbuilder .cff-container-field > div > .fields:has(.sht-picker) { flex: 1 1 100% !important; width: 100% !important; }
/* أزرار السلّم — بنفس شكل صفحة السلالم */
html #fbuilder .sht-k { display: block; margin: 0 0 10px; font-size: 14px; font-weight: 600; color: var(--sh-ink, #13223f); text-align: right; }
html #fbuilder .sht-chips { display: flex; flex-wrap: wrap; gap: 8px; margin: 0 0 18px; }
html #fbuilder .sht-chip { min-height: 44px; padding: 0 16px; border: 1px solid var(--sh-line, #d6e2dd); border-radius: 999px; background: #fff; font-family: inherit; font-size: 14px; font-weight: 600; color: var(--sh-text, #24324a); cursor: pointer; box-shadow: none; transition: border-color .15s, transform .15s; }
html #fbuilder .sht-chip:hover { border-color: var(--sh-navy-mid, #0b8972); transform: translateY(-1px); }
html #fbuilder .sht-chip.on { border-color: transparent; background: linear-gradient(135deg, var(--sh-navy, #0b3a33), var(--sh-navy-mid, #0b8972)); color: #fff; box-shadow: 0 8px 18px -8px rgba(11, 58, 51, .6); }
/* الفئة والمرتبة والدرجة */
html #fbuilder .sht-picker-row { display: flex; flex-wrap: wrap; gap: 0 20px; }
html #fbuilder .sht-picker-row > .sht-pf { flex: 1 1 calc(33.333% - 20px); min-width: 0; margin: 0 0 12px !important; float: none !important; }
html #fbuilder .sht-picker-row.two > .sht-pf { flex-basis: calc(50% - 20px); }
html #fbuilder .sht-picker-row.one > .sht-pf { flex-basis: 100%; }
html #fbuilder .sht-picker-row.four > .sht-pf { flex-basis: calc(25% - 20px); }
/* حقول النموذج التي انضمت إلى الصف */
html #fbuilder .sht-picker-row > .sht-ext { width: auto !important; float: none !important; clear: none !important; }
/* الحقول المخفية في CFF لا تحجز مساحة */
html #fbuilder .fields.cff-hidden-field { display: none !important; }
html #fbuilder .sht-hide, html #fbuilder .fields.sht-hide { display: none !important; }
@media (max-width: 640px) {
	html #fbuilder .sht-chips { flex-wrap: nowrap; overflow-x: auto; padding: 2px 0 8px; scrollbar-width: none; }
	html #fbuilder .sht-chips::-webkit-scrollbar { display: none; }
	html #fbuilder .sht-chip { flex: 0 0 auto; }
	html #fbuilder .sht-picker-row > .sht-pf, html #fbuilder .sht-picker-row.two > .sht-pf { flex-basis: 100%; }
}

/* قوائم البحث (select2) في نماذج CFF، مثل «اختر الدولة»: بنفس شكل بقية الحقول */
html #fbuilder .select2-container { width: 100% !important; max-width: none !important; font-family: inherit; }
html #fbuilder .select2-container .select2-selection--single { height: 48px !important; display: flex; align-items: center; border: 1px solid var(--sh-line, #d6e2dd) !important; border-radius: var(--sh-r-sm, 12px) !important; background: var(--sh-bg, #f4f8f6) !important; box-shadow: none !important; outline: none; }
html #fbuilder .select2-container .select2-selection--single .select2-selection__rendered { width: 100%; line-height: 46px !important; padding: 0 16px 0 40px !important; font-family: var(--sh-font, inherit); font-size: 15px; font-weight: 600; color: var(--sh-ink, #13223f) !important; text-align: right; }
html #fbuilder .select2-container .select2-selection--single .select2-selection__placeholder { color: var(--sh-placeholder, #8a948f); font-weight: 400; }
html #fbuilder .select2-container .select2-selection--single .select2-selection__arrow { height: 46px !important; width: 20px; left: 12px !important; right: auto !important; }
html #fbuilder .select2-container--open .select2-selection--single, html #fbuilder .select2-container--focus .select2-selection--single { background: #fff !important; border-color: var(--sh-navy-mid, #0b8972) !important; box-shadow: 0 0 0 4px rgba(11, 137, 114, .18) !important; }
/* القائمة المنسدلة نفسها تُرسم خارج النموذج */
.select2-container--open .select2-dropdown { border: 1px solid var(--sh-line-soft, #e3ece8) !important; border-radius: 14px !important; overflow: hidden; box-shadow: 0 24px 50px -20px rgba(19, 34, 63, .45); font-family: var(--sh-font, inherit); direction: rtl; }
.select2-container--open .select2-search--dropdown .select2-search__field { height: 40px; padding: 0 12px; border: 1px solid var(--sh-line, #d6e2dd) !important; border-radius: 10px; font-family: inherit; font-size: 14px; direction: rtl; }
.select2-container--open .select2-results__option { padding: 9px 14px; font-size: 14px; text-align: right; }
.select2-container--open .select2-results__option--highlighted[aria-selected], .select2-container--open .select2-results__option--highlighted { background: var(--sh-mist, #e8f1ee) !important; color: var(--sh-navy, #0b3a33) !important; }
.select2-container--open .select2-results__option[aria-selected=true], .select2-container--open .select2-results__option--selected { background: linear-gradient(135deg, var(--sh-navy, #0b3a33), var(--sh-navy-mid, #0b8972)) !important; color: #fff !important; }

/* عنوان قسم داخل نماذج الحاسبات (مثل «أيام العمل» و«أيام العطل») */
#fbuilder .sht-sec-title{display:flex;align-items:center;gap:8px;margin:4px 2px 2px;font-weight:700;font-size:16px;color:var(--sh-navy,#0b3a33)}
#fbuilder .sht-sec-title::before{content:"";width:6px;height:18px;border-radius:3px;background:var(--sh-gold,#c9a96a);flex:none}

/* بطاقات نتائج خارج الدوام (أيام العمل / أيام العطل) — تُبنى من معادلة الإجمالي في النموذج */
#fbuilder .sht-ot-cards{display:grid;grid-template-columns:1fr 1fr;gap:14px;margin:4px 0 6px}
#fbuilder .sht-ot-cards.one{grid-template-columns:1fr}
#fbuilder .sht-ot-cards:empty{display:none}
#fbuilder .sht-ot-card{border:1px solid var(--sh-line-soft,#dbe9e3);border-radius:16px;background:var(--sh-mist,#f6faf8);padding:12px 16px}
#fbuilder .sht-ot-title{display:flex;align-items:center;gap:8px;margin:0 0 6px;font-weight:700;font-size:15px;color:var(--sh-navy,#0b3a33)}
#fbuilder .sht-ot-title::before{content:"";width:6px;height:16px;border-radius:3px;background:var(--sh-gold,#c9a96a);flex:none}
#fbuilder .sht-ot-row{display:flex;justify-content:space-between;gap:12px;padding:7px 2px;border-bottom:1px dashed var(--sh-line-soft,#d5e5de);font-size:14px;color:var(--sh-text,#24324a)}
#fbuilder .sht-ot-row.sht-ot-sum{border-bottom:0;font-weight:800;color:var(--sh-navy,#0b3a33)}
@media (max-width:640px){#fbuilder .sht-ot-cards{grid-template-columns:1fr}}

/* حقل بعرض كامل داخل حاوية أعمدة (مثل «بدل الترحيل») */
html #fbuilder .cff-container-field .fields.sht-full{width:100%!important;max-width:100%!important;flex:0 0 100%!important;grid-column:1 / -1!important}
