.timeline-horizontal-container {
	position: relative;
	display: flex;
	align-items: flex-end;
	justify-content: space-around;
	padding: 40px 0 60px;
	margin-top: 30px;
	border-bottom: 2px solid #ccc;
	overflow-x: auto;
	scroll-behavior: smooth;
}

.timeline-horizontal-item {
	position: relative;
	text-align: center;
	min-width: 150px;
}

.timeline-dot {
	position: absolute;
	bottom: -8px;
	left: 50%;
	transform: translateX(-50%);
	width: 14px;
	height: 14px;
	background-color: #0077ff;
	border-radius: 50%;
	border: 2px solid #fff;
	box-shadow: 0 0 0 2px #0077ff;
}

.timeline-content {
	background-color: #fff;
	border-radius: 8px;
	box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
	padding: 10px;
	margin-bottom: 20px;
	display: inline-block;
}

.timeline-date {
	font-size: 0.8em;
	color: #888;
	margin-bottom: 5px;
}
body {
	font-family: system-ui, sans-serif;
}
.axis path,
.axis line {
	stroke: #ccc;
}
.snow-band {
	fill: rgba(180, 220, 255, 0.35);
}
.freezing-band {
	fill: rgba(200, 200, 255, 0.25);
}
.temp-line {
	fill: none;
	stroke-width: 2;
}
.legend rect {
	stroke-width: 0;
}
.hover-overlay {
	fill: transparent;
	cursor: pointer;
}
.tooltip {
	position: absolute;
	padding: 6px 10px;
	background: rgba(0, 0, 0, 0.8);
	color: #fff;
	border-radius: 4px;
	pointer-events: none;
	font-size: 13px;
	line-height: 1.3;
	opacity: 0;
	transition: opacity 0.15s;
}
.hover-line {
	stroke: #333;
	stroke-width: 1.5;
	stroke-dasharray: 4 4;
	opacity: 0;
}

#map {
	height: 80vh;
	width: 100%;
}
.content-section {
	padding: 20px;
}
.search-box {
	margin-bottom: 10px;
}
#working-map {
	height: 400px;
	width: 100%;
}
#tree-graph {
	width: 1000px;
	height: 900px;
	border: 1px solid #ccc;
}
#3d-graph {
	width: 100vw;
	height: 100vh;
	display: block;
}
.hint {
	position: absolute;
	top: 250px;
	left: 12px;
	background: rgba(255, 255, 255, 0.9);
	padding: 6px 10px;
	border-radius: 6px;
	font-family: sans-serif;
	font-size: 13px;
	pointer-events: none;
}
#login-screen {
	position: fixed;
	inset: 0;
	display: flex;
	align-items: center;
	justify-content: center;
	background: #f8f8f8;
	z-index: 9999;
}

@media print {
	body * {
		visibility: hidden;
	}

	#map-wrapper,
	#map-wrapper * {
		visibility: visible;
	}

	#map-wrapper {
		position: absolute;
		top: 0;
		left: 0;
		width: 100%;
		height: 100%;
	}

	#map {
		height: 100vh !important;
	}
}

.circle-label {
	white-space: pre-line;
	text-align: center;
	line-height: 1.2;
}

.device-gps {
	color: #2ecc71 !important;
	font-family: monospace;
	font-size: 0.8rem;
}
.device-notehub {
	color: #5dade2 !important;
	font-family: monospace;
	font-size: 0.8rem;
}
#device-list a.uk-active {
	font-weight: bold;
	text-decoration: underline;
}
#tree-graph {
	width: 100%;
	height: calc(100vh - 120px);
	overflow: hidden;
}

/* ─────────────────────────────────────────────
   Notes Grid
───────────────────────────────────────────── */

.property-header {
	display: flex;
	justify-content: space-between;
	align-items: center;
	margin-bottom: 12px;
}

.notes-grid {
	display: grid;
	grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
	gap: 12px;
	margin-top: 12px;
}

.note-item {
	position: relative;
	background: #fff;
	border: 1px solid #e5e5e5;
	border-radius: 8px;
	overflow: hidden;
	transition:
		box-shadow 0.2s ease,
		transform 0.2s ease,
		opacity 0.3s ease,
		outline 0.2s ease;
}

.note-item:hover {
	box-shadow: 0 4px 16px rgba(0, 0, 0, 0.12);
	transform: translateY(-2px);
}

.note-cell {
	width: 100%;
}

