:root {
	--color-primary: #011638;
	--color-primary-dark: #011638;
	--color-accent: #3b571e;
	--color-accent-dark: #2d4517;
	--color-success: #2e7d32;
	--color-warning: #f9a825;
	--color-danger: #c62828;
	--color-bg: #f0f2f5;
	--color-surface: #ffffff;
	--color-border: #e8eaed;
	--color-text: #1a1d21;
	--color-text-muted: #5f6368;
	--radius-sm: 6px;
	--radius-md: 10px;
	--radius-lg: 12px;
	--shadow-sm: 0 1px 3px rgba(0,0,0,0.06);
	--shadow-md: 0 4px 12px rgba(0,0,0,0.08);
	--shadow-lg: 0 8px 24px rgba(0,0,0,0.1);
}

html {
	overflow-x: hidden;
}

/* Operations shell: keep page height fixed; only main column scrolls */
html:has(body.dv-app) {
	height: 100%;
	overflow: hidden;
}

body.sidebar-active {
	overflow: hidden;
}

body {
	display: flex;
	flex-direction: column;
	min-height: 100vh;
	margin: 0;
	font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
	font-size: 15px;
	line-height: 1.5;
	color: var(--color-text);
	background: var(--color-bg);
	padding: 20px;
	overflow-x: hidden;
	-webkit-font-smoothing: antialiased;
}

h1 {
	color: var(--color-primary);
	font-size: 1.35rem;
	font-weight: 600;
	letter-spacing: -0.02em;
	margin: 0 0 16px 0;
}

h2 {
	color: var(--color-primary);
	font-size: 1.15rem;
	font-weight: 600;
	margin: 0 0 12px 0;
}

p {
	font-weight: 600;
	color: var(--color-accent);
}

@keyframes slideIn {
	from {
		opacity: 0;
		transform: translateY(16px);
	}
	to {
		opacity: 1;
		transform: translateY(0);
	}
}

.container {
	animation-name: slideIn;
	animation-duration: 0.5s;
	animation-fill-mode: forwards;
	opacity: 0;
	display: grid;
	grid-template-columns: 1fr 1fr;
	gap: 20px;
	row-gap: 20px;
	padding: 0 24px 24px 24px;
	width: 100%;
	box-sizing: border-box;
}

.dashboard-container {
	max-width: 1200px;
	background: var(--color-surface);
	padding: 24px;
	border-radius: var(--radius-lg);
	box-shadow: var(--shadow-sm);
	border: 1px solid var(--color-border);
	transition: box-shadow 0.2s ease, transform 0.2s ease;
}

.dashboard-container:hover {
	box-shadow: var(--shadow-md);
	transform: translateY(-2px);
}

.sensor_table caption {
	white-space: nowrap;
	caption-side: top;
	text-align: left;
	font-weight: 600;
	margin-bottom: 12px;
	color: var(--color-accent);
	font-size: 0.9rem;
}

.sensor_table {
	table-layout: fixed;
	width: 100%;
	border-collapse: separate;
	border-spacing: 0;
	border-radius: var(--radius-md);
	overflow: hidden;
}

.sensor_table th,
.sensor_table td {
	padding: 14px 18px;
	text-align: center;
	border-bottom: 1px solid var(--color-border);
	width: 50%;
}

.sensor_table td {
	font-size: 1.2rem;
	font-weight: 600;
}

.sensor_table thead th {
	background-color: var(--color-accent);
	text-align: center;
	font-weight: 600;
	color: white;
}

.chart-wrapper {
	margin-top: 24px;
}

.chart-wrapper h3 {
	font-size: 0.9rem;
	color: var(--color-accent);
	margin: 0 0 12px 0;
	font-weight: 600;
}

.sensor_table tbody tr:hover {
	background-color: rgba(59, 87, 30, 0.04);
}

.RAC {
	max-width: 1200px;
	background: var(--color-surface);
	padding: 24px;
	border-radius: var(--radius-lg);
	box-shadow: var(--shadow-sm);
	border: 1px solid var(--color-border);
	transition: box-shadow 0.2s ease, transform 0.2s ease;
}

.RAC:hover {
	box-shadow: var(--shadow-md);
	transform: translateY(-2px);
}

.mold_score {
	display: flex;
	align-items: center;
	background: rgba(1, 22, 56, 0.06);
	border-radius: var(--radius-md);
	padding: 8px 20px;
	margin: 8px 0 0 0;
	inline-size: fit-content;
}

.mold_score div {
	font-size: 2.25rem;
	font-weight: 700;
	letter-spacing: -0.03em;
}

.mold-score-low { color: var(--color-success); }
.mold-score-medium { color: var(--color-warning); }
.mold-score-high { color: var(--color-danger); }

.health-map {
	max-width: 2400px;
	background: var(--color-surface);
	grid-column: 1 / span 2;
	grid-row: 2;
	padding: 24px;
	border-radius: var(--radius-lg);
	box-shadow: var(--shadow-sm);
	border: 1px solid var(--color-border);
	text-align: center;
	transition: box-shadow 0.2s ease, transform 0.2s ease;
}

.health-map:hover {
	box-shadow: var(--shadow-md);
	transform: translateY(-2px);
}

.health-map #map {
	height: 65vh;
	width: 100%;
	border-radius: var(--radius-md);
	overflow: hidden;
}

.end {
	margin-top: auto;
	text-align: center;
	background: var(--color-surface);
	padding: 24px 0;
	width: 100%;
	border-top: 1px solid var(--color-border);
}

.footer-logo {
	height: 2.5rem;
	width: auto;
	opacity: 0.9;
}

@media (max-width: 900px) {
	body {
		padding: 12px;
		overflow-x: hidden;
	}

	.viewing-bar {
		margin: 0 12px 16px 12px;
		padding: 14px 16px;
	}
	
	.container {
		grid-template-columns: 1fr;
		padding: 12px;
		gap: 12px;
		row-gap: 12px;
	}
	.dashboard-container,
	.RAC,
	.health-map {
		max-width: 100%;
		justify-self: stretch;
	}
	.health-map {
		grid-column: 1;
		grid-row: auto;
		text-align: left;
	}
	/* Center headings  on mobile while content left-aligned */ 
	.dashboard-container h1,
	.dashboard-container h2,
	.RAC h1,
	.RAC h2,
	.health-map h1,
	.health-map h2 {
		text-align: center;
	}
	img {
		max-width: 100%;
		height: auto;
	}

	/* Monthly compliance reports: stack table rows vertically on mobile. */
	.reports-table thead {
		display: none;
	}
	.reports-table,
	.reports-table tbody,
	.reports-table tr,
	.reports-table td {
		display: block;
		width: 100%;
	}
	.reports-table tbody tr {
		border: 1px solid var(--color-border);
		border-radius: var(--radius-lg);
		margin-bottom: 16px;
		overflow: hidden;
		background: var(--color-surface);
	}
	.reports-table td {
		border-bottom: none;
		padding: 10px 16px;
		text-align: left;
	}
	.reports-table td[data-label]::before {
		content: attr(data-label);
		display: block;
		font-size: 0.8rem;
		color: var(--color-text-muted);
		font-weight: 600;
		margin-bottom: 4px;
	}
	.reports-table td:last-child {
		padding-bottom: 14px;
	}
	.view-report-btn {
		/* Keep it from touching the card edges on small screens */
		width: fit-content;
		max-width: 100%;
		display: block;
		margin: 0;
		margin-right: auto;
		text-align: left;
		white-space: nowrap;
		/* Slightly smaller tap target to prevent edge clipping */
		padding-left: 12px;
		padding-right: 12px;
	}
}

/* ========== App bar (mobile-app style) ========== */
.app-bar {
	position: fixed;
	top: 0;
	left: 0;
	right: 0;
	height: 56px;
	background: var(--color-accent-dark);
	display: flex;
	align-items: center;
	z-index: 1000;
	padding: 0 20px;
	box-shadow: 0 2px 8px rgba(0,0,0,0.15);
}

.app-bar-user {
	display: flex;
	align-items: center;
	gap: 8px;
	margin-left: auto;
	color: white;
}

.app-bar-user .user-icon {
	width: 22px;
	height: 22px;
	flex-shrink: 0;
}

.app-bar-user .user-name {
	font-size: 0.9rem;
	font-weight: 500;
}

.menu-toggle,
.sidebar-close {
	background: none;
	border: none;
	padding: 12px;
	cursor: pointer;
	display: flex;
	flex-direction: column;
	justify-content: center;
	gap: 5px;
}

.menu-toggle .hamburger-line {
	width: 22px;
	height: 2px;
	background: white;
	border-radius: 1px;
	transition: transform 0.2s ease;
}

.app-bar-logo {
	display: flex;
	align-items: center;
	padding-left: 12px;
	color: white;
}

.app-bar-logo .logo-img {
	height: 1.5rem;
	width: auto;
	display: block;
	filter: brightness(0) invert(1);
}

/* ========== Sidebar overlay (hidden until menu opens) ========== */
.sidebar-overlay {
	position: fixed;
	inset: 0;
	top: 0;
	left: 0;
	right: 0;
	bottom: 0;
	background: rgba(0,0,0,0.4);
	z-index: 1100;
	opacity: 0;
	visibility: hidden;
	pointer-events: none;
	transition: opacity 0.25s ease, visibility 0.25s ease;
}

.sidebar-overlay.overlay-visible {
	opacity: 1;
	visibility: visible;
	pointer-events: auto;
}

/* ========== Sidebar (hidden off-screen until hamburger is clicked) ========== */
.sidebar {
	position: fixed;
	top: 0;
	left: 0;
	width: 280px;
	max-width: 85vw;
	height: 100vh;
	height: 100dvh;
	background: white;
	z-index: 1200;
	transform: translateX(-100%);
	transition: transform 0.3s ease;
	box-shadow: 4px 0 12px rgba(0,0,0,0.15);
	visibility: visible;
	display: flex;
	flex-direction: column;
}

.sidebar.sidebar-open {
	transform: translateX(0);
}

.sidebar-nav {
	padding: 72px 0 24px;
	overflow-y: auto;
	flex: 1;
	-webkit-overflow-scrolling: touch;
}

.sidebar-close {
	position: absolute;
	top: 16px;
	left: 16px;
}

.sidebar-close .close-icon {
	width: 24px;
	height: 24px;
	stroke: #333;
}

.sidebar-menu {
	list-style: none !important;
	margin: 0;
	padding: 0;
}

.sidebar-menu > li {
	border-bottom: 1px solid #eee;
	list-style: none !important;
}

.sidebar-menu li {
	list-style: none !important;
}

.sidebar-link,
.sidebar-toggle {
	display: flex;
	align-items: center;
	justify-content: space-between;
	width: 100%;
	padding: 16px 20px;
	font-size: 1rem;
	color: #333 !important;
	background: none;
	border: none;
	cursor: pointer;
	text-align: left;
	font-family: inherit;
	text-decoration: none !important;
}

.sidebar-link:hover,
.sidebar-toggle:hover {
	background: rgba(59, 87, 30, 0.06);
	color: var(--color-accent) !important;
}

.sidebar-toggle .toggle-arrow {
	font-size: 1.2rem;
	transition: transform 0.2s ease;
}

.sidebar-toggle[aria-expanded="true"] .toggle-arrow {
	transform: rotate(90deg);
}

.sidebar-sublist {
	list-style: none !important;
	margin: 0;
	padding: 0;
	max-height: 0;
	overflow: hidden;
	transition: max-height 0.25s ease;
	background: #f9f9f9;
}

.sidebar-sublist li {
	list-style: none !important;
}

.sidebar-sublist.expanded {
	max-height: 400px;
}

.sidebar-sublink {
	display: block;
	padding: 12px 20px 12px 36px;
	color: #555 !important;
	text-decoration: none !important;
	font-size: 0.95rem;
}

a.sidebar-sublink:hover {
	background: rgba(59, 87, 30, 0.06);
	color: var(--color-accent) !important;
}

.sidebar-add-device {
	border-top: 1px solid var(--color-border);
	margin-top: 4px;
	padding-top: 12px !important;
	color: var(--color-primary) !important;
	font-weight: 600;
}

.sidebar-add-device:hover {
	color: var(--color-accent) !important;
}

/* ========== Main content offset for app bar ========== */
.app-main {
	flex: 1;
	margin-top: 56px;
	padding-top: 20px;
}

/* ========== Viewing bar + device selector ========== */
.viewing-bar {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 20px;
	margin: 0 24px 24px 24px;
	padding: 16px 24px;
	flex-wrap: wrap;
	background: var(--color-surface);
	border-radius: var(--radius-md);
	border: 1px solid var(--color-border);
	box-shadow: var(--shadow-sm);
}

.viewing-left {
	display: flex;
	align-items: center;
	gap: 12px;
}

.viewing-right {
	display: flex;
	align-items: center;
	gap: 12px;
	margin-left: auto;
}

.reports-link {
	background: var(--color-surface);
	border: 1px solid var(--color-border);
	border-radius: var(--radius-md);
	padding: 10px 18px;
	font-size: 0.9rem;
	font-weight: 600;
	color: var(--color-primary);
	cursor: pointer;
	font-family: inherit;
	box-shadow: var(--shadow-sm);
	transition: all 0.2s ease;
}

