:root {
	--brand-primary: #1e3a8a;
	--brand-primary-hover: #1d4ed8;
	--brand-accent: #dc2626;
	--brand-accent-soft: #fef2f2;
	--surface: #f8fafc;
	--surface-card: #ffffff;
	--border: #e2e8f0;
	--border-soft: #f1f5f9;
	--text: #0f172a;
	--text-muted: #64748b;
	--sidebar-bg: #0f172a;
	--sidebar-hover: #1e293b;
	--sidebar-active: #1e40af;
	--shadow-sm: 0 1px 2px rgba(15, 23, 42, 0.05);
	--shadow-md: 0 4px 16px rgba(15, 23, 42, 0.08);
	--shadow-lg: 0 12px 32px rgba(15, 23, 42, 0.12);
	--radius: 0.75rem;
	--radius-lg: 1rem;
	--font: 'Plus Jakarta Sans', system-ui, -apple-system, sans-serif;
}

* { box-sizing: border-box; }

body {
	font-family: var(--font);
	color: var(--text);
	background: var(--surface);
	-webkit-font-smoothing: antialiased;
}

body.layout-auth {
	background: linear-gradient(135deg, #0f172a 0%, #1e3a8a 50%, #1e40af 100%);
	min-height: 100vh;
}

body.layout-dashboard { background: var(--surface); }

body.layout-dashboard main { max-width: none; padding: 0; }

/* Buttons */
.btn {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	gap: 0.5rem;
	padding: 0.625rem 1.125rem;
	border-radius: var(--radius);
	font-size: 0.875rem;
	font-weight: 600;
	line-height: 1.25rem;
	border: 1px solid transparent;
	cursor: pointer;
	transition: all 0.15s ease;
	white-space: nowrap;
}
.btn:disabled { opacity: 0.55; cursor: not-allowed; }
.btn-primary { background: var(--brand-primary); color: #fff; }
.btn-primary:hover { background: var(--brand-primary-hover); }
.btn-secondary { background: #fff; color: var(--brand-primary); border-color: var(--border); }
.btn-secondary:hover { background: #f8fafc; border-color: #cbd5e1; }
.btn-danger { background: var(--brand-accent); color: #fff; }
.btn-danger:hover { background: #b91c1c; }
.btn-ghost { background: transparent; color: var(--text-muted); border-color: transparent; }
.btn-ghost:hover { background: #f1f5f9; color: var(--text); }
.btn-sm { padding: 0.4375rem 0.875rem; font-size: 0.8125rem; }
.btn-xs { padding: 0.25rem 0.5rem; font-size: 0.75rem; line-height: 1.2; min-height: 0; }
.btn-block { width: 100%; }

/* Cards */
.ui-card {
	background: var(--surface-card);
	border: 1px solid var(--border-soft);
	border-radius: var(--radius-lg);
	box-shadow: var(--shadow-sm);
}
.ui-card-hover:hover { box-shadow: var(--shadow-md); }
.ui-card-body { padding: 1.5rem; }
.ui-card-header {
	padding: 1rem 1.5rem;
	border-bottom: 1px solid var(--border-soft);
	font-weight: 600;
	color: var(--text);
}
.ui-stat-card { padding: 1.5rem; display: flex; flex-direction: column; min-height: 100%; }
.ui-stat-label {
	font-size: 0.6875rem;
	font-weight: 700;
	letter-spacing: 0.06em;
	text-transform: uppercase;
	color: var(--text-muted);
}
.ui-stat-value { font-size: 2.25rem; font-weight: 800; line-height: 1.1; margin-top: 0.5rem; }

/* Forms */
.label {
	display: block;
	font-size: 0.8125rem;
	font-weight: 600;
	color: #475569;
	margin-bottom: 0.375rem;
}
.input, .select, .textarea {
	width: 100%;
	border: 1px solid var(--border);
	border-radius: var(--radius);
	padding: 0.625rem 0.875rem;
	font-size: 0.875rem;
	background: #fff;
	color: var(--text);
	transition: border-color 0.15s, box-shadow 0.15s;
}
.input:focus, .select:focus, .textarea:focus {
	outline: none;
	border-color: #93c5fd;
	box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.15);
}

/* Badges */
.badge {
	display: inline-flex;
	align-items: center;
	padding: 0.25rem 0.75rem;
	border-radius: 9999px;
	font-size: 0.8125rem;
	font-weight: 600;
}
.badge-gray { background: #f1f5f9; color: #475569; }
.badge-blue { background: #dbeafe; color: #1d4ed8; }
.badge-yellow { background: #fef3c7; color: #b45309; }
.badge-green { background: #dcfce7; color: #15803d; }
.badge-red { background: #fee2e2; color: #b91c1c; }
.badge-purple { background: #ede9fe; color: #6d28d9; }

/* Page */
.page-header { margin-bottom: 2rem; }
.page-title { font-size: 1.875rem; font-weight: 800; color: var(--brand-primary); letter-spacing: -0.02em; }
.page-subtitle { color: var(--text-muted); margin-top: 0.375rem; font-size: 0.9375rem; }

.painel-subtabs {
	display: flex;
	flex-wrap: wrap;
	gap: 0.5rem;
	border-bottom: 1px solid var(--border);
}
.painel-subtab-btn {
	appearance: none;
	border: none;
	background: transparent;
	color: #64748b;
	font-size: 1.375rem;
	font-weight: 600;
	padding: 0.875rem 1.5rem;
	margin-bottom: -1px;
	border-bottom: 3px solid transparent;
	cursor: pointer;
	transition: color 0.15s ease, border-color 0.15s ease;
}
.painel-subtab-btn:hover {
	color: var(--brand-primary);
}
.painel-subtab-btn.painel-subtab-active {
	color: var(--brand-primary);
	border-bottom-color: var(--brand-primary);
}

.projetos-grid .projetos-card-header {
	text-align: center;
}
.projetos-grid .projetos-card-desc {
	text-align: center;
}

/* Utilities */
.hidden { display: none !important; }

/* Tables */
.data-table { width: 100%; font-size: 0.875rem; border-collapse: collapse; }
.data-table thead { background: #f8fafc; }
.data-table th {
	padding: 0.75rem 1rem;
	text-align: left;
	font-size: 0.75rem;
	font-weight: 700;
	text-transform: uppercase;
	letter-spacing: 0.04em;
	color: #475569;
	border-bottom: 1px solid var(--border);
}
.data-table th.text-right,
.data-table td.text-right {
	text-align: right;
}
.data-table th.sdwan-actions-col,
.data-table td.sdwan-actions-col {
	text-align: left;
	white-space: nowrap;
}
.data-table td {
	padding: 0.75rem 1rem;
	border-bottom: 1px solid var(--border-soft);
	color: #334155;
}
.data-table tbody tr:hover { background: #f8fafc; }
.data-table .sdwan-image-cell {
	width: 4.5rem;
	max-width: 4.5rem;
	vertical-align: middle;
}
.sdwan-table-thumb {
	display: block;
	width: 3rem;
	height: 3rem;
	max-width: 3rem;
	max-height: 3rem;
	object-fit: cover;
	border-radius: 0.375rem;
	border: 1px solid var(--border);
}
.sdwan-source-badge {
	display: inline-block;
	padding: 0.125rem 0.5rem;
	border-radius: 9999px;
	font-size: 0.75rem;
	font-weight: 600;
}
.sdwan-source-dashboard {
	background: #dbeafe;
	color: #1d4ed8;
}
.sdwan-source-public {
	background: #fef3c7;
	color: #b45309;
}
.sdwan-warning-badge {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	margin-left: 0.25rem;
	width: 1rem;
	height: 1rem;
	border-radius: 9999px;
	background: #fef3c7;
	color: #b45309;
	font-size: 0.65rem;
	font-weight: 700;
	vertical-align: middle;
}
.sdwan-goal-bar {
	height: 0.75rem;
	border-radius: 9999px;
	background: #e2e8f0;
	overflow: hidden;
}
.sdwan-page-header {
	display: flex;
	flex-direction: column;
	align-items: center;
	gap: 1.25rem;
	text-align: center;
}
.sdwan-action-panel {
	width: 100%;
	max-width: 56rem;
}
.sdwan-action-group {
	border: 1px solid #e2e8f0;
	border-radius: 0.75rem;
	padding: 0.75rem 1rem;
	background: #fff;
	box-shadow: 0 1px 2px rgba(15, 23, 42, 0.04);
}
.sdwan-action-group-title {
	font-size: 0.6875rem;
	font-weight: 700;
	letter-spacing: 0.06em;
	text-transform: uppercase;
	color: #64748b;
	margin-bottom: 0.625rem;
	text-align: center;
}
.sdwan-action-group-buttons {
	display: flex;
	flex-wrap: wrap;
	gap: 0.5rem;
	justify-content: center;
}
.sdwan-file-chips {
	display: flex;
	flex-wrap: wrap;
	gap: 0.5rem;
	justify-content: center;
	margin-top: 0.875rem;
}
.sdwan-file-chip {
	display: inline-flex;
	align-items: center;
	font-size: 0.75rem;
	font-weight: 500;
	padding: 0.3rem 0.75rem;
	border-radius: 9999px;
	border: 1px solid #e2e8f0;
	background: #f8fafc;
	color: #64748b;
}
.sdwan-file-chip-ok {
	background: #ecfdf5;
	border-color: #a7f3d0;
	color: #047857;
}
.sdwan-file-chip-empty {
	background: #f8fafc;
	border-color: #e2e8f0;
	color: #64748b;
}
.sdwan-goal-kpis {
	display: grid;
	grid-template-columns: repeat(3, minmax(0, 1fr));
	gap: 0.75rem;
	margin-bottom: 1rem;
}
.sdwan-goal-kpi {
	text-align: center;
	padding: 0.75rem 0.5rem;
	border-radius: 0.625rem;
	background: #f8fafc;
	border: 1px solid #e2e8f0;
}
.sdwan-goal-kpi .ui-stat-label {
	margin-bottom: 0.25rem;
}
.sdwan-goal-kpi-value {
	font-size: 1.75rem;
	font-weight: 800;
	line-height: 1.1;
}
.sdwan-section-title {
	font-size: 0.6875rem;
	font-weight: 700;
	letter-spacing: 0.06em;
	text-transform: uppercase;
	color: #64748b;
	margin-bottom: 0.75rem;
}
@media (max-width: 639px) {
	.sdwan-goal-kpis {
		grid-template-columns: 1fr;
	}
}
.sdwan-goal-bar-fill {
	height: 100%;
	background: linear-gradient(90deg, #059669, #10b981);
	border-radius: 9999px;
	transition: width 0.3s ease;
}
.sdwan-subtabs {
	display: flex;
	flex-wrap: wrap;
	gap: 0.5rem;
	justify-content: center;
	border-bottom: 1px solid #e2e8f0;
	padding-bottom: 0.25rem;
}
.sdwan-subtab {
	font-size: 0.875rem;
	font-weight: 600;
	color: #64748b;
	background: transparent;
	border: none;
	border-bottom: 2px solid transparent;
	padding: 0.5rem 1rem;
	margin-bottom: -1px;
	cursor: pointer;
	transition: color 0.15s ease, border-color 0.15s ease;
}
.sdwan-subtab:hover {
	color: #334155;
}
.sdwan-subtab-active {
	color: #1d4ed8;
	border-bottom-color: #1d4ed8;
}
.sdwan-alert-banner {
	border: 1px solid #fcd34d;
	background: #fffbeb;
	border-radius: 0.75rem;
	overflow: hidden;
}
.sdwan-alert-banner-btn {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	justify-content: space-between;
	gap: 0.5rem;
	width: 100%;
	padding: 0.75rem 1rem;
	background: transparent;
	border: none;
	cursor: pointer;
	text-align: left;
	font: inherit;
	color: #92400e;
}
.sdwan-alert-banner-btn:hover {
	background: #fef3c7;
}
.sdwan-alert-banner-action {
	font-size: 0.8125rem;
	font-weight: 600;
	color: #b45309;
	text-decoration: underline;
	text-underline-offset: 2px;
}
.sdwan-filter-chips {
	display: flex;
	flex-wrap: wrap;
	gap: 0.5rem;
}
.sdwan-filter-chip {
	display: inline-flex;
	align-items: center;
	gap: 0.25rem;
	font-size: 0.75rem;
	font-weight: 500;
	padding: 0.3rem 0.65rem;
	border-radius: 9999px;
	border: 1px solid #bfdbfe;
	background: #eff6ff;
	color: #1d4ed8;
	cursor: pointer;
}
.sdwan-filter-chip:hover {
	background: #dbeafe;
}
.sdwan-entry-modal {
	max-width: 56rem;
	width: calc(100% - 2rem);
}
.sdwan-ticket-modal {
	max-width: 56rem;
	width: calc(100% - 2rem);
}
.sdwan-ticket-view-active {
	font-weight: 600;
}
.sdwan-ticket-board-title {
	font-size: 0.8rem;
	font-weight: 700;
	letter-spacing: 0.04em;
	text-transform: uppercase;
	color: #475569;
}
.sdwan-ticket-status-grid,
.sdwan-ticket-special-grid {
	display: grid;
	gap: 0.75rem;
}
.sdwan-ticket-status-grid {
	grid-template-columns: repeat(2, minmax(0, 1fr));
}
.sdwan-ticket-special-grid {
	grid-template-columns: repeat(1, minmax(0, 1fr));
}
@media (min-width: 640px) {
	.sdwan-ticket-status-grid {
		grid-template-columns: repeat(3, minmax(0, 1fr));
	}
	.sdwan-ticket-special-grid {
		grid-template-columns: repeat(3, minmax(0, 1fr));
	}
}
@media (min-width: 1024px) {
	.sdwan-ticket-status-grid {
		grid-template-columns: repeat(6, minmax(0, 1fr));
	}
}
.sdwan-ticket-status-card {
	display: flex;
	flex-direction: column;
	justify-content: center;
	align-items: center;
	min-height: 5.25rem;
	padding: 0.75rem 0.5rem;
	border: 2px solid transparent;
	border-radius: 0.7rem;
	color: #fff;
	text-align: center;
	cursor: pointer;
	transition: transform 0.15s ease, box-shadow 0.15s ease, border-color 0.15s ease, opacity 0.15s ease;
	box-shadow: 0 1px 2px rgba(15, 23, 42, 0.12);
}
.sdwan-ticket-special-grid .sdwan-ticket-status-card {
	min-height: 4.75rem;
}
.sdwan-ticket-status-card:hover {
	transform: translateY(-1px);
	box-shadow: 0 6px 16px rgba(15, 23, 42, 0.18);
}
.sdwan-ticket-status-card.is-active {
	border-color: #0f172a;
	box-shadow: 0 0 0 2px rgba(15, 23, 42, 0.15);
}
.sdwan-ticket-status-card.is-zero {
	opacity: 0.72;
}
.sdwan-ticket-status-card.is-dark-text {
	color: #111827;
}
.sdwan-ticket-status-card-label {
	font-size: 0.74rem;
	line-height: 1.25;
	font-weight: 600;
	margin-bottom: 0.35rem;
	display: -webkit-box;
	-webkit-line-clamp: 2;
	-webkit-box-orient: vertical;
	overflow: hidden;
}
.sdwan-ticket-status-card-value {
	font-size: 1.75rem;
	line-height: 1;
	font-weight: 800;
}
.sdwan-ticket-active-filter {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 0.75rem;
	margin-top: 1rem;
	padding: 0.65rem 0.85rem;
	border-radius: 0.65rem;
	border: 1px solid #bfdbfe;
	background: #eff6ff;
	color: #1e3a8a;
	font-size: 0.875rem;
}
.sdwan-ticket-active-filter.hidden {
	display: none;
}
.sdwan-ticket-status-pill {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	min-width: 6.5rem;
	padding: 0.2rem 0.55rem;
	border-radius: 9999px;
	font-size: 0.75rem;
	font-weight: 600;
	line-height: 1.2;
	text-align: center;
}
.sdwan-ticket-status-pill.is-dark-text {
	color: #111827;
}
.sdwan-store-percent {
	display: inline-block;
	min-width: 2.5rem;
	font-weight: 600;
}
.sdwan-store-loja-btn {
	font: inherit;
	font-weight: 700;
	color: #1d4ed8;
	background: none;
	border: none;
	padding: 0;
	cursor: pointer;
	text-decoration: underline;
	text-underline-offset: 2px;
}
.sdwan-store-loja-btn:hover {
	color: #1e40af;
}
.sdwan-inconsistency-card {
	border: 1px solid #e2e8f0;
	border-radius: 0.75rem;
	padding: 0.75rem 1rem;
	background: #fff;
}
.sdwan-audit-table th,
.sdwan-audit-table td {
	padding: 0.35rem 0.5rem;
	font-size: 0.6875rem;
	line-height: 1.3;
}
.sdwan-audit-table th {
	font-size: 0.625rem;
	letter-spacing: 0.03em;
}
.sdwan-audit-table .empty-state {
	padding: 0.5rem;
	font-size: 0.75rem;
}
#sdwan-audit-toggle-icon.sdwan-audit-open {
	transform: rotate(180deg);
}
.sdwan-inconsistency-card h4 {
	font-size: 0.875rem;
	font-weight: 700;
	color: #334155;
	margin-bottom: 0.5rem;
}
.sdwan-import-errors {
	margin-top: 0.5rem;
	max-height: 10rem;
	overflow-y: auto;
	font-size: 0.75rem;
	color: #b91c1c;
	list-style: disc;
	padding-left: 1.25rem;
}
.sdwan-row-highlight {
	background: #fef9c3 !important;
}
.sdwan-sort-btn {
	font: inherit;
	font-weight: 600;
	color: inherit;
	background: none;
	border: none;
	padding: 0;
	cursor: pointer;
}
.sdwan-sort-btn:hover {
	color: var(--brand, #2563eb);
}
.sdwan-sort-btn.is-active {
	color: var(--brand, #2563eb);
	text-decoration: underline;
}
.sdwan-ticket-inline-status {
	min-width: 7rem;
	font-size: 0.75rem;
	padding: 0.15rem 0.35rem;
}
@media (max-width: 768px) {
	.sdwan-ticket-inline-status {
		max-width: 100%;
	}
	#sdwan-tickets-list-section .sdwan-actions-col {
		min-width: 8rem;
	}
}

/* Sidebar */
.sidebar {
	width: 16.5rem;
	background: var(--sidebar-bg);
	color: #e2e8f0;
	height: 100vh;
	position: fixed;
	left: 0;
	top: 0;
	z-index: 50;
	display: flex;
	flex-direction: column;
	border-right: 1px solid rgba(255,255,255,0.06);
	transition: transform 0.3s ease;
}
.sidebar-brand {
	padding: 1.25rem 1.25rem 1rem;
	border-bottom: 1px solid rgba(255,255,255,0.08);
}
.sidebar-brand-title { font-size: 1.125rem; font-weight: 800; color: #fff; }
.sidebar-brand-sub { font-size: 0.75rem; color: #94a3b8; margin-top: 0.125rem; }
.sidebar-nav { flex: 1; overflow-y: auto; padding: 0.75rem; }
.sidebar-section { font-size: 0.6875rem; font-weight: 700; letter-spacing: 0.08em; text-transform: uppercase; color: #64748b; padding: 0.75rem 0.75rem 0.375rem; }
.sidebar-item {
	width: 100%;
	text-align: left;
	display: flex;
	align-items: center;
	gap: 0.75rem;
	padding: 0.6875rem 0.75rem;
	border-radius: var(--radius);
	color: #cbd5e1;
	font-size: 0.875rem;
	font-weight: 500;
	border: none;
	background: transparent;
	cursor: pointer;
	transition: all 0.15s ease;
}
.sidebar-item:hover { background: var(--sidebar-hover); color: #fff; }
.sidebar-item.active { background: var(--sidebar-active); color: #fff; box-shadow: inset 3px 0 0 #60a5fa; }
.sidebar-item svg { width: 1.125rem; height: 1.125rem; flex-shrink: 0; opacity: 0.9; }
.sidebar-footer {
	padding: 1rem;
	border-top: 1px solid rgba(255,255,255,0.08);
	background: rgba(0,0,0,0.15);
}
.sidebar-user { display: flex; align-items: center; gap: 0.75rem; }
.sidebar-avatar {
	width: 2.5rem; height: 2.5rem; border-radius: 9999px;
	background: linear-gradient(135deg, #3b82f6, #1d4ed8);
	display: flex; align-items: center; justify-content: center;
	font-weight: 700; font-size: 0.875rem; color: #fff;
}

/* Topbar */
.topbar {
	position: sticky;
	top: 0;
	z-index: 30;
	background: rgba(255,255,255,0.92);
	backdrop-filter: blur(8px);
	border-bottom: 1px solid var(--border-soft);
	padding: 0.875rem 1.5rem;
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 1rem;
}
.topbar-left { display: flex; align-items: center; gap: 1rem; min-width: 0; }
.topbar-title { font-size: 1.125rem; font-weight: 700; color: var(--brand-primary); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.topbar-breadcrumb { font-size: 0.8125rem; color: var(--text-muted); }

/* Dropdown */
.ui-dropdown {
	background: #fff;
	border: 1px solid var(--border);
	border-radius: var(--radius);
	box-shadow: var(--shadow-lg);
	padding: 0.375rem;
	z-index: 40;
}
.ui-dropdown button, .ui-dropdown a {
	display: block;
	width: 100%;
	text-align: left;
	padding: 0.5rem 0.75rem;
	border-radius: 0.5rem;
	font-size: 0.8125rem;
	font-weight: 500;
	color: #334155;
	background: transparent;
	border: none;
	cursor: pointer;
	text-decoration: none;
}
.ui-dropdown button:hover, .ui-dropdown a:hover { background: #f1f5f9; }
.ui-dropdown .danger { color: #b91c1c; }
.ui-dropdown .danger:hover { background: #fef2f2; }

/* Modal */
.ui-modal {
	border: none;
	border-radius: var(--radius-lg);
	padding: 0;
	width: min(92vw, 48rem);
	box-shadow: var(--shadow-lg);
}
.ui-modal::backdrop { background: rgba(15, 23, 42, 0.45); backdrop-filter: blur(2px); }
.ui-modal-header {
	background: linear-gradient(135deg, var(--brand-primary), #1d4ed8);
	color: #fff;
	padding: 1rem 1.5rem;
	border-radius: var(--radius-lg) var(--radius-lg) 0 0;
	display: flex;
	flex-direction: column;
	gap: 0.75rem;
}
.ticket-status-notice {
	display: flex;
	align-items: center;
	flex-wrap: wrap;
	gap: 0.5rem;
	padding: 0.625rem 0.875rem;
	border-radius: var(--radius);
	background: rgba(255, 255, 255, 0.95);
	color: #065f46;
	border: 1px solid #a7f3d0;
	font-size: 0.875rem;
	font-weight: 500;
	box-shadow: var(--shadow-md);
	animation: ticketStatusNoticeIn 0.25s ease;
}
.ticket-status-notice.hidden { display: none; }
.ticket-status-notice .ticket-status-notice-icon {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 1.25rem;
	height: 1.25rem;
	border-radius: 9999px;
	background: #10b981;
	color: #fff;
	font-size: 0.75rem;
	font-weight: 700;
}
@keyframes ticketStatusNoticeIn {
	from { opacity: 0; transform: translateY(-0.35rem); }
	to { opacity: 1; transform: translateY(0); }
}
.ui-modal-body { padding: 1.5rem; background: #fff; }
.ui-modal-footer {
	padding: 1rem 1.5rem;
	border-top: 1px solid var(--border-soft);
	background: #f8fafc;
	border-radius: 0 0 var(--radius-lg) var(--radius-lg);
	display: flex;
	justify-content: flex-end;
	gap: 0.5rem;
}

/* Toast */
#toast {
	position: fixed;
	top: 1.25rem;
	right: 1.25rem;
	z-index: 9999;
	min-width: 16rem;
	max-width: 24rem;
	padding: 0.875rem 1rem;
	border-radius: var(--radius);
	box-shadow: var(--shadow-lg);
	font-size: 0.875rem;
	font-weight: 500;
	display: flex;
	align-items: center;
	gap: 0.625rem;
	transform: translateY(-1rem);
	opacity: 0;
	pointer-events: none;
	transition: all 0.25s ease;
}
#toast.show { transform: translateY(0); opacity: 1; pointer-events: auto; }
#toast.toast-success { background: #ecfdf5; color: #065f46; border: 1px solid #a7f3d0; }
#toast.toast-error { background: #fef2f2; color: #991b1b; border: 1px solid #fecaca; }
#toast.toast-info { background: #eff6ff; color: #1e40af; border: 1px solid #bfdbfe; }

/* Empty state */
.empty-state {
	padding: 3rem 1.5rem;
	text-align: center;
	color: var(--text-muted);
}
.empty-state-icon {
	width: 3rem; height: 3rem; margin: 0 auto 1rem;
	color: #cbd5e1;
}

/* Auth */
.auth-wrap {
	min-height: calc(100vh - 4rem);
	display: flex;
	align-items: center;
	justify-content: center;
	padding: 2rem 1rem;
}
.auth-card {
	width: 100%;
	max-width: 26rem;
	background: #fff;
	border-radius: 1.25rem;
	border: 1px solid rgba(255,255,255,0.2);
	box-shadow: var(--shadow-lg);
	overflow: hidden;
}
.auth-card-header {
	padding: 2rem 2rem 1rem;
	text-align: center;
	overflow: visible;
}
.auth-logo { height: 3.5rem; margin: 0 auto 1rem; object-fit: contain; }

.brand-logos--auth {
	display: flex;
	align-items: center;
	justify-content: center;
	gap: 0.875rem;
	max-width: 100%;
	margin: 0 auto 0.25rem;
}
.brand-logos--auth img {
	display: block;
	object-fit: contain;
	flex-shrink: 0;
}
.brand-logos--auth .brand-logo-controll {
	height: 2.5rem;
	width: auto;
	max-width: 9.5rem;
}
.brand-logos--auth .brand-logo-ca {
	height: 2.75rem;
	width: auto;
	max-width: 5rem;
}
.brand-logos-divider {
	width: 1px;
	height: 2.25rem;
	background: #e2e8f0;
	flex-shrink: 0;
}

.brand-logos--header {
	display: flex;
	align-items: center;
	gap: 0.75rem;
	margin-bottom: 1rem;
}
.brand-logos--header .brand-logo-controll {
	height: 2.5rem;
	width: auto;
	max-width: 9.5rem;
	object-fit: contain;
}
.brand-logos--header .brand-logo-ca {
	height: 2.5rem;
	width: auto;
	max-width: 5.5rem;
	object-fit: contain;
}

.brand-logos--topbar {
	display: none;
	align-items: center;
	gap: 0.625rem;
	flex-shrink: 0;
}
@media (min-width: 768px) {
	.brand-logos--topbar {
		display: flex;
	}
}
.brand-logos--topbar .brand-logo-controll {
	height: 2rem;
	width: auto;
	max-width: 8rem;
	object-fit: contain;
}
.brand-logos--topbar .brand-logo-ca {
	height: 2rem;
	width: auto;
	max-width: 4.5rem;
	object-fit: contain;
}

.page-header-main {
	display: flex;
	flex-direction: column;
	gap: 0.25rem;
}
@media (min-width: 640px) {
	.page-header-main {
		flex-direction: row;
		align-items: center;
		gap: 1.25rem;
	}
	.brand-logos--header {
		margin-bottom: 0;
	}
}

/* Skeleton */
.skeleton {
	background: linear-gradient(90deg, #f1f5f9 25%, #e2e8f0 50%, #f1f5f9 75%);
	background-size: 200% 100%;
	animation: shimmer 1.2s infinite;
	border-radius: 0.375rem;
}
@keyframes shimmer { 0% { background-position: 200% 0; } 100% { background-position: -200% 0; } }

/* Tab fade */
.tab-content { animation: fadeIn 0.2s ease; }
@keyframes fadeIn { from { opacity: 0; transform: translateY(4px); } to { opacity: 1; transform: none; } }

/* Filter bar */
.filter-bar {
	display: flex;
	flex-wrap: wrap;
	gap: 0.75rem;
	align-items: flex-end;
	padding: 1rem;
	background: #f8fafc;
	border-radius: var(--radius);
	border: 1px solid var(--border-soft);
	margin-bottom: 1.25rem;
}
.filter-bar .input, .filter-bar .select { min-width: 0; }

/* Scrollbar sidebar */
.sidebar-nav::-webkit-scrollbar { width: 4px; }
.sidebar-nav::-webkit-scrollbar-thumb { background: rgba(255,255,255,0.15); border-radius: 4px; }

/* Form sections (modals) */
.form-section {
	grid-column: 1 / -1;
	margin-top: 0.25rem;
	padding-top: 1rem;
	border-top: 1px solid var(--border-soft);
}
.form-section:first-child {
	margin-top: 0;
	padding-top: 0;
	border-top: none;
}
.form-section-title {
	font-size: 0.75rem;
	font-weight: 700;
	letter-spacing: 0.06em;
	text-transform: uppercase;
	color: var(--text-muted);
	margin-bottom: 0.75rem;
}

/* Table actions */
.btn-link {
	background: none;
	border: none;
	padding: 0;
	font-size: 0.8125rem;
	font-weight: 600;
	color: var(--brand-primary);
	cursor: pointer;
	text-decoration: none;
}
.btn-link:hover { text-decoration: underline; color: var(--brand-primary-hover); }
.btn-link.danger { color: #b91c1c; }
.btn-link.muted { color: #64748b; }

/* Stat skeleton */
.ui-stat-value.skeleton-stat {
	display: inline-block;
	min-width: 3.5rem;
	min-height: 2.25rem;
	border-radius: 0.5rem;
	color: transparent !important;
	user-select: none;
}

.badge-purple { background: #ede9fe; color: #6d28d9; }
.badge-red { background: #fee2e2; color: #b91c1c; }

/* Export cards */
.export-card {
	padding: 1.5rem;
	display: flex;
	flex-direction: column;
	height: 100%;
}
.export-card h3 { font-size: 1.0625rem; font-weight: 700; color: var(--brand-primary); margin-bottom: 0.5rem; }
.export-card p { flex: 1; font-size: 0.875rem; color: var(--text-muted); margin-bottom: 1rem; }

#toast .toast-icon {
	flex-shrink: 0;
	width: 1.25rem;
	height: 1.25rem;
	font-weight: 800;
	line-height: 1.25rem;
	text-align: center;
}

@media (max-width: 767px) {
	.topbar { padding: 0.75rem 1rem; }
	.page-title { font-size: 1.5rem; }
	.data-table { font-size: 0.8125rem; }
	.hide-mobile { display: none; }
}