.note-media .note-img {
	width: 100%;
	height: 140px;
	object-fit: cover;
	display: block;
}

.note-caption {
	font-size: 11px;
	color: #666;
	padding: 6px 8px 4px;
	margin: 0;
	white-space: nowrap;
	overflow: hidden;
	text-overflow: ellipsis;
}

.note-text-only {
	display: flex;
	align-items: center;
	justify-content: center;
	min-height: 100px;
	padding: 12px;
	background: #f8f8f8;
}

.note-pdf {
	display: flex;
	flex-direction: column;
	align-items: center;
	justify-content: center;
	min-height: 100px;
	background: #f0f4ff;
	cursor: pointer;
	gap: 6px;
	font-size: 13px;
	color: #3a5bbf;
}

.note-pdf-icon {
	font-size: 28px;
}

.note-actions {
	display: flex;
	justify-content: flex-end;
	gap: 2px;
	padding: 4px 6px;
	border-top: 1px solid #f0f0f0;
	background: #fafafa;
}

/* ─────────────────────────────────────────────
   Timeline Date Highlighting
───────────────────────────────────────────── */

.note-highlight {
	outline: 3px solid #1e87f0;
	outline-offset: -2px;
	box-shadow: 0 0 0 4px rgba(30, 135, 240, 0.18);
	transform: translateY(-2px);
	z-index: 1;
}

.note-dimmed {
	opacity: 0.28;
	filter: grayscale(40%);
}

.timeline-date-card {
	cursor: pointer;
	user-select: none;
	transition:
		background 0.15s,
		color 0.15s;
	padding: 10px 14px;
}

.timeline-date-card:hover {
	background: #eaf3ff !important;
	color: #1e87f0;
}

.timeline-date-active {
	background: #1e87f0 !important;
	color: #fff !important;
}

.timeline-date-active strong {
	color: #fff;
}
.graph-btn--active {
	background: #1e87f0;
	color: #fff;
	border-color: #1e87f0;
}
/* ============================================================
   plant-availability.css
   All selectors are scoped under #plant-availability-app so
   they won't conflict with your existing styles.
   CSS custom properties are also scoped to that root element.
============================================================ */

#plant-availability-app {
	--pa-soil: #2d1f0e;
	--pa-bark: #5c3d1e;
	--pa-moss: #4a6741;
	--pa-sage: #7a9e6f;
	--pa-leaf: #a8c49a;
	--pa-cream: #f5f0e8;
	--pa-parchment: #ede5d4;
	--pa-gold: #c9a227;
	--pa-mist: #e8efe5;

	font-family: "DM Sans", sans-serif;
	background: var(--pa-cream);
	color: var(--pa-soil);
	min-height: 100vh;
	box-sizing: border-box;
}

#plant-availability-app *,
#plant-availability-app *::before,
#plant-availability-app *::after {
	box-sizing: border-box;
}

/* ── Header ──────────────────────────────────────────────── */

#plant-availability-app .pa-header {
	background: var(--pa-soil);
	padding: 28px 40px 24px;
	display: flex;
	align-items: flex-end;
	gap: 16px;
	border-bottom: 3px solid var(--pa-gold);
}

#plant-availability-app .pa-logo-leaf {
	font-size: 2rem;
	line-height: 1;
}

#plant-availability-app .pa-header h1 {
	font-family: "Playfair Display", serif;
	color: var(--pa-cream);
	font-size: 1.9rem;
	letter-spacing: 0.01em;
	font-weight: 700;
	line-height: 1;
	margin: 0;
}

#plant-availability-app .pa-header p {
	color: var(--pa-leaf);
	font-size: 0.82rem;
	letter-spacing: 0.08em;
	text-transform: uppercase;
	font-weight: 400;
	margin-top: 4px;
	margin-bottom: 0;
}

/* ── Toolbar ─────────────────────────────────────────────── */

#plant-availability-app .pa-toolbar {
	background: var(--pa-parchment);
	border-bottom: 1px solid #d4c9b0;
	padding: 18px 40px;
	display: flex;
	flex-wrap: wrap;
	gap: 14px;
	align-items: center;
}

#plant-availability-app .pa-upload-zone {
	display: flex;
	align-items: center;
	gap: 10px;
	background: white;
	border: 2px dashed var(--pa-sage);
	border-radius: 8px;
	padding: 10px 18px;
	cursor: pointer;
	transition: all 0.2s;
	position: relative;
	overflow: hidden;
}