.reports-link:hover {
	background: rgba(1, 22, 56, 0.06);
	border-color: var(--color-primary);
}

/* Alerts box */
.alerts-box-wrapper {
	position: relative;
}

.alerts-trigger {
	display: flex;
	align-items: center;
	gap: 8px;
	background: var(--color-surface);
	border: 1px solid var(--color-border);
	border-radius: var(--radius-md);
	padding: 10px 16px;
	font-size: 0.9rem;
	font-weight: 600;
	color: var(--color-primary);
	cursor: pointer;
	font-family: inherit;
	box-shadow: var(--shadow-sm);
	position: relative;
	transition: all 0.2s ease;
}

.alerts-trigger:hover {
	background: rgba(1, 22, 56, 0.06);
	border-color: var(--color-primary);
}

.alerts-bell {
	width: 18px;
	height: 18px;
	flex-shrink: 0;
}

.alerts-label {
	white-space: nowrap;
}

.alerts-badge {
	position: absolute;
	top: -4px;
	right: -4px;
	min-width: 18px;
	height: 18px;
	padding: 0 5px;
	background: #dc3545;
	color: white;
	font-size: 0.75rem;
	font-weight: 600;
	border-radius: 9px;
	display: flex;
	align-items: center;
	justify-content: center;
	line-height: 1;
}

.alerts-dropdown {
	position: absolute;
	top: calc(100% + 8px);
	right: 0;
	min-width: 300px;
	background: var(--color-surface);
	border-radius: var(--radius-lg);
	box-shadow: var(--shadow-lg);
	border: 1px solid var(--color-border);
	padding: 8px 0;
	z-index: 100;
	display: none;
	max-height: 320px;
	overflow-y: auto;
}

.alerts-box-wrapper.open .alerts-dropdown {
	display: block;
}

.alert-item {
	padding: 14px 18px;
	border-bottom: 1px solid var(--color-border);
}

.alert-item:last-child {
	border-bottom: none;
}

.alert-empty {
	padding: 16px 20px;
	font-size: 0.88rem;
	color: var(--color-text-muted);
}

.alert-datetime {
	display: block;
	font-size: 0.75rem;
	color: var(--color-text-muted);
	margin-bottom: 6px;
	font-weight: 500;
}

.alert-title {
	color: var(--color-primary);
	font-size: 0.95rem;
	margin: 0 0 8px 0;
	font-weight: 600;
}

.alert-measures-title {
	font-size: 0.8rem;
	color: var(--color-text-muted);
	margin: 4px 0 6px 0;
	font-weight: 600;
}

.alert-measures-list {
	margin: 0 0 0 16px;
	padding: 0;
	font-size: 0.8rem;
	color: var(--color-text-muted);
	font-weight: normal;
	line-height: 1.5;
}

.alert-measures-list li {
	margin-bottom: 2px;
}

.content-view-hidden {
	display: none !important;
}

.back-btn {
	background: none;
	border: none;
	color: var(--color-primary);
	font-size: 0.95rem;
	cursor: pointer;
	padding: 8px 0;
	margin-bottom: 20px;
	font-family: inherit;
	transition: opacity 0.2s ease;
}

.back-btn:hover {
	opacity: 0.8;
	text-decoration: underline;
}

.reports-list-container,
.report-detail-container {
	max-width: 900px;
	margin: 0 auto;
	padding: 0 28px 48px;
}

.reports-list-title {
	color: var(--color-primary);
	font-size: 1.5rem;
	margin: 0 0 4px 0;
}

.reports-list-subtitle {
	color: var(--color-text-muted);
	font-size: 0.9rem;
	margin: 0 0 24px 0;
}

.reports-table {
	width: 100%;
	border-collapse: collapse;
	background: var(--color-surface);
	border-radius: var(--radius-lg);
	box-shadow: var(--shadow-sm);
	border: 1px solid var(--color-border);
	overflow: hidden;
}

.reports-table th,
.reports-table td {
	padding: 16px 20px;
	text-align: left;
	border-bottom: 1px solid var(--color-border);
}

.reports-table thead th {
	background: var(--color-primary);
	color: white;
	font-weight: 600;
}

.reports-table tbody tr:hover {
	background: rgba(1, 22, 56, 0.04);
}

.status-badge {
	display: inline-block;
	padding: 5px 12px;
	border-radius: 20px;
	font-size: 0.82rem;
	font-weight: 500;
}

.status-ok {
	background: rgba(46, 125, 50, 0.12);
	color: var(--color-success);
}

.view-report-btn {
	background: var(--color-primary);
	color: white;
	border: none;
	padding: 8px 16px;
	border-radius: var(--radius-sm);
	font-size: 0.9rem;
	cursor: pointer;
	font-family: inherit;
	font-weight: 500;
	transition: background 0.2s ease;
}

.view-report-btn:hover {
	background: var(--color-primary-dark);
}

.report-detail-title {
	color: var(--color-primary);
	font-size: 1.4rem;
	margin: 0 0 24px 0;
}

.report-section {
	margin-bottom: 28px;
	background: var(--color-surface);
	padding: 24px;
	border-radius: var(--radius-lg);
	box-shadow: var(--shadow-sm);
	border: 1px solid var(--color-border);
}

.report-section h2 {
	color: var(--color-primary);
	font-size: 1.1rem;
	margin: 0 0 16px 0;
}

.report-section .chart-wrapper {
	min-height: 220px;
}

.report-table-wrap {
	margin-top: 16px;
	overflow-x: auto;
}

.report-data-table {
	width: 100%;
	border-collapse: collapse;
	font-size: 0.9rem;
}

.report-data-table th,
.report-data-table td {
	padding: 12px 16px;
	text-align: left;
	border-bottom: 1px solid var(--color-border);
}

.report-data-table thead th {
	background: rgba(1, 22, 56, 0.08);
	color: var(--color-primary);
	font-weight: 600;
}

.maintenance-count {
	font-size: 1rem;
	color: var(--color-text);
}

.report-download {
	margin-top: 32px;
	padding-top: 24px;
	border-top: 1px solid var(--color-border);
}

.download-csv-btn {
	background: var(--color-accent);
	color: white;
	border: none;
	padding: 12px 24px;
	border-radius: var(--radius-md);
	font-size: 0.95rem;
	cursor: pointer;
	font-family: inherit;
	font-weight: 600;
	transition: background 0.2s ease;
}

.download-csv-btn:hover {
	background: var(--color-accent-dark);
}

.viewing-label {
	font-size: 0.95rem;
	color: var(--color-text-muted);
	font-weight: 500;
}

.device-selector {
	position: relative;
}

.device-trigger {
	display: inline-flex;
	align-items: center;
	gap: 8px;
	background: none;
	border: none;
	padding: 4px 0;
	cursor: pointer;
	font-family: inherit;
	font-size: 1.05rem;
	color: var(--color-primary);
	text-decoration: underline;
	text-underline-offset: 4px;
	transition: color 0.2s ease;
}

.device-trigger:hover {
	color: var(--color-accent);
}

.device-trigger .device-chevron {
	width: 18px;
	height: 18px;
	transition: transform 0.2s ease;
}

.device-selector.open .device-chevron {
	transform: rotate(180deg);
}

.device-dropdown {
	position: absolute;
	top: 100%;
	left: 0;
	margin-top: 8px;
	min-width: 220px;
	background: var(--color-surface);
	border: 1px solid var(--color-border);
	border-radius: var(--radius-lg);
	box-shadow: var(--shadow-lg);
	list-style: none;
	padding: 6px 0;
	z-index: 100;
	opacity: 0;
	visibility: hidden;
	transform: translateY(-4px);
	transition: opacity 0.2s ease, visibility 0.2s ease, transform 0.2s ease;
}

.device-selector.open .device-dropdown {
	opacity: 1;
	visibility: visible;
	transform: translateY(0);
}

.device-dropdown li {
	padding: 10px 16px;
	cursor: pointer;
	font-size: 0.95rem;
	color: #333;
}

.device-dropdown li:hover {
	background: rgba(1, 22, 56, 0.06);
	color: var(--color-accent);
}

.device-dropdown li[aria-selected="true"] {
	background: rgba(1, 22, 56, 0.1);
	color: var(--color-primary);
	font-weight: 600;
}

/* —— Auth (sign in / register) —— */
body.auth-body {
	display: block;
	padding: 0;
	min-height: 100vh;
	/*background: linear-gradient(165deg, #f4f2f0 0%, #f0f2f5 45%, #ece8e4 100%);*/
	background: #e4dfdb;
}	

.auth-shell {
	min-height: 100vh;
	display: flex;
	align-items: center;
	justify-content: center;
	padding: 32px 20px;
	box-sizing: border-box;
}

.auth-card {
	width: 100%;
	max-width: 400px;
	background: var(--color-surface);
	border-radius: var(--radius-lg);
	box-shadow: var(--shadow-lg);
	border: 1px solid var(--color-border);
	padding: 32px 28px 28px;
	box-sizing: border-box;
}

.auth-card-wide {
	max-width: 440px;
}

.auth-name-row {
	display: grid;
	grid-template-columns: 1fr 1fr;
	gap: 12px 16px;
	margin-bottom: 0;
}

@media (max-width: 480px) {
	.auth-name-row {
		grid-template-columns: 1fr;
	}
}

.auth-name-field .auth-label {
	margin-top: 0;
}

.auth-name-field .auth-label:first-child {
	margin-top: 0;
}

.auth-password-rules {
	margin: 10px 0 0;
	padding: 0 0 0 1.1rem;
	font-size: 0.82rem;
	font-weight: 500;
	line-height: 1.45;
	list-style-type: disc;
}

.auth-password-rules li {
	margin-bottom: 4px;
	color: var(--color-text-muted);
	transition: color 0.18s ease, font-weight 0.18s ease;
}

.auth-password-rules li.auth-password-rule-met {
	color: var(--color-success);
	font-weight: 600;
}

.auth-password-rules li:last-child {
	margin-bottom: 0;
}

.auth-password-rules-match {
	margin-top: 10px;
	margin-bottom: 12px;
}

.auth-logo {
	display: block;
	height: 40px;
	width: auto;
	margin: 0 auto 20px;
	object-fit: contain;
}

.auth-title {
	text-align: center;
	font-size: 1.5rem;
	margin: 0 0 6px;
	color: var(--color-primary);
}

.auth-subtitle {
	text-align: center;
	margin: 0 0 24px;
	font-size: 0.95rem;
	font-weight: 500;
	color: var(--color-text-muted);
}

.auth-flashes {
	list-style: none;
	margin: 0 0 16px;
	padding: 0;
}

.auth-flash {
	padding: 10px 12px;
	border-radius: var(--radius-sm);
	font-size: 0.9rem;
	margin-bottom: 8px;
}

.auth-flash-error {
	background: rgba(198, 40, 40, 0.08);
	color: var(--color-danger);
	border: 1px solid rgba(198, 40, 40, 0.25);
}

.auth-form {
	display: flex;
	flex-direction: column;
	gap: 0;
}

.auth-label {
	display: block;
	font-size: 0.85rem;
	font-weight: 600;
	color: var(--color-text);
	margin-bottom: 6px;
	margin-top: 14px;
}

.auth-label:first-of-type {
	margin-top: 0;
}

.auth-optional {
	font-weight: 500;
	color: var(--color-text-muted);
	font-size: 0.8rem;
}

.auth-input {
	width: 100%;
	box-sizing: border-box;
	padding: 11px 12px;
	border: 1px solid var(--color-border);
	border-radius: var(--radius-sm);
	font-size: 1rem;
	font-family: inherit;
	color: var(--color-text);
	background: #fff;
}

.auth-input:focus {
	outline: none;
	border-color: var(--color-primary);
	box-shadow: 0 0 0 3px rgba(1, 22, 56, 0.15);
}

.auth-hint {
	margin: 6px 0 0;
	font-size: 0.8rem;
	font-weight: 500;
	color: var(--color-text-muted);
}

.auth-submit {
	margin-top: 22px;
	width: 100%;
	padding: 12px 16px;
	border: none;
	border-radius: var(--radius-md);
	font-size: 1rem;
	font-weight: 600;
	font-family: inherit;
	color: #fff;
	background: linear-gradient(180deg, var(--color-primary) 0%, var(--color-primary-dark) 100%);
	cursor: pointer;
	box-shadow: var(--shadow-sm);
}

.auth-submit:hover {
	filter: brightness(1.05);
}

.auth-submit:active {
	transform: translateY(1px);
}

.auth-footer {
	margin: 20px 0 0;
	text-align: center;
	font-size: 0.9rem;
	font-weight: 500;
	color: var(--color-text-muted);
}

.auth-footer a {
	color: var(--color-primary);
	font-weight: 600;
	text-decoration: none;
}

.auth-footer a:hover {
	text-decoration: underline;
}

.sidebar-logout-form {
	margin: 0;
	padding: 0;
}

