/* KCO Plan Eval - Professional UI Styles */

:root {
	--kco-primary: #2563eb;
	--kco-primary-dark: #1e40af;
	--kco-success: #16a34a;
	--kco-danger: #dc2626;
	--kco-warning: #d97706;
	--kco-bg: #f8fafc;
	--kco-card-bg: #ffffff;
	--kco-border: #e2e8f0;
	--kco-text: #0f172a;
	--kco-text-muted: #64748b;
	--kco-radius: 12px;
	--kco-shadow: 0 1px 3px rgba(15, 23, 42, 0.08), 0 1px 2px rgba(15, 23, 42, 0.04);
	--kco-shadow-lg: 0 10px 25px -5px rgba(15, 23, 42, 0.1), 0 8px 10px -6px rgba(15,23,42,0.06);
}

.kco-panel, .kco-admin-dashboard {
	direction: rtl;
	font-family: "Vazirmatn", "IRANSans", -apple-system, sans-serif;
	color: var(--kco-text);
	max-width: 1100px;
	margin: 0 auto;
	line-height: 1.9;
}

.kco-panel-header {
	display: flex;
	justify-content: space-between;
	align-items: center;
	margin-bottom: 24px;
}
.kco-panel-header h2, .kco-panel h2 { font-size: 1.5rem; font-weight: 700; margin: 0 0 4px; }

hr, .kco-divider { border: none; border-top: 1px solid var(--kco-border); margin: 28px 0; }