#plant-availability-app .pa-upload-zone:hover {
	border-color: var(--pa-moss);
	background: var(--pa-mist);
}

#plant-availability-app .pa-upload-zone.dragover {
	border-color: var(--pa-gold);
	background: #fdf8ec;
}

#plant-availability-app .pa-upload-zone input[type="file"] {
	position: absolute;
	inset: 0;
	opacity: 0;
	cursor: pointer;
	width: 100%;
}

#plant-availability-app .pa-icon {
	font-size: 1.2rem;
}
#plant-availability-app .pa-upload-zone span {
	font-size: 0.88rem;
	font-weight: 500;
	color: var(--pa-bark);
}

#plant-availability-app .pa-search-wrap {
	position: relative;
	flex: 1;
	min-width: 200px;
	max-width: 380px;
}

#plant-availability-app .pa-search-wrap input {
	width: 100%;
	padding: 9px 14px 9px 36px;
	border: 1.5px solid #c9bfa8;
	border-radius: 7px;
	font-size: 0.88rem;
	font-family: "DM Sans", sans-serif;
	background: white;
	outline: none;
	transition: border-color 0.2s;
}

#plant-availability-app .pa-search-wrap input:focus {
	border-color: var(--pa-moss);
}

#plant-availability-app .pa-search-icon {
	position: absolute;
	left: 11px;
	top: 50%;
	transform: translateY(-50%);
	font-size: 0.9rem;
	color: var(--pa-sage);
	pointer-events: none;
}

#plant-availability-app .pa-sort-btn {
	display: flex;
	align-items: center;
	gap: 6px;
	padding: 9px 14px;
	border: 1.5px solid #c9bfa8;
	border-radius: 7px;
	background: white;
	font-size: 0.82rem;
	font-family: "DM Sans", sans-serif;
	font-weight: 500;
	color: var(--pa-bark);
	cursor: pointer;
	transition: all 0.2s;
}

#plant-availability-app .pa-sort-btn:hover,
#plant-availability-app .pa-sort-btn.active {
	background: var(--pa-moss);
	border-color: var(--pa-moss);
	color: white;
}

/* ── Firebase controls ───────────────────────────────────── */

#plant-availability-app .pa-firebase-controls {
	display: flex;
	align-items: center;
	gap: 8px;
	margin-left: auto;
}

#plant-availability-app .pa-fb-btn {
	display: flex;
	align-items: center;
	gap: 6px;
	padding: 9px 14px;
	border-radius: 7px;
	font-size: 0.82rem;
	font-family: "DM Sans", sans-serif;
	font-weight: 500;
	cursor: pointer;
	transition: all 0.2s;
	border: 1.5px solid transparent;
}

#plant-availability-app .pa-fb-save {
	background: var(--pa-gold);
	color: var(--pa-soil);
	border-color: var(--pa-gold);
}

#plant-availability-app .pa-fb-save:hover {
	background: #b8911f;
	border-color: #b8911f;
}

#plant-availability-app .pa-fb-load {
	background: white;
	color: var(--pa-bark);
	border-color: #c9bfa8;
}

#plant-availability-app .pa-fb-load:hover {
	background: var(--pa-mist);
	border-color: var(--pa-moss);
}

#plant-availability-app .pa-fb-btn:disabled {
	opacity: 0.5;
	cursor: not-allowed;
}

#plant-availability-app .pa-fb-status {
	font-size: 0.78rem;
	color: var(--pa-moss);
	font-style: italic;
	min-width: 120px;
	white-space: nowrap;
}

#plant-availability-app .pa-fb-status.error {
	color: #b5451b;
}

/* ── Source pills ────────────────────────────────────────── */

#plant-availability-app #pa-source-pills {
	display: flex;
	gap: 6px;
	flex-wrap: wrap;
}

#plant-availability-app .pa-pill {
	display: inline-flex;
	align-items: center;
	gap: 5px;
	background: var(--pa-soil);
	color: var(--pa-cream);
	font-size: 0.78rem;
	padding: 4px 10px;
	border-radius: 20px;
	font-weight: 500;
	cursor: pointer;
	user-select: none;
}

#plant-availability-app .pa-pill.active {
	background: var(--pa-moss);
}

#plant-availability-app .pa-pill .pa-close-pill {
	cursor: pointer;
	opacity: 0.6;
	font-size: 1em;
	line-height: 1;
	margin-left: 2px;
}