.sidebar-logout-btn {
	display: flex;
	align-items: center;
	width: 100%;
	padding: 16px 20px;
	text-align: left;
	border: none;
	background: none;
	font: inherit;
	font-size: 1rem;
	cursor: pointer;
	color: var(--color-danger, #c62828) !important;
}

.sidebar-logout-btn:hover {
	background: rgba(198, 40, 40, 0.06);
}

/* Safe area for notch devices */
@supports (padding-top: env(safe-area-inset-top)) {
	.app-bar {
		padding-top: env(safe-area-inset-top);
		height: calc(56px + env(safe-area-inset-top));
	}
	.app-main {
		margin-top: calc(56px + env(safe-area-inset-top));
	}
}

/* ========== Dryvera operations shell (dashboard) ========== */
body.dv-app {
	display: flex;
	flex-direction: row;
	align-items: stretch;
	padding: 0;
	margin: 0;
	min-height: 0;
	height: 100vh;
	height: 100dvh;
	max-height: 100vh;
	max-height: 100dvh;
	overflow: hidden;
	-webkit-font-smoothing: antialiased;
}

body.dv-sidebar-active {
	overflow: hidden;
}

.dv-sidebar-overlay {
	display: none;
	position: fixed;
	inset: 0;
	background: rgba(0, 0, 0, 0.45);
	z-index: 1290;
	opacity: 0;
	visibility: hidden;
	transition: opacity 0.2s ease, visibility 0.2s ease;
}

.dv-sidebar-overlay.dv-sidebar-overlay--visible {
	opacity: 1;
	visibility: visible;
}

.dv-sidebar {
	width: 260px;
	flex-shrink: 0;
	flex-grow: 0;
	background: #14212b;
	color: rgba(255, 255, 255, 0.88);
	display: flex;
	flex-direction: column;
	min-height: 0;
	align-self: stretch;
	max-height: 100vh;
	max-height: 100dvh;
	z-index: 1300;
	box-sizing: border-box;
}

.dv-sidebar__brand {
	padding: 28px 24px 20px;
	border-bottom: 1px solid rgba(255, 255, 255, 0.08);
	display:flex;
	justify-content: center; /* Center the logo horizontally */
}

.dv-sidebar__logo {
	height: 32px;
	width: auto;
	display: block;
	filter: brightness(0) invert(1);
}

.dv-sidebar__nav {
	flex: 1;
	padding: 16px 12px;
	display: flex;
	flex-direction: column;
	gap: 4px;
	overflow-y: auto;
}

.dv-nav-link {
	display: flex;
	align-items: center;
	gap: 12px;
	padding: 12px 14px;
	border-radius: 10px;
	color: rgba(255, 255, 255, 0.82) !important;
	text-decoration: none !important;
	font-size: 0.95rem;
	font-weight: 500;
	transition: background 0.15s ease, color 0.15s ease;
}

.dv-nav-link:hover {
	background: rgba(255, 255, 255, 0.06);
	color: #fff !important;
}

.dv-nav-link--active {
	background: #e8e4d9;
	color: #2d4517 !important;
}

.dv-nav-link--active:hover {
	background: #e0dccd;
	color: #243c12 !important;
}

.dv-nav-link--button {
	font: inherit;
	border: none;
	background: transparent;
	cursor: pointer;
	width: 100%;
	text-align: left;
	font-size: 0.95rem;
	font-weight: 500;
}

.dv-nav-icon {
	display: flex;
	align-items: center;
	justify-content: center;
	flex-shrink: 0;
	opacity: 0.9;
}

.dv-sidebar__footer {
	padding: 16px 12px 24px;
	border-top: 1px solid rgba(255, 255, 255, 0.08);
	display: flex;
	flex-direction: column;
	gap: 2px;
}

.dv-footer-link {
	display: flex;
	align-items: center;
	gap: 10px;
	padding: 10px 14px;
	border-radius: 8px;
	color: rgba(255, 255, 255, 0.7) !important;
	text-decoration: none !important;
	font-size: 0.88rem;
	transition: background 0.15s ease, color 0.15s ease;
}

.dv-footer-link:hover {
	background: rgba(255, 255, 255, 0.06);
	color: #fff !important;
}

.dv-footer-link--danger {
	color: rgba(255, 160, 160, 0.95) !important;
}

.dv-footer-link--danger:hover {
	background: rgba(198, 40, 40, 0.15);
}

.dv-footer-form {
	margin: 0;
	padding: 0;
}

.dv-footer-form .dv-footer-link--danger {
	width: 100%;
	border: none;
	background: transparent;
	cursor: pointer;
	font: inherit;
	text-align: left;
}

.dv-main-wrap {
	flex: 1;
	min-width: 0;
	min-height: 0;
	display: flex;
	flex-direction: column;
	background: #eef0f3;
	overflow: hidden;
}

.dv-topbar {
	background: #fff;
	border-bottom: 1px solid var(--color-border);
	padding: 0 24px;
	min-height: 64px;
	display: flex;
	align-items: center;
	gap: 16px;
	flex-shrink: 0;
	box-shadow: 0 1px 0 rgba(0, 0, 0, 0.04);
}

.dv-menu-toggle {
	display: none;
	flex-direction: column;
	justify-content: center;
	gap: 5px;
	padding: 10px;
	background: none;
	border: none;
	cursor: pointer;
	border-radius: 8px;
	flex-shrink: 0;
}

.dv-menu-toggle:hover {
	background: rgba(0, 0, 0, 0.05);
}

.dv-menu-toggle__bar {
	width: 22px;
	height: 2px;
	background: var(--color-text);
	border-radius: 1px;
}

.dv-topbar__inner {
	flex: 1;
	display: flex;
	align-items: center;
	gap: 20px;
	flex-wrap: wrap;
	min-width: 0;
}

.dv-portfolio-wrap {
	position: relative;
	flex-shrink: 0;
}

.dv-portfolio-static {
	display: inline-flex;
	align-items: center;
	gap: 6px;
	padding: 8px 12px;
	font-size: 0.95rem;
	color: var(--color-text);
}

.dv-portfolio-trigger {
	display: inline-flex;
	align-items: center;
	gap: 6px;
	padding: 8px 12px;
	background: none;
	border: none;
	border-radius: 8px;
	cursor: pointer;
	font: inherit;
	font-size: 0.95rem;
	color: var(--color-text);
	transition: background 0.15s ease;
}

.dv-portfolio-trigger:hover,
.dv-portfolio-wrap--open .dv-portfolio-trigger {
	background: rgba(1, 22, 56, 0.07);
}

.dv-portfolio-label {
	color: var(--color-text-muted);
	font-weight: 500;
}

.dv-portfolio-name {
	font-weight: 600;
	color: var(--color-primary);
}

.dv-chevron {
	flex-shrink: 0;
	opacity: 0.65;
}

.dv-chevron--green {
	color: var(--color-success);
	opacity: 1;
}

.dv-portfolio-menu {
	position: absolute;
	top: calc(100% + 6px);
	left: 0;
	min-width: 260px;
	margin: 0;
	padding: 6px 0;
	list-style: none;
	background: #fff;
	border: 1px solid var(--color-border);
	border-radius: var(--radius-lg);
	box-shadow: var(--shadow-lg);
	z-index: 200;
}

.dv-portfolio-menu li {
	padding: 10px 16px;
	cursor: pointer;
	font-size: 0.92rem;
	color: var(--color-text);
}

.dv-portfolio-menu li:hover {
	background: rgba(1, 22, 56, 0.06);
	color: var(--color-accent);
}

.dv-topbar__center {
	flex: 1;
	display: flex;
	justify-content: center;
	min-width: 140px;
}

.dv-search {
	display: flex;
	align-items: center;
	gap: 10px;
	width: 100%;
	max-width: 420px;
	padding: 10px 16px;
	background: #f3f5f7;
	border-radius: 999px;
	border: 1px solid transparent;
	transition: border-color 0.15s ease, background 0.15s ease;
}

.dv-search:focus-within {
	background: #fff;
	border-color: var(--color-border);
	box-shadow: var(--shadow-sm);
}

.dv-search__icon {
	color: var(--color-text-muted);
	display: flex;
}

.dv-search__input {
	flex: 1;
	border: none;
	background: transparent;
	font: inherit;
	font-size: 0.92rem;
	color: var(--color-text);
	outline: none;
	min-width: 0;
}

.dv-search__input::placeholder {
	color: #889099;
}

.dv-topbar__actions {
	display: flex;
	align-items: center;
	gap: 6px;
	flex-shrink: 0;
}

.dv-topbar-user {
	display: flex;
	align-items: center;
	margin-left: 8px;
	padding-left: 14px;
	border-left: 1px solid var(--color-border);
	min-width: 0;
}

.dv-topbar-user__name {
	font-size: 0.92rem;
	font-weight: 600;
	color: var(--color-text);
	max-width: 200px;
	overflow: hidden;
	text-overflow: ellipsis;
	white-space: nowrap;
}

.dv-icon-btn {
	position: relative;
	display: flex;
	align-items: center;
	justify-content: center;
	width: 44px;
	height: 44px;
	border: none;
	border-radius: 10px;
	background: transparent;
	color: var(--color-text-muted);
	cursor: pointer;
	transition: background 0.15s ease, color 0.15s ease;
}

.dv-icon-btn:hover {
	background: rgba(0, 0, 0, 0.05);
	color: var(--color-primary);
}

.dv-notify-dot {
	position: absolute;
	top: 10px;
	right: 10px;
	width: 8px;
	height: 8px;
	background: #e53935;
	border-radius: 50%;
	border: 2px solid #fff;
}

.dv-content {
	flex: 1;
	min-height: 0;
	overflow-x: hidden;
	overflow-y: auto;
	-webkit-overflow-scrolling: touch;
	padding: 24px 28px 40px;
	background: #f4f2f0;
}

.dv-overview-grid {
	display: grid;
	grid-template-columns: repeat(2, minmax(0, 1fr));
	gap: 22px;
	max-width: 1280px;
	margin: 0 auto;
}

/* Overview page: column-aware entrance animation */
@keyframes dvOverviewSlideInLeft {
	from {
		opacity: 0;
		transform: translateX(-40px);
	}
	70% {
		opacity: 0.85;
	}
	to {
		opacity: 1;
		transform: translateX(0);
	}
}

@keyframes dvOverviewSlideInRight {
	from {
		opacity: 0;
		transform: translateX(40px);
	}
	70% {
		opacity: 0.85;
	}
	to {
		opacity: 1;
		transform: translateX(0);
	}
}

.dv-overview-grid > .dv-card {
	opacity: 0;
}

.dv-overview-grid > .dv-card:nth-child(odd) {
	animation: dvOverviewSlideInLeft 920ms cubic-bezier(0.22, 1, 0.36, 1) forwards;
}

.dv-overview-grid > .dv-card:nth-child(even) {
	animation: dvOverviewSlideInRight 920ms cubic-bezier(0.22, 1, 0.36, 1) forwards;
}

.dv-card {
	background: #fff;
	border-radius: 14px;
	padding: 22px 24px;
	border: 1px solid var(--color-border);
	box-shadow: var(--shadow-sm);
	transition: transform 0.24s cubic-bezier(0.22, 1, 0.36, 1), box-shadow 0.24s ease;
	transform-origin: center;
	will-change: transform;
}

.dv-card:hover {
	box-shadow: var(--shadow-sm);
	transform: scale(1.2);
}

@media (prefers-reduced-motion: reduce) {
	.dv-card {
		transition: box-shadow 0.2s ease;
	}

	.dv-card:hover {
		transform: none;
	}

	.dv-overview-grid > .dv-card {
		opacity: 1;
		animation: none;
	}
}

.dv-card__title {
	font-size: 1.05rem;
	font-weight: 700;
	color: var(--color-text);
	margin: 0 0 18px 0;
	letter-spacing: -0.02em;
}

.dv-card__title--plain {
	margin-bottom: 14px;
}

.dv-card__title--row {
	display: flex;
	align-items: center;
	justify-content: space-between;
	width: 100%;
	margin-bottom: 16px;
}

.dv-card__title--tight {
	margin-bottom: 6px;
}

.dv-card__title--properties-link {
	justify-content: flex-start;
	gap: 10px;
}

.dv-card__title-count {
	font-weight: 700;
	color: var(--color-text-muted);
}

.dv-card__chevron {
	color: var(--color-text-muted);
	font-size: 1.25rem;
	font-weight: 300;
	line-height: 1;
}

.dv-card__view-all {
	display: inline-flex;
	align-items: center;
	gap: 6px;
	color: var(--color-text-muted);
	text-decoration: none;
}

.dv-card__view-all-text {
	max-width: 0;
	opacity: 0;
	overflow: hidden;
	white-space: nowrap;
	font-size: 0.84rem;
	font-weight: 700;
	color: var(--color-primary);
	transform: translateX(8px);
	transition: max-width 0.22s ease, opacity 0.22s ease, transform 0.22s ease;
}

.dv-card__view-all:hover .dv-card__view-all-text,
.dv-card__view-all:focus-visible .dv-card__view-all-text {
	max-width: 90px;
	opacity: 1;
	transform: translateX(0);
}

.dv-card__view-all:hover .dv-card__chevron,
.dv-card__view-all:focus-visible .dv-card__chevron {
	color: var(--color-primary);
}

.dv-card__head-row {
	display: flex;
	align-items: flex-start;
	justify-content: space-between;
	gap: 16px;
	flex-wrap: wrap;
	margin-bottom: 8px;
}

.dv-btn-generate {
	padding: 8px 18px;
	border: none;
	border-radius: 8px;
	font: inherit;
	font-size: 0.85rem;
	font-weight: 800;
	color: #fff;
	background: #2d5a3d;
	cursor: pointer;
	white-space: nowrap;
	transition: filter 0.15s ease, transform 0.1s ease;
}

.dv-btn-generate:hover {
	filter: brightness(1.06);
}

.dv-btn-generate:active {
	transform: translateY(1px);
}

.dv-risk-list {
	list-style: none;
	margin: 0;
	padding: 0;
	display: flex;
	flex-direction: column;
	gap: 18px;
}

.dv-risk-item {
	display: flex;
	gap: 14px;
	align-items: flex-start;
	padding-bottom: 4px;
}

.dv-risk-icon {
	flex-shrink: 0;
	width: 40px;
	height: 40px;
	border-radius: 50%;
	background: #2d5a3d;
	color: #fff;
	display: flex;
	align-items: center;
	justify-content: center;
}

.dv-risk-body {
	flex: 1;
	min-width: 0;
}

.dv-risk-row {
	display: flex;
	align-items: baseline;
	justify-content: space-between;
	gap: 12px;
}

.dv-risk-label {
	font-size: 0.95rem;
	font-weight: 800;
	color: var(--color-text);
}

.dv-risk-value {
	font-size: 1.35rem;
	font-weight: 700;
	color: var(--color-text);
	letter-spacing: -0.03em;
}

.dv-risk-caption {
	margin: 4px 0 0;
	font-size: 0.8rem;
	font-weight: 500;
	color: var(--color-text-muted);
}

.dv-alert-cards {
	list-style: none;
	margin: 0;
	padding: 0;
	display: flex;
	flex-direction: column;
	gap: 12px;
}

.dv-alert-card {
	display: flex;
	gap: 14px;
	align-items: flex-start;
	padding: 14px 16px;
	background: #f7f8fa;
	border-radius: 12px;
	border: 1px solid #e8eaed;
}

.dv-alert-card__body {
	flex: 1;
	min-width: 0;
}

.dv-alert-card__top {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 12px;
}

.dv-alert-card__icon {
	flex-shrink: 0;
	width: 44px;
	height: 44px;
	border-radius: 12px;
	background: #2d5a3d;
	color: #fff;
	display: flex;
	align-items: center;
	justify-content: center;
}

.dv-alert-card__title {
	margin: 0 0 4px;
	font-size: 0.95rem;
	font-weight: 700;
	color: var(--color-text);
}

.dv-alert-card__meta {
	margin: 0;
	font-size: 0.82rem;
	font-weight: 500;
	color: var(--color-text-muted);
}

.dv-alert-card__action {
	font-size: 0.82rem;
	font-weight: 700;
	color: var(--color-primary);
	text-decoration: none;
	white-space: nowrap;
}

.dv-alert-card__action:hover {
	text-decoration: underline;
}

.dv-alert-card--with-action {
	position: relative;
}

.dv-alert-card--with-action .dv-alert-card__body {
	padding-right: 108px;
}

.dv-alert-card--with-action .dv-alert-card__top {
	display: block;
}

.dv-alert-card--with-action .dv-alert-card__action {
	position: absolute;
	top: 14px;
	right: 16px;
	color: var(--color-primary);
	text-decoration: none;
}

.dv-alert-card--with-action .dv-alert-card__action:hover {
	text-decoration: underline;
}

.dv-compliance-list {
	list-style: none;
	margin: 0;
	padding: 0;
	border-top: 1px solid var(--color-border);
}

.dv-compliance-row {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 12px;
	padding: 16px 0;
	border-bottom: 1px solid var(--color-border);
	font-size: 0.92rem;
	font-weight: 500;
	color: var(--color-text);
}

.dv-compliance-row:last-child {
	border-bottom: none;
}

.dv-link-view {
	font-size: 0.88rem;
	font-weight: 600;
	color: var(--color-primary);
	text-decoration: none;
}

.dv-link-view:hover {
	text-decoration: underline;
}

.dv-card--properties .dv-properties-head {
	display: flex;
	align-items: flex-start;
	justify-content: space-between;
	gap: 16px;
	flex-wrap: wrap;
	margin-bottom: 8px;
}

.dv-properties-sub {
	display: flex;
	flex-direction: column;
	align-items: flex-start;
	gap: 4px;
	font-weight: 800;
}

.dv-properties-sub__risk {
	font-size: 0.78rem;
	font-weight: 700;
	color: var(--color-text);
	letter-spacing: 0.02em;
}

.dv-properties-sub__avg {
	font-size: 0.78rem;
	font-weight: 600;
	color: var(--color-text-muted);
	letter-spacing: 0.02em;
}

.dv-properties-toolbar {
	position: relative;
	align-self: flex-start;
}

.dv-sort-trigger {
	display: inline-flex;
	align-items: center;
	gap: 6px;
	padding: 8px 12px;
	border: 1px solid var(--color-border);
	border-radius: 8px;
	background: #fff;
	font: inherit;
	font-size: 0.82rem;
	font-weight: 600;
	color: var(--color-text);
	cursor: pointer;
	transition: border-color 0.15s ease, box-shadow 0.15s ease;
}

.dv-sort-trigger:hover,
.dv-properties-toolbar--open .dv-sort-trigger {
	border-color: rgba(45, 90, 61, 0.45);
	box-shadow: 0 1px 3px rgba(45, 90, 61, 0.12);
}

.dv-sort-label {
	white-space: nowrap;
}

.dv-sort-menu {
	position: absolute;
	top: calc(100% + 6px);
	right: 0;
	min-width: 160px;
	margin: 0;
	padding: 6px 0;
	list-style: none;
	background: #fff;
	border: 1px solid var(--color-border);
	border-radius: var(--radius-md);
	box-shadow: var(--shadow-md);
	z-index: 50;
}

.dv-sort-menu li {
	padding: 8px 14px;
	font-size: 0.85rem;
	cursor: pointer;
}

.dv-sort-menu li:hover {
	background: rgba(45, 90, 61, 0.08);
}

.dv-sort-menu--links li {
	padding: 0;
}

.dv-sort-menu--links li:hover {
	background: transparent;
}

.dv-sort-menu-link {
	display: block;
	padding: 8px 14px;
	font-size: 0.85rem;
	color: var(--color-text);
	text-decoration: none;
}

.dv-sort-menu-link:hover {
	background: rgba(45, 90, 61, 0.08);
}

.dv-properties-body {
	display: flex;
	align-items: flex-end;
	justify-content: center;
	gap: 8px;
	position: relative;
	padding: 8px 0 0;
	min-height: 200px;
}

.dv-properties-chart-views {
	flex: 1;
	min-width: 0;
	display: flex;
	flex-direction: column;
	align-items: center;
	justify-content: flex-end;
}

.dv-properties-chart-view {
	width: 100%;
	max-width: 280px;
	text-align: center;
}

.dv-properties-chart-view[hidden] {
	display: none !important;
}

.dv-card--properties .dv-properties-side-icons {
	position: relative;
	z-index: 2;
}

.dv-card--properties .dv-properties-side-icons .dv-side-icon {
	cursor: pointer;
}

.dv-card--properties .dv-properties-side-icons .dv-side-icon:hover {
	color: var(--color-text);
	border-color: #c5cdd4;
}

.dv-card--properties .dv-properties-side-icons .dv-side-icon:focus-visible {
	outline: 2px solid #2d5a3d;
	outline-offset: 2px;
}

.dv-card--properties .dv-properties-side-icons .dv-side-icon.dv-side-icon--active {
	border-color: #2d5a3d;
	color: #2d5a3d;
	background: rgba(45, 90, 61, 0.06);
}

.dv-mini-chart-wrap {
	width: 100%;
	max-width: 280px;
	margin: 0 auto;
	text-align: center;
}

.dv-mini-chart-svg {
	width: 100%;
	max-width: 280px;
	height: auto;
	display: block;
	margin: 0 auto;
}

.dv-mini-chart-axis {
	stroke: #c5cdd4;
	stroke-width: 1.25;
}

.dv-mini-chart-grid {
	stroke: #e8ecf0;
	stroke-width: 1;
}

.dv-mini-chart-axis-label,
.dv-mini-chart-x {
	font-size: 10px;
	font-weight: 600;
	fill: var(--color-text-muted);
	font-family: system-ui, -apple-system, Segoe UI, sans-serif;
}

.dv-mini-chart-bar {
	fill: #2d5a3d;
}

.dv-mini-chart-score {
	margin: 6px 0 0;
	font-size: 2.5rem;
	font-weight: 700;
	color: var(--color-text);
	letter-spacing: -0.04em;
	line-height: 1;
	text-align: center;
}

.dv-mini-chart-line {
	stroke: #2d5a3d;
}

.dv-mini-chart-dot {
	fill: #fff;
	stroke: #2d5a3d;
	stroke-width: 2;
}

.dv-mini-chart-trend-line {
	stroke: #2d5a3d;
}

.dv-mini-chart-trend-fit {
	stroke: #7a8a9a;
}

.dv-mini-chart-caption {
	margin: 4px 0 0;
	font-size: 0.78rem;
	font-weight: 600;
	color: var(--color-text-muted);
}

.dv-mini-chart-area {
	stroke: none;
}

.dv-gauge-wrap {
	position: relative;
	width: 100%;
	max-width: 280px;
	margin: 0 auto;
	text-align: center;
}

.dv-gauge-svg {
	width: 100%;
	max-width: 260px;
	height: auto;
	display: block;
	margin: 0 auto;
}

.dv-gauge-track {
	stroke: #d5dde3;
}

.dv-gauge-fill {
	stroke: #2d5a3d;
}

.dv-gauge-center {
	position: absolute;
	left: 50%;
	bottom: 18%;
	transform: translateX(-50%);
	pointer-events: none;
}

.dv-gauge-value {
	font-size: 2.5rem;
	font-weight: 700;
	color: var(--color-text);
	letter-spacing: -0.04em;
	line-height: 1;
}

.dv-gauge-updated {
	margin: 8px 0 0;
	font-size: 0.8rem;
	font-weight: 500;
	color: var(--color-text-muted);
	text-align: center;
}

.dv-properties-side-icons {
	display: flex;
	flex-direction: column;
	gap: 8px;
	padding-bottom: 36px;
	flex-shrink: 0;
}

.dv-side-icon {
	display: flex;
	align-items: center;
	justify-content: center;
	width: 36px;
	height: 36px;
	border: 1px solid var(--color-border);
	border-radius: 8px;
	background: #fff;
	color: var(--color-text-muted);
	cursor: default;
}

@media (max-width: 900px) {
	.dv-overview-grid {
		grid-template-columns: 1fr;
	}

	.dv-menu-toggle {
		display: flex;
	}

	.dv-sidebar-overlay {
		display: block;
	}

	.dv-sidebar {
		position: fixed;
		left: 0;
		top: 0;
		height: 100vh;
		height: 100dvh;
		max-height: 100vh;
		max-height: 100dvh;
		transform: translateX(-100%);
		transition: transform 0.28s ease;
		box-shadow: 8px 0 24px rgba(0, 0, 0, 0.2);
	}

	.dv-sidebar.dv-sidebar--open {
		transform: translateX(0);
	}

	.dv-topbar__inner {
		flex-wrap: nowrap;
	}

	.dv-topbar__center {
		flex: 0 1 auto;
		order: 3;
		width: 100%;
		justify-content: flex-start;
		margin-top: 0;
	}

	.dv-topbar {
		flex-wrap: wrap;
		padding-top: 12px;
		padding-bottom: 12px;
	}

	.dv-content {
		padding: 16px;
	}
}

@media (min-width: 901px) {
	.dv-sidebar-overlay.dv-sidebar-overlay--visible {
		display: none;
	}
}

/* —— Alerts queue page —— */
.dv-alerts-page {
	max-width: 1200px;
	margin: 0 auto;
}

.dv-alerts-page-header {
	display: flex;
	align-items: flex-start;
	justify-content: space-between;
	gap: 20px;
	flex-wrap: wrap;
	margin-bottom: 22px;
}

.dv-alerts-page-header__left {
	flex: 1;
	min-width: 200px;
}

.dv-alerts-page-title {
	font-size: 1.5rem;
	font-weight: 700;
	color: var(--color-primary);
	margin: 0 0 12px 0;
	letter-spacing: -0.02em;
}

.dv-alerts-sort-wrap {
	position: relative;
	display: inline-block;
}

.dv-alerts-sort-wrap--open .dv-alerts-sort-trigger {
	border-color: rgba(45, 90, 61, 0.45);
	box-shadow: 0 1px 3px rgba(45, 90, 61, 0.12);
}

.dv-alerts-sort-wrap .dv-sort-menu {
	left: 0;
	right: auto;
}

.dv-alerts-page-header__actions {
	display: flex;
	align-items: center;
	gap: 10px;
	flex-shrink: 0;
}

.dv-alerts-action-btn {
	display: inline-flex;
	align-items: center;
	gap: 8px;
	padding: 10px 18px;
	background: #2d5a3d;
	color: #fff;
	border: none;
	border-radius: 10px;
	font: inherit;
	font-size: 0.88rem;
	font-weight: 600;
	cursor: pointer;
	transition: filter 0.15s ease, transform 0.1s ease;
}

.dv-alerts-action-btn:hover {
	filter: brightness(1.06);
}

.dv-alerts-action-btn:active {
	transform: translateY(1px);
}

.dv-alerts-table-wrap {
	background: var(--color-surface);
	border-radius: 14px;
	border: 1px solid var(--color-border);
	box-shadow: var(--shadow-sm);
	overflow-x: auto;
	opacity: 0;
	animation: dvAlertsTableSlideInUp 920ms cubic-bezier(0.22, 1, 0.36, 1) forwards;
}

@keyframes dvAlertsTableSlideInUp {
	from {
		opacity: 0;
		transform: translateY(40px);
	}
	70% {
		opacity: 0.85;
	}
	to {
		opacity: 1;
		transform: translateY(0);
	}
}

.dv-alerts-table {
	width: 100%;
	border-collapse: collapse;
	min-width: 760px;
}

.dv-alerts-table thead th {
	background: #011638;
	color: #fff;
	text-align: left;
	padding: 14px 18px;
	font-weight: 600;
	font-size: 0.88rem;
	letter-spacing: 0.02em;
}

.dv-alerts-row td {
	padding: 20px 18px;
	border-bottom: 1px solid var(--color-border);
	vertical-align: top;
	font-size: 0.92rem;
}

.dv-alerts-row:last-child td {
	border-bottom: none;
}

.dv-alerts-loc-title {
	font-weight: 700;
	margin: 0 0 4px 0;
	color: var(--color-text);
	font-size: 0.95rem;
}

.dv-alerts-loc-sub {
	font-size: 0.84rem;
	color: var(--color-text-muted);
	margin: 0 0 12px 0;
	font-weight: 500;
}

.dv-alerts-details p {
	margin: 0 0 6px 0;
	font-size: 0.82rem;
	line-height: 1.45;
	color: var(--color-text);
	font-weight: 500;
}

.dv-alerts-details p:last-child {
	margin-bottom: 0;
}

.dv-alerts-details__kw {
	font-weight: 600;
}

.dv-alerts-date-main {
	font-weight: 600;
	margin: 0 0 4px 0;
	color: var(--color-text);
}

.dv-alerts-date-sub {
	font-size: 0.8rem;
	color: var(--color-text-muted);
	margin: 0;
	font-weight: 500;
}

.dv-alerts-risk-val {
	font-weight: 700;
	font-size: 1.15rem;
	margin: 0 0 4px 0;
	color: var(--color-text);
	letter-spacing: -0.02em;
}

.dv-alerts-risk-sub {
	font-size: 0.8rem;
	color: var(--color-text-muted);
	margin: 0;
	font-weight: 500;
}

.dv-alerts-action-links {
	display: flex;
	flex-direction: column;
	gap: 8px;
	align-items: flex-start;
}

.dv-alerts-inline-action {
	font-size: 0.88rem;
	font-weight: 600;
	color: #2d5a3d;
	text-decoration: none;
}

.dv-alerts-inline-action:hover {
	text-decoration: underline;
}

.dv-alerts-inline-action--create {
	position: relative;
	display: inline-block;
	min-width: 86px;
	text-align: center;
	text-decoration: none;
}

.dv-alerts-inline-action--create:hover {
	text-decoration: none;
}

.dv-alerts-inline-action--create .dv-action-label {
	display: inline-block;
	transform-origin: center;
	transition: transform 0.2s ease, opacity 0.2s ease;
}

.dv-alerts-inline-action--create.dv-action--collapse .dv-action-label {
	transform: scaleX(0);
	opacity: 0;
}

.dv-alerts-inline-action--create .dv-action-split {
	position: relative;
	display: inline-block;
	min-width: 86px;
	height: 1.2em;
}

.dv-alerts-inline-action--create .dv-action-split__half {
	position: absolute;
	top: 0;
	opacity: 0;
	transition: transform 0.24s ease, opacity 0.24s ease;
	white-space: nowrap;
}

.dv-alerts-inline-action--create .dv-action-split__half--left {
	right: 50%;
	transform: translateX(0);
}

.dv-alerts-inline-action--create .dv-action-split__half--right {
	left: 50%;
	transform: translateX(0);
}

.dv-alerts-inline-action--create .dv-action-split.dv-action-split--open .dv-action-split__half {
	opacity: 1;
}

.dv-alerts-inline-action--create .dv-action-split.dv-action-split--open .dv-action-split__half--left {
	transform: translateX(-2px);
}

.dv-alerts-inline-action--create .dv-action-split.dv-action-split--open .dv-action-split__half--right {
	transform: translateX(2px);
}

.dv-alerts-footer {
	text-align: center;
	margin: 28px 0 8px;
}

.dv-alerts-show-all {
	background: none;
	border: none;
	font: inherit;
	font-size: 0.92rem;
	font-weight: 600;
	color: #2d5a3d;
	cursor: pointer;
	display: inline-flex;
	align-items: center;
	gap: 6px;
	padding: 8px 12px;
	border-radius: 8px;
	transition: background 0.15s ease;
}

.dv-alerts-show-all:hover {
	background: rgba(45, 90, 61, 0.08);
}

.dv-alerts-show-all__chev {
	flex-shrink: 0;
	color: #2d5a3d;
}

@media (max-width: 640px) {
	.dv-alerts-page-header {
		flex-direction: column;
		align-items: stretch;
	}

	.dv-alerts-page-header__actions {
		justify-content: flex-start;
		flex-wrap: wrap;
	}
}

/* —— Properties page —— */
.dv-properties-page {
	max-width: 1200px;
	margin: 0 auto;
}

.dv-properties-sort-wrap {
	position: relative;
	display: inline-block;
}

.dv-properties-sort-wrap--open .dv-sort-trigger {
	border-color: rgba(45, 90, 61, 0.45);
	box-shadow: 0 1px 3px rgba(45, 90, 61, 0.12);
}

.dv-properties-sort-wrap .dv-sort-menu {
	left: 0;
	right: auto;
}

.dv-properties-top-grid {
	display: grid;
	grid-template-columns: 1fr 1fr;
	gap: 22px;
	margin-bottom: 22px;
	align-items: stretch;
}

.dv-properties-summary-card {
	background: var(--color-surface);
	border-radius: 14px;
	border: 1px solid var(--color-border);
	box-shadow: var(--shadow-sm);
	overflow: hidden;
	display: flex;
	flex-direction: column;
}

.dv-properties-metrics-table {
	width: 100%;
	border-collapse: collapse;
}

.dv-properties-metrics-table thead th {
	background: #011638;
	color: #fff;
	text-align: left;
	padding: 14px 18px;
	font-weight: 700;
	font-size: 0.88rem;
}

.dv-properties-metrics-table tbody td {
	padding: 18px;
	font-size: 0.95rem;
	font-weight: 600;
	color: var(--color-text);
	border-bottom: 1px solid var(--color-border);
}

.dv-properties-metrics-table tbody tr:last-child td {
	border-bottom: none;
}

.dv-properties-issues {
	padding: 20px 22px 22px;
	flex: 1;
}

.dv-properties-issues__title {
	font-size: 1rem;
	font-weight: 700;
	color: var(--color-text);
	margin: 0 0 12px 0;
}

.dv-properties-issues__list {
	margin: 0;
	padding-left: 1.25rem;
	font-size: 0.92rem;
	font-weight: 500;
	line-height: 1.55;
	color: var(--color-text);
}

.dv-properties-issues__list li {
	margin-bottom: 8px;
}

.dv-properties-issues__list li:last-child {
	margin-bottom: 0;
}

.dv-properties-risk-card {
	display: flex;
	flex-direction: column;
	margin: 0;
}

.dv-properties-risk-head {
	display: flex;
	align-items: flex-start;
	justify-content: space-between;
	gap: 12px;
	margin-bottom: 8px;
}

.dv-properties-risk-head .dv-card__title {
	margin-bottom: 4px;
}

.dv-properties-risk-icons {
	display: flex;
	gap: 8px;
	flex-shrink: 0;
}

.dv-properties-risk-icons .dv-side-icon {
	display: flex;
	align-items: center;
	justify-content: center;
	width: 36px;
	height: 36px;
	border: 1px solid var(--color-border);
	border-radius: 8px;
	background: #fff;
	color: var(--color-text-muted);
}

.dv-properties-risk-gauge {
	flex: 1;
	display: flex;
	align-items: center;
	justify-content: center;
	padding: 8px 0 4px;
	min-height: 200px;
}

.dv-properties-risk-chart-body {
	flex: 1;
	display: flex;
	align-items: center;
	justify-content: center;
	padding: 8px 0 4px;
	min-height: 200px;
}

.dv-properties-risk-card .dv-properties-chart-views {
	justify-content: center;
	max-width: 320px;
	margin: 0 auto;
	width: 100%;
}

.dv-properties-page .dv-card:hover {
	transform: none;
}

.dv-properties-risk-card .dv-properties-risk-icons {
	position: relative;
	z-index: 2;
}

.dv-properties-risk-card .dv-properties-risk-icons .dv-side-icon {
	cursor: pointer;
}

.dv-properties-risk-card .dv-properties-risk-icons .dv-side-icon:hover {
	color: var(--color-text);
	border-color: #c5cdd4;
}

.dv-properties-risk-card .dv-properties-risk-icons .dv-side-icon:focus-visible {
	outline: 2px solid #2d5a3d;
	outline-offset: 2px;
}

.dv-properties-risk-card .dv-properties-risk-icons .dv-side-icon.dv-side-icon--active {
	border-color: #2d5a3d;
	color: #2d5a3d;
	background: rgba(45, 90, 61, 0.06);
}

.dv-heatmap-card {
	background: var(--color-surface);
	border-radius: 14px;
	border: 1px solid var(--color-border);
	box-shadow: var(--shadow-sm);
	padding: 22px 24px 24px;
}

.dv-heatmap-head {
	display: flex;
	align-items: flex-start;
	justify-content: space-between;
	gap: 20px;
	flex-wrap: wrap;
	margin-bottom: 20px;
}

.dv-heatmap-title {
	font-size: 1.05rem;
	font-weight: 700;
	color: var(--color-text);
	margin: 0;
	letter-spacing: -0.02em;
}

.dv-heatmap-subtitle {
	font-size: 0.78rem;
	font-weight: 600;
	color: var(--color-text-muted);
	margin: 6px 0 0 0;
}

.dv-heatmap-legend-wrap {
	display: flex;
	align-items: center;
	gap: 10px;
	flex-shrink: 0;
}

.dv-heatmap-legend-label {
	font-size: 0.72rem;
	font-weight: 600;
	color: var(--color-text-muted);
	white-space: nowrap;
}

.dv-heatmap-legend-bar {
	width: 180px;
	max-width: 40vw;
	height: 12px;
	border-radius: 6px;
	background: linear-gradient(90deg, #2e7d32 0%, #f9a825 50%, #c62828 100%);
	box-shadow: inset 0 1px 2px rgba(0, 0, 0, 0.08);
}

.dv-heatmap-floors {
	display: flex;
	flex-direction: column;
	gap: 4px;
}

.dv-heatmap-floor {
	display: grid;
	grid-template-columns: 88px 1fr;
	gap: 14px 16px;
	align-items: start;
}

@media (max-width: 600px) {
	.dv-heatmap-floor {
		grid-template-columns: 1fr;
	}
}

.dv-heatmap-floor-label {
	font-size: 0.88rem;
	font-weight: 700;
	color: var(--color-text-muted);
	padding-top: 8px;
}

.dv-heatmap-units {
	display: flex;
	flex-wrap: wrap;
	align-content: flex-start;
	/* Explicit both axes so row spacing matches column spacing */
	row-gap: 4px;
	column-gap: 4px;
}

.dv-unit {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	min-width: 44px;
	height: 44px;
	padding: 0 8px;
	border-radius: 0;
	font-size: 0.85rem;
	font-weight: 700;
	/* Subtle edge so adjacent tiles read as separate cells */
	box-shadow: inset 0 0 0 1px rgba(0, 0, 0, 0.06);
}

/* Low-risk “green” band: stepped shades (cooler → warmer within safe range) */
.dv-unit--heat-g1 {
	background: #c5e1a5;
	color: #1b3308;
}

.dv-unit--heat-g2 {
	background: #9ccc65;
	color: #1e3d0f;
}

.dv-unit--heat-g3 {
	background: #7cb342;
	color: #fff;
	text-shadow: 0 1px 0 rgba(0, 0, 0, 0.12);
}

.dv-unit--heat-g4 {
	background: #689f38;
	color: #fff;
	text-shadow: 0 1px 0 rgba(0, 0, 0, 0.15);
}

.dv-unit--heat-g5 {
	background: #558b2f;
	color: #fff;
	text-shadow: 0 1px 0 rgba(0, 0, 0, 0.18);
}

.dv-unit--med {
	background: #f9a825;
	color: #1a1d21;
}

.dv-unit--high {
	background: #c62828;
	color: #fff;
	text-shadow: 0 1px 0 rgba(0, 0, 0, 0.2);
}

@media (max-width: 900px) {
	.dv-properties-top-grid {
		grid-template-columns: 1fr;
	}
}

/* —— Cases page —— */
.dv-cases-page {
	max-width: 900px;
	margin: 0 auto;
}

.dv-reports-hub-page .dv-cases-page-header {
	margin-bottom: 22px;
}

.dv-reports-hub-sort-dropdown {
	position: relative;
	display: inline-block;
}

.dv-reports-hub-sort-dropdown--open .dv-cases-sort-trigger {
	border-color: rgba(45, 90, 61, 0.45);
	box-shadow: 0 1px 3px rgba(45, 90, 61, 0.12);
}

.dv-reports-hub-sort-dropdown .dv-sort-menu {
	left: 0;
	right: auto;
}

.dv-reports-pdf-modal {
	position: fixed;
	inset: 0;
	z-index: 4000;
	padding: 20px;
	box-sizing: border-box;
	opacity: 0;
	visibility: hidden;
	pointer-events: none;
	transition:
		opacity 0.32s cubic-bezier(0.4, 0, 0.2, 1),
		visibility 0s linear 0.32s;
}

.dv-reports-pdf-modal.dv-reports-pdf-modal--open {
	opacity: 1;
	visibility: visible;
	pointer-events: auto;
	transition:
		opacity 0.34s cubic-bezier(0.4, 0, 0.2, 1),
		visibility 0s linear 0s;
}

.dv-reports-pdf-modal__backdrop {
	position: absolute;
	inset: 0;
	background: rgba(0, 0, 0, 0.4);
	transition: background 0.34s ease;
}

.dv-reports-pdf-modal--open .dv-reports-pdf-modal__backdrop {
	background: rgba(0, 0, 0, 0.48);
}

.dv-reports-pdf-modal__dialog {
	position: absolute;
	left: 50%;
	top: 50%;
	z-index: 1;
	display: flex;
	flex-direction: column;
	width: min(920px, calc(100% - 40px));
	height: min(88vh, 820px);
	max-height: calc(100% - 40px);
	background: var(--color-surface);
	border-radius: 14px;
	border: 1px solid var(--color-border);
	box-shadow: 0 24px 64px rgba(0, 0, 0, 0.22);
	overflow: hidden;
	transform: translate(-50%, calc(-50% + 14px)) scale(0.97);
	opacity: 0;
	transition:
		transform 0.4s cubic-bezier(0.22, 1, 0.36, 1),
		opacity 0.34s cubic-bezier(0.4, 0, 0.2, 1);
	will-change: transform, opacity;
}

.dv-reports-pdf-modal--open .dv-reports-pdf-modal__dialog {
	transform: translate(-50%, -50%) scale(1);
	opacity: 1;
}

.dv-reports-pdf-modal__head {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 12px;
	padding: 14px 16px;
	border-bottom: 1px solid var(--color-border);
	flex-shrink: 0;
}

.dv-reports-pdf-modal__title {
	margin: 0;
	font-size: 1.05rem;
	font-weight: 700;
	color: var(--color-text);
	letter-spacing: -0.02em;
}

.dv-reports-pdf-modal__close {
	display: flex;
	align-items: center;
	justify-content: center;
	width: 40px;
	height: 40px;
	padding: 0;
	border: none;
	border-radius: 10px;
	background: transparent;
	color: var(--color-text-muted);
	cursor: pointer;
	transition: background 0.15s ease, color 0.15s ease;
}

.dv-reports-pdf-modal__close:hover {
	background: rgba(1, 22, 56, 0.08);
	color: var(--color-text);
}

.dv-reports-pdf-modal__frame-wrap {
	flex: 1;
	min-height: 0;
	background: #e8ecf0;
}

.dv-reports-pdf-modal__frame {
	display: block;
	width: 100%;
	height: 100%;
	min-height: 320px;
	border: 0;
}

.dv-case-print-modal__actions {
	display: flex;
	align-items: center;
	gap: 8px;
}

.dv-alerts-action-btn--mini {
	padding: 8px 12px;
	font-size: 0.8rem;
}

.dv-cases-action-link--btn {
	display: inline;
	background: none;
	border: none;
	padding: 0;
	margin: 0;
	cursor: pointer;
	text-align: right;
	font: inherit;
	font-size: inherit;
	font-weight: inherit;
	color: inherit;
}

.dv-cases-action-link--btn:hover {
	text-decoration: underline;
}

.dv-cases-page-header {
	display: flex;
	flex-direction: column;
	align-items: flex-start;
	gap: 12px;
	margin-bottom: 22px;
}

.dv-cases-page-title {
	font-size: 1.5rem;
	font-weight: 700;
	color: var(--color-primary);
	margin: 0;
	letter-spacing: -0.02em;
}

.dv-cases-sort-wrap {
	display: flex;
	align-items: center;
	gap: 10px;
	flex-wrap: wrap;
}

.dv-cases-sort-prefix {
	font-size: 0.95rem;
	font-weight: 500;
	color: var(--color-text-muted);
}

.dv-cases-sort-dropdown {
	position: relative;
	display: inline-block;
}

.dv-cases-sort-dropdown--open .dv-cases-sort-trigger {
	border-color: rgba(45, 90, 61, 0.45);
	box-shadow: 0 1px 3px rgba(45, 90, 61, 0.12);
}

.dv-cases-sort-value {
	color: #2d5a3d;
	font-weight: 600;
}

.dv-cases-table-wrap {
	background: var(--color-surface);
	border-radius: 14px;
	border: 1px solid var(--color-border);
	box-shadow: var(--shadow-sm);
	overflow: hidden;
}

.dv-cases-table {
	width: 100%;
	border-collapse: collapse;
}

.dv-cases-table thead th {
	background: #011638;
	color: #fff;
	padding: 14px 20px;
	font-size: 0.88rem;
	font-weight: 700;
}

.dv-cases-table thead th:nth-child(1) {
	text-align: left;
}

.dv-cases-table thead th:nth-child(2) {
	text-align: center;
}

.dv-cases-table thead th:nth-child(3) {
	text-align: center;
}

.dv-cases-table thead th:nth-child(4) {
	text-align: center;
}

.dv-cases-table thead th:nth-child(5) {
	text-align: right;
}

.dv-reports-hub-table thead th:nth-child(3) {
	text-align: right;
}

.dv-cases-row td {
	padding: 20px;
	vertical-align: top;
	border-bottom: 1px solid var(--color-border);
	font-size: 0.92rem;
}

.dv-cases-row:last-child td {
	border-bottom: none;
}

.dv-cases-cell-case {
	text-align: left;
}

.dv-cases-case-id {
	font-weight: 700;
	margin: 0;
	color: var(--color-text);
}

.dv-cases-case-sub {
	margin: 6px 0 0 0;
	font-size: 0.84rem;
	font-weight: 500;
	color: var(--color-text-muted);
}

.dv-cases-loc-title {
	margin: 0;
	font-size: 0.95rem;
	font-weight: 700;
	color: var(--color-text);
}

.dv-cases-status-main {
	margin: 0;
	font-size: 0.95rem;
	font-weight: 700;
	color: var(--color-text);
}

.dv-cases-status-sub {
	margin: 4px 0 0 0;
	font-size: 0.84rem;
	font-weight: 500;
	color: var(--color-text-muted);
}

.dv-cases-cell-date {
	text-align: center;
	font-weight: 600;
	color: var(--color-text);
}

.dv-cases-cell-actions {
	text-align: right;
}

.dv-cases-actions {
	display: flex;
	flex-direction: column;
	align-items: flex-end;
	gap: 8px;
}

.dv-cases-action-link {
	font-size: 0.88rem;
	font-weight: 600;
	color: #2d5a3d;
	text-decoration: none;
}

.dv-cases-action-link:hover {
	text-decoration: underline;
}

.dv-cases-footer {
	text-align: center;
	margin: 28px 0 8px;
}

.dv-cases-show-all {
	background: none;
	border: none;
	font: inherit;
	font-size: 0.92rem;
	font-weight: 600;
	color: #2d5a3d;
	cursor: pointer;
	display: inline-flex;
	align-items: center;
	gap: 6px;
	padding: 8px 12px;
	border-radius: 8px;
	transition: background 0.15s ease;
}

.dv-cases-show-all:hover {
	background: rgba(45, 90, 61, 0.08);
}

.dv-cases-show-all__chev {
	flex-shrink: 0;
	color: #2d5a3d;
}

@media (max-width: 640px) {
	.dv-cases-table thead {
		display: none;
	}

	.dv-cases-row,
	.dv-cases-row td {
		display: block;
		width: 100%;
		text-align: left !important;
	}

	.dv-cases-row td {
		border-bottom: none;
		padding: 12px 16px;
	}

	.dv-cases-row td::before {
		display: block;
		font-size: 0.75rem;
		font-weight: 700;
		color: var(--color-text-muted);
		margin-bottom: 4px;
		text-transform: uppercase;
		letter-spacing: 0.04em;
	}

	.dv-cases-cell-case::before {
		content: "Month";
	}

	.dv-cases-cell-date::before {
		content: "Date";
	}

	.dv-cases-cell-actions::before {
		content: "Export";
	}

	.dv-cases-row {
		border-bottom: 1px solid var(--color-border);
		padding: 8px 0;
	}

	.dv-cases-actions {
		align-items: flex-start;
	}
}

/* —— Case detail —— */
.dv-case-detail-page {
	max-width: 1100px;
	margin: 0 auto;
	opacity: 0;
	transform: translateY(20px);
	transition: opacity 380ms cubic-bezier(0.22, 1, 0.36, 1), transform 380ms cubic-bezier(0.22, 1, 0.36, 1);
}

.dv-case-detail-page.dv-case-detail-page--enter {
	opacity: 1;
	transform: translateY(0);
}

@media (prefers-reduced-motion: reduce) {
	.dv-case-detail-page {
		opacity: 1;
		transform: none;
		transition: none;
	}
}

.dv-case-detail-header {
	display: flex;
	align-items: flex-start;
	justify-content: space-between;
	gap: 20px;
	flex-wrap: wrap;
	margin-bottom: 24px;
}

.dv-case-detail-header__left {
	flex: 1;
	min-width: 220px;
}

.dv-case-detail-title {
	font-size: 1.65rem;
	font-weight: 700;
	color: var(--color-primary);
	margin: 0 0 12px 0;
	letter-spacing: -0.02em;
}

.dv-case-detail-sort-dropdown {
	position: relative;
	display: inline-block;
}

.dv-case-detail-sort-dropdown--open .dv-cases-sort-trigger {
	border-color: rgba(45, 90, 61, 0.45);
	box-shadow: 0 1px 3px rgba(45, 90, 61, 0.12);
}

.dv-case-detail-info-card {
	background: var(--color-surface);
	border-radius: 14px;
	border: 1px solid var(--color-border);
	box-shadow: var(--shadow-sm);
	overflow: hidden;
	margin-bottom: 22px;
}

.dv-case-detail-info-table {
	width: 100%;
	border-collapse: collapse;
}

.dv-case-detail-info-table thead th {
	background: #011638;
	color: #fff;
	padding: 14px 18px;
	font-size: 0.88rem;
	font-weight: 700;
}

.dv-case-detail-info-table thead th:nth-child(1) {
	text-align: left;
}

.dv-case-detail-info-table thead th:nth-child(2) {
	text-align: center;
}

.dv-case-detail-info-table thead th:nth-child(3) {
	text-align: left;
}

.dv-case-detail-info-table thead th:nth-child(4) {
	text-align: right;
}

.dv-case-detail-info-table tbody td {
	padding: 18px;
	vertical-align: top;
	border-bottom: 1px solid var(--color-border);
	font-size: 0.92rem;
}

.dv-case-detail-info-cell--loc {
	text-align: left;
}

.dv-case-detail-info-cell--date {
	text-align: center;
	font-weight: 600;
}

.dv-case-detail-info-cell--assign {
	text-align: left;
}

.dv-case-detail-assignee-trigger {
	display: inline-flex;
	flex-direction: column;
	align-items: flex-start;
	gap: 0;
	width: 100%;
	padding: 0;
	margin: 0;
	background: transparent;
	border: none;
	text-align: left;
	cursor: pointer;
}

.dv-case-detail-assignee-trigger:hover .dv-case-detail-strong {
	color: var(--color-primary-dark);
}

.dv-case-detail-assignee-trigger:focus-visible {
	outline: 2px solid #2d5a3d;
	outline-offset: 3px;
	border-radius: 8px;
}

.dv-case-detail-info-cell--status {
	text-align: right;
}

.dv-case-detail-strong {
	font-weight: 700;
	margin: 0;
	color: var(--color-text);
}

.dv-case-detail-muted {
	margin: 6px 0 0 0;
	font-size: 0.84rem;
	font-weight: 500;
	color: var(--color-text-muted);
}

.dv-case-detail-desc {
	padding: 22px 22px 24px;
	border-top: 1px solid var(--color-border);
}

.dv-case-detail-desc__label {
	font-size: 0.72rem;
	font-weight: 700;
	text-transform: uppercase;
	letter-spacing: 0.06em;
	color: var(--color-text-muted);
	margin: 0 0 8px 0;
}

.dv-case-detail-desc__label:not(:first-child) {
	margin-top: 18px;
}

.dv-case-detail-desc__type {
	font-weight: 700;
	font-size: 0.95rem;
	margin: 0 0 0 0;
	color: var(--color-text);
	display: flex;
	flex-wrap: wrap;
	align-items: baseline;
	gap: 0;
}

.dv-case-detail-desc__type-sep {
	font-weight: 700;
	color: var(--color-text-muted);
	white-space: pre;
}

.dv-case-detail-desc__type-part {
	font: inherit;
	font-weight: 700;
	margin: 0;
	padding: 0;
	color: var(--color-primary);
	background: none;
	border: none;
	border-radius: 4px;
	cursor: pointer;
	text-align: left;
	text-decoration: underline;
	text-decoration-color: transparent;
	text-underline-offset: 3px;
	transition: color 0.15s ease, text-decoration-color 0.15s ease, background 0.15s ease;
}

.dv-case-detail-desc__type-part:hover {
	color: var(--color-primary-dark);
	text-decoration-color: currentColor;
}

.dv-case-detail-desc__type-part:focus-visible {
	outline: 2px solid #2d5a3d;
	outline-offset: 2px;
}

/* Case detail: issue type info (compact modal, same interaction pattern as reports PDF) */
.dv-case-issue-modal {
	position: fixed;
	inset: 0;
	z-index: 4000;
	padding: 20px;
	box-sizing: border-box;
	opacity: 0;
	visibility: hidden;
	pointer-events: none;
	transition:
		opacity 0.32s cubic-bezier(0.4, 0, 0.2, 1),
		visibility 0s linear 0.32s;
}

.dv-case-issue-modal.dv-case-issue-modal--open {
	opacity: 1;
	visibility: visible;
	pointer-events: auto;
	transition:
		opacity 0.34s cubic-bezier(0.4, 0, 0.2, 1),
		visibility 0s linear 0s;
}

.dv-case-issue-modal__backdrop {
	position: absolute;
	inset: 0;
	background: rgba(0, 0, 0, 0.4);
	transition: background 0.34s ease;
}

.dv-case-issue-modal--open .dv-case-issue-modal__backdrop {
	background: rgba(0, 0, 0, 0.48);
}

.dv-case-issue-modal__dialog {
	position: absolute;
	left: 50%;
	top: 50%;
	z-index: 1;
	display: flex;
	flex-direction: column;
	width: min(420px, calc(100% - 40px));
	max-width: 100%;
	max-height: min(420px, calc(100% - 40px));
	background: var(--color-surface);
	border-radius: 14px;
	border: 1px solid var(--color-border);
	box-shadow: 0 24px 64px rgba(0, 0, 0, 0.22);
	overflow: hidden;
	transform: translate(-50%, calc(-50% + 14px)) scale(0.97);
	opacity: 0;
	transition:
		transform 0.4s cubic-bezier(0.22, 1, 0.36, 1),
		opacity 0.34s cubic-bezier(0.4, 0, 0.2, 1);
	will-change: transform, opacity;
}

.dv-case-issue-modal--open .dv-case-issue-modal__dialog {
	transform: translate(-50%, -50%) scale(1);
	opacity: 1;
}

.dv-case-issue-modal__head {
	display: flex;
	align-items: flex-start;
	justify-content: space-between;
	gap: 12px;
	padding: 16px 18px 12px;
	border-bottom: 1px solid var(--color-border);
	flex-shrink: 0;
}

.dv-case-issue-modal__title {
	margin: 0;
	padding-right: 8px;
	font-size: 1.05rem;
	font-weight: 700;
	color: var(--color-text);
	letter-spacing: -0.02em;
	line-height: 1.3;
}

.dv-case-issue-modal__close {
	display: flex;
	align-items: center;
	justify-content: center;
	width: 40px;
	height: 40px;
	margin: -4px -6px 0 0;
	padding: 0;
	flex-shrink: 0;
	border: none;
	border-radius: 10px;
	background: transparent;
	color: var(--color-text-muted);
	cursor: pointer;
	transition: background 0.15s ease, color 0.15s ease;
}

.dv-case-issue-modal__close:hover {
	background: rgba(1, 22, 56, 0.08);
	color: var(--color-text);
}

.dv-case-issue-modal__body {
	padding: 16px 18px 20px;
	overflow-y: auto;
	flex: 1;
	min-height: 0;
}

.dv-case-issue-modal__text {
	margin: 0;
	font-size: 0.92rem;
	font-weight: 500;
	line-height: 1.55;
	color: var(--color-text);
}

.dv-case-timeline-modal__dialog {
	width: min(820px, calc(100% - 40px));
	max-height: min(520px, calc(100% - 40px));
}

.dv-case-timeline-modal__body {
	padding-top: 10px;
}

.dv-case-timeline-modal__updated {
	margin: 0 0 14px 0;
	font-size: 0.82rem;
	font-weight: 600;
	color: var(--color-text-muted);
}

.dv-case-timeline-modal__list {
	list-style: none;
	margin: 0;
	padding: 0;
	border-top: 1px solid var(--color-border);
}

.dv-case-timeline-modal__item {
	display: grid;
	grid-template-columns: 110px 1fr;
	gap: 12px 16px;
	padding: 12px 0;
	border-bottom: 1px solid var(--color-border);
}

.dv-case-timeline-modal__time {
	font-size: 1rem;
	font-weight: 700;
	color: #626b7b;
	line-height: 1.1;
}

.dv-case-timeline-modal__desc {
	font-size: 0.97rem;
	font-weight: 600;
	color: var(--color-text);
	line-height: 1.35;
}

.dv-case-assignee-modal__dialog {
	width: min(460px, calc(100% - 40px));
	max-height: min(520px, calc(100% - 40px));
}

.dv-case-assignee-list {
	list-style: none;
	margin: 0;
	padding: 0;
	max-height: 290px;
	overflow-y: auto;
	border: 1px solid var(--color-border);
	border-radius: 12px;
}

.dv-case-assignee-item + .dv-case-assignee-item {
	border-top: 1px solid var(--color-border);
}

.dv-case-assignee-item__btn {
	display: block;
	width: 100%;
	text-align: left;
	padding: 11px 13px;
	background: transparent;
	border: none;
	cursor: pointer;
}

.dv-case-assignee-item__btn:hover {
	background: rgba(17, 92, 52, 0.08);
}

.dv-case-assignee-item[aria-selected='true'] .dv-case-assignee-item__btn {
	background: rgba(17, 92, 52, 0.12);
}

.dv-case-assignee-item__name {
	display: block;
	font-size: 0.95rem;
	font-weight: 700;
	color: var(--color-text);
}

.dv-case-assignee-item__role {
	display: block;
	margin-top: 4px;
	font-size: 0.82rem;
	font-weight: 500;
	color: var(--color-text-muted);
}

.dv-case-assignee-status {
	margin: 10px 0 0;
	min-height: 1.2em;
	font-size: 0.82rem;
	font-weight: 600;
	color: var(--color-text-muted);
}

.dv-case-assignee-actions {
	display: flex;
	justify-content: flex-end;
	margin-top: 10px;
}

.dv-case-timeline-modal__empty {
	padding: 14px 0;
	font-size: 0.9rem;
	font-weight: 500;
	color: var(--color-text-muted);
}

.dv-case-detail-desc__summary {
	margin: 0;
	font-size: 0.92rem;
	font-weight: 500;
	line-height: 1.55;
	color: var(--color-text);
}

.dv-case-detail-split {
	display: grid;
	grid-template-columns: 1fr 1fr;
	gap: 22px;
	align-items: stretch;
}

.dv-case-detail-panel-card {
	background: var(--color-surface);
	border-radius: 14px;
	border: 1px solid var(--color-border);
	box-shadow: var(--shadow-sm);
	padding: 22px 24px 24px;
	display: flex;
	flex-direction: column;
	min-height: 100%;
	box-sizing: border-box;
}

.dv-case-detail-panel-title {
	font-size: 1.95rem;
	font-weight: 700;
	margin: 0 0 14px 0;
	color: var(--color-text);
}

.dv-case-detail-section {
	border-top: 1px solid #7f8793;
	padding: 14px 0;
}

.dv-case-detail-section--notes {
	padding-top: 0;
	border-top: none;
}

.dv-case-detail-notes-label {
	font-size: 1.05rem;
	font-weight: 700;
	line-height: 1.15;
	margin: 0 0 2px 0;
	color: var(--color-text);
}

.dv-case-detail-evidence-notes {
	font-size: 0.95rem;
	font-weight: 500;
	line-height: 1.25;
	margin: 0;
	color: #626b7b;
}

.dv-case-detail-notes-input {
	width: 100%;
	box-sizing: border-box;
	margin-top: 2px;
	padding: 10px 12px;
	border: 1px solid #c8ced8;
	border-radius: 8px;
	background: #fff;
	font: inherit;
	font-size: 0.95rem;
	font-weight: 500;
	line-height: 1.45;
	color: #2c3340;
	resize: vertical;
	min-height: 68px;
}

.dv-case-detail-notes-input:focus-visible {
	outline: 2px solid rgba(45, 90, 61, 0.32);
	outline-offset: 1px;
	border-color: #2d5a3d;
}

.dv-case-detail-notes-controls {
	display: flex;
	align-items: center;
	gap: 12px;
	margin-top: 10px;
}

.dv-case-detail-notes-save {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	padding: 8px 14px;
	border: none;
	border-radius: 8px;
	background: #2d5a3d;
	color: #fff;
	font: inherit;
	font-size: 0.86rem;
	font-weight: 700;
	cursor: pointer;
	transition: filter 0.15s ease, opacity 0.15s ease;
}

.dv-case-detail-notes-save:hover {
	filter: brightness(1.06);
}

.dv-case-detail-notes-save:disabled {
	cursor: not-allowed;
	opacity: 0.65;
}

.dv-case-detail-notes-status {
	font-size: 0.84rem;
	font-weight: 600;
	color: #5f6878;
	min-height: 1em;
}

.dv-case-detail-row-head {
	display: flex;
	align-items: baseline;
	justify-content: space-between;
	gap: 12px;
}

.dv-case-detail-row-title {
	font-size: 0.95rem;
	font-weight: 700;
	line-height: 1.15;
	color: var(--color-text);
}

.dv-case-detail-files {
	margin: 2px 0 0 0;
	display: flex;
	flex-wrap: wrap;
	gap: 0;
}

.dv-case-detail-file-link {
	font-size: 0.95rem;
	font-weight: 500;
	color: #626b7b;
	text-decoration: none;
}

.dv-case-detail-file-link:hover {
	text-decoration: underline;
}

.dv-case-detail-inline-link {
	font-size: 0.95rem;
	font-weight: 600;
	color: #2d5a3d;
	text-decoration: none;
}

.dv-case-detail-inline-link:hover {
	text-decoration: underline;
}

.dv-case-detail-timeline-count {
	margin: 6px 0 0;
	font-size: 0.9rem;
	font-weight: 600;
	color: #626b7b;
}

.dv-case-detail-card-actions {
	display: flex;
	justify-content: space-between;
	flex-wrap: nowrap;
	gap: 18px;
	margin-top: auto;
	padding-top: 28px;
}

.dv-case-detail-pill-btn {
	flex: 1 1 0;
	min-width: 0;
	padding: 14px 26px;
	border: none;
	border-radius: 22px;
	background: #2d5a3d;
	color: #fff;
	font: inherit;
	font-size: 1rem;
	font-weight: 700;
	line-height: 1.1;
	cursor: pointer;
	transition: filter 0.15s ease;
}

.dv-case-detail-pill-btn:hover {
	filter: brightness(1.06);
}

.dv-case-detail-checklist {
	list-style: none;
	margin: 0;
	padding: 0;
}

.dv-case-detail-checklist li {
	margin-bottom: 14px;
}

.dv-case-detail-checklist li:last-child {
	margin-bottom: 0;
}

.dv-case-detail-check-label {
	display: flex;
	align-items: flex-start;
	gap: 12px;
	font-size: 0.92rem;
	font-weight: 500;
	color: var(--color-text);
	cursor: pointer;
	line-height: 1.4;
}

.dv-case-detail-checkbox {
	width: 18px;
	height: 18px;
	margin: 2px 0 0 0;
	flex-shrink: 0;
	accent-color: #2d5a3d;
	cursor: pointer;
}

.dv-case-detail-panel-footer {
	text-align: center;
	margin: 20px 0 0;
	padding-top: 18px;
	border-top: 1px solid var(--color-border);
	margin-top: auto;
}

.dv-case-detail-show-more {
	background: none;
	border: none;
	font: inherit;
	font-size: 0.92rem;
	font-weight: 600;
	color: #2d5a3d;
	cursor: pointer;
	display: inline-flex;
	align-items: center;
	gap: 6px;
	padding: 6px 10px;
	border-radius: 8px;
	transition: background 0.15s ease;
}

.dv-case-detail-show-more:hover {
	background: rgba(45, 90, 61, 0.08);
}

.dv-case-detail-show-more__chev {
	flex-shrink: 0;
	color: #2d5a3d;
}

@media (max-width: 900px) {
	.dv-case-detail-split {
		grid-template-columns: 1fr;
	}
}

@media (max-width: 640px) {
	.dv-case-detail-info-table thead {
		display: none;
	}

	.dv-case-detail-info-table tbody tr {
		display: block;
	}

	.dv-case-detail-info-table tbody td {
		display: block;
		width: 100%;
		text-align: left !important;
		border-bottom: none;
		padding: 12px 16px;
	}

	.dv-case-detail-info-table tbody td::before {
		display: block;
		font-size: 0.72rem;
		font-weight: 700;
		color: var(--color-text-muted);
		margin-bottom: 6px;
		text-transform: uppercase;
		letter-spacing: 0.04em;
	}

	.dv-case-detail-info-cell--loc::before {
		content: "Location";
	}

	.dv-case-detail-info-cell--date::before {
		content: "Date";
	}

	.dv-case-detail-info-cell--assign::before {
		content: "Assigned";
	}

	.dv-case-detail-info-cell--status::before {
		content: "Status";
	}

	.dv-case-detail-info-table tbody tr {
		border-bottom: 1px solid var(--color-border);
		padding-bottom: 8px;
	}
}

/* —— Account page —— */
.dv-account-page {
	max-width: 720px;
	margin: 0 auto;
}

.dv-account-header {
	margin-bottom: 22px;
}

.dv-account-title {
	font-size: 1.5rem;
	font-weight: 700;
	color: var(--color-text);
	margin: 0 0 8px 0;
	letter-spacing: -0.02em;
}

.dv-account-subtitle {
	margin: 0;
	font-size: 0.95rem;
	font-weight: 500;
	color: var(--color-text-muted);
}

.dv-account-card {
	background: var(--color-surface);
	border-radius: 14px;
	border: 1px solid var(--color-border);
	box-shadow: var(--shadow-sm);
	padding: 28px 28px 24px;
}

.dv-account-section {
	margin: 0;
}

.dv-account-section--divider {
	margin-top: 28px;
	padding-top: 28px;
	border-top: 1px solid var(--color-border);
}

.dv-account-section-heading {
	display: flex;
	align-items: center;
	gap: 10px;
	font-size: 1.02rem;
	font-weight: 700;
	color: var(--color-text);
	margin: 0 0 20px 0;
	letter-spacing: -0.02em;
}

.dv-account-section-icon {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	color: var(--color-text-muted);
}

.dv-account-grid--2 {
	display: grid;
	grid-template-columns: repeat(2, minmax(0, 1fr));
	gap: 18px 22px;
}

@media (max-width: 640px) {
	.dv-account-grid--2 {
		grid-template-columns: 1fr;
	}
}

.dv-account-field {
	display: flex;
	flex-direction: column;
	gap: 6px;
	min-width: 0;
}

.dv-account-label {
	font-size: 0.78rem;
	font-weight: 600;
	color: var(--color-text-muted);
}

.dv-account-input,
.dv-account-select {
	width: 100%;
	box-sizing: border-box;
	padding: 11px 14px;
	font: inherit;
	font-size: 0.92rem;
	color: var(--color-text);
	background: #fff;
	border: 1px solid #d5dde3;
	border-radius: var(--radius-sm);
	outline: none;
}

.dv-account-input:read-only,
.dv-account-select:disabled {
	color: var(--color-text);
	opacity: 1;
	cursor: default;
	background: #fafbfc;
}

.dv-account-select {
	appearance: none;
	background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' viewBox='0 0 24 24' fill='none' stroke='%235f6368' stroke-width='2'%3E%3Cpath d='M6 9l6 6 6-6'/%3E%3C/svg%3E");
	background-repeat: no-repeat;
	background-position: right 12px center;
	padding-right: 36px;
}

.dv-account-details {
	margin-top: 28px;
	padding-top: 20px;
	border-top: 1px solid var(--color-border);
}

.dv-account-details-summary {
	list-style: none;
	display: flex;
	align-items: center;
	justify-content: center;
	gap: 8px;
	cursor: pointer;
	font-size: 0.92rem;
	font-weight: 600;
	color: var(--color-success);
	user-select: none;
}

.dv-account-details-summary::-webkit-details-marker {
	display: none;
}

.dv-account-details-chev {
	flex-shrink: 0;
	transition: transform 0.2s ease;
}

.dv-account-details[open] .dv-account-details-chev {
	transform: rotate(180deg);
}

.dv-account-details-body {
	padding: 16px 8px 0;
	text-align: center;
}

.dv-account-details-hint {
	margin: 0;
	font-size: 0.88rem;
	font-weight: 500;
	color: var(--color-text-muted);
	line-height: 1.45;
}

/* Case print preview page (shown inside modal iframe) */
body.dv-case-print-page {
	margin: 0;
	padding: 0;
	background: #f7f7f7;
	color: #111;
	font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
}

.dv-case-print-wrap {
	max-width: 920px;
	margin: 0 auto;
	padding: 26px 28px 36px;
	background: #fff;
	box-sizing: border-box;
}

.dv-case-print-header {
	border-bottom: 2px solid #011638;
	padding-bottom: 10px;
	margin-bottom: 18px;
}

.dv-case-print-title {
	margin: 0;
	font-size: 1.45rem;
	font-weight: 700;
	color: #111;
}

.dv-case-print-subtitle {
	margin: 6px 0 0;
	font-size: 0.92rem;
	font-weight: 500;
	color: #555;
}

.dv-case-print-block {
	margin-bottom: 18px;
	page-break-inside: avoid;
}

.dv-case-print-block__title {
	margin: 0 0 8px;
	font-size: 1.02rem;
	font-weight: 700;
	color: #111;
}

.dv-case-print-grid {
	display: grid;
	grid-template-columns: repeat(2, minmax(0, 1fr));
	gap: 10px 16px;
	font-size: 0.9rem;
	line-height: 1.4;
}

.dv-case-print-para {
	margin: 10px 0 0;
	font-size: 0.9rem;
	font-weight: 500;
	line-height: 1.45;
	color: #222;
}

.dv-case-print-list {
	margin: 0;
	padding-left: 1.1rem;
	font-size: 0.9rem;
	line-height: 1.45;
}

@media print {
	body.dv-case-print-page {
		background: #fff;
	}
	.dv-case-print-wrap {
		max-width: none;
		margin: 0;
		padding: 0;
	}
}

/* Heatmap unit cells (links) */
a.dv-unit--cell {
	text-decoration: none;
	color: inherit;
	cursor: pointer;
	box-sizing: border-box;
	transition: filter 0.12s ease, transform 0.1s ease;
}

a.dv-unit--cell:hover {
	filter: brightness(0.97);
}

a.dv-unit--cell:focus-visible {
	outline: 2px solid var(--color-primary);
	outline-offset: 2px;
}

/* Property unit drill-in (heatmap) */
.dv-property-unit-page {
	max-width: 1200px;
	margin: 0 auto;
}

.dv-property-unit-header {
	display: flex;
	align-items: flex-start;
	justify-content: space-between;
	gap: 20px;
	flex-wrap: wrap;
	margin-bottom: 22px;
}

.dv-property-unit-header__left {
	flex: 1;
	min-width: 200px;
}

.dv-property-unit-back,
.dv-case-detail-back {
	display: inline-block;
	font-size: 0.88rem;
	font-weight: 600;
	color: var(--color-primary);
	text-decoration: underline;
	text-underline-offset: 3px;
	margin-bottom: 10px;
}

.dv-property-unit-back:hover,
.dv-case-detail-back:hover {
	color: var(--color-primary-dark);
}

.dv-property-unit-title {
	font-size: 1.5rem;
	font-weight: 700;
	color: var(--color-primary);
	margin: 0;
	letter-spacing: -0.02em;
}

.dv-property-unit-grid {
	display: grid;
	grid-template-columns: repeat(2, minmax(0, 1fr));
	gap: 22px;
	align-items: stretch;
}

@media (max-width: 900px) {
	.dv-property-unit-grid {
		grid-template-columns: 1fr;
	}
}

.dv-property-unit-card {
	background: var(--color-surface);
	border-radius: 14px;
	border: 1px solid var(--color-border);
	box-shadow: var(--shadow-sm);
	padding: 0;
	overflow: hidden;
	display: flex;
	flex-direction: column;
	min-height: 0;
}

.dv-property-unit-status-table {
	width: 100%;
	border-collapse: collapse;
}

.dv-property-unit-status-table thead th {
	background: #011638;
	color: #fff;
	padding: 12px 18px;
	font-size: 0.82rem;
	font-weight: 700;
	text-align: left;
}

.dv-property-unit-status-table thead th:nth-child(2),
.dv-property-unit-status-table thead th:nth-child(3) {
	text-align: center;
}

.dv-property-unit-status-table tbody td {
	padding: 18px;
	vertical-align: top;
	font-size: 0.9rem;
	border-bottom: 1px solid var(--color-border);
}

.dv-property-unit-status-table tbody td:nth-child(2),
.dv-property-unit-status-table tbody td:nth-child(3) {
	text-align: center;
}

.dv-property-unit-strong {
	font-weight: 700;
	margin: 0;
	color: var(--color-text);
}

.dv-property-unit-muted {
	margin: 6px 0 0 0;
	font-size: 0.84rem;
	font-weight: 500;
	color: var(--color-text-muted);
}

.dv-property-unit-issues {
	padding: 20px 20px 22px;
}

.dv-property-unit-issues__title {
	font-size: 0.95rem;
	font-weight: 700;
	color: var(--color-text);
	margin: 0 0 12px 0;
}

.dv-property-unit-issues__list {
	margin: 0;
	padding-left: 1.2rem;
	font-size: 0.9rem;
	font-weight: 500;
	color: var(--color-text);
	line-height: 1.45;
}

.dv-property-unit-issues__list li {
	margin-bottom: 8px;
}

.dv-property-unit-issues__list li:last-child {
	margin-bottom: 0;
}

.dv-property-unit-card--risk {
	padding: 22px 24px 24px;
}

.dv-property-unit-card-head {
	padding: 20px 22px 12px;
	border-bottom: 1px solid var(--color-border);
}

.dv-property-unit-card-title {
	font-size: 1.02rem;
	font-weight: 700;
	color: var(--color-text);
	margin: 0 0 6px 0;
	letter-spacing: -0.02em;
}

.dv-property-unit-card-meta {
	margin: 0;
	font-size: 0.78rem;
	font-weight: 600;
	color: var(--color-text-muted);
}

.dv-property-unit-timeline {
	list-style: none;
	margin: 0;
	padding: 16px 22px 12px;
	flex: 1;
}

.dv-property-unit-timeline__row {
	display: grid;
	grid-template-columns: 88px 1fr;
	gap: 12px 16px;
	padding: 10px 0;
	border-bottom: 1px solid rgba(0, 0, 0, 0.06);
	font-size: 0.88rem;
}

.dv-property-unit-timeline__row:last-child {
	border-bottom: none;
}

.dv-property-unit-timeline__time {
	font-weight: 700;
	color: var(--color-text-muted);
}

.dv-property-unit-timeline__desc {
	font-weight: 500;
	color: var(--color-text);
}

.dv-property-unit-card-foot {
	text-align: center;
	padding: 8px 16px 18px;
	margin-top: auto;
}

.dv-property-unit-text-link {
	font-size: 0.88rem;
	font-weight: 600;
	color: var(--color-success);
	text-decoration: none;
}

.dv-property-unit-text-link:hover {
	text-decoration: underline;
}

.dv-property-unit-card--next .dv-property-unit-card-head {
	border-bottom: none;
	padding-bottom: 16px;
}

.dv-property-unit-notify {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	gap: 10px;
	margin: 0 22px 18px;
	padding: 11px 20px;
	border: none;
	border-radius: 10px;
	background: #2d5a3d;
	color: #fff;
	font: inherit;
	font-size: 0.88rem;
	font-weight: 600;
	cursor: pointer;
	transition: filter 0.15s ease;
	align-self: flex-start;
}

.dv-property-unit-notify:hover {
	filter: brightness(1.06);
}

.dv-property-unit-checklist {
	list-style: none;
	margin: 0;
	padding: 0 22px 22px;
}

.dv-property-unit-checklist__row {
	display: flex;
	align-items: flex-start;
	justify-content: space-between;
	gap: 12px;
	padding: 12px 0;
	border-top: 1px solid var(--color-border);
	font-size: 0.9rem;
}

.dv-property-unit-checklist__row:first-child {
	border-top: none;
	padding-top: 4px;
}

.dv-property-unit-check-label {
	display: flex;
	align-items: flex-start;
	gap: 10px;
	font-weight: 500;
	color: var(--color-text);
	cursor: pointer;
	flex: 1;
	min-width: 0;
	line-height: 1.35;
}

.dv-property-unit-check {
	width: 18px;
	height: 18px;
	margin: 2px 0 0 0;
	flex-shrink: 0;
	accent-color: #2d5a3d;
	cursor: pointer;
}

/* Expand and highlight alerts after "View" on overview is clicked */
.dv-alerts-row--focus {
	position: relative;
	transform-origin: center;
	animation: dvAlertFocusPop 1200ms cbuic-bezier(0.22, 1, 0.36, 1) forwards;
}

.dv-alerts-row--focus td {
	animation: dvAlertFocusGlow 1400ms ease-in-out forwards;
}

/* Control the intermetidate steps of dvAlertFocusPop animation */
@keyframes dvAlertFocusPop {
	0% { transform: scale(1); }
	30% { transform:scale(1.015); }
	100% { transform: scale(1); }
}

/* Control the intermetidate steps of dvAlertFocusGlow animation */
@keyframes dvAlertFocusGlow {
	0% { background-color: rgba(45, 90, 61, 0); }
	35% { background-color: rgba(45, 90, 61, 0.18); }
	100% { background-color: rgba(45, 90, 61, 0); }
}


@media (prefers-reduced-motion: reduce) {
	.dv-alerts-row--focus,
	.dv-alerts-row--focus td {
		animation: none;
	}

	.dv-alerts-table-wrap {
		opacity: 1;
		animation: none;
	}
}
