/* ===========================================================
   پرتال فرانت‌اند حسابداری / انبار / فروشگاه — ایران کاور
   طراحی شیشه‌ای (Glassmorphism) هماهنگ با برند: پس‌زمینه تیره #3c3c3c + نارنجی #ff5a1f
   =========================================================== */

.ic-fe-root {
	--ic-orange: #ff5a1f;
	--ic-orange-soft: rgba(255, 90, 31, 0.18);
	--ic-dark: #2b2b2d;
	--ic-dark-2: #3c3c3c;
	--ic-glass-bg: rgba(255, 255, 255, 0.06);
	--ic-glass-border: rgba(255, 255, 255, 0.14);
	--ic-text: #f2f2f2;
	--ic-text-dim: #b9b9bc;

	direction: rtl;
	text-align: right;
	font-family: 'Vazirmatn', Tahoma, sans-serif;
	color: var(--ic-text);
	background: radial-gradient(circle at 20% 0%, #4a4a4d 0%, var(--ic-dark) 55%, #202021 100%);
	border-radius: 20px;
	padding: 28px;
	min-height: 70vh;
	position: relative;
	overflow: hidden;
}
.ic-fe-root::before {
	content: "";
	position: absolute;
	inset: 0;
	background: radial-gradient(circle at 85% 15%, rgba(255, 90, 31, 0.15), transparent 45%);
	pointer-events: none;
}
.ic-fe-root * { box-sizing: border-box; }

/* ---------- کارت شیشه‌ای پایه ---------- */
.ic-glass {
	background: var(--ic-glass-bg);
	backdrop-filter: blur(18px);
	-webkit-backdrop-filter: blur(18px);
	border: 1px solid var(--ic-glass-border);
	border-radius: 16px;
	box-shadow: 0 8px 32px rgba(0, 0, 0, 0.28);
}

/* ---------- هدر پرتال ---------- */
.ic-fe-header {
	display: flex;
	justify-content: space-between;
	align-items: center;
	flex-wrap: wrap;
	gap: 14px;
	padding: 18px 24px;
	margin-bottom: 22px;
	position: relative;
	z-index: 1;
}
.ic-fe-header h1 {
	margin: 0;
	font-size: 20px;
	color: #fff;
}
.ic-fe-header .ic-fe-sub { color: var(--ic-text-dim); font-size: 13px; margin-top: 4px; }
.ic-fe-user {
	display: flex;
	align-items: center;
	gap: 12px;
	font-size: 13px;
	color: var(--ic-text-dim);
}
.ic-fe-logout {
	color: #ffb199;
	text-decoration: none;
	border: 1px solid rgba(255, 90, 31, 0.4);
	padding: 6px 14px;
	border-radius: 20px;
	transition: all .15s ease;
}
.ic-fe-logout:hover { background: var(--ic-orange); color: #fff; border-color: var(--ic-orange); }

/* ---------- ورود ---------- */
.ic-fe-login-wrap {
	max-width: 380px;
	margin: 40px auto;
	padding: 36px 32px;
	position: relative;
	z-index: 1;
}
.ic-fe-login-wrap h2 { text-align: center; margin: 0 0 6px; color: #fff; }
.ic-fe-login-wrap p.ic-fe-login-desc { text-align: center; color: var(--ic-text-dim); font-size: 13px; margin-bottom: 24px; }
.ic-fe-error {
	background: rgba(214, 54, 56, 0.15);
	border: 1px solid rgba(214, 54, 56, 0.4);
	color: #ff9d9d;
	padding: 10px 14px;
	border-radius: 10px;
	font-size: 13px;
	margin-bottom: 18px;
	text-align: center;
}
.ic-fe-denied {
	max-width: 420px;
	margin: 60px auto;
	padding: 36px 32px;
	text-align: center;
	position: relative;
	z-index: 1;
}

/* ---------- فرم‌ها ---------- */
.ic-fe-field { margin-bottom: 16px; }
.ic-fe-field label { display: block; font-size: 13px; color: var(--ic-text-dim); margin-bottom: 6px; }
.ic-fe-root input[type=text],
.ic-fe-root input[type=email],
.ic-fe-root input[type=password],
.ic-fe-root input[type=number],
.ic-fe-root input[type=date],
.ic-fe-root input[type=tel],
.ic-fe-root select,
.ic-fe-root textarea {
	width: 100%;
	background: rgba(255, 255, 255, 0.07);
	border: 1px solid rgba(255, 255, 255, 0.16);
	color: #fff;
	border-radius: 10px;
	padding: 10px 14px;
	font-family: inherit;
	font-size: 14px;
	transition: border-color .15s ease, background .15s ease;
}
.ic-fe-root input:focus,
.ic-fe-root select:focus,
.ic-fe-root textarea:focus {
	outline: none;
	border-color: var(--ic-orange);
	background: rgba(255, 255, 255, 0.1);
}
.ic-fe-root input::placeholder, .ic-fe-root textarea::placeholder { color: #9a9a9d; }
.ic-fe-root select option { color: #000; }

.ic-fe-btn {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	gap: 6px;
	background: linear-gradient(135deg, var(--ic-orange), #ff7a45);
	color: #fff;
	border: none;
	padding: 11px 24px;
	border-radius: 10px;
	font-size: 14px;
	font-weight: 600;
	cursor: pointer;
	text-decoration: none;
	transition: transform .12s ease, box-shadow .12s ease;
	box-shadow: 0 4px 14px rgba(255, 90, 31, 0.35);
}
.ic-fe-btn:hover { transform: translateY(-1px); box-shadow: 0 6px 18px rgba(255, 90, 31, 0.45); color: #fff; }
.ic-fe-btn.ic-fe-btn-ghost {
	background: rgba(255, 255, 255, 0.08);
	box-shadow: none;
	border: 1px solid var(--ic-glass-border);
}
.ic-fe-btn.ic-fe-btn-danger { background: linear-gradient(135deg, #d63638, #ff5a5a); box-shadow: 0 4px 14px rgba(214, 54, 56, 0.35); }
.ic-fe-btn.ic-fe-btn-block { width: 100%; }
.ic-fe-btn.ic-fe-btn-sm { padding: 6px 14px; font-size: 12.5px; }

.ic-fe-notice {
	background: rgba(77, 210, 140, 0.15);
	border: 1px solid rgba(77, 210, 140, 0.4);
	color: #9ef0c4;
	padding: 10px 16px;
	border-radius: 10px;
	margin-bottom: 18px;
	font-size: 13.5px;
}

/* ---------- تب‌ها ---------- */
.ic-fe-tabs {
	display: flex;
	flex-wrap: wrap;
	gap: 10px;
	margin-bottom: 22px;
	position: relative;
	z-index: 1;
}
.ic-fe-tab {
	padding: 10px 18px;
	border-radius: 24px;
	font-size: 13.5px;
	text-decoration: none;
	color: var(--ic-text-dim);
	background: rgba(255, 255, 255, 0.05);
	border: 1px solid var(--ic-glass-border);
	transition: all .15s ease;
}
.ic-fe-tab:hover { color: #fff; background: rgba(255, 255, 255, 0.1); }
.ic-fe-tab.active {
	background: linear-gradient(135deg, var(--ic-orange), #ff7a45);
	color: #fff;
	border-color: transparent;
	box-shadow: 0 4px 14px rgba(255, 90, 31, 0.35);
}

/* ---------- بخش محتوا ---------- */
.ic-fe-section {
	padding: 24px;
	margin-bottom: 22px;
	position: relative;
	z-index: 1;
}
.ic-fe-section h2 {
	margin: 0 0 18px;
	font-size: 16px;
	color: #fff;
	border-right: 3px solid var(--ic-orange);
	padding-right: 10px;
}
.ic-fe-section .ic-fe-desc { color: var(--ic-text-dim); font-size: 13px; margin-bottom: 16px; }

/* ---------- کارت‌های آماری کوچک ---------- */
.ic-fe-stats { display: flex; flex-wrap: wrap; gap: 14px; margin-bottom: 22px; position: relative; z-index: 1; }
.ic-fe-stat { flex: 1; min-width: 160px; padding: 16px 18px; }
.ic-fe-stat .lbl { display: block; font-size: 12px; color: var(--ic-text-dim); margin-bottom: 8px; }
.ic-fe-stat .val { display: block; font-size: 17px; font-weight: 700; color: var(--ic-orange); }

/* ---------- جدول ---------- */
.ic-fe-table-wrap { overflow-x: auto; }
table.ic-fe-table { width: 100%; border-collapse: collapse; font-size: 13px; min-width: 560px; }
table.ic-fe-table th, table.ic-fe-table td { padding: 10px 12px; text-align: right; border-bottom: 1px solid rgba(255, 255, 255, 0.08); }
table.ic-fe-table th { color: var(--ic-text-dim); font-weight: 600; font-size: 12.5px; }
table.ic-fe-table tr:hover td { background: rgba(255, 255, 255, 0.03); }
.ic-fe-negative { color: #ff8080; font-weight: 700; }
.ic-fe-positive { color: #6be3a6; font-weight: 700; }

/* ---------- فرم‌های ردیفی (اقلام فاکتور) ---------- */
.ic-fe-items-table input, .ic-fe-items-table select { min-width: 120px; }
.ic-fe-items-table td { padding: 6px 4px; }

/* ---------- بارگذاری تصویر محصول ---------- */
.ic-fe-image-picker { display: flex; flex-wrap: wrap; gap: 10px; margin-bottom: 10px; }
.ic-fe-image-thumb {
	width: 84px; height: 84px; border-radius: 10px; overflow: hidden; position: relative;
	border: 1px solid var(--ic-glass-border); background: rgba(255,255,255,.05);
}
.ic-fe-image-thumb img { width: 100%; height: 100%; object-fit: cover; display: block; }
.ic-fe-image-thumb .remove {
	position: absolute; top: 2px; left: 2px; background: rgba(0,0,0,.6); color: #fff;
	border: none; border-radius: 50%; width: 20px; height: 20px; font-size: 12px; cursor: pointer; line-height: 1;
}
.ic-fe-image-add {
	width: 84px; height: 84px; border-radius: 10px; display: flex; align-items: center; justify-content: center;
	border: 1px dashed var(--ic-glass-border); color: var(--ic-text-dim); cursor: pointer; font-size: 24px;
	background: rgba(255,255,255,.03);
}
.ic-fe-image-add:hover { color: var(--ic-orange); border-color: var(--ic-orange); }

/* ---------- سوییچ نوع محصول ---------- */
.ic-fe-toggle-group { display: flex; gap: 10px; margin-bottom: 18px; }
.ic-fe-toggle-group label {
	flex: 1; text-align: center; padding: 10px; border-radius: 10px; cursor: pointer;
	background: rgba(255,255,255,.05); border: 1px solid var(--ic-glass-border); font-size: 13px;
}
.ic-fe-toggle-group input { display: none; }
.ic-fe-toggle-group input:checked + span { color: #fff; }
.ic-fe-toggle-group label:has(input:checked) { background: linear-gradient(135deg, var(--ic-orange), #ff7a45); border-color: transparent; }

.ic-fe-variation-row td { vertical-align: middle; }
.ic-fe-badge {
	display: inline-block; background: var(--ic-orange-soft); color: #ffb18e; font-size: 11px;
	padding: 2px 10px; border-radius: 12px; margin-right: 6px;
}

/* ---------- ریسپانسیو ---------- */
@media (max-width: 700px) {
	.ic-fe-root { padding: 16px; border-radius: 14px; }
	.ic-fe-header { padding: 14px 16px; }
	.ic-fe-section { padding: 16px; }
	.ic-fe-stat { min-width: 130px; }
}
