/* Operations dashboard — Umrah Hosting branded */
@import url("brand.css");

:root {
	--utl-brand: #0F3D28;
	--utl-brand-light: #247A4D;
	--utl-accent: #C4A35A;
	--utl-bg: #F6F9F7;
	--utl-card: #fff;
	--utl-border: #D9E5DE;
	--utl-text: #1A1A1A;
	--utl-muted: #5C6B63;
	--utl-warn: #9A6B1F;
	--utl-success: #1B5E3B;
}

.utl-ops {
	max-width: 1280px;
	margin: 0 auto 48px;
	color: var(--utl-text);
	font-size: 15px;
	line-height: 1.5;
}

.utl-ops-header {
	display: flex;
	flex-wrap: wrap;
	justify-content: space-between;
	gap: 16px;
	align-items: flex-start;
	margin-bottom: 20px;
	padding: 24px 28px;
	background: linear-gradient(135deg, var(--uh-green-dark) 0%, var(--uh-green) 55%, var(--uh-green-mid) 100%);
	border-radius: 14px;
	color: #fff;
}

.utl-ops-kicker {
	margin: 0 0 4px;
	font-size: 12px;
	text-transform: uppercase;
	letter-spacing: 0.08em;
	opacity: 0.85;
}

.utl-ops-header h2 {
	margin: 0;
	font-size: 28px;
	font-weight: 700;
	color: #fff;
}

.utl-ops-sub {
	margin: 8px 0 0;
	opacity: 0.9;
	font-size: 14px;
}

.utl-ops-header-actions {
	display: flex;
	flex-wrap: wrap;
	gap: 8px;
}

.utl-btn {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	gap: 6px;
	padding: 10px 16px;
	border-radius: 8px;
	border: none;
	font-size: 14px;
	font-weight: 600;
	cursor: pointer;
	text-decoration: none;
	line-height: 1.2;
	transition: background 0.15s, color 0.15s;
}

