/* -------------------------------
   HOME DASHBOARD
--------------------------------*/

.home-layout {
	min-height: 100%;
	width: 100%;
}

.home-sidebar {
	width: 16.66666667%;
	min-width: 220px;
}

.home-main {
	width: 83.33333333%;
	min-width: 0;
}

.home-content {
	padding: 12px;
}

.home-toolbar {
	position: sticky;
	top: 0;
	z-index: 5;
	background: #f8f9fa;
	padding-bottom: 8px;
}

.home-section {
	margin-bottom: 1.5rem;
}

.home-section .card-header {
	background: #fff;
	border-bottom: 1px solid #e9ecef;
}

.home-section h2 {
	font-size: 1.75rem;
	font-weight: 600;
}

.home-grid {
	display: grid;
	grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
	gap: 1rem;
}

.home-tile {
	position: relative;
	display: grid;
	grid-template-columns: 60px minmax(0, 1fr);
	grid-template-areas:
		"icon title"
		"icon description";
	column-gap: 10px;
	align-items: start;
	min-height: 120px;
	padding: 16px;
	color: var(--bs-primary);
	text-decoration: none;
	background: #fff;
	border: 1px solid #e9ecef;
	border-radius: 10px;
	transition: border-color 0.15s ease, box-shadow 0.15s ease, transform 0.15s ease;
}

.home-tile:hover {
	color: var(--bs-primary);
	border-color: var(--bs-primary);
	box-shadow: 0 5px 12px rgba(0, 0, 0, 0.08);
	transform: translateY(-2px);
}

.home-tile-icon {
	grid-area: icon;
	width: 60px;
	height: 60px;
	object-fit: contain;
	border: 1px solid #dee2e6;
	border-radius: 0.375rem;
	padding: 4px;
}

.home-tile-title {
	grid-area: title;
	min-width: 0;
	font-size: 1.1rem;
	font-weight: 600;
	line-height: 1.25;
	color: var(--bs-primary);
	overflow-wrap: anywhere;
}

.home-tile-description {
	grid-area: description;
	min-width: 0;
	margin-top: 8px;
	font-size: 0.95rem;
	line-height: 1.35;
	color: var(--bs-primary);
	overflow-wrap: anywhere;
}

.home-tile-badge {
	position: absolute;
	top: 8px;
	left: 8px;
	z-index: 1;
}

.home-recent-tile {
	background: #f8fafc;
	border-color: #e2e8f0;
}

.home-tile.is-hidden {
	display: none !important;
}

.home-section.is-empty {
	display: none !important;
}

.home-search-mode .tab-pane {
	display: block !important;
	opacity: 1 !important;
}

.home-search-mode .tab-pane:not(.search-has-results) {
	display: none !important;
}

.home-search-mode #main-menu-tab .nav-link {
	opacity: 0.6;
}

@media (max-width: 991.98px) {
	.home-layout {
		flex-direction: column;
	}

	.home-sidebar,
	.home-main {
		width: 100%;
	}

	.home-sidebar {
		min-width: 0;
	}

	#main-menu-tab {
		flex-direction: row !important;
		gap: 0.25rem;
		overflow-x: auto;
	}

	#main-menu-tab .nav-link {
		white-space: nowrap;
	}
}

@media (max-width: 575.98px) {
	.home-content {
		padding: 8px;
	}

	.home-grid {
		grid-template-columns: 1fr;
	}
}