/* Buttons */
.kco-btn {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	gap: 6px;
	padding: 10px 20px;
	border-radius: 8px;
	font-weight: 600;
	font-size: 0.92rem;
	text-decoration: none;
	border: 1px solid transparent;
	cursor: pointer;
	transition: all .15s ease;
}
.kco-btn-primary { background: var(--kco-primary); color: #fff; }
.kco-btn-primary:hover { background: var(--kco-primary-dark); color: #fff; }
.kco-btn-outline { background: transparent; border-color: var(--kco-border); color: var(--kco-text); }
.kco-btn-outline:hover { background: var(--kco-bg); }
.kco-btn-success { background: var(--kco-success); color: #fff; }
.kco-btn-success:hover { filter: brightness(0.92); }
.kco-btn-danger { background: var(--kco-danger); color: #fff; }
.kco-btn-danger:hover { filter: brightness(0.92); }
.kco-btn-sm { padding: 5px 12px; font-size: 0.76rem; gap: 4px; }
.kco-btn-block { width: 100%; margin-top: 8px; }

/* Cards */
.kco-plan-cards { display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: 16px; }
.kco-plan-cards-2col { grid-template-columns: repeat(2, 1fr); }
@media (max-width: 560px) { .kco-plan-cards-2col { grid-template-columns: 1fr; } }
.kco-plan-card {
	background: var(--kco-card-bg);
	border: 1px solid var(--kco-border);
	border-radius: var(--kco-radius);
	padding: 20px;
	box-shadow: var(--kco-shadow);
	transition: box-shadow .2s ease, transform .2s ease;
}
.kco-plan-card:hover { box-shadow: var(--kco-shadow-lg); transform: translateY(-2px); }
.kco-plan-card-title { font-weight: 700; font-size: 0.92rem; line-height: 1.5; margin-bottom: 8px; }
.kco-plan-card-meta { display: flex; gap: 8px; align-items: center; margin-bottom: 14px; flex-wrap: wrap; }
.kco-plan-event { font-size: 0.82rem; color: var(--kco-text-muted); }
.kco-plan-card-footer { display: flex; justify-content: space-between; align-items: center; border-top: 1px solid var(--kco-border); padding-top: 12px; }
.kco-plan-card-footer-stacked { flex-direction: column; align-items: flex-start; gap: 10px; }
.kco-plan-card-actions { display: flex; align-items: center; gap: 6px; flex-wrap: nowrap; width: 100%; }
.kco-plan-card-actions .kco-btn { flex: 1 1 0; white-space: nowrap; }
.kco-plan-last-change { font-size: 0.76rem; color: var(--kco-text-muted); display: inline-flex; align-items: center; gap: 4px; }
.kco-plan-last-change-icon { font-size: 0.9em; line-height: 1; }

/* Guide file box */
.kco-guide-box {
	display: flex;
	align-items: center;
	gap: 16px;
	background: linear-gradient(135deg, #eef2ff 0%, #e0f2fe 100%);
	border: 1px solid #c7d2fe;
	border-radius: var(--kco-radius);
	padding: 18px 22px;
	margin-bottom: 24px;
}
.kco-guide-box-icon { font-size: 2rem; line-height: 1; }
.kco-guide-box-text { flex: 1; }
.kco-guide-box-text strong { display: block; font-size: 1.05rem; color: #3730a3; margin-bottom: 2px; }
.kco-guide-box-text p { margin: 0; font-size: 0.85rem; color: #4338ca; }
.kco-back-link {
	display: inline-flex;
	align-items: center;
	gap: 6px;
	margin-bottom: 18px;
	padding: 8px 16px;
	border: 1px solid var(--kco-border);
	border-radius: 999px;
	background: var(--kco-card-bg);
	color: var(--kco-text);
	text-decoration: none;
	font-size: 0.85rem;
	font-weight: 600;
	box-shadow: var(--kco-shadow);
	transition: all .15s ease;
}
.kco-back-link:hover { color: #fff; background: var(--kco-primary); border-color: var(--kco-primary); }

/* Badges (status) */
.kco-badge { display: inline-block; padding: 4px 12px; border-radius: 999px; font-size: 0.78rem; font-weight: 600; background: #e2e8f0; color: #334155; }
.kco-badge-warning { background: #fef3c7; color: #92400e; }
.kco-status-submitted { background: #e0e7ff; color: #3730a3; }
.kco-status-pending_completion { background: #f3e8ff; color: #6d28d9; }
.kco-status-ai_screening { background: #fef3c7; color: #92400e; }
.kco-status-stage1_eval { background: #dbeafe; color: #1e40af; }
.kco-status-stage1_done { background: #cffafe; color: #155e75; }
.kco-status-needs_docs { background: #fee2e2; color: #991b1b; }
.kco-status-stage2_final_eval { background: #ede9fe; color: #5b21b6; }
.kco-status-rejected { background: #fee2e2; color: #991b1b; }
.kco-status-approved_booklet { background: #dcfce7; color: #166534; }
.kco-status-approved_presentation { background: #bbf7d0; color: #14532d; }
.kco-status-other { background: #f1f5f9; color: #475569; }

/* Empty states & notices */
.kco-empty-state { text-align: center; padding: 48px 20px; background: var(--kco-card-bg); border: 1px dashed var(--kco-border); border-radius: var(--kco-radius); color: var(--kco-text-muted); }
.kco-notice { padding: 14px 18px; border-radius: 8px; background: #fef3c7; color: #92400e; margin-bottom: 16px; }
.kco-notice-success { background: #dcfce7; color: #166534; }

.kco-submit-actions { display: flex; gap: 10px; justify-content: center; margin-top: 16px; }

/* Evaluator table */
.kco-plan-table { width: 100%; border-collapse: collapse; background: var(--kco-card-bg); border-radius: var(--kco-radius); overflow: hidden; box-shadow: var(--kco-shadow); }
.kco-plan-table th, .kco-plan-table td { padding: 14px 16px; text-align: right; border-bottom: 1px solid var(--kco-border); }
.kco-plan-table th { background: var(--kco-bg); font-weight: 700; font-size: 0.85rem; color: var(--kco-text-muted); }

.kco-stage1-breakdown-table-wrap { overflow-x: auto; margin-bottom: 14px; }
.kco-stage1-breakdown-table { width: 100%; border-collapse: collapse; font-size: 0.84rem; }
.kco-stage1-breakdown-table th, .kco-stage1-breakdown-table td { padding: 7px 10px; text-align: center; border: 1px solid var(--kco-border); white-space: nowrap; }
.kco-stage1-breakdown-table th:first-child, .kco-stage1-breakdown-table td:first-child { text-align: right; white-space: normal; background: var(--kco-bg); font-weight: 600; }
.kco-stage1-breakdown-table thead th { background: #eef2ff; color: #3730a3; }

/* Evaluate plan page */
.kco-eval-header {
	background: linear-gradient(180deg, #f5f8ff 0%, var(--kco-card-bg) 55%);
	border: 1px solid var(--kco-border);
	border-inline-start: 5px solid var(--kco-primary);
	border-radius: var(--kco-radius);
	padding: 22px 26px;
	margin-bottom: 20px;
	box-shadow: var(--kco-shadow);
}
.kco-eval-header h2 { margin: 0 0 10px; }
.kco-eval-header-meta { display: flex; gap: 20px; color: var(--kco-text-muted); font-size: 0.92rem; margin-bottom: 12px; flex-wrap: wrap; }
.kco-eval-header-meta span { display: inline-flex; gap: 4px; }
.kco-ai-summary-box { background: var(--kco-bg); border-radius: 8px; padding: 12px 16px; border-inline-start: 4px solid var(--kco-primary); margin-top: 10px; }
.kco-ai-summary-box p { margin: 6px 0 0; color: var(--kco-text-muted); }

.kco-eval-grid { display: grid; grid-template-columns: 2fr 1fr; gap: 20px; align-items: start; }
@media (max-width: 800px) { .kco-eval-grid { grid-template-columns: 1fr; } }

.kco-eval-section, .kco-scoring-box { background: var(--kco-card-bg); border: 1px solid var(--kco-border); border-radius: var(--kco-radius); padding: 20px; margin-bottom: 16px; box-shadow: var(--kco-shadow); }
.kco-eval-section h3, .kco-scoring-box h3 { margin-top: 0; font-size: 1.05rem; }

/* --- گفتگوی داخلی ارزیابان/مدیر: طراحی متمایز شبیه چت --- */
.kco-internal-messages {
	background: linear-gradient(180deg, #faf5ff 0%, var(--kco-card-bg) 120px);
	border: 1px solid #e9d5ff;
	border-inline-start: 5px solid #9333ea;
}
.kco-internal-messages h3 { display: flex; align-items: center; gap: 8px; color: #6b21a8; }
.kco-internal-messages h3::before { content: "💬"; }
.kco-internal-messages .kco-messages-thread {
	max-height: 360px;
	overflow-y: auto;
	margin-bottom: 14px;
	display: flex;
	flex-direction: column;
	gap: 10px;
	padding-inline-end: 4px;
}
.kco-internal-messages .kco-message {
	position: relative;
	background: #fff;
	border: 1px solid #f1e6fb;
	border-radius: 12px;
	padding: 10px 14px 12px;
	box-shadow: 0 1px 3px rgba(88,28,135,0.06);
	margin-bottom: 0;
}
.kco-internal-messages .kco-message strong { color: #6b21a8; font-size: 0.86rem; }
.kco-internal-messages .kco-message-manager { background: #fff7ed; border-color: #fed7aa; border-inline-start: 4px solid var(--kco-warning); }
.kco-internal-messages .kco-message-manager strong { color: #9a3412; }
.kco-internal-messages .kco-message-business { background: #eff6ff; border-color: #bfdbfe; border-inline-start: 4px solid var(--kco-primary); }
.kco-internal-messages .kco-message-business strong { color: #1e40af; }
.kco-internal-messages .kco-message-form textarea {
	border: 1px solid #e9d5ff;
	background: #fff;
}
.kco-internal-messages .kco-message-form textarea:focus { outline: none; border-color: #9333ea; box-shadow: 0 0 0 3px rgba(147,51,234,0.12); }
.kco-internal-messages #kco-send-internal { align-self: flex-end; background: #9333ea; border-color: #9333ea; color: #fff; }
.kco-internal-messages #kco-send-internal:hover { background: #7e22ce; }

.kco-accordion { border: 1px solid var(--kco-border); border-radius: var(--kco-radius); overflow: hidden; margin-bottom: 16px; background: var(--kco-card-bg); }
.kco-accordion-toggle {
	width: 100%;
	display: flex;
	align-items: center;
	justify-content: space-between;
	text-align: right;
	padding: 16px 20px;
	background: var(--kco-bg);
	border: none;
	font-weight: 700;
	font-size: 1rem;
	cursor: pointer;
	color: var(--kco-text);
}
.kco-accordion-toggle::after {
	content: "\25BE"; /* فلش رو به پایین */
	display: inline-block;
	transition: transform .2s ease;
	color: var(--kco-primary);
	font-size: 1.1rem;
}
.kco-accordion-toggle.active::after { transform: rotate(180deg); }
/* از max-height ثابت استفاده نمی‌کنیم چون برای طرح‌های با فیلدهای زیاد محتوا را نصفه می‌برید؛
   نمایش/عدم‌نمایش کامل با display کنترل می‌شود و کل محتوا همیشه به‌طور کامل رندر می‌شود. */
.kco-accordion-content { display: none; padding: 0 20px; }
.kco-accordion-content.open { display: block; padding: 18px 20px; animation: kco-fade-in .2s ease; }
@keyframes kco-fade-in { from { opacity: 0; } to { opacity: 1; } }
.kco-detail-row { display: flex; gap: 8px; padding: 10px 0; border-bottom: 1px dashed var(--kco-border); }
.kco-detail-row:last-child { border-bottom: none; }
.kco-detail-label { font-weight: 600; color: var(--kco-text-muted); min-width: 220px; flex-shrink: 0; }
.kco-detail-value { word-break: break-word; }

.kco-doc-list { list-style: none; padding: 0; }
.kco-doc-list li { margin-bottom: 8px; display: flex; align-items: center; gap: 10px; }
.kco-doc-list a { color: var(--kco-primary); text-decoration: none; font-weight: 600; }
.kco-doc-remove-btn {
	background: none; border: none; color: var(--kco-danger);
	font-size: 1.1rem; line-height: 1; cursor: pointer; padding: 2px 6px; border-radius: 6px;
}
.kco-doc-remove-btn:hover { background: #fef2f2; }
.kco-edit-doc-upload { display: flex; align-items: center; gap: 12px; margin-top: 10px; }
.kco-edit-doc-upload #kco-edit-doc-upload-status { font-size: 0.85rem; }

.kco-message-audience {
	display: flex; flex-wrap: wrap; align-items: center; gap: 14px;
	font-size: 0.82rem; color: var(--kco-text-muted);
	margin: 10px 0;
}
.kco-message-audience-label { font-weight: 600; color: var(--kco-text); }
.kco-message-audience label { display: flex; align-items: center; gap: 4px; cursor: pointer; }
.kco-message { padding: 10px 14px; border-radius: 8px; background: var(--kco-bg); margin-bottom: 10px; }
.kco-message-manager { background: #fef3c7; border-inline-start: 4px solid var(--kco-warning); }
.kco-message-business { background: #eff6ff; border-inline-start: 4px solid var(--kco-primary); }
.kco-message-time, .kco-notif-time { font-size: 0.72rem; color: var(--kco-text-muted); display: block; margin-top: 4px; }
.kco-stage1-comment-row { display: flex; justify-content: space-between; align-items: flex-start; gap: 12px; }
.kco-stage1-comment-main { flex: 1; min-width: 0; }
.kco-stage1-comment-action { flex-shrink: 0; }

.kco-score-row { margin-bottom: 14px; }
.kco-score-row label { display: block; font-weight: 600; font-size: 0.88rem; margin-bottom: 6px; }
.kco-score-row input[type=number], .kco-score-row textarea { width: 100%; padding: 8px 12px; border: 1px solid var(--kco-border); border-radius: 8px; font-family: inherit; box-sizing: border-box; }
.kco-final-decision-buttons { display: flex; flex-direction: column; gap: 8px; margin-top: 12px; }

.kco-message-form { margin-top: 16px; display: flex; flex-direction: column; gap: 10px; }
.kco-message-form textarea { padding: 10px; border-radius: 8px; border: 1px solid var(--kco-border); font-family: inherit; box-sizing: border-box; }
.kco-file-label { font-size: 0.82rem; color: var(--kco-text-muted); display: flex; align-items: center; gap: 8px; }
.kco-internal-messages .kco-messages-thread { max-height: 340px; overflow-y: auto; margin-bottom: 12px; }
.kco-docs-request-banner { border-inline-start: 4px solid var(--kco-danger); }
.kco-docs-request-banner span { display: block; margin-top: 6px; font-size: 0.82rem; }

/* Notification bell */
.kco-notif-wrap { position: relative; }
.kco-notif-toggle {
	position: relative;
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 42px; height: 42px;
	border-radius: 50%;
	border: 1px solid var(--kco-border);
	background: var(--kco-card-bg);
	cursor: pointer;
	font-size: 1.2rem;
	transition: background .15s ease, border-color .15s ease;
}
.kco-notif-toggle:hover { background: var(--kco-bg); border-color: #cbd5e1; }
.kco-notif-badge {
	display: none;
	position: absolute;
	top: -3px; inset-inline-end: -3px;
	min-width: 19px; height: 19px;
	padding: 0 5px;
	border-radius: 999px;
	background: var(--kco-danger);
	color: #fff;
	font-size: 0.7rem;
	font-weight: 700;
	align-items: center;
	justify-content: center;
	line-height: 1;
	box-shadow: 0 0 0 2px var(--kco-card-bg);
}

/* Panel */
.kco-notif-panel {
	display: none;
	position: absolute;
	inset-inline-end: 0;
	top: calc(100% + 10px);
	width: 380px;
	max-width: calc(100vw - 24px);
	max-height: 480px;
	background: var(--kco-card-bg);
	border: 1px solid var(--kco-border);
	border-radius: 16px;
	box-shadow: var(--kco-shadow-lg);
	z-index: 60;
	overflow: hidden;
	flex-direction: column;
}
.kco-notif-panel.open { display: flex; }

.kco-notif-panel-header {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 10px;
	padding: 16px 18px 12px;
	flex-shrink: 0;
}
.kco-notif-panel-header h3 { margin: 0; font-size: 1.02rem; font-weight: 700; color: var(--kco-text); }
.kco-notif-mark-all {
	background: none;
	border: none;
	color: var(--kco-primary);
	font-size: 0.76rem;
	font-weight: 600;
	cursor: pointer;
	padding: 4px 2px;
	white-space: nowrap;
}
.kco-notif-mark-all:hover { text-decoration: underline; }
.kco-notif-mark-all:disabled { color: var(--kco-text-muted); cursor: default; text-decoration: none; }

.kco-notif-tabs {
	display: flex;
	gap: 6px;
	padding: 0 18px 12px;
	flex-shrink: 0;
	border-bottom: 1px solid var(--kco-border);
}
.kco-notif-tab {
	border: none;
	background: var(--kco-bg);
	color: var(--kco-text-muted);
	font-size: 0.8rem;
	font-weight: 600;
	padding: 6px 14px;
	border-radius: 999px;
	cursor: pointer;
	transition: background .15s ease, color .15s ease;
}
.kco-notif-tab:hover { background: #eef2f7; }
.kco-notif-tab.active { background: var(--kco-primary); color: #fff; }

.kco-notif-list {
	list-style: none;
	margin: 0;
	padding: 6px 8px 10px;
	overflow-y: auto;
	flex: 1;
}

.kco-notif-item {
	display: flex;
	align-items: flex-start;
	gap: 12px;
	text-decoration: none;
	color: var(--kco-text);
	cursor: pointer;
	padding: 10px 10px;
	border-radius: 12px;
	transition: background .15s ease;
}
.kco-notif-item:hover { background: var(--kco-bg); }
.kco-notif-item + .kco-notif-item { margin-top: 2px; }
.kco-notif-item.kco-notif-hidden { display: none; }

.kco-notif-icon {
	flex-shrink: 0;
	position: relative;
	width: 40px; height: 40px;
	border-radius: 50%;
	display: flex;
	align-items: center;
	justify-content: center;
	font-size: 1.05rem;
	background: #eef2ff;
	color: var(--kco-primary);
}
.kco-notif-icon.type-plan_created { background: #e0edff; color: #2563eb; }
.kco-notif-icon.type-status_changed { background: #ede9fe; color: #7c3aed; }
.kco-notif-icon.type-decision { background: #dcfce7; color: #16a34a; }
.kco-notif-icon.type-docs_requested { background: #ffedd5; color: #d97706; }
.kco-notif-icon.type-scored { background: #fef9c3; color: #ca8a04; }
.kco-notif-icon.type-message { background: #e0e7ff; color: #4f46e5; }
.kco-notif-icon.type-edited { background: #ccfbf1; color: #0d9488; }
.kco-notif-icon.type-stage_ready { background: #dbeafe; color: #0369a1; }
.kco-notif-icon.type-reopened { background: #fee2e2; color: #dc2626; }
.kco-notif-icon.type-general { background: #f1f5f9; color: var(--kco-text-muted); }
.kco-notif-unread-dot {
	position: absolute;
	top: -1px; inset-inline-end: -1px;
	width: 10px; height: 10px;
	border-radius: 50%;
	background: var(--kco-success);
	border: 2px solid var(--kco-card-bg);
}

.kco-notif-body { flex: 1; min-width: 0; }
.kco-notif-message {
	font-size: 0.86rem;
	line-height: 1.6;
	color: var(--kco-text);
	margin: 0;
}
.kco-notif-item.unread .kco-notif-message { font-weight: 700; }
.kco-notif-meta {
	display: flex;
	align-items: center;
	gap: 8px;
	margin-top: 4px;
}
.kco-notif-time {
	font-size: 0.74rem;
	color: var(--kco-text-muted);
	display: inline-block;
	margin: 0;
}
.kco-notif-action {
	display: inline-flex;
	align-items: center;
	gap: 4px;
	margin-top: 8px;
	font-size: 0.74rem;
	font-weight: 700;
	color: #fff;
	background: var(--kco-primary);
	padding: 5px 12px;
	border-radius: 999px;
	text-decoration: none;
}
.kco-notif-action:hover { background: var(--kco-primary-dark); }

.kco-notif-list .kco-empty-state {
	padding: 40px 16px;
	text-align: center;
	color: var(--kco-text-muted);
	font-size: 0.85rem;
}

/* Admin dashboard */
.kco-admin-columns { display: grid; grid-template-columns: 2.2fr 1fr; gap: 20px; margin-top: 20px; }
.kco-admin-col { background: #fff; border: 1px solid var(--kco-border); border-radius: var(--kco-radius); padding: 20px; }
.kco-notif-list { list-style: none; margin: 0; padding: 0; }
.kco-notif-list li { padding: 10px 0; border-bottom: 1px solid var(--kco-border); font-size: 0.88rem; }
.kco-notif-list li.unread { font-weight: 700; }

/* Notices (error variant, success/warning already defined above) */
.kco-notice-error { background: #fee2e2; color: #991b1b; }

/* ستون‌های سفارشی لیست طرح‌ها در پیشخوان وردپرس */
.wp-list-table .column-kco_status,
.wp-list-table .column-kco_ai_score,
.wp-list-table .column-kco_stage1,
.wp-list-table .column-kco_final { width: 15%; }
.wp-list-table .kco-badge { white-space: nowrap; }

/* Evaluators admin page */
.kco-evaluators-page { max-width: 1200px; }
.kco-create-card {
	background: var(--kco-card-bg);
	border: 1px solid var(--kco-border);
	border-radius: var(--kco-radius);
	padding: 24px 26px;
	box-shadow: var(--kco-shadow);
	margin: 20px 0 32px;
}
.kco-create-card h2 { margin-top: 0; margin-bottom: 4px; font-size: 1.15rem; }
.kco-create-card > .description { margin-bottom: 20px; color: var(--kco-text-muted); }

.kco-form-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 16px; margin-bottom: 20px; }
.kco-field label { display: block; font-weight: 600; font-size: 0.85rem; margin-bottom: 6px; color: var(--kco-text); }
.kco-field input[type="text"],
.kco-field input[type="email"],
.kco-field select {
	width: 100%;
	padding: 10px 12px;
	border: 1px solid var(--kco-border);
	border-radius: 8px;
	font-family: inherit;
	font-size: 0.92rem;
	background: #fff;
	box-sizing: border-box;
}
.kco-field input:focus, .kco-field select:focus {
	outline: none;
	border-color: var(--kco-primary);
	box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.12);
}

.kco-evaluator-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: 16px; }
.kco-evaluator-card {
	background: var(--kco-card-bg);
	border: 1px solid var(--kco-border);
	border-radius: var(--kco-radius);
	padding: 18px 20px;
	box-shadow: var(--kco-shadow);
	transition: box-shadow .2s ease, transform .2s ease;
}
.kco-evaluator-card:hover { box-shadow: var(--kco-shadow-lg); transform: translateY(-2px); }
.kco-evaluator-top { display: flex; align-items: center; gap: 12px; margin-bottom: 14px; }
.kco-evaluator-avatar {
	width: 44px; height: 44px; border-radius: 50%;
	background: linear-gradient(135deg, var(--kco-primary) 0%, var(--kco-primary-dark) 100%);
	color: #fff; display: flex; align-items: center; justify-content: center;
	font-weight: 700; font-size: 1.05rem; flex-shrink: 0;
}
.kco-evaluator-name { font-weight: 700; font-size: 1rem; }
.kco-evaluator-email { font-size: 0.8rem; color: var(--kco-text-muted); direction: ltr; text-align: right; }
.kco-evaluator-meta { display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: 12px; }
.kco-evaluator-mobile { font-size: 0.82rem; color: var(--kco-text-muted); margin-bottom: 12px; direction: ltr; text-align: right; }

.kco-role-badge { display: inline-block; padding: 4px 12px; border-radius: 999px; font-size: 0.75rem; font-weight: 600; background: #e2e8f0; color: #334155; }
.kco-role-business { background: #dbeafe; color: #1e40af; }
.kco-role-kco_evaluator_stage1 { background: #fef3c7; color: #92400e; }
.kco-role-kco_evaluator_final { background: #ede9fe; color: #5b21b6; }
.kco-role-kco_manager { background: #dcfce7; color: #166534; }

.kco-evaluator-actions { display: flex; gap: 8px; align-items: center; border-top: 1px solid var(--kco-border); padding-top: 12px; margin-top: 12px; flex-wrap: wrap; }
.kco-evaluator-actions form { flex: 1 1 auto; margin: 0; }

.kco-password-row { display: flex; gap: 8px; align-items: center; }
.kco-password-row input { flex: 1; }
.kco-password-row button { white-space: nowrap; }

.kco-edit-details { margin-top: 4px; }
.kco-edit-details summary { list-style: none; cursor: pointer; width: 100%; text-align: center; }
.kco-edit-details summary::-webkit-details-marker { display: none; }
.kco-edit-details[open] summary { margin-bottom: 12px; }
.kco-edit-form { display: flex; flex-direction: column; gap: 12px; padding: 14px; background: var(--kco-bg); border-radius: 8px; margin-bottom: 4px; }
.kco-edit-form .kco-field label { font-size: 0.8rem; }

/* ===================================================================
   صفحه‌ی ارزیابی طرح - چرخه‌ی فرآیند (تایم‌لاین) + سایدبار اطلاعات طرح
   =================================================================== */

.kco-timeline-page-icon { font-size: 1.2em; }

/* --- تایم‌لاین چرخه‌ی وضعیت --- */
.kco-timeline { position: relative; padding-inline-start: 34px; margin-bottom: 24px; }
.kco-timeline::before {
	content: '';
	position: absolute;
	inset-inline-start: 15px;
	top: 6px; bottom: 6px;
	width: 2px;
	background: var(--kco-border);
}
.kco-timeline-item { position: relative; margin-bottom: 18px; }
.kco-timeline-item:last-child { margin-bottom: 0; }
.kco-timeline-marker {
	position: absolute;
	inset-inline-start: -34px;
	top: 2px;
	width: 30px; height: 30px;
	border-radius: 50%;
	display: flex; align-items: center; justify-content: center;
	background: #fff;
	border: 2px solid var(--kco-border);
	color: var(--kco-text-muted);
	font-size: 0.85rem;
	font-weight: 700;
	z-index: 1;
}
.kco-timeline-item.is-done .kco-timeline-marker { background: var(--kco-success); border-color: var(--kco-success); color: #fff; }
.kco-timeline-item.is-current .kco-timeline-marker { background: var(--kco-primary); border-color: var(--kco-primary); color: #fff; box-shadow: 0 0 0 4px rgba(37,99,235,0.15); }
.kco-timeline-body {
	background: var(--kco-card-bg);
	border: 1px solid var(--kco-border);
	border-radius: var(--kco-radius);
	padding: 14px 18px;
	box-shadow: var(--kco-shadow);
}
.kco-timeline-item.is-current .kco-timeline-body { border-color: #bfdbfe; background: #f8fbff; }
.kco-timeline-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 10px; flex-wrap: wrap; margin-bottom: 6px; }
.kco-timeline-actor { display: flex; align-items: center; gap: 10px; }
.kco-timeline-avatar {
	width: 32px; height: 32px; border-radius: 50%;
	background: linear-gradient(135deg, var(--kco-primary) 0%, var(--kco-primary-dark) 100%);
	color: #fff; display: flex; align-items: center; justify-content: center;
	font-weight: 700; font-size: 0.9rem; flex-shrink: 0;
}
.kco-timeline-role { display: block; font-size: 0.74rem; color: var(--kco-text-muted); }
.kco-timeline-time { font-size: 0.76rem; color: var(--kco-text-muted); white-space: nowrap; }
.kco-timeline-content p { margin: 0; font-size: 0.92rem; }
.kco-timeline-note {
	margin-top: 8px;
	padding: 8px 12px;
	background: var(--kco-bg);
	border-inline-start: 3px solid var(--kco-primary);
	border-radius: 6px;
	font-size: 0.85rem;
	color: var(--kco-text-muted);
}

/* --- تایم‌لاین افقی (نواری) گردش‌کار طرح برای کاربر کسب‌وکار --- */
.kco-btimeline-wrap {
	overflow-x: auto;
	margin-bottom: 24px;
	padding-bottom: 6px;
}
.kco-btimeline {
	position: relative;
	display: flex;
	min-width: max-content;
	padding: 10px 6px 4px;
}
.kco-btimeline::before {
	content: '';
	position: absolute;
	top: 32px;
	inset-inline-start: 66px;
	inset-inline-end: 66px;
	height: 2px;
	background: var(--kco-border);
	z-index: 0;
}
.kco-btimeline-step {
	position: relative;
	z-index: 1;
	display: flex;
	flex-direction: column;
	align-items: center;
	text-align: center;
	width: 168px;
	flex-shrink: 0;
	padding: 0 10px;
}
.kco-btimeline-icon {
	width: 46px; height: 46px;
	border-radius: 50%;
	background: var(--kco-card-bg);
	border: 2px solid var(--kco-border);
	display: flex;
	align-items: center;
	justify-content: center;
	font-size: 1.25rem;
	margin-bottom: 8px;
	flex-shrink: 0;
}
.kco-btimeline-icon.variant-default { border-color: var(--kco-primary); }
.kco-btimeline-icon.variant-warning { border-color: var(--kco-warning); }
.kco-btimeline-icon.variant-danger { border-color: var(--kco-danger); }
.kco-btimeline-icon.variant-success { border-color: var(--kco-success); }
.kco-btimeline-icon.is-current { color: #fff; box-shadow: 0 0 0 4px rgba(37,99,235,0.15); }
.kco-btimeline-icon.variant-default.is-current { background: var(--kco-primary); }
.kco-btimeline-icon.variant-warning.is-current { background: var(--kco-warning); box-shadow: 0 0 0 4px rgba(217,119,6,0.15); }
.kco-btimeline-icon.variant-danger.is-current { background: var(--kco-danger); box-shadow: 0 0 0 4px rgba(220,38,38,0.15); }
.kco-btimeline-icon.variant-success.is-current { background: var(--kco-success); box-shadow: 0 0 0 4px rgba(22,163,74,0.15); }
.kco-btimeline-body { display: flex; flex-direction: column; gap: 2px; }
.kco-btimeline-body strong { font-size: 0.86rem; color: var(--kco-text); }
.kco-btimeline-desc { font-size: 0.72rem; color: var(--kco-text-muted); line-height: 1.5; }
.kco-btimeline-time { font-size: 0.68rem; color: var(--kco-text-muted); direction: ltr; }
.kco-btimeline-meta-row { display: flex; align-items: center; justify-content: center; gap: 6px; margin: 4px 0 2px; }
.kco-btimeline-score {
	font-size: 0.7rem;
	font-weight: 700;
	color: var(--kco-primary);
	background: #eef2ff;
	padding: 2px 9px;
	border-radius: 999px;
	white-space: nowrap;
}
.kco-btimeline-comment-btn {
	flex-shrink: 0;
	width: 22px; height: 35px;
	border-radius: 50%;
	border: 1px solid #3a83ed !important;
	background: var(--kco-card-bg);
	cursor: pointer;
	font-size: 0.72rem;
	line-height: 1;
	display: inline-flex;
	align-items: center;
	justify-content: center;
	padding: 0;
	transition: background .15s ease, border-color .15s ease;
}
.kco-btimeline-comment-btn:hover { background: #3a83ed !important; border-color: #3a83ed !important; }

.kco-btimeline-modal {
	display: none;
	position: fixed;
	inset: 0;
	background: rgba(15, 23, 42, 0.5);
	z-index: 300;
	align-items: center;
	justify-content: center;
	padding: 20px;
}
.kco-btimeline-modal.open { display: flex; }
.kco-btimeline-modal-box {
	position: relative;
	background: var(--kco-card-bg);
	border-radius: 16px;
	width: 420px;
	max-width: 100%;
	max-height: 70vh;
	overflow-y: auto;
	padding: 22px 20px 20px;
	box-shadow: var(--kco-shadow-lg);
}
.kco-btimeline-modal-box h4 { margin: 0 0 10px; font-size: 0.95rem; padding-inline-end: 24px; }
.kco-btimeline-modal-close {
	position: absolute;
	top: 10px; inset-inline-end: 14px;
	background: none;
	border: none;
	font-size: 1.5rem;
	line-height: 1;
	cursor: pointer;
	color: var(--kco-text-muted);
}
.kco-btimeline-modal-close:hover { color: var(--kco-text); }
.kco-btimeline-modal-body { white-space: pre-line; font-size: 0.88rem; line-height: 1.9; color: var(--kco-text); }

/* --- سایدبار اطلاعات طرح در صفحه‌ی ارزیابی --- */
.kco-info-sidebar {
	background: var(--kco-card-bg);
	border: 1px solid var(--kco-border);
	border-radius: var(--kco-radius);
	padding: 20px;
	box-shadow: var(--kco-shadow);
	margin-bottom: 16px;
}
.kco-info-sidebar-title { font-weight: 700; margin-bottom: 10px; color: var(--kco-text-muted); font-size: 0.85rem; }
.kco-info-sidebar-name { font-size: 1.05rem; margin: 0 0 4px; }
.kco-info-sidebar-num { font-size: 0.8rem; color: var(--kco-text-muted); margin: 0 0 12px; }
.kco-info-sidebar-meta { display: flex; flex-direction: column; gap: 6px; font-size: 0.86rem; color: var(--kco-text-muted); margin-bottom: 12px; }
.kco-info-sidebar-docs { margin: 14px 0; padding-top: 14px; border-top: 1px dashed var(--kco-border); }
.kco-info-sidebar-docs-title { font-weight: 600; font-size: 0.85rem; margin-bottom: 8px; }
.kco-doc-chip {
	display: inline-flex; align-items: center; gap: 4px;
	padding: 6px 12px; margin: 0 4px 6px 0;
	border-radius: 999px; border: 1px solid var(--kco-border);
	background: var(--kco-bg); color: var(--kco-primary);
	font-size: 0.78rem; font-weight: 600; text-decoration: none;
}
.kco-doc-chip:hover { background: var(--kco-primary); color: #fff; border-color: var(--kco-primary); }

/* ===================================================================
   صفحه‌ی مستقل «جزئیات کامل طرح»
   =================================================================== */
.kco-plan-full-details { padding-bottom: 40px; }
.kco-fulldetail-hero {
	display: flex; align-items: center; justify-content: space-between; gap: 20px;
	background: linear-gradient(135deg, #eef2ff 0%, #e0f2fe 100%);
	border: 1px solid #c7d2fe;
	border-radius: var(--kco-radius);
	padding: 26px 30px;
	margin-bottom: 22px;
	flex-wrap: wrap;
}
.kco-fulldetail-hero h1 { margin: 10px 0 12px; font-size: 1.5rem; }
.kco-fulldetail-hero-meta { display: flex; gap: 18px; flex-wrap: wrap; color: #3730a3; font-size: 0.88rem; }
.kco-fulldetail-hero-score { text-align: center; background: #fff; border-radius: 14px; padding: 14px 22px; box-shadow: var(--kco-shadow); flex-shrink: 0; }
.kco-fulldetail-score-num { display: block; font-size: 2rem; font-weight: 800; color: var(--kco-primary); line-height: 1; }
.kco-fulldetail-score-label { display: block; font-size: 0.72rem; color: var(--kco-text-muted); margin-top: 4px; }
.kco-fulldetail-hero-actions { display: flex; align-items: center; gap: 10px; flex-shrink: 0; }

.kco-fulldetail-groups { display: grid; grid-template-columns: repeat(auto-fit, minmax(320px, 1fr)); gap: 16px; }
.kco-fulldetail-top-row { display: grid; grid-template-columns: 1fr 2fr; gap: 16px; margin-bottom: 16px; align-items: start; }
.kco-fulldetail-col-stack { display: flex; flex-direction: column; gap: 16px; }
@media (max-width: 780px) { .kco-fulldetail-top-row { grid-template-columns: 1fr; } }
.kco-fulldetail-card { background: var(--kco-card-bg); border: 1px solid var(--kco-border); border-radius: var(--kco-radius); padding: 20px; box-shadow: var(--kco-shadow); }
.kco-fulldetail-card h3 { margin: 0 0 12px; font-size: 1rem; color: var(--kco-primary-dark); border-bottom: 2px solid var(--kco-bg); padding-bottom: 8px; }
.kco-fulldetail-grid .kco-detail-row { flex-direction: column; gap: 2px; padding: 8px 0; }
.kco-fulldetail-grid .kco-detail-label { min-width: 0; font-size: 0.78rem; }
.kco-fulldetail-grid .kco-detail-value { font-size: 0.94rem; font-weight: 500; }

/* --- کارت لینک به صفحه‌ی جزئیات کامل (داخل صفحه‌ی ارزیابی) --- */
.kco-fulldetail-link-card {
	display: flex; align-items: center; gap: 14px;
	background: var(--kco-card-bg); border: 1px solid var(--kco-border); border-radius: var(--kco-radius);
	padding: 16px 20px; margin-bottom: 8px; box-shadow: var(--kco-shadow); flex-wrap: wrap;
}
.kco-fulldetail-link-icon { font-size: 1.8rem; }
.kco-fulldetail-link-text { flex: 1; min-width: 160px; }
.kco-fulldetail-link-text p { margin: 2px 0 0; font-size: 0.8rem; color: var(--kco-text-muted); }
.kco-fulldetail-link-note { font-size: 0.78rem; color: var(--kco-text-muted); margin: 0 0 18px; }

/* ===================================================================
   لیست شکیل طرح‌های در انتظار (پنل ارزیاب) - نوار ابزار + جدول رنگی
   =================================================================== */
.kco-list-toolbar {
	display: flex; align-items: center; gap: 12px; flex-wrap: wrap;
	margin-bottom: 14px; padding: 12px 16px;
	background: var(--kco-card-bg); border: 1px solid var(--kco-border);
	border-radius: var(--kco-radius); box-shadow: var(--kco-shadow);
}
.kco-list-search {
	flex: 1; min-width: 220px; padding: 9px 14px;
	border: 1px solid var(--kco-border); border-radius: 999px;
	font-family: inherit; font-size: 0.88rem;
}
.kco-list-search:focus { outline: none; border-color: var(--kco-primary); box-shadow: 0 0 0 3px rgba(37,99,235,0.12); }
.kco-list-filter { padding: 9px 14px; border: 1px solid var(--kco-border); border-radius: 999px; font-family: inherit; font-size: 0.85rem; background: var(--kco-bg); }
.kco-list-count { font-size: 0.8rem; color: var(--kco-text-muted); white-space: nowrap; margin-inline-start: auto; }

.kco-fancy-table-wrap { overflow-x: auto; border-radius: var(--kco-radius); box-shadow: var(--kco-shadow); }
.kco-fancy-table { width: 100%; border-collapse: collapse; background: var(--kco-card-bg); }
.kco-fancy-table thead th {
	background: linear-gradient(180deg, #eef2ff, #e0e7ff);
	color: #3730a3; font-weight: 700; font-size: 0.8rem;
	padding: 12px 16px; text-align: right; white-space: nowrap;
	border-bottom: 2px solid #c7d2fe;
}
.kco-fancy-table tbody tr { transition: background .12s ease; border-bottom: 1px solid var(--kco-border); }
.kco-fancy-table tbody tr:nth-child(even) { background: #fafbff; }
.kco-fancy-table tbody tr:hover { background: #eef2ff; }
.kco-fancy-table td { padding: 12px 16px; font-size: 0.88rem; vertical-align: middle; }
.kco-fancy-id { font-weight: 700; color: var(--kco-primary-dark); font-family: monospace, inherit; white-space: nowrap; }
.kco-fancy-title { font-weight: 600; }
.kco-fancy-muted { color: var(--kco-text-muted); }

.kco-event-chip {
	display: inline-block; padding: 4px 10px; border-radius: 999px;
	background: #f0fdf4; color: #166534; border: 1px solid #bbf7d0;
	font-size: 0.76rem; font-weight: 600; white-space: nowrap;
}
.kco-founder-cell { display: flex; align-items: center; gap: 8px; }
.kco-founder-avatar {
	width: 26px; height: 26px; border-radius: 50%; flex-shrink: 0;
	background: linear-gradient(135deg, var(--kco-primary), var(--kco-primary-dark));
	color: #fff; display: flex; align-items: center; justify-content: center;
	font-size: 0.76rem; font-weight: 700;
}
.kco-ai-score-pill { display: inline-block; padding: 4px 12px; border-radius: 999px; font-size: 0.78rem; font-weight: 700; white-space: nowrap; }
.kco-ai-score-high { background: #dcfce7; color: #166534; }
.kco-ai-score-mid  { background: #fef9c3; color: #854d0e; }
.kco-ai-score-low  { background: #fee2e2; color: #991b1b; }

/* ===================================================================
   صفحه‌ی ویرایش طرح (کسب‌وکار) - طراحی حرفه‌ای‌تر
   =================================================================== */
.kco-edit-hero {
	display: flex; align-items: center; justify-content: space-between; gap: 16px;
	background: var(--kco-card-bg); border: 1px solid var(--kco-border);
	border-inline-start: 5px solid var(--kco-primary);
	border-radius: var(--kco-radius); padding: 18px 24px; margin-bottom: 16px;
	box-shadow: var(--kco-shadow); flex-wrap: wrap;
}
.kco-edit-hero h2 { margin: 0 0 4px; }
.kco-edit-hero-title { margin: 0; color: var(--kco-text-muted); font-size: 0.9rem; }
.kco-edit-request-notice { background: #fef2f2; color: #991b1b; border: 1px solid #fecaca; }

.kco-edit-card { background: var(--kco-card-bg); border: 1px solid var(--kco-border); border-radius: var(--kco-radius); padding: 20px 24px; margin-bottom: 16px; box-shadow: var(--kco-shadow); }
.kco-edit-card-title { margin: 0 0 16px; font-size: 1rem; color: var(--kco-primary-dark); padding-bottom: 10px; border-bottom: 2px solid var(--kco-bg); }
.kco-edit-card-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); gap: 16px 20px; }
.kco-edit-field-wide { grid-column: 1 / -1; }
.kco-edit-field label { display: block; font-weight: 600; font-size: 0.85rem; margin-bottom: 6px; color: var(--kco-text); }
.kco-edit-field input[type=text], .kco-edit-field textarea, .kco-edit-field select {
	width: 100%; box-sizing: border-box; padding: 9px 12px;
	border: 1px solid var(--kco-border); border-radius: 8px; font-family: inherit; font-size: 0.9rem;
	background: var(--kco-bg);
	transition: border-color .15s ease, box-shadow .15s ease;
}
.kco-edit-field input[type=text]:focus, .kco-edit-field textarea:focus, .kco-edit-field select:focus {
	outline: none; border-color: var(--kco-primary); background: #fff;
	box-shadow: 0 0 0 3px rgba(37,99,235,0.12);
}
.kco-edit-radio-group { display: flex; flex-wrap: wrap; gap: 12px; }
.kco-edit-radio-option { display: inline-flex; align-items: center; gap: 6px; font-size: 0.86rem; font-weight: 400; padding: 7px 12px; border: 1px solid var(--kco-border); border-radius: 999px; background: var(--kco-bg); cursor: pointer; }
.kco-edit-radio-option:has(input:checked) { border-color: var(--kco-primary); background: #eff6ff; color: var(--kco-primary-dark); font-weight: 600; }

.kco-edit-save-bar { position: sticky; bottom: 0; background: var(--kco-card-bg); padding: 14px 20px; border: 1px solid var(--kco-border); border-radius: var(--kco-radius); box-shadow: var(--kco-shadow-lg); display: flex; align-items: center; gap: 12px; }
#kco-edit-save-status { font-size: 0.85rem; font-weight: 600; }

/* ===================================================================
   دستیار هوشمند تکمیل فرم ثبت طرح
   =================================================================== */
.kco-ai-assist-box {
	display: flex;
	align-items: center;
	gap: 16px;
	background: linear-gradient(135deg, #f3e8ff 0%, #ede9fe 100%);
	border: 1px solid #ddd6fe;
	border-radius: var(--kco-radius);
	padding: 16px 22px;
	margin-bottom: 24px;
}
.kco-ai-assist-box-icon {
	flex-shrink: 0;
	width: 40px; height: 40px;
	border-radius: 10px;
	background: linear-gradient(135deg, #7c3aed, #2563eb);
	color: #fff;
	display: flex; align-items: center; justify-content: center;
}
.kco-ai-assist-box-text { flex: 1; min-width: 180px; }
.kco-ai-assist-box-text strong { display: block; font-size: 1.02rem; color: #5b21b6; margin-bottom: 2px; }
.kco-ai-assist-box-text p { margin: 0; font-size: 0.85rem; color: #6d28d9; }
.kco-ai-assist-open-btn {
	flex-shrink: 0;
	background: linear-gradient(135deg, #7c3aed, #2563eb);
	color: #fff !important;
	border: none;
	font-weight: 700;
}
.kco-ai-assist-open-btn:hover { opacity: 0.92; }

.kco-ai-modal {
	position: fixed;
	inset: 0;
	background: rgba(15, 23, 42, 0.55);
	z-index: 400;
	align-items: center;
	justify-content: center;
	padding: 20px;
}
.kco-ai-modal.open { display: flex; }
.kco-ai-chat-bubble {
	background: #ede9fe;
	border: 1px solid #ddd6fe;
	color: #4c1d95;
	border-radius: 14px 14px 14px 4px;
	padding: 12px 16px;
	font-size: 0.86rem;
	line-height: 1.9;
	margin-bottom: 16px;
}

/* ===================================================================
   درخواست حذف طرح
   =================================================================== */
.kco-btn-danger-outline {
	background: transparent;
	color: var(--kco-danger) !important;
	border: 1px solid #fecaca;
}
.kco-btn-danger-outline:hover { background: #fef2f2; border-color: var(--kco-danger); }
.kco-plan-delete-pending {
	font-size: 0.78rem;
	color: #92400e;
	background: #fef3c7;
	border: 1px solid #fde68a;
	border-radius: 999px;
	padding: 6px 12px;
	white-space: nowrap;
}
.kco-ai-pending-notice { background: #f3e8ff; color: #5b21b6; border: 1px solid #ddd6fe; }
.kco-ai-modal-box {
	direction: rtl;
	font-family: "Vazirmatn", "IRANSans", -apple-system, sans-serif;
	position: relative;
	background: var(--kco-card-bg);
	border-radius: 18px;
	width: 640px;
	max-width: 100%;
	max-height: 88vh;
	overflow-y: auto;
	padding: 26px 26px 22px;
	box-shadow: var(--kco-shadow-lg);
}
.kco-ai-modal-close {
	position: absolute; top: 14px; inset-inline-end: 16px;
	background: none; border: none; font-size: 1.6rem; line-height: 1;
	cursor: pointer; color: var(--kco-text-muted);
}
.kco-ai-modal-close:hover { color: var(--kco-text); }
.kco-ai-modal-header { margin-bottom: 18px; }
.kco-ai-modal-badge {
	display: inline-block; padding: 4px 12px; border-radius: 999px;
	background: linear-gradient(120deg, #6d28d9, #2563eb); color: #fff;
	font-size: 0.76rem; font-weight: 700; margin-bottom: 8px;
}
.kco-ai-modal-header h3 { margin: 0; font-size: 1.2rem; }

.kco-ai-step-hint { color: var(--kco-text-muted); font-size: 0.86rem; margin: 0 0 14px; line-height: 1.9; }
#kco-ai-description {
	width: 100%; box-sizing: border-box; padding: 12px 14px; border: 1px solid var(--kco-border);
	border-radius: 10px; font-family: inherit; font-size: 0.92rem; resize: vertical; background: var(--kco-bg);
}
#kco-ai-description:focus { outline: none; border-color: var(--kco-primary); background: #fff; box-shadow: 0 0 0 3px rgba(37,99,235,0.12); }

.kco-ai-file-row { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; margin-top: 14px; }
.kco-ai-file-label { cursor: pointer; margin: 0; }
#kco-ai-files { display: none; }
.kco-ai-file-note { font-size: 0.76rem; color: var(--kco-text-muted); }
.kco-ai-file-chips { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 10px; }
.kco-ai-chip {
	display: inline-flex; align-items: center; gap: 6px;
	background: var(--kco-bg); border: 1px solid var(--kco-border);
	border-radius: 999px; padding: 5px 12px; font-size: 0.8rem;
}
.kco-ai-chip-remove {
	background: none; border: none; cursor: pointer; color: var(--kco-danger);
	font-size: 1rem; line-height: 1; padding: 0;
}

.kco-ai-error { color: var(--kco-danger); font-size: 0.85rem; margin-top: 10px; min-height: 1em; }
.kco-ai-step-actions { margin-top: 18px; display: flex; justify-content: flex-end; gap: 10px; }

.kco-ai-spinner {
	width: 40px; height: 40px; margin: 10px auto 18px;
	border: 4px solid var(--kco-border); border-top-color: var(--kco-primary);
	border-radius: 50%; animation: kco-ai-spin 0.8s linear infinite;
}
#kco-ai-step-loading { text-align: center; color: var(--kco-text-muted); padding: 24px 0; }
@keyframes kco-ai-spin { to { transform: rotate(360deg); } }

.kco-ai-review-label { display: flex; align-items: center; gap: 6px; cursor: pointer; }
.kco-ai-review-checkbox { margin: 0; }
.kco-ai-review-field.kco-edit-field label.kco-ai-review-label { font-weight: 600; font-size: 0.85rem; margin-bottom: 6px; color: var(--kco-text); }
.kco-ai-review-actions { display: flex; gap: 10px; flex-wrap: wrap; margin-top: 18px; }
.kco-ai-review-note { font-size: 0.78rem; color: var(--kco-text-muted); margin-top: 10px; line-height: 1.8; }

.kco-ai-done-icon { font-size: 2.4rem; text-align: center; margin-bottom: 6px; }
#kco-ai-step-done { text-align: center; padding: 10px 0; }
#kco-ai-step-done p { color: var(--kco-text); margin-bottom: 16px; }

/* ورود/ثبت‌نام لازم است */
.kco-login-required {
	text-align: center;
	max-width: 420px;
	margin: 40px auto;
	padding: 36px 30px;
	background: var(--kco-card-bg);
	border: 1px solid var(--kco-border);
	border-radius: var(--kco-radius);
	box-shadow: var(--kco-shadow);
}
.kco-login-required-icon { font-size: 2.2rem; margin-bottom: 10px; }
.kco-login-required h3 { margin: 0 0 8px; }
.kco-login-required p { color: var(--kco-text-muted); margin: 0 0 18px; font-size: 0.9rem; }
.kco-login-required .kco-btn { display: inline-flex; padding: 10px 28px; }