.utl-btn-primary { background: var(--utl-accent); color: var(--utl-brand); }
.utl-btn-primary:hover { background: #e6b000; color: var(--utl-brand); }
.utl-btn-outline { background: transparent; border: 1px solid rgba(255,255,255,0.55); color: #fff; }
.utl-btn-outline:hover { background: rgba(255,255,255,0.12); color: #fff; }
.utl-btn-ghost { background: rgba(255,255,255,0.14); color: #fff; }
.utl-btn-ghost:hover { background: rgba(255,255,255,0.22); color: #fff; }
.utl-btn-wa { background: #25d366; color: #fff; }
.utl-btn-wa:hover { background: #1da851; color: #fff; }
.utl-btn-sm { padding: 6px 12px; font-size: 12px; }

.utl-flash {
	padding: 12px 16px;
	border-radius: 8px;
	margin-bottom: 16px;
	font-weight: 600;
}
.utl-flash-success { background: #d1fae5; color: #065f46; }

.utl-alert {
	padding: 12px 16px;
	border-radius: 8px;
	margin-bottom: 16px;
	display: flex;
	flex-wrap: wrap;
	gap: 8px;
	align-items: center;
}
.utl-alert-warn { background: #fffbeb; border: 1px solid #fcd34d; color: #92400e; }
.utl-alert a { font-weight: 700; }

.utl-log-panel {
	background: var(--utl-card);
	border: 1px solid var(--utl-border);
	border-radius: 12px;
	padding: 18px 20px;
	margin-bottom: 18px;
	box-shadow: 0 1px 2px rgba(0,0,0,0.04);
}

.utl-log-panel-head {
	display: flex;
	justify-content: space-between;
	align-items: center;
	margin-bottom: 12px;
}
.utl-log-panel-head h3 { margin: 0; font-size: 16px; }
.utl-log-panel-head span { color: var(--utl-muted); font-size: 12px; }

.utl-log-row {
	display: flex;
	flex-wrap: wrap;
	gap: 8px;
	margin-bottom: 8px;
}
.utl-log-row textarea { flex: 1 1 240px; min-width: 200px; }

.utl-input {
	padding: 10px 12px;
	border: 1px solid var(--utl-border);
	border-radius: 8px;
	font-size: 14px;
	background: #fff;
	box-sizing: border-box;
}
.utl-input-sm { padding: 7px 10px; font-size: 13px; }

.utl-ops-toolbar {
	display: flex;
	gap: 8px;
	align-items: center;
	margin-bottom: 16px;
}

.utl-stat-grid {
	display: grid;
	grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
	gap: 12px;
	margin-bottom: 20px;
}

.utl-stat-card {
	background: var(--utl-card);
	border: 1px solid var(--utl-border);
	border-radius: 12px;
	padding: 16px;
	box-shadow: 0 1px 2px rgba(0,0,0,0.04);
}
.utl-stat-label { display: block; font-size: 12px; color: var(--utl-muted); text-transform: uppercase; letter-spacing: 0.04em; }
.utl-stat-value { display: block; font-size: 26px; font-weight: 700; color: var(--utl-brand); line-height: 1.2; margin: 4px 0; }
.utl-stat-card small { color: var(--utl-muted); font-size: 12px; }
.utl-stat-warn .utl-stat-value { color: var(--utl-warn); }
.utl-stat-money .utl-stat-value { color: var(--utl-success); }

.utl-ops-layout {
	display: grid;
	grid-template-columns: 1fr 320px;
	gap: 20px;
	align-items: start;
}

.utl-panel {
	background: var(--utl-card);
	border: 1px solid var(--utl-border);
	border-radius: 12px;
	margin-bottom: 16px;
	overflow: hidden;
	box-shadow: 0 1px 2px rgba(0,0,0,0.04);
}

.utl-panel-head {
	display: flex;
	flex-wrap: wrap;
	justify-content: space-between;
	align-items: center;
	gap: 10px;
	padding: 14px 16px;
	border-bottom: 1px solid var(--utl-border);
	background: #fafafa;
}
.utl-panel-head h3 { margin: 0; font-size: 15px; }

.utl-panel-queue { border-color: #fcd34d; }
.utl-panel-queue .utl-panel-head { background: #fffbeb; }

.utl-queue-list { padding: 8px 12px; }
.utl-queue-item {
	display: flex;
	justify-content: space-between;
	gap: 12px;
	padding: 12px 8px;
	border-bottom: 1px solid var(--utl-border);
}
.utl-queue-item:last-child { border-bottom: none; }
.utl-queue-item small { display: block; color: var(--utl-muted); margin-top: 2px; }
.utl-queue-msg { margin: 6px 0 0; font-size: 13px; color: var(--utl-text); }
.utl-queue-actions { display: flex; flex-direction: column; gap: 6px; align-items: flex-end; }

.utl-lead-filters { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; }

.utl-table-wrap { overflow-x: auto; }
.utl-table { width: 100%; border-collapse: collapse; font-size: 13px; }
.utl-table th, .utl-table td { padding: 10px 12px; border-bottom: 1px solid var(--utl-border); vertical-align: top; text-align: left; }
.utl-table th { background: #f9fafb; font-size: 12px; text-transform: uppercase; letter-spacing: 0.03em; color: var(--utl-muted); }
.utl-table-compact th, .utl-table-compact td { padding: 8px 10px; }
.utl-empty { text-align: center; color: var(--utl-muted); padding: 24px !important; }

.utl-actions-cell { min-width: 220px; }
.utl-inline-form { display: flex; flex-wrap: wrap; gap: 4px; margin-bottom: 4px; align-items: center; }
.utl-inline-form select { max-width: 140px; font-size: 12px; }

.utl-badge { display: inline-block; padding: 2px 8px; border-radius: 999px; font-size: 11px; font-weight: 700; color: #fff; }
.utl-badge-umrah { background: #2271b1; }
.utl-badge-taxi { background: #d97706; }

.utl-pill { display: inline-block; padding: 2px 8px; border-radius: 999px; font-size: 11px; font-weight: 600; background: #eee; }
.utl-pill-new { background: #dbeafe; color: #1e40af; }
.utl-pill-assigned { background: #fef3c7; color: #92400e; }
.utl-pill-contacted { background: #e0e7ff; color: #3730a3; }
.utl-pill-confirmed { background: #d1fae5; color: #065f46; }
.utl-pill-completed { background: #d1fae5; color: #065f46; }
.utl-pill-cancelled { background: #fee2e2; color: #991b1b; }

.utl-row-overdue { background: #fffbeb !important; }
.utl-tag-overdue { display: inline-block; margin-left: 4px; padding: 1px 6px; border-radius: 4px; font-size: 10px; background: #fef3c7; color: #92400e; font-weight: 700; }

.utl-pagination { display: flex; flex-wrap: wrap; gap: 6px; padding: 12px 16px; }
.utl-page {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	min-width: 32px;
	height: 32px;
	padding: 0 8px;
	border-radius: 6px;
	border: 1px solid var(--utl-border);
	text-decoration: none;
	color: var(--utl-text);
	font-size: 13px;
}
.utl-page.is-active { background: var(--utl-brand); color: #fff; border-color: var(--utl-brand); }

.utl-side-list { list-style: none; margin: 0; padding: 8px 16px 16px; }
.utl-side-list li { padding: 10px 0; border-bottom: 1px solid var(--utl-border); }
.utl-side-list li:last-child { border-bottom: none; }
.utl-side-list span { display: block; font-size: 14px; }
.utl-side-list small { color: var(--utl-muted); }

.utl-capacity-row { padding: 10px 16px 14px; border-bottom: 1px solid var(--utl-border); }
.utl-capacity-row:last-child { border-bottom: none; }
.utl-capacity-meta { display: flex; justify-content: space-between; gap: 8px; font-size: 13px; margin-bottom: 6px; }
.utl-progress { height: 6px; background: #e5e7eb; border-radius: 999px; overflow: hidden; }
.utl-progress span { display: block; height: 100%; background: linear-gradient(90deg, var(--utl-brand-light), var(--utl-accent)); border-radius: 999px; }

.utl-bar-row { display: grid; grid-template-columns: 1fr 1fr auto; gap: 8px; align-items: center; padding: 8px 16px; font-size: 13px; }
.utl-bar { height: 8px; background: #eef2f7; border-radius: 999px; overflow: hidden; }
.utl-bar i { display: block; height: 100%; background: var(--utl-brand-light); border-radius: 999px; }

/* Legacy grid helpers */
.utl-dashboard { max-width: 1280px; margin: 0 auto 40px; }
.utl-cards { display: grid; grid-template-columns: repeat(auto-fill, minmax(140px, 1fr)); gap: 12px; margin: 20px 0; }
.utl-card-mini { background: #fff; border: 1px solid var(--utl-border); border-radius: 8px; padding: 14px; text-align: center; }
.utl-card-mini strong { display: block; font-size: 22px; color: var(--utl-success); }
.utl-card-mini span { font-size: 12px; color: var(--utl-muted); }
.utl-card-warn strong { color: var(--utl-warn); }
.utl-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 20px; margin: 24px 0; }
.utl-grid-item { background: #fff; border: 1px solid var(--utl-border); border-radius: 8px; overflow: hidden; padding-bottom: 14px; }
.utl-grid-item img { width: 100%; height: auto; display: block; }
.utl-grid-item h3 { font-size: 17px; margin: 12px 14px 6px; }
.utl-grid-item .utl-price { color: var(--utl-success); font-weight: 700; margin: 0 14px; }
.utl-grid-item .utl-meta { color: var(--utl-muted); font-size: 13px; margin: 4px 14px; }
.utl-grid-btn { display: inline-block; margin: 4px 0 0; background: var(--utl-brand); color: #fff !important; padding: 6px 12px; border-radius: 6px; text-decoration: none; border: none; cursor: pointer; font-size: 12px; }
.utl-grid-btn:hover { background: var(--uh-green-dark); color: var(--uh-gold-bright); }
.utl-submit-btn { background: var(--utl-brand); color: #fff; border: none; padding: 10px 18px; border-radius: 8px; cursor: pointer; font-weight: 600; }
.utl-submit-btn:hover { background: var(--uh-green-dark); color: var(--uh-gold-bright); }
.utl-error { color: #991b1b; background: #fee2e2; padding: 12px; border-radius: 8px; }
.utl-portal-login { max-width: 420px; }

.utl-dashboard-provider .utl-stat-grid { margin-top: 16px; }

@media (max-width: 960px) {
	.utl-ops-layout { grid-template-columns: 1fr; }
	.utl-ops-header { padding: 18px; }
	.utl-ops-header h2 { font-size: 22px; }
}

/* wp-admin embed */
.utl-wrap .utl-ops { max-width: none; }
.utl-wrap .utl-ops-header { margin-top: 10px; }

/* View tabs */
.utl-view-tabs { display: flex; gap: 8px; margin-bottom: 16px; flex-wrap: wrap; }
.utl-view-tab {
	padding: 8px 16px;
	border-radius: 999px;
	border: 1px solid var(--utl-border);
	background: var(--utl-card);
	color: var(--utl-text);
	text-decoration: none;
	font-size: 13px;
	font-weight: 600;
}
.utl-view-tab.is-active { background: var(--utl-brand); color: #fff; border-color: var(--utl-brand); }

/* Kanban */
.utl-kanban-board { display: grid; grid-template-columns: repeat(4, 1fr); gap: 12px; margin-bottom: 12px; }
.utl-kanban-col { background: var(--utl-card); border: 1px solid var(--utl-border); border-radius: 12px; min-height: 320px; display: flex; flex-direction: column; }
.utl-kanban-col-head { display: flex; justify-content: space-between; padding: 12px 14px; border-bottom: 1px solid var(--utl-border); background: #fafafa; border-radius: 12px 12px 0 0; }
.utl-kanban-col-head h3 { margin: 0; font-size: 14px; }
.utl-kanban-col-body { flex: 1; padding: 10px; min-height: 120px; }
.utl-kanban-col-body.is-drag-over { background: rgba(3,139,143,0.08); outline: 2px dashed var(--utl-brand-light); }
.utl-kanban-card { background: #fff; border: 1px solid var(--utl-border); border-radius: 8px; padding: 10px; margin-bottom: 8px; cursor: grab; box-shadow: 0 1px 2px rgba(0,0,0,0.04); }
.utl-kanban-card.is-dragging { opacity: 0.5; }
.utl-kanban-title { font-weight: 700; color: var(--utl-brand); text-decoration: none; display: block; margin-bottom: 4px; }
.utl-kanban-meta { display: flex; gap: 6px; align-items: center; margin-top: 6px; }
.utl-kanban-snippet { font-size: 12px; color: var(--utl-muted); margin: 6px 0 0; }
.utl-kanban-hint { font-size: 12px; color: var(--utl-muted); margin-bottom: 24px; }

/* Calendar */
.utl-calendar-panel { margin-bottom: 24px; }
.utl-calendar-grid { padding: 8px 0; }
.utl-cal-hour { display: grid; grid-template-columns: 80px 1fr; gap: 12px; border-bottom: 1px solid var(--utl-border); padding: 10px 16px; align-items: start; }
.utl-cal-time { font-size: 12px; font-weight: 700; color: var(--utl-muted); padding-top: 4px; }
.utl-cal-event { background: #ecfdf5; border-left: 3px solid var(--utl-brand-light); padding: 8px 10px; border-radius: 6px; margin-bottom: 6px; }
.utl-cal-event a { text-decoration: none; color: var(--utl-text); }
.utl-cal-empty { color: var(--utl-muted); font-size: 12px; }

/* Modal */
.utl-modal { display: none; position: fixed; inset: 0; z-index: 100000; }
.utl-modal.is-open { display: block; }
.utl-modal-backdrop { position: absolute; inset: 0; background: rgba(0,0,0,0.5); }
.utl-modal-dialog {
	position: relative;
	max-width: 920px;
	width: calc(100% - 32px);
	max-height: calc(100vh - 48px);
	margin: 24px auto;
	background: var(--utl-card);
	border-radius: 14px;
	overflow: auto;
	box-shadow: 0 20px 60px rgba(0,0,0,0.25);
}
.utl-modal-close {
	position: absolute;
	top: 12px;
	right: 14px;
	z-index: 2;
	background: transparent;
	border: none;
	font-size: 28px;
	line-height: 1;
	cursor: pointer;
	color: var(--utl-muted);
}
.utl-modal-body { padding: 0; }
.utl-modal-inner { padding: 20px 24px 24px; }
.utl-modal-head { display: flex; justify-content: space-between; align-items: flex-start; gap: 12px; margin-bottom: 16px; padding-right: 36px; }
.utl-modal-head h3 { margin: 0 0 8px; }
.utl-modal-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; }
.utl-modal-section h4 { margin: 0 0 10px; font-size: 14px; }
.utl-dl { display: grid; grid-template-columns: 100px 1fr; gap: 6px 12px; font-size: 13px; margin: 0 0 16px; }
.utl-dl dt { color: var(--utl-muted); margin: 0; }
.utl-dl dd { margin: 0; }
.utl-modal-msg { font-size: 13px; background: #f9fafb; padding: 10px; border-radius: 8px; max-height: 160px; overflow: auto; }
.utl-modal-form label { display: block; margin-bottom: 12px; font-size: 13px; font-weight: 600; }
.utl-modal-form .utl-input { width: 100%; margin-top: 4px; }
.utl-modal-actions { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 8px; }
.utl-modal-commission { font-size: 13px; color: var(--utl-muted); margin-top: 12px; }
body.utl-modal-open { overflow: hidden; }
.utl-loading { padding: 40px; text-align: center; color: var(--utl-muted); }

/* Dark mode */
.utl-ops[data-utl-theme="dark"] {
	--utl-bg: #0f1419;
	--utl-card: #1a2228;
	--utl-border: #2d3748;
	--utl-text: #e5e7eb;
	--utl-muted: #9ca3af;
}
.utl-ops[data-utl-theme="dark"] .utl-panel-head,
.utl-ops[data-utl-theme="dark"] .utl-kanban-col-head,
.utl-ops[data-utl-theme="dark"] .utl-table th { background: #141b21; }
.utl-ops[data-utl-theme="dark"] .utl-kanban-card,
.utl-ops[data-utl-theme="dark"] .utl-input { background: #141b21; color: var(--utl-text); border-color: var(--utl-border); }
.utl-ops[data-utl-theme="dark"] .utl-modal-msg { background: #141b21; }
.utl-ops[data-utl-theme="dark"] .utl-cal-event { background: #1e3a3a; }
.utl-ops[data-utl-theme="dark"] .utl-flash-success { background: #064e3b; color: #a7f3d0; }
.utl-ops[data-utl-theme="dark"] .utl-alert-warn { background: #422006; border-color: #92400e; color: #fcd34d; }

/* Front admin + user dashboards */
.utl-dash-tabs {
	display: flex;
	flex-wrap: wrap;
	gap: 6px;
	margin: 0 0 20px;
	padding: 6px;
	background: var(--uh-green-soft, #E8F5EE);
	border-radius: 12px;
}
.utl-dash-tab {
	display: inline-flex;
	align-items: center;
	gap: 6px;
	padding: 10px 16px;
	border-radius: 8px;
	text-decoration: none;
	font-weight: 600;
	font-size: 14px;
	color: var(--uh-green-dark, #0F3D28);
	background: transparent;
}
.utl-dash-tab:hover { background: rgba(255,255,255,0.7); color: var(--uh-green-dark); }
.utl-dash-tab.is-active {
	background: var(--uh-green-dark, #0F3D28);
	color: #fff;
}
.utl-tab-count {
	display: inline-flex;
	min-width: 1.4em;
	padding: 0 6px;
	border-radius: 999px;
	background: var(--uh-gold, #C4A35A);
	color: #0F3D28;
	font-size: 11px;
	justify-content: center;
}
.utl-dash-tab.is-active .utl-tab-count { background: var(--uh-gold-bright); }
.utl-ops-quick {
	display: flex;
	flex-wrap: wrap;
	gap: 10px;
	margin: 0 0 24px;
}
.utl-quick-link {
	padding: 10px 14px;
	border-radius: 8px;
	border: 1px solid var(--uh-border);
	background: #fff;
	color: var(--uh-green-dark);
	font-weight: 600;
	font-size: 13px;
	text-decoration: none;
}
.utl-quick-link:hover {
	border-color: var(--uh-gold);
	background: var(--uh-gold-soft);
	color: var(--uh-green-dark);
}
.utl-ops-columns {
	display: grid;
	grid-template-columns: repeat(3, 1fr);
	gap: 16px;
	margin-bottom: 24px;
}
.utl-card-panel {
	background: #fff;
	border: 1px solid var(--uh-border);
	border-radius: 12px;
	padding: 18px 20px;
	box-shadow: 0 1px 0 rgba(15,61,40,0.04);
}
.utl-card-panel h3 {
	margin: 0 0 12px;
	font-family: var(--uh-font-display);
	font-size: 18px;
	color: var(--uh-green-dark);
}
.utl-dash-list {
	list-style: none;
	margin: 0;
	padding: 0;
}
.utl-dash-list li {
	display: flex;
	flex-wrap: wrap;
	align-items: baseline;
	gap: 8px 12px;
	padding: 10px 0;
	border-bottom: 1px solid var(--uh-border);
	font-size: 13px;
}
.utl-dash-list li:last-child { border-bottom: 0; }
.utl-dash-list small { color: var(--uh-muted); width: 100%; }
.utl-dash-list em { margin-left: auto; font-style: normal; font-weight: 700; color: var(--uh-green); }
.utl-dash-list-rich li {
	justify-content: space-between;
	align-items: center;
}
.utl-dash-list-rich li > div:first-child { flex: 1; }
.utl-user-gate-grid {
	display: grid;
	grid-template-columns: 1fr 1fr;
	gap: 20px;
	margin-top: 8px;
}
.utl-user-dash,
.utl-admin-front {
	font-family: var(--uh-font-body);
}
.utl-flash-error {
	background: #fef2f2;
	color: #991b1b;
	border: 1px solid #fecaca;
	padding: 12px 16px;
	border-radius: 8px;
	margin-bottom: 16px;
}
.utl-btn-outline {
	background: transparent;
	border: 1px solid rgba(255,255,255,0.55);
	color: #fff;
}
.utl-btn-sm { padding: 7px 12px; font-size: 13px; }

@media (max-width: 960px) {
	.utl-kanban-board { grid-template-columns: 1fr 1fr; }
	.utl-modal-grid { grid-template-columns: 1fr; }
	.utl-ops-columns { grid-template-columns: 1fr; }
	.utl-user-gate-grid { grid-template-columns: 1fr; }
}
@media (max-width: 600px) {
	.utl-kanban-board { grid-template-columns: 1fr; }
}