#plant-availability-app .pa-pill .pa-close-pill:hover {
	opacity: 1;
}

/* ── Stats bar ───────────────────────────────────────────── */

#plant-availability-app .pa-stats-bar {
	background: var(--pa-mist);
	border-bottom: 1px solid #d4c9b0;
	padding: 8px 40px;
	display: flex;
	gap: 24px;
	align-items: center;
	font-size: 0.82rem;
	color: var(--pa-bark);
	flex-wrap: wrap;
}

#plant-availability-app .pa-stats-bar strong {
	color: var(--pa-moss);
	font-weight: 600;
}

/* ── Table wrap ──────────────────────────────────────────── */

#plant-availability-app #pa-table-wrap {
	padding: 24px 40px 40px;
}

/* ── Empty state ─────────────────────────────────────────── */

#plant-availability-app .pa-empty-state {
	text-align: center;
	padding: 60px 20px;
	color: var(--pa-sage);
}

#plant-availability-app .pa-empty-icon {
	font-size: 3rem;
	margin-bottom: 12px;
}

#plant-availability-app .pa-empty-state h2 {
	font-family: "Playfair Display", serif;
	font-size: 1.4rem;
	color: var(--pa-bark);
	margin-bottom: 8px;
}

#plant-availability-app .pa-empty-state p {
	font-size: 0.88rem;
}

/* ── Drag-and-drop overlay ───────────────────────────────── */

#pa-drop-overlay {
	display: none;
	position: fixed;
	inset: 0;
	background: rgba(45, 31, 14, 0.55);
	z-index: 9999;
	align-items: center;
	justify-content: center;
}

#pa-drop-overlay.show {
	display: flex;
}

#plant-availability-app .pa-drop-box {
	background: white;
	border: 3px dashed var(--pa-gold);
	border-radius: 16px;
	padding: 48px 64px;
	text-align: center;
	font-family: "Playfair Display", serif;
	font-size: 1.5rem;
	color: var(--pa-bark);
}

/* ── Tabulator overrides ─────────────────────────────────── */

#plant-availability-app .tabulator {
	border: 1.5px solid #d4c9b0 !important;
	border-radius: 10px !important;
	overflow: hidden;
	font-family: "DM Sans", sans-serif !important;
	font-size: 0.875rem !important;
	background: white !important;
	box-shadow: 0 2px 12px rgba(45, 31, 14, 0.08);
}

#plant-availability-app .tabulator .tabulator-header {
	background: var(--pa-soil) !important;
	border-bottom: 2px solid var(--pa-gold) !important;
}

#plant-availability-app .tabulator .tabulator-header .tabulator-col {
	background: transparent !important;
	border-right: 1px solid rgba(255, 255, 255, 0.12) !important;
}

#plant-availability-app
	.tabulator
	.tabulator-header
	.tabulator-col
	.tabulator-col-content {
	padding: 12px 10px !important;
}

#plant-availability-app
	.tabulator
	.tabulator-header
	.tabulator-col
	.tabulator-col-title {
	font-family: "DM Sans", sans-serif;
	font-size: 0.72rem;
	font-weight: 500;
	letter-spacing: 0.1em;
	text-transform: uppercase;
	color: var(--pa-leaf) !important;
}

#plant-availability-app
	.tabulator
	.tabulator-header
	.tabulator-col.tabulator-sortable:hover {
	background: rgba(255, 255, 255, 0.05) !important;
}

#plant-availability-app
	.tabulator
	.tabulator-header
	.tabulator-col
	.tabulator-arrow {
	border-top-color: var(--pa-gold) !important;
	border-bottom-color: var(--pa-gold) !important;
}

#plant-availability-app .tabulator-row {
	border-bottom: 1px solid #ede5d4 !important;
	transition: background 0.1s;
}

#plant-availability-app .tabulator-row:hover {
	background: var(--pa-mist) !important;
}

#plant-availability-app .tabulator-row.tabulator-row-even {
	background: #faf8f4 !important;
}

#plant-availability-app .tabulator-row .tabulator-cell {
	padding: 10px 10px !important;
	border-right: 1px solid #ede5d4 !important;
	color: var(--pa-soil);
}

#plant-availability-app .tabulator-footer {
	background: var(--pa-parchment) !important;
	border-top: 1px solid #d4c9b0 !important;
	padding: 8px 12px !important;
}

#plant-availability-app .tabulator-paginator {
	font-family: "DM Sans", sans-serif !important;
	font-size: 0.82rem !important;
	color: var(--pa-bark) !important;
}

