/* استایل افزونه پیگیری سفارش - کاملا محلی، بدون وابستگی خارجی */

.otfa-wrapper {
	direction: rtl;
	text-align: right;
	font-family: inherit; /* از فونت قالب سایت پیروی می‌کند */
	max-width: 480px;
	margin: 0 auto;
}

.otfa-box {
	background: #fff;
	border: 1px solid #e4e4e4;
	border-radius: 10px;
	padding: 24px;
	box-shadow: 0 2px 10px rgba(0, 0, 0, 0.04);
}

.otfa-title {
	margin: 0 0 8px;
	font-size: 20px;
	font-weight: 700;
}

.otfa-desc {
	margin: 0 0 20px;
	font-size: 14px;
	color: #666;
	line-height: 1.8;
}

.otfa-field {
	margin-bottom: 16px;
}

.otfa-field label {
	display: block;
	margin-bottom: 6px;
	font-size: 14px;
	font-weight: 600;
}

.otfa-field input {
	width: 100%;
	box-sizing: border-box;
	padding: 12px 14px;
	font-size: 16px; /* جلوگیری از زوم خودکار در موبایل */
	border: 1px solid #d4d4d4;
	border-radius: 8px;
	direction: ltr;
	text-align: right;
	background: #fafafa;
}

.otfa-field input:focus {
	outline: none;
	border-color: #999;
	background: #fff;
}

.otfa-submit-btn {
	width: 100%;
	padding: 13px 14px;
	font-size: 16px;
	font-weight: 700;
	color: #fff;
	background: #222;
	border: none;
	border-radius: 8px;
	cursor: pointer;
	transition: opacity 0.15s ease;
}

.otfa-submit-btn:hover,
.otfa-submit-btn:focus {
	opacity: 0.88;
}

.otfa-submit-btn:disabled {
	opacity: 0.6;
	cursor: not-allowed;
}

.otfa-loading {
	margin-top: 12px;
	font-size: 14px;
	color: #666;
	text-align: center;
}

.otfa-result:empty {
	margin: 0;
}

.otfa-message {
	margin-top: 20px;
	padding: 16px;
	border-radius: 8px;
	font-size: 14px;
	line-height: 1.9;
}

.otfa-error {
	background: #fdecea;
	color: #611a15;
	border: 1px solid #f5c6cb;
}

.otfa-success {
	background: #f7faf7;
	border: 1px solid #d9e8d9;
}

.otfa-order-header {
	display: flex;
	align-items: center;
	justify-content: space-between;
	flex-wrap: wrap;
	gap: 8px;
	margin-bottom: 14px;
	padding-bottom: 12px;
	border-bottom: 1px dashed #d9e8d9;
}

.otfa-order-number {
	font-size: 15px;
}

.otfa-order-status {
	display: inline-block;
	padding: 5px 12px;
	border-radius: 20px;
	font-size: 13px;
	font-weight: 700;
	background: #e8f0fe;
	color: #1a4d8f;
	white-space: nowrap;
}

.otfa-order-status.status-completed,
.otfa-order-status.status-processing {
	background: #e5f6e8;
	color: #1e6b30;
}

.otfa-order-status.status-cancelled,
.otfa-order-status.status-failed,
.otfa-order-status.status-refunded {
	background: #fbe7e7;
	color: #a01c1c;
}

.otfa-order-status.status-pending,
.otfa-order-status.status-on-hold {
	background: #fff3da;
	color: #8a5a00;
}

.otfa-order-meta {
	width: 100%;
	border-collapse: collapse;
	margin-bottom: 14px;
	font-size: 14px;
}

.otfa-order-meta th,
.otfa-order-meta td {
	text-align: right;
	padding: 6px 0;
	vertical-align: top;
}

.otfa-order-meta th {
	color: #666;
	font-weight: 500;
	width: 40%;
}

.otfa-items h4 {
	margin: 0 0 8px;
	font-size: 14px;
}

.otfa-items ul {
	list-style: none;
	margin: 0;
	padding: 0;
}

.otfa-items li {
	display: flex;
	justify-content: space-between;
	gap: 10px;
	padding: 8px 0;
	border-bottom: 1px solid #eef2ee;
	font-size: 14px;
}

.otfa-items li:last-child {
	border-bottom: none;
}

.otfa-item-qty {
	color: #666;
	white-space: nowrap;
}

/* موبایل */
@media (max-width: 480px) {
	.otfa-box {
		padding: 18px;
		border-radius: 8px;
	}

	.otfa-title {
		font-size: 18px;
	}
}
