.chabok-form-builder {
	direction: rtl;
	text-align: right;
	max-width: 100%;
	width: 100%;
	margin: 0 auto;
	font-family: inherit;
}

.chabok-form-builder-row {
	display: flex;
	flex-wrap: wrap;
	gap: 18px;
	margin-bottom: 8px;
}

/* گرید فیلدها - 12/6/4/3 */
.chabok-form-builder-field {
	flex: 0 0 100%;
	max-width: 100%;
	box-sizing: border-box;
}

.chabok-form-builder-field.cff-col-12 { flex-basis: 100%; max-width: 100%; }
.chabok-form-builder-field.cff-col-6  { flex-basis: calc(50% - 9px); max-width: calc(50% - 9px); }
.chabok-form-builder-field.cff-col-4  { flex-basis: calc(33.333% - 12px); max-width: calc(33.333% - 12px); }
.chabok-form-builder-field.cff-col-3  { flex-basis: calc(25% - 13.5px); max-width: calc(25% - 13.5px); }

@media (max-width: 640px) {
	.chabok-form-builder-field.cff-col-6,
	.chabok-form-builder-field.cff-col-4,
	.chabok-form-builder-field.cff-col-3 {
		flex-basis: 100%;
		max-width: 100%;
	}
}

.chabok-form-builder-field label {
	display: block;
	font-weight: 600;
	margin-bottom: 6px;
	font-size: 14px;
	color: #1e1e1e;
}

.cff-required {
	color: #e63946;
	margin-inline-start: 2px;
}

.chabok-form-builder-field input[type="text"],
.chabok-form-builder-field input[type="email"],
.chabok-form-builder-field input[type="tel"],
.chabok-form-builder-field input[type="number"],
.chabok-form-builder-field input[type="date"],
.chabok-form-builder-field input[type="file"],
.chabok-form-builder-field select,
.chabok-form-builder-field textarea {
	width: 100%;
	padding: 10px 14px;
	border: 1.5px solid #dfe2e6;
	border-radius: 10px;
	font-size: 14px;
	background: #fff;
	transition: border-color 0.15s ease, box-shadow 0.15s ease;
	box-sizing: border-box;
	font-family: inherit;
}

.yp-form-section {
	overflow: unset;
}
.yp-form-section .yp-container {
	overflow: unset;z-index: 9;
}
.yp-form-section .yp-row.yp-ajax-grid {
	position: relative;
	z-index: 6;
	margin-top: -20px;
	box-shadow: 0 0 20px #ccc;
	border-radius: 10px;
	padding: 20px;
	top: -53px;
	background: #fff;
}

.chabok-form-builder-field input:focus,
.chabok-form-builder-field select:focus,
.chabok-form-builder-field textarea:focus {
	outline: none;
	border-color: #2b14d8;
	box-shadow: 0 0 0 3px rgba(92, 136, 231, 0.15);
}

.chabok-form-builder-field.has-error input,
.chabok-form-builder-field.has-error select,
.chabok-form-builder-field.has-error textarea {
	border-color: #e63946;
}

.cff-choice-group {
	display: flex;
	flex-wrap: wrap;
	gap: 10px 20px;
}

.cff-choice-option {
	display: flex;
	align-items: center;
	gap: 6px;
	font-weight: 400 !important;
	cursor: pointer;
}

.cff-help-text {
	display: block;
	font-size: 12px;
	color: #6b7280;
	margin-top: 4px;
}

.cff-error-text {
	display: block;
	font-size: 12px;
	color: #e63946;
	margin-top: 4px;
	min-height: 14px;
}

.cff-heading {
	margin: 10px 0 4px;
}

.cff-paragraph {
	color: #4b5563;
	margin: 0 0 10px;
}

.cff-divider {
	border: none;
	border-top: 1px solid #e5e7eb;
	margin: 16px 0;
}

/* ناوبری مراحل */
.chabok-form-builder-steps-nav {
	display: flex;
	list-style: none;
	padding: 0;
	margin: 0 0 28px;
	counter-reset: cff-step;
}

.cff-step-indicator {
	flex: 1;
	text-align: center;
	position: relative;
	font-size: 13px;
	color: #9ca3af;
}

.cff-step-indicator:not(:last-child)::after {
	content: '';
	position: absolute;
	top: 14px;
	right: -50%;
	width: 100%;
	height: 2px;
	background: #e5e7eb;
	z-index: 0;
}

.cff-step-indicator.is-active:not(:last-child)::after,
.cff-step-indicator.is-active ~ .cff-step-indicator::after {
	background: #e5e7eb;
}

.cff-step-number {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 28px;
	height: 28px;
	border-radius: 50%;
	background: #f0f0f3;
	color: #9ca3af;
	font-weight: 700;
	position: relative;
	z-index: 1;
	margin-bottom: 6px;
}

.cff-step-indicator.is-active .cff-step-number {
	background: #4129fc;
	color: #fff;
}

.cff-step-indicator.is-active {
	color: #1e1e1e;
	font-weight: 600;
}

.cff-step-title {
	display: block;
}

/* دکمه‌ها */
.chabok-form-builder-nav {
	display: flex;
	gap: 10px;
	margin-top: 20px;
	justify-content: flex-start;
}

.cff-btn {
	padding: 11px 26px;
	border-radius: 10px;
	border: none;
	font-size: 14px;
	font-weight: 600;
	cursor: pointer;
	transition: opacity 0.15s ease, transform 0.1s ease;
}

.cff-btn-submit,
.cff-btn-next {
	background: linear-gradient(135deg, #5c65e7, #7c97f0);
	color: #fff;
}

.cff-btn-prev {
	background: #f0f0f3;
	color: #374151;
}

.cff-btn:hover {
	opacity: 0.9;
}

.cff-btn:active {
	transform: scale(0.98);
}

.cff-btn.is-loading {
	opacity: 0.6;
	pointer-events: none;
}

/* پیام موفقیت/خطا */
.chabok-form-builder-message {
	margin-top: 16px;
	padding: 12px 16px;
	border-radius: 10px;
	font-size: 14px;
	width:100%;
	height: 50px;
  	max-height: max-content;
	display: flex;
  	align-items: center;
}

.chabok-form-builder-message.is-success {
	background: #ecfdf3;
	color: #067647;
	border: 1px solid #abefc6;
}

.chabok-form-builder-message.is-error {
	background: #fef3f2;
	color: #b42318;
	border: 1px solid #fda29b;
}


.cff-form-status{
    padding:30px;
    border-radius:12px;
    text-align:center;
    margin-bottom:0;
	margin-right: auto;
	margin-left: auto;
}

.cff-form-status h3{
    margin-bottom:10px;
}

.cff-form-status-pending{
    background:#eef7ff;
    border:1px solid #b9d8ff;
}

.cff-form-status-expired{
    background:#fff1f1;
    border:1px solid #ffb5b5;
}

.cff-countdown{
    display:flex;
    justify-content:center;
    gap:15px;
    margin-top:25px;
}

.cff-count-item{
    min-width:90px;
    background:#fff;
    border-radius:10px;
    padding:15px;
    box-shadow:0 3px 15px rgba(0,0,0,.05);
}

.cff-count-number{
    font-size:28px;
    font-weight:bold;
}

.cff-count-label{
    margin-top:5px;
    font-size:13px;
    color:#777;
}