#plant-availability-app .tabulator-page {
	background: white !important;
	border: 1.5px solid #c9bfa8 !important;
	border-radius: 5px !important;
	color: var(--pa-bark) !important;
	font-family: "DM Sans", sans-serif !important;
	font-size: 0.82rem !important;
	margin: 0 2px !important;
	padding: 4px 8px !important;
	cursor: pointer !important;
}

#plant-availability-app .tabulator-page.active {
	background: var(--pa-moss) !important;
	border-color: var(--pa-moss) !important;
	color: white !important;
}

#plant-availability-app .tabulator-page:hover:not(.active):not([disabled]) {
	background: var(--pa-mist) !important;
}

/* ── Cell formatters ─────────────────────────────────────── */

#plant-availability-app .pa-cell-name {
	font-weight: 500;
}
#plant-availability-app .pa-cell-botanical {
	font-style: italic;
	color: var(--pa-moss);
	font-size: 0.83em;
}
#plant-availability-app .pa-cell-price {
	font-weight: 600;
	color: var(--pa-bark);
}
#plant-availability-app .pa-cell-source {
	font-size: 0.78em;
	color: var(--pa-sage);
	background: var(--pa-mist);
	padding: 2px 6px;
	border-radius: 3px;
}

/* ── metric ───────────────────────────────── */
.property-summary-footer {
	display: flex;
	flex-wrap: wrap;
	gap: 1rem;
	margin-top: 12px;
	padding: 12px 16px;
	background: #f8f9fa;
	border: 1px solid #dee2e6;
	border-radius: 6px;
}

.summary-metric {
	min-width: 160px;
	flex: 1 1 160px;
}

.summary-metric-label {
	font-size: 0.75rem;
	color: #6c757d;
	text-transform: uppercase;
	letter-spacing: 0.02em;
	margin-bottom: 2px;
}

.summary-metric-value {
	font-size: 1.1rem;
	font-weight: 600;
	color: #212529;
}

.property-detail-modal {
	background: #fff;
	border-radius: 8px;
	width: 640px;
	max-width: 92vw;
	max-height: 80vh;
	overflow-y: auto;
	box-shadow: 0 8px 30px rgba(0, 0, 0, 0.2);
}

.property-detail-section-title {
	margin: 16px 20px 8px;
	font-size: 0.9rem;
	color: #495057;
}

.property-detail-table {
	width: calc(100% - 40px);
	margin: 0 20px 8px;
	border-collapse: collapse;
	font-size: 0.85rem;
}

.property-detail-table th {
	text-align: left;
	padding: 6px 8px;
	border-bottom: 2px solid #dee2e6;
	color: #6c757d;
	font-weight: 600;
}

.property-detail-table td {
	padding: 6px 8px;
	border-bottom: 1px solid #f1f3f5;
}

.property-detail-empty {
	text-align: center;
	color: #adb5bd;
	font-style: italic;
}

.property-summary-selection-label {
	font-size: 0.85rem;
	color: #495057;
	margin: 8px 0 4px;
}
#worktickets-grid .tabulator {
	font-size: 0.78rem;
}
#worktickets-grid .tabulator-row,
#worktickets-grid .tabulator-cell {
	min-height: 28px;
	padding: 3px 6px;
}
#worktickets-grid .tabulator-col-title {
	font-size: 0.72rem;
}

.notes-layout {
	display: flex;
	gap: 20px;
	align-items: flex-start;
}
.notes-main {
	flex: 1;
	min-width: 0;
}
.property-sidebar {
	flex: 0 0 220px;
	position: sticky;
	top: 20px;
	max-height: calc(100vh - 40px);
	overflow-y: auto;
	font-size: 0.9rem;
}
.property-sidebar li a {
	display: block;
	padding: 6px 8px;
	border-radius: 4px;
}
.property-sidebar li a:hover {
	background: rgba(0, 0, 0, 0.05);
}
.property-sidebar .sidebar-date {
	display: block;
	font-size: 0.75rem;
	color: #999;
}
.property-card.property-flash {
	outline: 2px solid #1e87f0;
	transition: outline-color 0.3s;
}

/* stack on small screens */
@media (max-width: 959px) {
	.notes-layout {
		flex-direction: column;
	}
	.property-sidebar {
		flex: none;
		width: 100%;
		position: static;
		max-height: 200px;
	}
}
