﻿/**
 * ============================================
 * APP.CSS - Stylesheet cho á»©ng dá»¥ng quáº£n lÃ½ tráº¡m Ä‘o mÆ°a
 * ============================================
 * 
 * File nÃ y chá»©a táº¥t cáº£ cÃ¡c style CSS cho á»©ng dá»¥ng quáº£n lÃ½ tráº¡m Ä‘o mÆ°a
 * Ä�Æ°á»£c tÃ¡ch ra tá»« index.html Ä‘á»ƒ dá»… báº£o trÃ¬ vÃ  quáº£n lÃ½
 * 
 * Cáº¥u trÃºc:
 * 1. Typography & Base Styles
 * 2. Map Container Styles
 * 3. Map Legend Panel Styles
 * 4. Station Detail Styles
 * 5. Search Bar Styles
 * 6. Map Layer Panel Styles
 * 7. Timeline Styles
 * 8. Responsive Styles
 */

/* ============================================
   0. TYPOGRAPHY & BASE STYLES - Unified Typography Scale
   ============================================ */

/* Global font family - Inter for modern, clean typography with excellent Vietnamese support */
body,
html {
	font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', 'Roboto', 'Oxygen', 'Ubuntu', 'Cantarell', 'Fira Sans', 'Droid Sans', 'Helvetica Neue', sans-serif;
	font-feature-settings: 'kern' 1, 'liga' 1;
	-webkit-font-smoothing: antialiased;
	-moz-osx-font-smoothing: grayscale;
	text-rendering: optimizeLegibility;
	font-size: 14px; /* Base font size */
}

/* Ensure Vietnamese characters render beautifully */
/* Note: CSS rule with missing selector removed */

/* Improve readability for Vietnamese text */
body {
	letter-spacing: -0.01em;
	line-height: 1.6;
}

/* Typography Scale - Unified system */
/* Base: 14px, Large: 16px, Medium: 14px, Small: 12px, Extra Small: 11px, Tiny: 10px */

/* Headings with better spacing */
h1, h2, h3, h4, h5, h6 {
	font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
	font-weight: 600;
	letter-spacing: -0.02em;
	line-height: 1.3;
}

/* ============================================
   1. MAP CONTAINER STYLES
   ============================================ */

/* Map container - no scrollbar, fit in viewport */
#map-container {
	width: 100%;
	height: 100%;
	overflow: hidden;
	background: #1a1a1a;
	position: relative;
}

/* Tổng diện tích tưới (ha) khi highlight vùng theo trạm bơm */
.bacninh-vungtuoi-highlight-area {
	display: none;
	position: absolute;
	left: 20px;
	bottom: 62px;
	z-index: 120;
	max-width: min(320px, calc(100% - 24px));
	padding: 10px 12px;
	border-radius: 8px;
	background: rgba(15, 23, 42, 0.88);
	border: 1px solid rgba(148, 163, 184, 0.35);
	box-shadow: 0 4px 16px rgba(0, 0, 0, 0.35);
	color: #f1f5f9;
	font-size: 13px;
	line-height: 1.45;
	pointer-events: none;
}
.bacninh-vungtuoi-highlight-area.visible {
	display: block;
}
.bacninh-vungtuoi-highlight-area .bacninh-vungtuoi-highlight-area-title {
	font-size: 11px;
	font-weight: 600;
	letter-spacing: 0.02em;
	color: rgba(226, 232, 240, 0.85);
	text-transform: uppercase;
}
.bacninh-vungtuoi-highlight-area .bacninh-vungtuoi-highlight-area-value {
	font-weight: 600;
	font-size: 15px;
	color: #fdba74;
	margin-top: 4px;
}
.bacninh-vungtuoi-highlight-area .bacninh-vungtuoi-highlight-area-hint {
	margin-top: 6px;
	font-size: 11px;
	color: rgba(226, 232, 240, 0.65);
}

/* Station / reservoir detail maps (Vị trí trạm, Vị trí hồ chứa) */
.station-location-map {
	width: 100%;
	height: 300px;
	border-radius: 8px;
	overflow: hidden;
}

/* When the card is expanded fullscreen, let the map fill all available height */
.card.card-expand .station-location-map {
	height: 100% !important;
}

/* Overview Map Container */
.overview-map-container {
	position: absolute;
	bottom: 20px; /* Position at bottom right */
	right: 20px;
	width: 200px;
	height: 200px;
	z-index: 1; /* Below legend panel (999) but above map */
	background: rgba(0, 0, 0, 0.75);
	backdrop-filter: blur(8px);
	-webkit-backdrop-filter: blur(8px);
	border: 1px solid rgba(255, 255, 255, 0.2);
	border-radius: 12px;
	box-shadow: 0 4px 16px rgba(0, 0, 0, 0.5);
	overflow: hidden;
	transition: opacity 0.3s ease, visibility 0.3s ease;
}

.overview-map-container.hidden {
	opacity: 0;
	visibility: hidden;
	pointer-events: none;
}

/* Hide overview map on mobile by default (can be overridden by JavaScript) */
@media (max-width: 991px) {
	/* Ensure overview map is positioned at bottom-right on mobile */
	.overview-map-container {
		position: absolute !important;
		top: auto !important;
		bottom: 20px !important;
		right: 10px !important;
		left: auto !important;
		width: 180px !important;
		height: 180px !important;
	}
	
	.overview-map-container:not(.force-show) {
		opacity: 0;
		visibility: hidden;
		pointer-events: none;
	}
}

#overview-map {
	width: 100%;
	height: 100%;
}

/* Overview Map Viewport Indicator */
.overview-viewport {
	position: absolute;
	border: 2px solid #00d4ff;
	background: rgba(0, 212, 255, 0.1);
	pointer-events: none;
	z-index: 10;
	box-sizing: border-box;
}

/* Zoom box drawing style */
.boxdraw {
	position: absolute;
	top: 0;
	left: 0;
	width: 0;
	height: 0;
	border: 2px solid #00d4ff;
	background: rgba(0, 212, 255, 0.1);
	pointer-events: none;
	z-index: 10000;
	box-sizing: border-box;
}

/* When map tab is active, disable scrollbar on parent containers */
#tab-map {
	position: relative;
	height: 100%;
	overflow: hidden;
	display: flex;
	flex-direction: column;
}

#tab-map .mailbox-detail-content {
	position: relative;
	height: 100%;
	overflow: hidden;
	padding: 0;
	flex: 1;
}

/* Enable scrolling for mailbox-detail-content (except map tab) */
.mailbox-detail-content {
	overflow-y: auto;
	overflow-x: hidden;
	-webkit-overflow-scrolling: touch; /* Smooth scrolling on iOS */
	height: 100%; /* Ensure container takes full height */
	max-height: 100%; /* Prevent overflow */
}

/* Specific rule for tab-lake-list to ensure scrolling works */
#tab-lake-list {
	display: flex;
	flex-direction: column;
	height: 100%;
	min-height: 0;
}

#tab-lake-list .mailbox-detail-content {
	overflow-y: auto !important;
	overflow-x: hidden;
	flex: 1;
	min-height: 0;
	-webkit-overflow-scrolling: touch;
}

/* Allow wheel scrolling on mailbox-detail-content even when inside dragscroll */
.mailbox-detail.dragscroll .mailbox-detail-content {
	pointer-events: auto !important;
	/* Ensure wheel events work for scrolling */
	touch-action: pan-y;
	cursor: default !important;
	/* Override dragscroll cursor - không dùng cursor grab */
	/* Tắt dragscroll behavior cho mailbox-detail-content */
	user-select: auto;
	-webkit-user-select: auto;
	-moz-user-select: auto;
	-ms-user-select: auto;
}

/* Prevent dragscroll from interfering with wheel scrolling on mailbox-detail-content */
.mailbox-detail.dragscroll .mailbox-detail-content * {
	pointer-events: auto;
}

/* Ensure mailbox-detail-content can receive wheel events */
.mailbox-detail-content {
	/* Allow wheel events to bubble and be handled */
	will-change: scroll-position;
	/* Đảm bảo cursor không bị dragscroll override */
	cursor: default !important;
}

/* Tắt dragscroll behavior cho mailbox-detail-content */
.mailbox-detail.dragscroll .mailbox-detail-content:not(#tab-map .mailbox-detail-content) {
	/* Loại bỏ dragscroll behavior */
	cursor: default !important;
	user-select: auto !important;
}

/* Disable scrollbar on mailbox-content scrollbar wrapper when map is shown */
.mailbox-content[data-map-active="true"] > div[data-scrollbar="true"] {
	overflow: hidden !important;
	height: 100% !important;
}

/* Ensure mailbox-detail takes full height when map is active */
.mailbox-content[data-map-active="true"] .mailbox-detail {
	height: 100%;
	overflow: hidden;
}

/* ============================================
   2. MAP LEGEND PANEL STYLES
   ============================================ */

/* Map Legend Panel */
.map-legend-panel {
	position: absolute;
	bottom: 20px; /* Góc dưới bên trái */
	left: 20px;
	right: auto; /* Đảm bảo không bị override */
	top: auto; /* Đảm bảo không bị override */
	background: rgba(255, 255, 255, 0.95);
	border-radius: 8px;
	box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
	max-width: 280px;
	width: auto; /* Chiều rộng tự động theo nội dung */
	max-height: calc(40vh - 45px); /* Giảm xuống một nửa chiều cao */
	overflow: hidden; /* Chỉ cho body cuộn để tránh 2 thanh cuộn */
	display: flex;
	flex-direction: column;
	z-index: 999; /* Lower than timeline z-index (1000) */
	transition: all 0.3s ease;
}

.map-legend-panel.collapsed {
	max-height: 40px;
	overflow: hidden;
}

.map-legend-panel-header {
	padding: 12px 16px;
	border-bottom: 1px solid rgba(0, 0, 0, 0.1);
	display: flex;
	align-items: center;
	justify-content: space-between;
	cursor: pointer;
	user-select: none;
}

.map-legend-panel-header h6 {
	margin: 0;
	font-size: 14px; /* Base size - unified */
	font-weight: 600;
	color: #333;
}

.map-legend-panel-toggle {
	background: none;
	border: none;
	color: #666;
	cursor: pointer;
	padding: 4px;
	display: flex;
	align-items: center;
	transition: transform 0.3s;
}

.map-legend-panel.collapsed .map-legend-panel-toggle {
	transform: rotate(180deg);
}

.map-legend-panel-body {
	padding: 12px 16px;
	flex: 1 1 auto;
	min-height: 0;
	max-height: 400px;
	overflow-y: auto;
	overflow-x: hidden;
}

/* Custom scrollbar for legend panel */
.map-legend-panel-body::-webkit-scrollbar {
	width: 6px;
}

.map-legend-panel-body::-webkit-scrollbar-track {
	background: rgba(0, 0, 0, 0.05);
	border-radius: 3px;
}

.map-legend-panel-body::-webkit-scrollbar-thumb {
	background: rgba(0, 0, 0, 0.2);
	border-radius: 3px;
}

.map-legend-panel-body::-webkit-scrollbar-thumb:hover {
	background: rgba(0, 0, 0, 0.3);
}

.map-legend-item {
	margin-bottom: 16px;
}

.map-legend-item:last-child {
	margin-bottom: 0;
}

.map-legend-item-title {
	font-size: 12px; /* Small - unified scale */
	font-weight: 600;
	color: #333;
	margin-bottom: 8px;
}

.map-legend-item-row {
	display: flex;
	align-items: center;
	margin-bottom: 6px;
	font-size: 12px; /* Small - unified */
	color: #555;
}

.map-legend-item-row:last-child {
	margin-bottom: 0;
}

.map-legend-color-box {
	width: 20px;
	height: 20px;
	border-radius: 3px;
	margin-right: 8px;
	flex-shrink: 0;
	border: 1px solid rgba(0, 0, 0, 0.1);
}

.map-legend-item-label {
	flex: 1;
}

/* Hide legend when not needed */
.map-legend-panel.hidden {
	display: none;
}

/* ============================================
   LEGEND LINE STYLES (for fault lines)
   ============================================ */

.legend-line {
	display: inline-block; 
	width: 30px; 
	height: 0; 
	border-top-width: 2px; 
	margin-right: 5px; 
	vertical-align: middle; 
}

.dashed-red {
	border-top-style: dashed; 
	border-top-color: #FF0000;
}

.solid-red {
	border-top-style: solid; 
	border-top-color: #FF0000;
}

/* ============================================
   3. STATION DETAIL STYLES - Modern Card Layout
   ============================================ */

/* Station detail container - Card layout for desktop, table for mobile */
.station-detail-container {
	display: flex;
	flex-direction: column;
	gap: 20px;
}

/* Station detail table - For mobile only */
.station-detail-table {
	width: 100%;
	border-collapse: collapse;
}

.station-detail-table tr {
	border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.station-detail-table td {
	padding: 12px 0;
	color: rgba(255, 255, 255, 0.9);
	font-size: 14px; /* Base size - unified */
}

.station-detail-table td:first-child {
	color: rgba(255, 255, 255, 0.6);
	width: 40%;
	font-weight: 500;
	text-align: left;
}

.station-detail-table td:last-child {
	text-align: right;
}

/* Table section header for grouping */
.station-detail-table .table-section-header {
	background-color: rgba(255, 255, 255, 0.05);
	font-weight: 600;
	font-size: 15px;
	color: rgba(255, 255, 255, 0.9);
	text-transform: uppercase;
	letter-spacing: 0.5px;
	padding: 16px;
	text-align: center !important;
}

/* Table images cell for mobile */
.station-detail-table .table-images-cell {
	padding: 16px !important;
	text-align: center !important;
}

.station-detail-table .table-images-cell .widget-img-list {
	display: flex;
	flex-wrap: wrap;
	gap: 2px;
	justify-content: flex-start;
	margin-bottom: 8px;
	max-height: none !important;
	overflow: visible !important;
}

.station-detail-table .table-images-cell .widget-img-list-item {
	flex: 0 0 auto;
	width: calc(33.333% - 2px);
	max-width: 180px;
}

.station-detail-table .table-images-cell .widget-img-list-item a {
	display: block;
	width: 100%;
	padding-top: 100%; /* Square aspect ratio */
	position: relative;
	border-radius: 4px;
	overflow: hidden;
}

.station-detail-table .table-images-cell .widget-img-list-item a .img {
	position: absolute;
	top: 0;
	left: 0;
	width: 100%;
	height: 100%;
	background-size: cover;
	background-position: center;
	background-repeat: no-repeat;
	transition: transform 0.3s ease, box-shadow 0.3s ease;
}

/* Hiệu ứng hover cho ảnh thực địa - Mobile view */
.station-detail-table .table-images-cell .widget-img-list-item a {
	transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.station-detail-table .table-images-cell .widget-img-list-item:hover a {
	transform: translateY(-8px) scale(1.05);
	box-shadow: 0 12px 24px rgba(0, 0, 0, 0.4), 0 6px 12px rgba(0, 0, 0, 0.3);
	z-index: 10;
	position: relative;
}

.station-detail-table .table-images-cell .widget-img-list-item:hover a .img {
	transform: scale(1.1);
}

/* Modern Card Layout for Desktop */
.station-detail-cards {
	display: none; /* Hidden on mobile by default */
}

@media (min-width: 992px) {
	.station-detail-table {
		display: none; /* Hide table on desktop */
	}
	
	.station-detail-cards {
		display: block; /* Show cards on desktop */
	}
}

/* Station Header Card */
.station-header-card {
	background: linear-gradient(135deg, rgba(0, 212, 255, 0.1) 0%, rgba(0, 153, 204, 0.05) 100%);
	border: 1px solid rgba(0, 212, 255, 0.2);
	border-radius: 12px;
	padding: 24px;
	margin-bottom: 8px;
}

.station-header-content {
	display: flex;
	justify-content: space-between;
	align-items: flex-start;
	gap: 20px;
}

/* Trạm mưa / trạm thủy văn: cụm badge + Sinh báo cáo căn phải */
.station-header-content.iot-station-header-with-report {
	align-items: center;
}

.station-header-content.iot-station-header-with-report .iot-station-header-actions {
	display: flex;
	align-items: center;
	justify-content: flex-end;
	gap: 10px;
	margin-left: auto;
	flex-shrink: 0;
	flex-wrap: wrap;
}

.station-header-content.iot-station-header-with-report .iot-station-header-actions .trambom-edit-btn {
	margin-left: 0;
}

.station-title-section h2 {
	margin: 0 0 8px 0;
	font-size: 20px;
	font-weight: 600;
	color: #fff;
	line-height: 1.3;
}

.station-code {
	display: inline-block;
	background: rgba(255, 255, 255, 0.1);
	padding: 4px 12px;
	border-radius: 6px;
	font-size: 12px;
	font-weight: 600;
	color: rgba(255, 255, 255, 0.8);
	letter-spacing: 0.5px;
	margin-top: 4px;
}

/* Trambom edit mode (Sửa / Cập nhật) */
.trambom-edit-btn {
	margin-left: 12px;
	margin-top: 4px;
	padding: 6px 14px;
	border-radius: 999px;
	border: 1px solid rgba(255, 255, 255, 0.22);
	background: rgba(255, 255, 255, 0.06);
	color: rgba(255, 255, 255, 0.92);
	font-size: 12px;
	font-weight: 700;
	cursor: pointer;
	transition: background 0.2s ease, border-color 0.2s ease, transform 0.12s ease, box-shadow 0.2s ease;
}

.trambom-edit-btn:hover {
	background: rgba(16, 185, 129, 0.16);
	border-color: rgba(52, 211, 153, 0.55);
	box-shadow: 0 6px 18px rgba(16, 185, 129, 0.14);
	transform: translateY(-1px);
}

.trambom-edit-btn:active {
	transform: translateY(0px);
}

.trambom-header-actions {
	display: inline-flex;
	align-items: center;
	gap: 8px;
	margin-top: 6px;
	flex-wrap: wrap;
}

.trambom-report-btn {
	padding: 6px 14px;
	border-radius: 999px;
	border: 1px solid rgba(59, 130, 246, 0.55);
	background: rgba(37, 99, 235, 0.2);
	color: #dbeafe;
	font-size: 12px;
	font-weight: 700;
	cursor: pointer;
	transition: background 0.2s ease, border-color 0.2s ease, transform 0.12s ease, box-shadow 0.2s ease;
}

.trambom-report-btn:hover {
	background: rgba(59, 130, 246, 0.3);
	border-color: rgba(147, 197, 253, 0.8);
	box-shadow: 0 6px 18px rgba(37, 99, 235, 0.2);
	transform: translateY(-1px);
}

.trambom-report-btn:active {
	transform: translateY(0px);
}

.trambom-list-toolbar {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	justify-content: space-between;
	gap: 8px;
	margin-bottom: 8px;
}

.pctt-capde-legend {
	width: 100%;
	flex-basis: 100%;
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: 8px 14px;
	margin-top: 4px;
	padding: 8px 10px;
	border-radius: 8px;
	background: rgba(0, 0, 0, 0.22);
	border: 1px solid rgba(255, 255, 255, 0.08);
	font-size: 11px;
	line-height: 1.35;
	color: rgba(255, 255, 255, 0.75);
}

.pctt-capde-legend-label {
	font-weight: 700;
	color: rgba(255, 255, 255, 0.88);
	margin-right: 4px;
}

.pctt-capde-legend-muted {
	color: rgba(255, 255, 255, 0.5);
}

.pctt-capde-legend-dot-muted {
	background: rgba(255, 255, 255, 0.28) !important;
}

.pctt-capde-legend-item {
	display: inline-flex;
	align-items: center;
	gap: 6px;
	white-space: nowrap;
}

.pctt-capde-legend-dot {
	width: 8px;
	height: 8px;
	border-radius: 50%;
	flex-shrink: 0;
	box-shadow: 0 0 0 1px rgba(255, 255, 255, 0.15);
}

.pctt-capde-list-line {
	display: flex;
	align-items: center;
	gap: 6px;
	margin-top: 4px;
	font-size: 12px;
	font-weight: 600;
	line-height: 1.35;
}

.pctt-capde-list-dot {
	width: 8px;
	height: 8px;
	border-radius: 50%;
	flex-shrink: 0;
	box-shadow: 0 0 0 1px rgba(255, 255, 255, 0.12);
}

.trambom-ds-report-btn {
	flex-shrink: 0;
	font-size: 11px;
	padding: 5px 12px;
}

.trambom-edit-input {
	width: 100%;
	background: rgba(0, 0, 0, 0.25);
	border: 1px solid rgba(255, 255, 255, 0.16);
	color: #fff;
	border-radius: 8px;
	padding: 8px 10px;
	font-size: 12px;
	font-weight: 600;
	outline: none;
	pointer-events: auto !important;
	cursor: text !important;
	position: relative;
	z-index: 5;
}

.trambom-edit-input:focus {
	border-color: rgba(52, 211, 153, 0.75);
	box-shadow: 0 0 0 2px rgba(52, 211, 153, 0.14);
}

.kenh-edit-input {
	width: 100%;
	background: rgba(0, 0, 0, 0.25);
	border: 1px solid rgba(255, 255, 255, 0.16);
	color: #fff;
	border-radius: 8px;
	padding: 8px 10px;
	font-size: 12px;
	font-weight: 600;
	outline: none;
	pointer-events: auto !important;
	cursor: text !important;
	position: relative;
	z-index: 5;
}

.kenh-edit-input:focus {
	border-color: rgba(52, 211, 153, 0.75);
	box-shadow: 0 0 0 2px rgba(52, 211, 153, 0.14);
}

.station-status-badge {
	display: inline-flex;
	align-items: center;
	padding: 8px 16px;
	border-radius: 8px;
	font-size: 13px;
	font-weight: 600;
	gap: 6px;
}

.station-status-badge.active {
	background: rgba(40, 167, 69, 0.2);
	color: #28a745;
	border: 1px solid rgba(40, 167, 69, 0.3);
}

.station-status-badge.maintenance {
	background: rgba(255, 193, 7, 0.2);
	color: #ffc107;
	border: 1px solid rgba(255, 193, 7, 0.3);
}

.station-status-badge.inactive {
	background: rgba(220, 53, 69, 0.2);
	color: #dc3545;
	border: 1px solid rgba(220, 53, 69, 0.3);
}

/* Info Cards Grid */
.station-info-grid {
	display: grid;
	grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
	gap: 16px;
	margin-bottom: 16px;
}

/* Quantum-style Card Layout (theo máº«u analytics.html) */
.quantum-card-group {
	background: rgba(255, 255, 255, 0.03);
	border: 1px solid rgba(255, 255, 255, 0.1);
	border-radius: 8px;
	overflow: hidden;
	transition: all 0.3s ease;
	height: 100%;
	display: flex;
	flex-direction: column;
}

.quantum-card-group:hover {
	background: rgba(255, 255, 255, 0.05);
	border-color: rgba(255, 255, 255, 0.15);
	transform: translateY(-2px);
	box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
}

.quantum-card-group .card-header {
	background: rgba(255, 255, 255, 0.02);
	border-bottom: 1px solid rgba(255, 255, 255, 0.1);
	padding: 12px 16px;
	font-size: 11px;
	font-weight: 600;
	text-transform: uppercase;
	letter-spacing: 0.5px;
	color: rgba(255, 255, 255, 0.9);
}

.quantum-card-group .card-header a {
	color: rgba(255, 255, 255, 0.7);
	text-decoration: none;
	font-size: 10px;
	font-weight: 500;
}

.quantum-card-group .card-header a:hover {
	color: rgba(255, 255, 255, 0.9);
}

.quantum-card-group .card-body {
	flex: 1;
	padding: 16px;
	background: transparent;
}

.quantum-card-group .card-body hr {
	border-color: rgba(255, 255, 255, 0.1);
	margin: 12px 0;
}

.quantum-card-group .card-body .row {
	margin-left: 0;
	margin-right: 0;
}

.quantum-card-group .card-body .row > div {
	padding-left: 0;
	padding-right: 0;
}

/* Row g-3 spacing for Quantum cards */
.station-detail-container .row.g-3 {
	margin-left: -12px;
	margin-right: -12px;
}

.station-detail-container .row.g-3 > * {
	padding-left: 12px;
	padding-right: 12px;
	margin-bottom: 24px;
}

/* Compact grid layout Ä‘á»ƒ táº­n dá»¥ng khÃ´ng gian */
.station-info-grid-compact {
	grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
	gap: 12px;
}

@media (min-width: 1200px) {
	.station-info-grid-compact {
		grid-template-columns: repeat(3, 1fr);
	}
}

@media (min-width: 1600px) {
	.station-info-grid-compact {
		grid-template-columns: repeat(4, 1fr);
	}
}

/* Accordion Styles for Grouped Information */
.station-info-accordion {
	display: flex;
	flex-direction: column;
	gap: 12px;
	margin-bottom: 16px;
}

.station-accordion-item {
	background: rgba(255, 255, 255, 0.02);
	border: 1px solid rgba(255, 255, 255, 0.08);
	border-radius: 12px;
	overflow: hidden;
	transition: all 0.3s ease;
	box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.station-accordion-item:hover {
	border-color: rgba(255, 255, 255, 0.15);
	box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
	transform: translateY(-1px);
}

.station-accordion-header {
	display: flex;
	align-items: center;
	justify-content: space-between;
	padding: 16px 20px;
	cursor: pointer;
	transition: all 0.2s ease;
	user-select: none;
}

.station-accordion-header:hover {
	background: rgba(255, 255, 255, 0.05) !important;
}

.station-accordion-header-left {
	display: flex;
	align-items: center;
	gap: 14px;
	flex: 1;
}

.station-accordion-icon {
	width: 40px;
	height: 40px;
	display: flex;
	align-items: center;
	justify-content: center;
	background: rgba(255, 255, 255, 0.1);
	border-radius: 10px;
	font-size: 20px;
	flex-shrink: 0;
	transition: all 0.3s ease;
}

.station-accordion-item:hover .station-accordion-icon {
	background: rgba(255, 255, 255, 0.15);
	transform: scale(1.05);
}

.station-accordion-title-section {
	display: flex;
	flex-direction: column;
	gap: 4px;
	flex: 1;
}

.station-accordion-title {
	font-size: 15px;
	font-weight: 600;
	color: rgba(255, 255, 255, 0.95);
	margin: 0;
	letter-spacing: 0.3px;
}

.station-accordion-count {
	font-size: 12px;
	color: rgba(255, 255, 255, 0.5);
	font-weight: 400;
}

.station-accordion-toggle {
	width: 32px;
	height: 32px;
	display: flex;
	align-items: center;
	justify-content: center;
	color: rgba(255, 255, 255, 0.7);
	font-size: 20px;
	transition: all 0.3s ease;
	flex-shrink: 0;
}

.station-accordion-toggle iconify-icon {
	transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.station-accordion-content {
	display: block;
	overflow: hidden;
	transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
	background: rgba(0, 0, 0, 0.2);
}

.station-accordion-body {
	padding: 20px;
	display: flex;
	flex-direction: column;
	gap: 12px;
}

/* Field Item Styles */
.station-field-item {
	padding: 14px 16px;
	background: rgba(255, 255, 255, 0.03);
	border-radius: 8px;
	transition: all 0.2s ease;
	border-left: 2px solid transparent;
}

.station-field-item:hover {
	background: rgba(255, 255, 255, 0.06);
	transform: translateX(2px);
}

.station-field-item-filled {
	border-left-color: inherit;
}

.station-field-item-empty {
	opacity: 0.6;
}

.station-field-label {
	display: flex;
	align-items: center;
	justify-content: space-between;
	margin-bottom: 8px;
	gap: 8px;
}

.station-field-label-text {
	font-size: 12px;
	font-weight: 500;
	color: rgba(255, 255, 255, 0.7);
	text-transform: uppercase;
	letter-spacing: 0.5px;
	flex: 1;
}

.station-field-indicator {
	width: 6px;
	height: 6px;
	border-radius: 50%;
	flex-shrink: 0;
	animation: pulse 2s ease-in-out infinite;
}

@keyframes pulse {
	0%, 100% {
		opacity: 1;
	}
	50% {
		opacity: 0.5;
	}
}

.station-field-value {
	font-size: 14px;
	color: rgba(255, 255, 255, 0.95);
	font-weight: 500;
	line-height: 1.6;
	word-break: break-word;
}

.station-field-value-empty {
	font-size: 13px;
	color: rgba(255, 255, 255, 0.4);
	font-style: italic;
}

/* Individual Info Card */
.station-info-card {
	background: rgba(255, 255, 255, 0.03);
	border: 1px solid rgba(255, 255, 255, 0.1);
	border-radius: 10px;
	padding: 20px;
	transition: all 0.3s ease;
}

/* Card chiếm toàn bộ chiều rộng trong grid */
.station-info-card-full {
	grid-column: 1 / -1;
}

.station-info-card-group {
	padding: 18px;
}

.station-info-group-content {
	display: flex;
	flex-direction: column;
	gap: 0;
}

.station-info-card:hover {
	background: rgba(255, 255, 255, 0.05);
	border-color: rgba(255, 255, 255, 0.15);
	transform: translateY(-2px);
}

.station-info-card-header {
	display: flex;
	align-items: center;
	gap: 12px;
	margin-bottom: 16px;
	padding-bottom: 12px;
	border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.station-info-card-title-section {
	display: flex;
	flex-direction: column;
	gap: 4px;
	flex: 1;
}

.station-info-card-count {
	font-size: 11px;
	color: rgba(255, 255, 255, 0.5);
	font-weight: 400;
}

.station-info-card-icon {
	width: 32px;
	height: 32px;
	display: flex;
	align-items: center;
	justify-content: center;
	background: rgba(0, 212, 255, 0.1);
	border-radius: 8px;
	color: #00d4ff;
	font-size: 18px;
}

.station-info-card-title {
	font-size: 13px;
	font-weight: 600;
	color: rgba(255, 255, 255, 0.7);
	text-transform: uppercase;
	letter-spacing: 0.5px;
	margin: 0;
}

.station-info-item {
	margin-bottom: 16px;
}

.station-info-item:last-child {
	margin-bottom: 0;
}

/* Compact item vá»›i spacing tá»‘i Æ°u */
.station-info-item-compact {
	margin-bottom: 18px;
	padding: 12px;
	background: rgba(255, 255, 255, 0.02);
	border-radius: 8px;
	border-left: 2px solid transparent;
	transition: all 0.2s ease;
}

.station-info-item-compact:hover {
	background: rgba(255, 255, 255, 0.04);
	transform: translateX(2px);
}

.station-info-item-filled {
	border-left-color: inherit;
}

.station-info-item-empty {
	opacity: 0.65;
}

.station-info-label {
	font-size: 12px;
	color: rgba(255, 255, 255, 0.5);
	margin-bottom: 4px;
	font-weight: 400;
}

/* Label lá»›n hÆ¡n cho compact layout */
.station-info-label-large {
	font-size: 13px;
	color: rgba(255, 255, 255, 0.6);
	margin-bottom: 8px;
	font-weight: 500;
	text-transform: uppercase;
	letter-spacing: 0.5px;
	line-height: 1.4;
}

.station-info-value {
	font-size: 14px;
	color: rgba(255, 255, 255, 0.9);
	font-weight: 500;
	word-break: break-word;
	line-height: 1.5;
}

/* Value lá»›n hÆ¡n cho compact layout */
.station-info-value-large {
	font-size: 15px;
	color: rgba(255, 255, 255, 0.95);
	font-weight: 600;
	word-break: break-word;
	line-height: 1.6;
}

.station-info-value-empty {
	font-size: 13px;
	color: rgba(255, 255, 255, 0.4);
	font-style: italic;
	font-weight: 400;
}

.station-info-value.highlight {
	color: #00d4ff;
	font-weight: 600;
}

/* Trạm bơm — lưới thuộc tính responsive trong từng nhóm */
.trambom-fields-grid {
	display: grid;
	grid-template-columns: 1fr;
	gap: 12px;
	align-items: stretch;
}

@media (min-width: 576px) {
	.trambom-fields-grid {
		grid-template-columns: repeat(2, minmax(0, 1fr));
		gap: 12px 14px;
	}
}

@media (min-width: 992px) {
	.trambom-fields-grid {
		grid-template-columns: repeat(3, minmax(0, 1fr));
	}
}

@media (min-width: 1400px) {
	.trambom-fields-grid {
		grid-template-columns: repeat(4, minmax(0, 1fr));
	}
}

.trambom-fields-grid .station-info-item {
	margin-bottom: 0;
}

/* Cột km PCTT — header: tên trái; Sửa + badge Dữ liệu căn phải, sát nhau */
.station-header-content.pctt-cotkm-top-header {
	align-items: center;
	width: 100%;
}

.station-header-content.pctt-cotkm-top-header .station-title-section {
	flex: 1;
	min-width: 0;
}

.pctt-cotkm-header-actions {
	display: inline-flex;
	align-items: center;
	gap: 10px;
	flex-shrink: 0;
	margin-left: auto;
}

.pctt-cotkm-header-actions .trambom-edit-btn {
	margin-left: 0;
	margin-top: 0;
}

/* Địa điểm cột km: mỗi trường một hàng (không xếp nhiều cột) */
.trambom-fields-grid.pctt-cotkm-diadiem-grid {
	grid-template-columns: 1fr !important;
}

/* Kho bãi vật tư — hàng 3 thẻ (Địa điểm | Bản đồ | Chức năng) luôn tối đa 3 cột (không lên 4 ở màn rộng) */
@media (min-width: 1200px) {
	.station-info-grid-compact.pctt-khovattu-top-grid {
		grid-template-columns: repeat(3, minmax(0, 1fr));
	}
}

/* Kho bãi vật tư — lưới ô trong khung: tối đa 3 cột (không dùng 4 cột breakpoint 1400px) */
.trambom-fields-grid.pctt-khovattu-fields-grid {
	grid-template-columns: 1fr;
}

@media (min-width: 576px) {
	.trambom-fields-grid.pctt-khovattu-fields-grid {
		grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
	}
}

@media (min-width: 992px) {
	.trambom-fields-grid.pctt-khovattu-fields-grid {
		grid-template-columns: repeat(3, minmax(0, 1fr)) !important;
	}
}

/* Kho bãi — 4 khung (Đặc điểm, Thời gian…, Chủng loại, Liên kết) xếp lưới 3 cột */
.station-info-grid.pctt-khovattu-lower-cards {
	grid-template-columns: 1fr;
}

@media (min-width: 992px) {
	.station-info-grid.pctt-khovattu-lower-cards {
		grid-template-columns: repeat(3, minmax(0, 1fr));
	}
}

/* Trong từng thẻ hẹp: các ô thuộc tính một cột dọc */
.trambom-fields-grid.pctt-khovattu-fields-grid.pctt-khovattu-fields-grid--in-card {
	grid-template-columns: 1fr !important;
}

.trambom-field-cell .pctt-edit-input,
.pctt-cotkm-diadiem-cell .pctt-edit-input {
	width: 100%;
	max-width: 100%;
	box-sizing: border-box;
	padding: 8px 11px;
	border-radius: 6px;
	border: 1px solid rgba(0, 212, 255, 0.35);
	background: rgba(0, 0, 0, 0.32);
	color: rgba(255, 255, 255, 0.96);
	font-size: 14px;
	font-weight: 600;
	line-height: 1.4;
	outline: none;
}

.trambom-field-cell .pctt-edit-input:focus {
	border-color: rgba(52, 211, 153, 0.65);
	box-shadow: 0 0 0 2px rgba(16, 185, 129, 0.12);
}

.trambom-field-cell textarea.pctt-edit-input {
	min-height: 72px;
	resize: vertical;
	font-weight: 500;
	font-family: inherit;
	line-height: 1.45;
}

.trambom-field-cell {
	padding: 12px 14px;
	background: rgba(255, 255, 255, 0.04);
	border: 1px solid rgba(255, 255, 255, 0.08);
	border-radius: 8px;
	display: flex;
	flex-direction: column;
	gap: 6px;
	justify-content: flex-start;
	text-align: left;
	min-width: 0;
}

.trambom-field-cell .station-info-label {
	text-align: left;
	margin-bottom: 0;
	line-height: 1.35;
}

.trambom-field-cell .station-info-value {
	text-align: left;
	font-weight: 600;
	line-height: 1.45;
}

.trambom-field-cell--full {
	grid-column: 1 / -1;
}

.trambom-field-cell--full .station-info-value {
	white-space: pre-wrap;
	font-weight: 500;
}

/* Ô chưa có dữ liệu — xếp sau, tông màu mờ hơn */
.trambom-field-cell--empty {
	background: rgba(0, 0, 0, 0.25);
	border-color: rgba(255, 255, 255, 0.05);
	border-style: dashed;
	opacity: 0.92;
}

.trambom-field-cell--empty .station-info-label {
	color: rgba(255, 255, 255, 0.38);
}

.trambom-field-cell--empty .station-info-value {
	color: rgba(255, 255, 255, 0.42);
	font-weight: 500;
}

/* Khung địa điểm (diadiem) — hàng trên cùng trạm bơm */
.trambom-diadiem-card .trambom-diadiem-frame {
	padding: 14px 16px;
	background: linear-gradient(145deg, rgba(0, 212, 255, 0.08) 0%, rgba(0, 120, 160, 0.06) 100%);
	border: 1px solid rgba(0, 212, 255, 0.28);
	border-radius: 10px;
	min-height: 52px;
	display: flex;
	align-items: center;
}

.trambom-diadiem-text {
	font-size: 14px;
	font-weight: 500;
	color: rgba(255, 255, 255, 0.92);
	line-height: 1.55;
	text-align: justify;
	word-break: break-word;
	width: 100%;
}

.trambom-diadiem-card--empty .trambom-diadiem-frame {
	background: rgba(0, 0, 0, 0.22);
	border-color: rgba(255, 255, 255, 0.08);
	border-style: dashed;
}

.trambom-diadiem-card--empty .trambom-diadiem-text {
	color: rgba(255, 255, 255, 0.4);
	font-weight: 500;
}

/* Trạm bơm: hàng riêng cho "Diện tích tưới/tiêu" (1/3) + "Danh sách kênh" (2/3) */
.trambom-kenh-row {
	grid-column: 1 / -1;
	display: grid;
	grid-template-columns: minmax(280px, 1fr) minmax(420px, 2fr);
	gap: 16px;
	align-items: start;
}

.trambom-kenh-row-area,
.trambom-kenh-row-list {
	min-width: 0;
}

.trambom-kenh-row-list .station-info-card {
	display: flex;
	flex-direction: column;
}

#trambomKenhTableContainer {
	flex: 1;
	min-height: 0;
	display: flex;
	flex-direction: column;
}

.trambom-kenh-table-wrap {
	flex: 1;
	min-height: 0;
}

.trambom-kenh-table {
	height: 100%;
}

@media (max-width: 1199.98px) {
	.trambom-kenh-row {
		grid-template-columns: 1fr;
	}
}

/* Rainfall Stats Card - Prominent */
.station-rainfall-card {
	background: linear-gradient(135deg, rgba(0, 212, 255, 0.15) 0%, rgba(0, 153, 204, 0.1) 100%);
	border: 1px solid rgba(0, 212, 255, 0.3);
	border-radius: 12px;
	padding: 24px;
	display: grid;
	grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
	gap: 24px;
	margin-bottom: 16px;
}

.station-rainfall-stat {
	text-align: center;
}

.station-rainfall-stat-label {
	font-size: 12px;
	color: rgba(255, 255, 255, 0.6);
	margin-bottom: 8px;
	text-transform: uppercase;
	letter-spacing: 0.5px;
}

.station-rainfall-stat-value {
	font-size: 32px;
	font-weight: 700;
	color: #00d4ff;
	line-height: 1.2;
	margin-bottom: 4px;
}

.station-rainfall-stat-unit {
	font-size: 14px;
	color: rgba(255, 255, 255, 0.5);
}

/* Location Card - Full width */
.station-location-card {
	background: rgba(255, 255, 255, 0.03);
	border: 1px solid rgba(255, 255, 255, 0.1);
	border-radius: 10px;
	padding: 20px;
	margin-bottom: 16px;
}

.station-location-content {
	display: grid;
	grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
	gap: 20px;
	margin-top: 16px;
}

/* Contact Card */
.station-contact-card {
	background: rgba(255, 255, 255, 0.03);
	border: 1px solid rgba(255, 255, 255, 0.1);
	border-radius: 10px;
	padding: 20px;
}

/* Mobile Back Button */
.btn-back-mobile {
	display: inline-flex;
	align-items: center;
	gap: 8px;
	padding: 8px 16px;
	background: rgba(255, 255, 255, 0.1);
	border: 1px solid rgba(255, 255, 255, 0.2);
	border-radius: 6px;
	color: rgba(255, 255, 255, 0.9);
	font-size: 14px;
	font-weight: 500;
	cursor: pointer;
	transition: all 0.2s ease;
	margin-bottom: 16px;
	margin-right: 12px;
}

.btn-back-mobile:hover {
	background: rgba(255, 255, 255, 0.15);
	border-color: rgba(255, 255, 255, 0.3);
	color: #fff;
}

.btn-back-mobile iconify-icon {
	font-size: 18px;
}

/* Mobile header adjustment */
.mailbox-detail-header {
	display: flex;
	align-items: center;
	gap: 12px;
}

.mailbox-detail-header h5 {
	margin: 0;
	flex: 1;
}

/* Responsive adjustments for station detail */
@media (max-width: 991.98px) {
	.station-detail-cards {
		display: none !important;
	}
	
	.station-detail-table {
		display: table !important;
	}
	
	/* On mobile, show back button when viewing detail */
	#tab-detail:not([style*="display: none"]) .btn-back-mobile {
		display: inline-flex !important;
	}
	
	/* On mobile, hide list tab when detail is shown */
	#tab-list[style*="display: none"] {
		display: none !important;
	}
	
	#tab-detail[style*="display: none"] {
		display: none !important;
	}
	
	/* Ensure search input is clickable on mobile */
	.mailbox-detail-content {
		position: relative;
		pointer-events: auto !important;
	}
	
	.mailbox-detail-content #mobileStationList {
		position: relative;
		pointer-events: auto !important;
		z-index: 1;
	}
	
	.mailbox-sidebar-search {
		position: relative;
		z-index: 100 !important;
		pointer-events: auto !important;
	}
	
	.mailbox-sidebar-search .input-group {
		position: relative;
		z-index: 101 !important;
		pointer-events: auto !important;
	}
	
	.mailbox-sidebar-search .input-group-text {
		pointer-events: auto !important;
		z-index: 102 !important;
		position: relative;
	}
	
	.mailbox-sidebar-search .form-control {
		pointer-events: auto !important;
		z-index: 102 !important;
		position: relative;
		cursor: text !important;
	}
	
	.mailbox-sidebar-search * {
		pointer-events: auto !important;
	}
	
	/* Override dragscroll for search input */
	.mailbox-detail.dragscroll .mailbox-sidebar-search {
		pointer-events: auto !important;
		touch-action: manipulation;
	}
	
	.mailbox-detail.dragscroll .mailbox-sidebar-search * {
		pointer-events: auto !important;
		touch-action: manipulation;
	}
	
	/* Specific rule for stationSearchInputMobile */
	#stationSearchInputMobile {
		pointer-events: auto !important;
		touch-action: manipulation !important;
		cursor: text !important;
		z-index: 1000 !important;
		position: relative;
	}
	
	/* Specific rule for lakeSearchInput */
	#lakeSearchInput {
		pointer-events: auto !important;
		touch-action: manipulation !important;
		cursor: text !important;
		z-index: 1000 !important;
		position: relative;
	}
	
	/* Ensure input group containing the search input is clickable */
	.mailbox-sidebar-search .input-group {
		pointer-events: auto !important;
		touch-action: manipulation !important;
	}
	
	/* Prevent dragscroll from interfering with input focus */
	.mailbox-detail.dragscroll #stationSearchInputMobile {
		pointer-events: auto !important;
		touch-action: manipulation !important;
		cursor: text !important;
	}
	
	/* Prevent dragscroll from interfering with lake search input focus */
	.mailbox-detail.dragscroll #lakeSearchInput {
		pointer-events: auto !important;
		touch-action: manipulation !important;
		cursor: text !important;
	}
}

@media (min-width: 992px) {
	.btn-back-mobile {
		display: none !important;
	}
}

@media (min-width: 992px) {
	.station-info-grid {
		grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
	}
	
	.station-rainfall-card {
		grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
	}
}

@media (min-width: 1200px) {
	.station-info-grid {
		grid-template-columns: repeat(3, 1fr);
	}
	
	.station-rainfall-card {
		grid-template-columns: repeat(2, 1fr);
	}
}

/* Table styles for mobile vá»›i chá»¯ lá»›n hÆ¡n */
.table-label-large {
	font-size: 13px;
	font-weight: 500;
	color: rgba(255, 255, 255, 0.7);
	text-transform: uppercase;
	letter-spacing: 0.5px;
	padding: 12px 16px;
	text-align: left;
}

.table-value-large {
	font-size: 15px;
	font-weight: 600;
	color: rgba(255, 255, 255, 0.95);
	padding: 12px 16px;
	line-height: 1.6;
	text-align: right;
}

/* Empty state */
.empty-state {
	text-align: center;
	padding: 20px 20px;
	color: rgba(255, 255, 255, 0.5);
}

.empty-state-icon {
	font-size: 64px;
	margin-bottom: 20px;
	opacity: 0.5;
}

/* Loading state */
.loading-state {
	text-align: center;
	padding: 40px 20px;
	color: rgba(255, 255, 255, 0.6);
}

/* ============================================
   4. SEARCH BAR STYLES
   ============================================ */

/* Map coordinates display */
#map-coordinates {
	font-size: 12px; /* Small - unified */
	color: rgba(255, 255, 255, 0.9);
	white-space: nowrap;
}

/* Search bar styling */
.menu-search-inline {
	position: relative;
	width: 300px;
}

.menu-search-inline .menu-icon {
	position: absolute;
	left: 12px;
	top: 50%;
	transform: translateY(-50%);
	z-index: 1;
	color: rgba(255, 255, 255, 0.5);
}

.menu-search-inline .form-control {
	padding-left: 40px;
	background: rgba(255, 255, 255, 0.1);
	border: 1px solid rgba(255, 255, 255, 0.1);
	color: #fff;
}

.menu-search-inline .form-control::placeholder {
	color: rgba(255, 255, 255, 0.5);
}

.menu-search-inline .form-control:focus {
	background: rgba(255, 255, 255, 0.15);
	border-color: rgba(255, 255, 255, 0.2);
	color: #fff;
}

/* Station search bar */
.mailbox-sidebar-search {
	padding: 12px;
	border-bottom: 1px solid rgba(255, 255, 255, 0.1);
	position: relative;
	z-index: 1;
}

.mailbox-sidebar-search .input-group {
	position: relative;
	z-index: 2;
}

.mailbox-sidebar-search .input-group-text {
	background: rgba(255, 255, 255, 0.1) !important;
	border-color: rgba(255, 255, 255, 0.1) !important;
	color: rgba(255, 255, 255, 0.7);
	pointer-events: auto;
	position: relative;
	z-index: 3;
}

.mailbox-sidebar-search .form-control {
	background: rgba(255, 255, 255, 0.1) !important;
	border-color: rgba(255, 255, 255, 0.1) !important;
	color: #fff !important;
	pointer-events: auto;
	position: relative;
	z-index: 3;
}

.mailbox-sidebar-search .form-control::placeholder {
	color: rgba(255, 255, 255, 0.5);
}

.mailbox-sidebar-search .form-control:focus {
	background: rgba(255, 255, 255, 0.15) !important;
	border-color: rgba(255, 255, 255, 0.2) !important;
	box-shadow: none;
}

/* Lake list mobile: căn phải trạng thái công trình */
.lake-mobile-item .mailbox-time {
	margin-left: auto;
	text-align: right;
}

/* Đảm bảo dòng tiêu đề trong lake-mobile-item là flex để căn phải được */
.lake-mobile-item .mailbox-sender {
	display: flex;
	align-items: center;
	gap: 8px;
}

/* Form select styles - ensure clickable */
.form-select {
	pointer-events: auto !important;
	position: relative;
	z-index: 10;
	cursor: pointer !important;
	touch-action: manipulation;
	/* Hide default browser arrow */
	-webkit-appearance: none;
	-moz-appearance: none;
	appearance: none;
	/* Add custom arrow - use background-color first, then arrow */
	background-color: rgba(33, 37, 41, 1);
	background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12'%3E%3Cpath fill='%23ffffff' d='M6 9L1 4h10z'/%3E%3C/svg%3E");
	background-repeat: no-repeat;
	background-position: right 12px center;
	background-size: 12px;
	padding-right: 35px;
}

/* Dark theme select background */
.form-select.bg-dark {
	background-color: rgba(33, 37, 41, 1) !important;
	background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12'%3E%3Cpath fill='%23ffffff' d='M6 9L1 4h10z'/%3E%3C/svg%3E");
	background-repeat: no-repeat;
	background-position: right 12px center;
	background-size: 12px;
}

.form-select:focus {
	outline: none;
	border-color: rgba(0, 212, 255, 0.5);
	box-shadow: 0 0 0 2px rgba(0, 212, 255, 0.1);
}

.form-select option {
	background: #2a2a2a !important;
	color: #ffffff !important;
	padding: 10px 12px;
	font-size: 14px;
}

.form-select option:hover,
.form-select option:checked,
.form-select option:focus {
	background: rgba(0, 212, 255, 0.2) !important;
	color: #ffffff !important;
}

/* For Firefox */
@-moz-document url-prefix() {
	.form-select {
		background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12'%3E%3Cpath fill='%23ffffff' d='M6 9L1 4h10z'/%3E%3C/svg%3E");
	}
}

/* Ensure select is clickable even in dragscroll containers */
.dragscroll .form-select,
.mailbox-detail .form-select,
.station-data-section .form-select,
.card-body .form-select,
#chartTypeSelect {
	pointer-events: auto !important;
	position: relative;
	z-index: 100 !important;
	cursor: pointer !important;
	touch-action: manipulation;
	-webkit-user-select: none;
	-moz-user-select: none;
	user-select: none;
}

/* Export buttons - increase height */
.export-btn {
	min-height: 42px;
	padding: 10px 16px;
	display: flex;
	align-items: center;
	justify-content: center;
	gap: 8px;
	font-size: 14px;
}

.export-btn iconify-icon {
	font-size: 18px;
}

/* Dropdown menu for chart export */
.btn-group {
	position: relative !important;
	z-index: 99999 !important;
}

.btn-group.show {
	z-index: 99999 !important;
}

.btn-group .dropdown-menu {
	position: absolute !important;
	z-index: 99999 !important;
	top: 100% !important;
	left: 0 !important;
	margin-top: 4px;
	min-width: 100%;
	display: none !important;
	pointer-events: auto !important;
}

.btn-group .dropdown-menu.show,
#exportChartDropdownMenu.show {
	display: block !important;
	z-index: 99999 !important;
	opacity: 1 !important;
	visibility: visible !important;
}

.dropdown-menu-dark {
	background-color: rgba(33, 37, 41, 0.98) !important;
	border: 1px solid rgba(255, 255, 255, 0.1) !important;
	border-radius: 6px;
	padding: 4px;
	box-shadow: 0 4px 12px rgba(0, 0, 0, 0.5);
	backdrop-filter: blur(10px);
	position: absolute !important;
	z-index: 99999 !important;
	pointer-events: auto !important;
}

.dropdown-menu-dark .dropdown-item {
	color: rgba(255, 255, 255, 0.9);
	padding: 8px 12px;
	border-radius: 4px;
	display: flex;
	align-items: center;
	gap: 8px;
	transition: all 0.2s ease;
	cursor: pointer;
	pointer-events: auto !important;
	position: relative;
	z-index: 100000;
}

.dropdown-menu-dark .dropdown-item:hover {
	background-color: rgba(0, 212, 255, 0.2);
	color: #fff;
}

.dropdown-menu-dark .dropdown-item iconify-icon {
	font-size: 16px;
}

.dropdown-menu-dark .dropdown-divider {
	border-color: rgba(255, 255, 255, 0.1);
	margin: 4px 0;
}

.btn-group .dropdown-toggle::after {
	margin-left: 8px;
}

/* Ensure parent containers don't clip dropdown */
.station-data-section,
.card-body,
.row,
.col-md-3 {
	overflow: visible !important;
	position: relative;
}

.station-data-section .row > div,
.station-data-section .col-md-3 {
	overflow: visible !important;
	position: relative;
}

/* Ensure chart canvas doesn't cover dropdown */
#rainfallChart {
	position: relative;
	z-index: 1;
}

/* Ensure card doesn't clip dropdown */
.card {
	overflow: visible !important;
}

.card-body {
	overflow: visible !important;
	position: relative;
}

/* Date input wrapper with DD/MM/YYYY format display */
.date-input-wrapper {
	position: relative;
	width: 100%;
	display: flex;
	align-items: center;
	border: 1px solid rgba(255, 255, 255, 0.15);
	border-radius: 6px;
	background: rgba(33, 37, 41, 1);
	padding: 0;
	transition: all 0.2s ease;
}

.date-input-wrapper:hover {
	border-color: rgba(0, 212, 255, 0.3);
}

.date-input-wrapper:focus-within {
	border-color: rgba(0, 212, 255, 0.5);
	box-shadow: 0 0 0 2px rgba(0, 212, 255, 0.1);
}

.date-input-native {
	position: relative;
	z-index: 2;
	color: transparent !important;
	cursor: pointer;
	width: 100%;
	padding-right: 45px !important;
	padding-left: 12px !important;
	border: none !important;
	background: transparent !important;
	height: 38px;
}

.date-input-native::-webkit-calendar-picker-indicator {
	display: none;
}

.date-display {
	position: absolute;
	left: 12px;
	top: 50%;
	transform: translateY(-50%);
	pointer-events: none;
	z-index: 3;
	color: #fff !important;
	font-size: 14px;
	background: transparent;
	opacity: 1;
	font-weight: 400;
}

.date-picker-btn {
	position: absolute;
	right: 4px;
	top: 50%;
	transform: translateY(-50%);
	z-index: 4;
	background: rgba(0, 212, 255, 0.2);
	border: none;
	border-radius: 4px;
	padding: 6px 8px;
	cursor: pointer;
	display: flex;
	align-items: center;
	justify-content: center;
	transition: all 0.2s ease;
	pointer-events: auto;
}

.date-picker-btn:hover {
	background: rgba(0, 212, 255, 0.4);
	transform: translateY(-50%) scale(1.05);
}

.date-picker-btn:active {
	background: rgba(0, 212, 255, 0.6);
	transform: translateY(-50%) scale(0.95);
}

.date-picker-btn iconify-icon {
	color: rgba(0, 212, 255, 1);
	font-size: 18px;
	display: block;
}

.date-input-native:focus {
	border: none !important;
	box-shadow: none !important;
	outline: none !important;
}

.date-input-wrapper:focus-within .date-display {
	color: #fff !important;
	opacity: 1;
}

.date-input-native:valid + .date-display {
	color: #fff !important;
	opacity: 1;
}

/* Ensure parent containers don't block select */
.station-data-section,
.card-body,
.row {
	position: relative;
}

.station-data-section .row > div {
	position: relative;
	z-index: 1;
}

/* ============================================
   5. MAP LAYER PANEL STYLES
   ============================================ */

/* Map Layer Panel - Windy.com style */
.map-layer-panel {
	position: fixed;
	top: 76px;
	right: -320px;
	width: 320px;
	height: calc(100vh - 56px);
	background: rgba(17, 26, 28, 0.95);
	backdrop-filter: blur(10px);
	box-shadow: -2px 0 10px rgba(0, 0, 0, 0.3);
	transition: right 0.3s ease;
	z-index: 1000;
	overflow-y: auto;
	border-left: 1px solid rgba(255, 255, 255, 0.1);
}

.map-layer-panel.active {
	right: 0;
}

.map-layer-panel-header {
	padding: 15px 20px;
	border-bottom: 1px solid rgba(255, 255, 255, 0.1);
	display: flex;
	align-items: center;
	justify-content: space-between;
	background: rgba(255, 255, 255, 0.05);
}

.map-layer-panel-header h5 {
	margin: 0;
	font-size: 14px; /* Base size - unified */
	font-weight: 600;
	color: #fff;
}

.map-layer-panel-close {
	background: none;
	border: none;
	color: rgba(255, 255, 255, 0.7);
	cursor: pointer;
	padding: 5px;
	display: flex;
	align-items: center;
	justify-content: center;
	transition: color 0.2s;
}

.map-layer-panel-close:hover {
	color: #fff;
}

.map-layer-panel-content {
	padding: 10px 0;
}

.map-layer-group {
	margin-bottom: 5px;
}

.map-layer-group-title {
	padding: 8px 20px;
	font-size: 11px; /* Extra small - unified scale */
	font-weight: 600;
	color: rgba(255, 255, 255, 0.72);
	text-transform: uppercase;
	letter-spacing: 0.5px;
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 8px;
	background: rgba(255, 255, 255, 0.02);
}

.map-layer-group-switch {
	margin: 0;
	display: inline-flex;
	align-items: center;
}

.map-layer-group-switch .form-check-input {
	margin: 0;
	width: 34px;
	height: 19px;
	border: 1px solid rgba(251, 191, 36, 0.7);
	background-color: rgba(255, 255, 255, 0.08);
	box-shadow: 0 0 0 1px rgba(251, 191, 36, 0.18);
}

.map-layer-group-switch .form-check-input:focus {
	border-color: rgba(251, 191, 36, 0.9);
	box-shadow: 0 0 0 2px rgba(251, 191, 36, 0.2);
}

.map-layer-group-switch .form-check-input:checked {
	background-color: #f59e0b;
	border-color: #fbbf24;
}

.map-layer-group-switch .form-check-input:indeterminate {
	background-color: #f59e0b;
	border-color: #fbbf24;
}

.map-layer-item {
	display: flex;
	align-items: center;
	padding: 10px 20px;
	cursor: pointer;
	transition: background 0.2s;
	border-left: 3px solid transparent;
	user-select: none;
}

.map-layer-item input[type="checkbox"] {
	cursor: pointer;
}

.map-layer-item:hover {
	background: rgba(255, 255, 255, 0.05);
}

.map-layer-item.active {
	background: rgba(255, 255, 255, 0.08);
	border-left-color: #00d4ff;
}

.map-layer-item-icon {
	width: 32px;
	height: 32px;
	display: flex;
	align-items: center;
	justify-content: center;
	margin-right: 12px;
	border-radius: 4px;
	background: rgba(255, 255, 255, 0.1);
	flex-shrink: 0;
}

.map-layer-item.active .map-layer-item-icon {
	background: rgba(0, 212, 255, 0.2);
}

.map-layer-item-content {
	flex: 1;
	min-width: 0;
}

.map-layer-item-title {
	font-size: 14px; /* Base size - unified */
	color: rgba(255, 255, 255, 0.9);
	font-weight: 500;
	margin-bottom: 2px;
}

.map-layer-item-subtitle {
	font-size: 12px; /* Small - unified */
	color: rgba(255, 255, 255, 0.5);
}

.map-layer-item-toggle {
	margin-left: 10px;
	flex-shrink: 0;
}

.map-layer-item-toggle .form-check-input {
	width: 36px;
	height: 20px;
	cursor: pointer;
}

/* ============================================
   RISK MAP MANUAL FORM STYLES
   ============================================ */

.risk-map-manual-form {
	padding: 0 20px 16px 20px;
	background: rgba(255, 255, 255, 0.02);
	border-top: 1px solid rgba(255, 255, 255, 0.05);
	animation: slideDown 0.3s ease;
	overflow: hidden;
}

@keyframes slideDown {
	from {
		opacity: 0;
		max-height: 0;
		padding-top: 0;
		padding-bottom: 0;
	}
	to {
		opacity: 1;
		max-height: 500px;
		padding-top: 0;
		padding-bottom: 16px;
	}
}

.risk-map-manual-toggle.active .risk-map-caret {
	transform: rotate(90deg);
	transition: transform 0.3s ease;
}

.risk-map-caret {
	transition: transform 0.3s ease;
}

.risk-map-form-content {
	padding-top: 16px;
}

.risk-map-form-group {
	margin-bottom: 16px;
}

.risk-map-form-label {
	display: block;
	font-size: 12px;
	color: rgba(255, 255, 255, 0.7);
	margin-bottom: 8px;
	font-weight: 500;
}

.risk-map-form-select,
.risk-map-form-input {
	width: 100%;
	padding: 10px 12px;
	background: rgba(255, 255, 255, 0.1);
	border: 1px solid rgba(255, 255, 255, 0.1);
	border-radius: 6px;
	color: #fff;
	font-size: 14px;
	transition: all 0.2s ease;
	box-sizing: border-box;
}

.risk-map-form-select:focus,
.risk-map-form-input:focus {
	outline: none;
	background: rgba(255, 255, 255, 0.15);
	border-color: rgba(0, 212, 255, 0.5);
	box-shadow: 0 0 0 2px rgba(0, 212, 255, 0.1);
}

.risk-map-form-select option {
	background: #1a1a1a;
	color: #fff;
}

.risk-map-form-input::placeholder {
	color: rgba(255, 255, 255, 0.4);
}

.risk-map-form-buttons {
	margin-top: 20px;
}

.risk-map-form-buttons .btn {
	font-size: 13px;
	padding: 10px 16px;
	border-radius: 6px;
	font-weight: 500;
	transition: all 0.2s ease;
	border: none;
}

.risk-map-form-buttons .btn-primary {
	background: linear-gradient(135deg, #00d4ff 0%, #0099cc 100%);
	color: #fff;
}

.risk-map-form-buttons .btn-primary:hover {
	background: linear-gradient(135deg, #00e5ff 0%, #00aadd 100%);
	transform: translateY(-1px);
	box-shadow: 0 4px 12px rgba(0, 212, 255, 0.3);
}

.risk-map-form-buttons .btn-secondary {
	background: rgba(255, 255, 255, 0.1);
	border: 1px solid rgba(255, 255, 255, 0.2);
	color: rgba(255, 255, 255, 0.9);
}

.risk-map-form-buttons .btn-secondary:hover {
	background: rgba(255, 255, 255, 0.15);
	border-color: rgba(255, 255, 255, 0.3);
	color: #fff;
}

/* Layer panel overlay - only show when panel is active */
.map-layer-panel-overlay {
	display: none !important; /* Completely hidden when not active */
	position: fixed;
	top: 56px;
	left: 0;
	right: 0;
	bottom: 0;
	background: rgba(0, 0, 0, 0.5);
	z-index: 999;
	opacity: 0;
	transition: opacity 0.3s;
	pointer-events: none; /* Don't block clicks when not active */
}

.map-layer-panel-overlay.active {
	display: block !important; /* Show when active */
	opacity: 0; /* sá»­a láº¡i 1 vá»� 0*/
	pointer-events: auto; /* Allow clicks when active */
}

/* ============================================
   6. TIMELINE STYLES
   ============================================ */

/* Modern Timeline Styles - Windy.com style full-width */
.modern-timeline {
	position: fixed;
	bottom: 0;
	left: 0;
	right: auto; /* KhÃ´ng dÃ¹ng right Ä‘á»ƒ trÃ¡nh conflict vá»›i left vÃ  width */
	width: 100%;
	z-index: 1000;
	visibility: hidden;
	opacity: 0;
	transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
	pointer-events: none;
	box-sizing: border-box;
	margin: 0;
	padding: 0;
}

/* Ensure timeline spans full width even when sidebar is open */
.app-sidebar-collapsed .modern-timeline {
	/* Position vÃ  width sáº½ Ä‘Æ°á»£c set bá»Ÿi JavaScript Ä‘á»ƒ Ä‘áº£m báº£o tÃ­nh nháº¥t quÃ¡n */
}

.modern-timeline.visible {
	visibility: visible;
	opacity: 1;
	pointer-events: all;
	transform: translateY(0);
}

.modern-timeline.hidden {
	transform: translateY(100%);
}

/* Timeline split layouts - KhÃ´ng dÃ¹ng !important Ä‘á»ƒ cho phÃ©p JavaScript override */
.modern-timeline.timeline-split-2 {
	/* Width sáº½ Ä‘Æ°á»£c set bá»Ÿi JavaScript dá»±a trÃªn sá»‘ timeline */
}

.modern-timeline.timeline-split-4 {
	/* Width sáº½ Ä‘Æ°á»£c set bá»Ÿi JavaScript dá»±a trÃªn sá»‘ timeline */
}

/* Ensure timelines don't overlap when split - add border between them */
.modern-timeline.timeline-split-2:not(:first-child),
.modern-timeline.timeline-split-4:not(:first-child) {
	border-left: 1px solid rgba(255, 255, 255, 0.1);
	margin-left: 0; /* Ä�áº£m báº£o khÃ´ng cÃ³ khoáº£ng cÃ¡ch */
}

/* Ä�áº£m báº£o cÃ¡c timeline náº±m sÃ¡t nhau, khÃ´ng cÃ³ khoáº£ng cÃ¡ch */
.modern-timeline.visible {
	margin: 0 !important;
	padding: 0;
	box-sizing: border-box;
}

/* Timeline label styling for split layouts */
.modern-timeline.timeline-split-2 .timeline-label,
.modern-timeline.timeline-split-4 .timeline-label {
	font-size: 10px;
	padding: 2px 4px;
}

/* Mobile: Ensure timelines stack properly without overlap */
@media (max-width: 991.98px) {
	.modern-timeline.visible {
		position: fixed !important;
		width: 100% !important;
		left: 0 !important;
		right: 0 !important;
	}
	
	.modern-timeline.visible:not(:last-child) {
		margin-bottom: 0;
	}
	
	/* Ensure timeline containers don't overflow on mobile */
	.modern-timeline .timeline-container {
		max-width: 100%;
		overflow-x: hidden;
	}
}

.timeline-container {
	background: rgba(17, 26, 28, 0.95);
	backdrop-filter: blur(20px);
	-webkit-backdrop-filter: blur(20px);
	border-radius: 0;
	padding: 8px 16px;
	box-shadow: 0 -4px 20px rgba(0, 0, 0, 0.3), 0 0 0 1px rgba(255, 255, 255, 0.1) inset;
	width: 100%;
	box-sizing: border-box;
}

.timeline-controls {
	display: flex;
	align-items: center;
	gap: 8px;
	margin-bottom: 4px;
	max-width: 100%;
	overflow: hidden; /* Prevent overflow */
}

.timeline-label {
	font-size: 11px;
	font-weight: 600;
	color: rgba(255, 255, 255, 0.9);
	text-align: center;
	margin-top: 4px;
	padding: 2px 8px;
	text-transform: uppercase;
	letter-spacing: 0.5px;
	white-space: nowrap;
	overflow: hidden;
	text-overflow: ellipsis;
}

.timeline-btn {
	width: 36px;
	height: 36px;
	border-radius: 8px;
	border: none;
	display: flex;
	align-items: center;
	justify-content: center;
	cursor: pointer;
	transition: all 0.2s ease;
	background: rgba(255, 255, 255, 0.1);
	color: #fff;
	font-size: 14px;
	flex-shrink: 0; /* Prevent buttons from shrinking */
}

.timeline-btn:hover {
	background: rgba(255, 255, 255, 0.2);
	transform: scale(1.05);
}

.timeline-btn:active {
	transform: scale(0.95);
}

.timeline-btn.play {
	width: 40px;
	height: 40px;
	background: linear-gradient(135deg, #00d4ff 0%, #0099cc 100%);
	box-shadow: 0 3px 12px rgba(0, 212, 255, 0.4);
}

.timeline-btn.play:hover {
	background: linear-gradient(135deg, #00e5ff 0%, #00aadd 100%);
	box-shadow: 0 4px 16px rgba(0, 212, 255, 0.6);
}

.timeline-btn.pause {
	background: linear-gradient(135deg, #ff6b6b 0%, #ee5a6f 100%);
	box-shadow: 0 3px 12px rgba(255, 107, 107, 0.4);
}

.timeline-btn.pause:hover {
	background: linear-gradient(135deg, #ff7b7b 0%, #ff6a7f 100%);
	box-shadow: 0 4px 16px rgba(255, 107, 107, 0.6);
}

.timeline-slider-wrapper {
	flex: 1;
	position: relative;
	padding: 4px 0;
	min-width: 0; /* Allow flex item to shrink below its minimum content size */
	overflow: hidden; /* Prevent content from overflowing */
	max-width: 100%; /* Ensure it doesn't exceed container */
}

.timeline-info {
	display: flex;
	justify-content: space-between;
	align-items: center;
	margin-top: 4px;
	font-size: 12px; /* Small - unified */
	color: rgba(255, 255, 255, 0.7);
	width: 100%;
	flex-wrap: wrap;
	gap: 6px;
	overflow: hidden; /* Prevent text overflow */
	min-width: 0; /* Allow shrinking */
}

.timeline-current-time {
	font-weight: 600;
	color: #00d4ff;
	font-size: 14px; /* Base size - unified */
	white-space: nowrap;
	overflow: hidden;
	text-overflow: ellipsis;
	max-width: 100%;
	flex-shrink: 1; /* Allow shrinking if needed */
}

.timeline-range {
	display: flex;
	justify-content: space-between;
	width: 100%;
	margin-top: 2px;
	gap: 6px;
	overflow: hidden;
	min-width: 0; /* Allow shrinking */
}

.timeline-date {
	color: rgba(255, 255, 255, 0.5);
	font-size: 11px; /* Extra small - unified */
	white-space: nowrap;
	overflow: hidden;
	text-overflow: ellipsis;
	flex-shrink: 1; /* Allow shrinking if needed */
}

/* Custom ionRangeSlider styling */
.modern-timeline .irs {
	height: 35px;
	width: 100%;
}

.modern-timeline .irs-line {
	height: 4px;
	background: rgba(255, 255, 255, 0.2);
	border-radius: 2px;
	width: 100%;
}

.modern-timeline .irs-bar {
	height: 4px;
	background: linear-gradient(90deg, #00d4ff 0%, #0099cc 100%);
	border-radius: 2px;
}

.modern-timeline .irs-handle {
	width: 16px;
	height: 16px;
	top: 10px;
	background: #fff;
	border: 2px solid #00d4ff;
	border-radius: 50%;
	box-shadow: 0 2px 6px rgba(0, 212, 255, 0.5);
	cursor: pointer;
	transition: all 0.2s ease;
}

.modern-timeline .irs-handle:hover {
	transform: scale(1.2);
	box-shadow: 0 4px 12px rgba(0, 212, 255, 0.7);
}

.modern-timeline .irs-handle.state_hover {
	transform: scale(1.2);
}

.modern-timeline .irs-from,
.modern-timeline .irs-to,
.modern-timeline .irs-single {
	background: rgba(0, 212, 255, 0.9);
	color: #fff;
	font-size: 11px; /* Extra small - unified */
	padding: 2px 6px;
	border-radius: 4px;
	top: -28px;
	white-space: nowrap;
}

.modern-timeline .irs-from:before,
.modern-timeline .irs-to:before,
.modern-timeline .irs-single:before {
	border-top-color: rgba(0, 212, 255, 0.9);
}

.modern-timeline .irs-grid-text {
	color: rgba(255, 255, 255, 0.5);
	font-size: 10px; /* Tiny - unified scale */
	bottom: -4px;
	white-space: nowrap;
}

/* ============================================
   7. SIDEBAR MENU STYLES - Unified typography
   ============================================ */

/* Sidebar menu with balanced font sizes - aligned with overall design */
.app-sidebar .menu-header {
	font-size: 12px !important;
	font-weight: 600 !important;
	letter-spacing: 0.5px;
	padding: 12px 20px 8px !important;
	text-transform: uppercase;
}

.app-sidebar .menu-item {
	padding: 0 !important;
}

.app-sidebar .menu-link {
	padding: 12px 20px !important;
	font-size: 14px !important; /* Base size - unified with body */
	line-height: 1.5 !important;
	min-height: 44px !important;
	display: flex !important;
	align-items: center !important;
}

.app-sidebar .menu-text {
	font-size: 14px !important; /* Unified base size */
	font-weight: 400 !important;
	line-height: 1.5 !important;
	letter-spacing: 0;
}

.app-sidebar .menu-icon {
	width: 20px !important;
	height: 20px !important;
	font-size: 20px !important;
	margin-right: 12px !important;
	display: flex !important;
	align-items: center !important;
	justify-content: center !important;
	flex-shrink: 0;
}

.app-sidebar .menu-icon iconify-icon {
	width: 20px !important;
	height: 20px !important;
	font-size: 20px !important;
}

.app-sidebar .menu-badge {
	font-size: 12px !important; /* Small size - unified scale */
	font-weight: 600 !important;
	padding: 3px 7px !important;
	min-width: 22px !important;
	height: 22px !important;
	line-height: 1.3 !important;
	margin-left: auto !important;
	display: flex !important;
	align-items: center !important;
	justify-content: center !important;
	flex-shrink: 0;
}

/* Hover and active states with better visibility */
.app-sidebar .menu-item:hover .menu-link,
.app-sidebar .menu-item.active .menu-link {
	background-color: rgba(255, 255, 255, 0.1) !important;
	font-weight: 500 !important;
}

.app-sidebar .menu-item.active .menu-link {
	background-color: rgba(0, 212, 255, 0.15) !important;
	color: #00d4ff !important;
	font-weight: 500 !important;
}

/* Improve contrast for better readability */
.app-sidebar .menu-link {
	color: rgba(255, 255, 255, 0.9) !important;
}

.app-sidebar .menu-link:hover {
	color: #fff !important;
}

/* Thanh cuộn dọc khi danh mục sidebar dài */
#sidebar .app-sidebar-content {
	overflow-y: auto !important;
	scrollbar-width: thin;
	scrollbar-color: rgba(0, 212, 255, 0.55) rgba(255, 255, 255, 0.08);
}

#sidebar .app-sidebar-content::-webkit-scrollbar {
	width: 8px;
}

#sidebar .app-sidebar-content::-webkit-scrollbar-track {
	background: rgba(255, 255, 255, 0.08);
	border-radius: 999px;
}

#sidebar .app-sidebar-content::-webkit-scrollbar-thumb {
	background: linear-gradient(180deg, rgba(0, 212, 255, 0.75), rgba(0, 153, 204, 0.75));
	border-radius: 999px;
}

#sidebar .app-sidebar-content::-webkit-scrollbar-thumb:hover {
	background: linear-gradient(180deg, rgba(0, 212, 255, 0.95), rgba(0, 153, 204, 0.95));
}

/* Nhóm menu đóng/mở: click tiêu đề (menu-header) */
.app-sidebar .menu-group .menu-header.menu-group-toggle {
	display: flex;
	align-items: center;
	justify-content: space-between;
	cursor: pointer;
	user-select: none;
}

.app-sidebar .menu-group .menu-group-caret {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	font-size: 14px;
	opacity: 0.8;
	transition: transform 0.2s ease, opacity 0.2s ease;
}

.app-sidebar .menu-group.menu-group-collapsed .menu-group-caret {
	transform: rotate(-90deg);
	opacity: 0.65;
}

.app-sidebar .menu-group.menu-group-collapsed .menu-item {
	display: none;
}

/* ============================================
   8. UTILITY STYLES
   ============================================ */

/* Hide mailbox-sidebar when sidebar is collapsed, but allow it to show when explicitly displayed */
/* Hide mailbox-sidebar by default */
#mailboxSidebar {
	display: none !important;
}

.app-sidebar-collapsed .mailbox-sidebar {
	display: none !important;
}

/* Show mailbox-sidebar when it has visible class */
#mailboxSidebar.visible {
	display: block !important;
}

.mailbox-sidebar.visible {
	display: block !important;
}

/* Toolbar button spacing */
.mailbox-toolbar-item {
	margin-right: 8px;
}

/* ============================
   Lake list selection highlight
   ============================ */

/* Desktop: dòng hồ đang chọn trong bảng */
#lakeListContainer table tbody tr.table-active {
	outline: 2px solid #00d4ff;
	outline-offset: -2px;
	background-color: rgba(0, 212, 255, 0.12);
}

/* Mobile: item hồ đang chọn */
.lake-mobile-item.active {
	border: 1px solid #00d4ff;
	box-shadow: 0 0 0 1px rgba(0, 212, 255, 0.4);
}

/* ============================================
   9. RESPONSIVE STYLES
   ============================================ */

/* Mobile responsive */
@media (max-width: 991.98px) {
	.map-legend-panel {
		bottom: 60px; /* Adjust to not overlap with compact timeline */
		right: 10px;
		left: 10px;
		max-width: none;
		max-height: calc(60vh - 80px); /* Reserve space for compact timeline */
		/* Ensure it doesn't overlap with Mapbox zoom controls */
		margin-right: 50px; /* Space for zoom controls */
	}
	
	/* Ensure Mapbox controls don't overlap with legend panel on mobile */
	.mapboxgl-ctrl-top-right {
		top: 10px !important;
		right: 10px !important;
	}
	
	.map-legend-panel.collapsed {
		max-height: 40px;
	}
	
	.map-legend-panel-body {
		max-height: calc(60vh - 80px - 50px); /* Subtract header height and timeline space */
	}
	
	.menu-search-inline {
		width: 100%;
	}
	
	.map-layer-panel {
		width: 280px;
		right: -280px;
	}
	
	.map-layer-panel-overlay.active {
		display: block;
	}
	
	/* Timeline adjustments for mobile */
	.modern-timeline .timeline-container {
		padding: 10px 12px;
	}
	
	/* Slightly larger on mobile but still unified */
	.app-sidebar .menu-header {
		font-size: 12px !important; /* Same as desktop - unified */
		padding: 12px 20px 8px !important;
	}
	
	.app-sidebar .menu-link {
		padding: 12px 20px !important;
		font-size: 14px !important; /* Same as desktop - unified */
		min-height: 44px !important;
	}
	
	.app-sidebar .menu-text {
		font-size: 14px !important; /* Unified */
	}
	
	.app-sidebar .menu-icon {
		width: 20px !important; /* Unified */
		height: 20px !important;
		font-size: 20px !important;
		margin-right: 12px !important;
	}
}

/* Hide brand on mobile */
@media (max-width: 991.98px) {
	.brand {
		display: none !important;
	}
}

/* Timeline responsive */
@media (max-width: 768px) {
	.timeline-container {
		padding: 6px 10px;
	}
	
	.timeline-controls {
		gap: 6px;
		flex-wrap: wrap;
		margin-bottom: 3px;
		overflow: hidden; /* Prevent overflow */
	}
	
	.timeline-label {
		font-size: 10px;
		margin-top: 2px;
		padding: 1px 4px;
	}
	
	.timeline-btn {
		width: 32px;
		height: 32px;
		font-size: 12px;
		flex-shrink: 0; /* Prevent buttons from shrinking */
	}
	
	.timeline-btn.play {
		width: 36px;
		height: 36px;
	}
	
	.timeline-slider-wrapper {
		width: 100%;
		order: 3; /* Move slider below buttons on mobile */
		margin-top: 4px;
		padding: 2px 0;
		max-width: 100%; /* Full width on mobile */
		overflow: hidden; /* Prevent content from overflowing */
	}
	
	.timeline-info {
		font-size: 10px;
		flex-wrap: wrap;
		margin-top: 2px;
		overflow: hidden; /* Prevent text overflow */
		min-width: 0; /* Allow shrinking */
	}
	
	.timeline-current-time {
		font-size: 11px;
		overflow: hidden;
		text-overflow: ellipsis;
		max-width: 100%;
		flex-shrink: 1; /* Allow shrinking if needed */
	}
	
	.modern-timeline .irs {
		height: 30px;
	}
	
	.modern-timeline .irs-handle {
		width: 14px;
		height: 14px;
		top: 8px;
	}
}

/* ============================================
   9. GO TO COORDINATES DIALOG
   ============================================ */

/* Overlay */
.goto-coordinates-overlay {
	position: fixed;
	top: 0;
	left: 0;
	width: 100%;
	height: 100%;
	background: rgba(0, 0, 0, 0.7);
	backdrop-filter: blur(4px);
	-webkit-backdrop-filter: blur(4px); /* Safari support */
	display: flex;
	align-items: center;
	justify-content: center;
	z-index: 10000;
	opacity: 0;
	visibility: hidden;
	transition: opacity 0.2s ease, visibility 0.2s ease;
	padding: 20px;
	overflow-y: auto;
	-webkit-overflow-scrolling: touch; /* Smooth scrolling on iOS */
}

.goto-coordinates-overlay.show {
	opacity: 1;
	visibility: visible;
}

/* Dialog container */
.goto-coordinates-dialog {
	background: #2d2d2d;
	border-radius: 12px;
	box-shadow: 0 8px 32px rgba(0, 0, 0, 0.4);
	width: 100%;
	max-width: 420px;
	max-height: 90vh;
	display: flex;
	flex-direction: column;
	transform: scale(0.9);
	transition: transform 0.2s ease;
	overflow: hidden;
}

.goto-coordinates-overlay.show .goto-coordinates-dialog {
	transform: scale(1);
}

/* Dialog header */
.goto-coordinates-header {
	padding: 20px;
	border-bottom: 1px solid rgba(255, 255, 255, 0.1);
	display: flex;
	align-items: center;
	justify-content: space-between;
	flex-shrink: 0;
}

.goto-coordinates-header h5 {
	color: #fff;
	font-size: 18px;
	font-weight: 600;
	margin: 0;
}

.goto-coordinates-close {
	background: transparent;
	border: none;
	color: rgba(255, 255, 255, 0.6);
	cursor: pointer;
	padding: 4px;
	display: flex;
	align-items: center;
	justify-content: center;
	width: 32px;
	height: 32px;
	border-radius: 6px;
	transition: all 0.2s ease;
}

.goto-coordinates-close:hover {
	background: rgba(255, 255, 255, 0.1);
	color: #fff;
}

/* Dialog body */
.goto-coordinates-body {
	padding: 24px;
	flex: 1;
	overflow-y: auto;
	min-height: 0;
}

.goto-coordinates-form-group {
	margin-bottom: 20px;
}

.goto-coordinates-form-group:last-child {
	margin-bottom: 0;
}

.goto-coordinates-label {
	display: flex;
	align-items: center;
	color: #fff;
	font-size: 14px;
	font-weight: 500;
	margin-bottom: 8px;
}

.goto-coordinates-input {
	width: 100%;
	padding: 12px 16px;
	background: rgba(255, 255, 255, 0.05);
	border: 1px solid rgba(255, 255, 255, 0.15);
	border-radius: 8px;
	color: #fff;
	font-size: 15px;
	font-family: 'Inter', sans-serif;
	transition: all 0.2s ease;
	box-sizing: border-box;
	-webkit-appearance: none;
	-moz-appearance: textfield;
	touch-action: manipulation; /* Better touch handling on mobile */
}

.goto-coordinates-input::placeholder {
	color: rgba(255, 255, 255, 0.3);
}

.goto-coordinates-input:focus {
	outline: none;
	border-color: #00d4ff;
	background: rgba(255, 255, 255, 0.08);
	box-shadow: 0 0 0 3px rgba(0, 212, 255, 0.1);
}

.goto-coordinates-input::-webkit-inner-spin-button,
.goto-coordinates-input::-webkit-outer-spin-button {
	-webkit-appearance: none;
	margin: 0;
}

.goto-coordinates-hint {
	color: rgba(255, 255, 255, 0.4);
	font-size: 12px;
	margin-top: 6px;
}

.goto-coordinates-error {
	color: #ff6b6b;
	font-size: 13px;
	margin-top: 12px;
	padding: 10px;
	background: rgba(255, 107, 107, 0.1);
	border-radius: 6px;
	border-left: 3px solid #ff6b6b;
	display: none;
}

.goto-coordinates-error.show {
	display: block;
}

/* Dialog footer */
.goto-coordinates-footer {
	padding: 16px 20px;
	border-top: 1px solid rgba(255, 255, 255, 0.1);
	display: flex;
	align-items: center;
	justify-content: flex-end;
	gap: 12px;
	flex-shrink: 0;
}

.goto-coordinates-footer .btn {
	min-width: 100px;
	display: flex;
	align-items: center;
	justify-content: center;
	gap: 6px;
	font-weight: 500;
	font-size: 12px;
}

/* Mobile responsive */
@media (max-width: 768px) {
	.goto-coordinates-overlay {
		padding: 12px;
		align-items: flex-end;
	}
	
	.goto-coordinates-dialog {
		max-width: 100%;
		max-height: 85vh;
		border-radius: 16px 16px 0 0;
	}
	
	.goto-coordinates-header {
		padding: 16px;
	}
	
	.goto-coordinates-header h5 {
		font-size: 16px;
	}
	
	.goto-coordinates-body {
		padding: 20px 16px;
	}
	
	.goto-coordinates-form-group {
		margin-bottom: 16px;
	}
	
	.goto-coordinates-input {
		padding: 14px 16px;
		font-size: 16px; /* Prevent zoom on iOS */
	}
	
	.goto-coordinates-footer {
		padding: 14px 16px;
		flex-direction: column-reverse;
		gap: 10px;
	}
	
	.goto-coordinates-footer .btn {
		width: 100%;
		min-width: auto;
		padding: 12px;
	}
}

@media (max-width: 480px) {
	.goto-coordinates-overlay {
		padding: 0;
	}
	
	.goto-coordinates-dialog {
		border-radius: 0;
		max-height: 100vh;
	}
	
	.goto-coordinates-header {
		padding: 14px;
	}
	
	.goto-coordinates-body {
		padding: 18px 14px;
	}
	
	.goto-coordinates-footer {
		padding: 12px 14px;
	}
}

/* ============================================
   10. GO TO COORDINATES MARKER (FLAG ICON)
   ============================================ */

.goto-flag-marker {
	transition: transform 0.2s ease;
}

.goto-flag-marker:hover {
	transform: scale(1.1);
}

.goto-flag-marker svg {
	display: block;
	filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.3));
}

/* ============================================
   11. MAPBOX CONTROLS PANEL
   ============================================ */

/* Góc trên phải: nút Home + nhóm zoom cùng hàng (Home bên trái) */
.mapboxgl-ctrl-top-right {
	display: flex;
	flex-direction: row;
	align-items: flex-start;
	justify-content: flex-end;
	gap: 6px;
	flex-wrap: wrap;
}

/* Mapbox Controls Toggle Button */
.mapbox-controls-toggle {
	position: absolute;
	top: 85px; /* Điều chỉnh xuống dưới một chút để có khoảng cách với button trên */
	right: 10px;
	z-index: 2;
	width: 32px;
	height: 32px;
	background: rgba(0, 0, 0, 0.75);
	backdrop-filter: blur(8px);
	-webkit-backdrop-filter: blur(8px);
	border: 1px solid rgba(255, 255, 255, 0.2);
	border-radius: 12px;
	cursor: pointer;
	display: flex;
	align-items: center;
	justify-content: center;
	transition: all 0.3s ease;
	box-shadow: 0 4px 16px rgba(0, 0, 0, 0.3);
}

.mapbox-controls-toggle:hover {
	background: rgba(0, 0, 0, 0.85);
	border-color: rgba(255, 255, 255, 0.3);
	transform: scale(1.05);
}

.mapbox-controls-toggle:active {
	transform: scale(0.95);
}

.mapbox-controls-toggle iconify-icon {
	font-size: 24px;
	color: rgba(255, 255, 255, 0.9);
	transition: all 0.3s ease;
}

.mapbox-controls-toggle:hover iconify-icon {
	color: #00d4ff;
}

.mapbox-controls-toggle.active {
	background: rgba(0, 212, 255, 0.2);
	border-color: #00d4ff;
}

.mapbox-controls-toggle.active iconify-icon {
	color: #00d4ff;
}

.mapbox-controls-panel {
	position: absolute;
	top: 100px;
	right: 20px;
	z-index: 2;
	background: rgba(0, 0, 0, 0.75);
	backdrop-filter: blur(8px);
	-webkit-backdrop-filter: blur(8px);
	border-radius: 12px;
	padding: 10px;
	box-shadow: 0 4px 16px rgba(0, 0, 0, 0.3);
	min-width: 200px;
	max-width: 280px;
	/* Ensure it doesn't overlap with navigation controls */
	margin-top: 10px;
	transition: all 0.3s ease;
	opacity: 1;
	visibility: visible;
	transform: translateX(0);
}

.mapbox-controls-panel.hidden {
	opacity: 0;
	visibility: hidden;
	transform: translateX(20px);
	pointer-events: none;
}

.mapbox-control-group {
	margin-bottom: 8px;
}

.mapbox-control-group:last-child {
	margin-bottom: 0;
}

.mapbox-control-label {
	color: rgba(255, 255, 255, 0.9);
	font-size: 11px;
	font-weight: 600;
	text-transform: uppercase;
	letter-spacing: 0.5px;
	margin-bottom: 6px;
	padding: 0 4px;
}

/* Dynamic Lighting Selector */
.mapbox-lighting-selector {
	display: grid;
	grid-template-columns: repeat(2, 1fr);
	gap: 4px;
}

.lighting-btn {
	background: rgba(255, 255, 255, 0.1);
	border: 1px solid rgba(255, 255, 255, 0.2);
	border-radius: 8px;
	color: rgba(255, 255, 255, 0.7);
	padding: 6px 8px;
	cursor: pointer;
	transition: all 0.2s ease;
	display: flex;
	flex-direction: column;
	align-items: center;
	gap: 3px;
	font-size: 11px;
	font-weight: 500;
	min-height: 45px;
	justify-content: center;
}

.lighting-btn iconify-icon {
	font-size: 16px;
	color: rgba(255, 255, 255, 0.8);
}

.lighting-btn span {
	font-size: 9px;
	white-space: nowrap;
}

.lighting-btn:hover {
	background: rgba(255, 255, 255, 0.15);
	border-color: rgba(255, 255, 255, 0.3);
	color: rgba(255, 255, 255, 0.9);
	transform: translateY(-2px);
}

.lighting-btn.active {
	background: rgba(0, 212, 255, 0.3);
	border-color: #00d4ff;
	color: #fff;
	box-shadow: 0 0 12px rgba(0, 212, 255, 0.4);
}

.lighting-btn.active iconify-icon {
	color: #00d4ff;
}

/* Quick Actions Grid (4 buttons) */
.mapbox-quick-actions-grid {
	display: grid;
	grid-template-columns: repeat(2, 1fr);
	gap: 4px;
}

.mapbox-quick-action-btn {
	background: rgba(255, 255, 255, 0.1);
	border: 1px solid rgba(255, 255, 255, 0.2);
	border-radius: 8px;
	color: rgba(255, 255, 255, 0.7);
	padding: 6px 8px;
	cursor: pointer;
	transition: all 0.2s ease;
	display: flex;
	flex-direction: column;
	align-items: center;
	gap: 3px;
	font-size: 11px;
	font-weight: 500;
	min-height: 45px;
	justify-content: center;
}

.mapbox-quick-action-btn iconify-icon {
	font-size: 16px;
	color: rgba(255, 255, 255, 0.8);
}

.mapbox-quick-action-btn span {
	font-size: 9px;
	white-space: nowrap;
	text-align: center;
}

.mapbox-quick-action-btn:hover {
	background: rgba(255, 255, 255, 0.15);
	border-color: rgba(255, 255, 255, 0.3);
	color: rgba(255, 255, 255, 0.9);
	transform: translateY(-2px);
}

.mapbox-quick-action-btn.active {
	background: rgba(0, 212, 255, 0.3);
	border-color: #00d4ff;
	color: #fff;
	box-shadow: 0 0 12px rgba(0, 212, 255, 0.4);
}

.mapbox-quick-action-btn.active iconify-icon {
	color: #00d4ff;
}

/* Control Buttons */
.mapbox-control-btn {
	width: 100%;
	background: rgba(255, 255, 255, 0.1);
	border: 1px solid rgba(255, 255, 255, 0.2);
	border-radius: 8px;
	color: rgba(255, 255, 255, 0.9);
	padding: 8px 10px;
	cursor: pointer;
	transition: all 0.2s ease;
	display: flex;
	align-items: center;
	gap: 8px;
	font-size: 12px;
	font-weight: 500;
	margin-bottom: 4px;
	text-align: left;
}

.mapbox-control-btn:last-child {
	margin-bottom: 0;
}

.mapbox-control-btn iconify-icon {
	font-size: 16px;
	color: rgba(255, 255, 255, 0.8);
	flex-shrink: 0;
}

.mapbox-control-btn:hover {
	background: rgba(255, 255, 255, 0.15);
	border-color: rgba(255, 255, 255, 0.3);
	color: #fff;
	transform: translateX(-2px);
}

.mapbox-control-btn:active {
	transform: translateX(0);
}

.mapbox-control-btn.active {
	background: rgba(0, 212, 255, 0.2);
	border-color: #00d4ff;
	color: #00d4ff;
}

.mapbox-control-btn.active iconify-icon {
	color: #00d4ff;
}

/* Mobile responsive */
@media (max-width: 768px) {
	/* Ensure Mapbox zoom controls have proper spacing */
	.mapboxgl-ctrl-top-right {
		top: 10px !important;
		right: 10px !important;
	}
	
	.mapbox-controls-toggle {
		top: 60px; /* Điều chỉnh để có khoảng cách phù hợp */
		right: 10px;
		width: 40px;
		height: 40px;
	}
	
	.mapbox-controls-toggle iconify-icon {
		font-size: 20px;
	}
	
	.mapbox-controls-panel {
		top: 110px; /* Position below Mapbox zoom controls */
		right: 10px;
		padding: 10px;
		min-width: 160px;
		max-width: 200px;
	}
	
	.mapbox-control-label {
		font-size: 10px;
		margin-bottom: 6px;
	}
	
	.mapbox-lighting-selector {
		gap: 4px;
	}
	
	.lighting-btn {
		padding: 5px 6px;
		min-height: 40px;
		font-size: 10px;
	}
	
	.lighting-btn iconify-icon {
		font-size: 16px;
	}
	
	.lighting-btn span {
		font-size: 9px;
	}
	
	.mapbox-quick-actions-grid {
		gap: 4px;
	}
	
	.mapbox-quick-action-btn {
		padding: 5px 6px;
		min-height: 40px;
		font-size: 10px;
	}
	
	.mapbox-quick-action-btn iconify-icon {
		font-size: 16px;
	}
	
	.mapbox-quick-action-btn span {
		font-size: 9px;
	}
	
	.mapbox-control-btn {
		padding: 7px 9px;
		font-size: 11px;
		margin-bottom: 4px;
		justify-content: flex-start; /* Align icon and text to left */
	}
	
	.mapbox-control-btn iconify-icon {
		font-size: 16px;
		flex-shrink: 0; /* Prevent icon from shrinking */
	}
	
	.mapbox-control-btn span {
		display: inline; /* Show text on mobile for control buttons */
		margin-left: 8px;
		font-size: 11px;
	}
	
	/* Overview map - smaller on mobile and positioned at bottom right */
	.overview-map-container {
		position: absolute !important;
		top: auto !important; /* Override any top positioning */
		bottom: 20px !important; /* Position at bottom right */
		right: 10px !important;
		left: auto !important;
		width: 180px !important;
		height: 180px !important;
	}
	
	/* Keep lighting buttons icon-only on mobile */
	.lighting-btn span {
		display: block; /* Keep lighting buttons as they are (icon + text below) */
	}
}

@media (max-width: 480px) {
	/* Ensure Mapbox zoom controls have proper spacing on very small screens */
	.mapboxgl-ctrl-top-right {
		top: 8px !important;
		right: 8px !important;
	}
	
	.mapbox-controls-toggle {
		top: 85px; /* Điều chỉnh để có khoảng cách phù hợp */
		right: 15px;
		width: 36px;
		height: 36px;
	}
	
	.mapbox-controls-toggle iconify-icon {
		font-size: 18px;
	}
	
	.mapbox-controls-panel {
		top: 80px; /* Position below Mapbox zoom controls */
		right: 15px;
		padding: 8px;
		min-width: 160px;
		max-width: 180px;
	}
	
	.mapbox-lighting-selector {
		grid-template-columns: repeat(4, 1fr);
		gap: 3px;
	}
	
	.lighting-btn {
		padding: 4px 6px;
		min-height: 45px;
	}
	
	.lighting-btn span {
		display: none; /* Hide text labels on very small screens */
	}
	
	/* Show text for control buttons (Tuyáº¿t rÆ¡i, Chá»¥p mÃ n hÃ¬nh, etc.) on very small screens */
	.mapbox-control-btn {
		padding: 8px 10px;
		font-size: 11px;
		justify-content: flex-start;
	}
	
	.mapbox-control-btn iconify-icon {
		font-size: 14px;
		flex-shrink: 0;
	}
	
	.mapbox-control-btn span {
		display: inline; /* Show text on very small screens for control buttons */
		margin-left: 6px;
		font-size: 10px;
	}
}

/* HIá»†U á»¨NG VÃ’NG TRÃ’N Ä�á»˜NG Ä�áº¤T */
/* Khung chá»©a marker */
.pulse-marker {
    width: 20px;
    height: 20px;
    border-radius: 50%;
    cursor: pointer;
    position: relative;
}

/* TÃ¢m cá»§a vÃ²ng trÃ²n */
.pulse-marker::after {
    content: '';
    position: absolute;
    width: 100%;
    height: 100%;
    top: 0;
    left: 0;
    background-color: inherit; /* Láº¥y mÃ u tá»« inline style JS */
    border-radius: 50%;
    z-index: 2;
}

/* Hiá»‡u á»©ng sÃ³ng lan tá»�a */
.pulse-marker::before {
    content: '';
    position: absolute;
    width: 100%;
    height: 100%;
    top: 0;
    left: 0;
    background-color: inherit;
    border-radius: 50%;
    opacity: 0.8;
    animation: earthquake-pulse 2s infinite;
    z-index: 1;
}

@keyframes earthquake-pulse {
    0% {
        transform: scale(1);
        opacity: 0.8;
    }
    100% {
        transform: scale(4);
        opacity: 0;
    }
}

/* áº¨n cÃ¡c nÃºt Ä‘iá»�u khiá»ƒn máº·c Ä‘á»‹nh cá»§a Mapbox */
.mapboxgl-ctrl-geolocate {
    display: none !important;
}

/* ============================================
   LITY LIGHTBOX GALLERY NAVIGATION STYLES
   ============================================ */

/* Hiá»ƒn thá»‹ counter vÃ  mÃ´ táº£ áº£nh trong lity lightbox */
.lity-desc {
    position: absolute;
    bottom: 20px;
    left: 50%;
    transform: translateX(-50%);
    background: rgba(0, 0, 0, 0.8);
    color: #fff;
    padding: 8px 16px;
    border-radius: 4px;
    font-size: 14px;
    font-weight: 500;
    z-index: 9999;
    pointer-events: none;
}

/* Style cho container áº£nh trong gallery */
.widget-img-list {
    display: flex !important;
    flex-wrap: wrap !important;
    gap: 2px;
    max-height: none !important;
    overflow: visible !important;
    height: auto !important;
    min-height: auto !important;
}

.widget-img-list-item {
    flex: 0 0 auto;
    transition: transform 0.3s ease;
}

/* Hiệu ứng hover cho ảnh thực địa - Desktop view */
.widget-img-list-item a {
	display: block;
	position: relative;
	transition: transform 0.3s ease, box-shadow 0.3s ease;
	border-radius: 4px;
	overflow: hidden;
	width: 180px;
	padding-top: 180px; /* Square aspect ratio */
}

.widget-img-list-item a .img {
	transition: transform 0.3s ease;
	position: absolute;
	top: 0;
	left: 0;
	width: 100%;
	height: 100%;
	background-size: cover;
	background-position: center;
	background-repeat: no-repeat;
}

.widget-img-list-item:hover {
	z-index: 10;
	position: relative;
}

.widget-img-list-item:hover a {
	transform: translateY(-10px) scale(1.08);
	box-shadow: 0 16px 32px rgba(0, 0, 0, 0.5), 0 8px 16px rgba(0, 0, 0, 0.4);
}

.widget-img-list-item:hover a .img {
	transform: scale(1.12);
}

/* Đảm bảo tất cả ảnh được hiển thị, không bị giới hạn */
.quantum-card-group .card .widget-img-list,
.quantum-card-group .card-body .widget-img-list,
.card .widget-img-list {
	max-height: none !important;
	overflow: visible !important;
	height: auto !important;
}

.quantum-card-group .card,
.quantum-card-group .card-body {
	overflow: visible !important;
	max-height: none !important;
}

/* Đảm bảo tất cả widget-img-list-item được hiển thị */
.widget-img-list-item {
	display: flex !important;
	visibility: visible !important;
	opacity: 1 !important;
	height: auto !important;
	max-height: none !important;
}

/* Đảm bảo tất cả ảnh từ ảnh thứ 5 trở đi được hiển thị - override mọi CSS khác */
.widget-img-list-item:nth-child(n+5),
.widget-img-list-item:nth-child(5),
.widget-img-list-item:nth-child(6),
.widget-img-list-item:nth-child(7),
.widget-img-list-item:nth-child(8),
.widget-img-list-item:nth-child(9),
.widget-img-list-item:nth-child(10),
.widget-img-list-item:nth-child(11),
.widget-img-list-item:nth-child(12),
.widget-img-list-item:nth-child(13),
.widget-img-list-item:nth-child(14),
.widget-img-list-item:nth-child(15),
.widget-img-list-item:nth-child(16) {
	display: flex !important;
	visibility: visible !important;
	opacity: 1 !important;
	height: auto !important;
	max-height: none !important;
	width: auto !important;
}

/* Đảm bảo tất cả ảnh trong desktop view được hiển thị */
.quantum-card-group .widget-img-list-item,
.quantum-card-group .card .widget-img-list-item,
.quantum-card-group .card-body .widget-img-list-item,
.card .widget-img-list-item,
.card-body .widget-img-list-item {
	display: flex !important;
	visibility: visible !important;
	opacity: 1 !important;
}

/* Đảm bảo container card không bị giới hạn chiều cao */
.quantum-card-group .card,
.quantum-card-group .card-body,
.quantum-card-group .card .card,
.quantum-card-group .card .card-body {
	max-height: none !important;
	overflow: visible !important;
	height: auto !important;
}

/* Đảm bảo row và col không bị giới hạn */
.station-detail-cards .row,
.station-detail-cards .col-12,
.station-detail-cards .col-xl-8 {
	max-height: none !important;
	overflow: visible !important;
	height: auto !important;
}

/* Há»— trá»£ keyboard navigation hint */
.lity-content:focus {
    outline: none;
}

/* Ä�áº£m báº£o lity container cÃ³ thá»ƒ nháº­n keyboard events */
.lity-enabled {
    cursor: pointer;
}

/*ThÃªm CSS nháº¥p nhÃ¡y*/
@keyframes pulse-red {
	0% {
		transform: scale(1);
		opacity: 1;
	}
	50% {
		transform: scale(1.35);
		opacity: 0.6;
	}
	100% {
		transform: scale(1);
		opacity: 1;
	}
}

.rain-dot {
	display: inline-block;
	width: 10px;
	height: 10px;
	border-radius: 50%;
	margin-right: 6px;
	vertical-align: middle;
	flex-shrink: 0; /* trÃ¡nh bá»‹ mÃ©o khi flex */
}

.rain-dot-danger {
	animation: pulse-red 1.4s ease-in-out infinite;
	box-shadow: 0 0 8px rgba(230, 57, 70, 0.75);
}

.rain-legend {
	margin-top: 8px;
	font-size: 13px;
}

.rain-legend-item {
	display: flex;
	align-items: center;
	margin-bottom: 4px;
}

.rain-legend-text {
	line-height: 1.2;
}

/* ============================================
   KÊNH — Nút chọn loại công trình trên kênh
   ============================================ */

.kenh-congtrinh-card .kenh-congtrinh-hint {
	font-size: 12px;
	line-height: 1.5;
	margin-bottom: 14px;
}

.kenh-congtrinh-type-btns {
	display: flex;
	flex-wrap: wrap;
	gap: 10px;
	margin-bottom: 16px;
}

.kenh-congtrinh-btn {
	display: inline-flex;
	align-items: center;
	gap: 10px;
	padding: 10px 18px;
	font-size: 13px;
	font-weight: 600;
	letter-spacing: 0.02em;
	border: 1px solid rgba(255, 255, 255, 0.2);
	border-radius: 999px;
	background: rgba(255, 255, 255, 0.05);
	color: rgba(255, 255, 255, 0.88);
	cursor: pointer;
	transition: background 0.22s ease, border-color 0.22s ease, color 0.2s ease, box-shadow 0.22s ease, transform 0.18s ease;
	box-shadow: 0 1px 2px rgba(0, 0, 0, 0.15);
}

.kenh-congtrinh-btn .kenh-congtrinh-btn-icon {
	display: flex;
	align-items: center;
	justify-content: center;
	width: 28px;
	height: 28px;
	border-radius: 50%;
	background: rgba(255, 255, 255, 0.08);
	font-size: 18px;
	line-height: 1;
	opacity: 0.95;
	transition: background 0.2s ease, color 0.2s ease;
}

.kenh-congtrinh-btn:hover {
	background: rgba(16, 185, 129, 0.16);
	border-color: rgba(52, 211, 153, 0.55);
	color: #fff;
	transform: translateY(-2px);
	box-shadow: 0 6px 20px rgba(16, 185, 129, 0.18);
}

.kenh-congtrinh-btn:hover .kenh-congtrinh-btn-icon {
	background: rgba(16, 185, 129, 0.25);
}

.kenh-congtrinh-btn.active {
	background: linear-gradient(145deg, rgba(16, 185, 129, 0.45) 0%, rgba(5, 150, 105, 0.55) 100%);
	border-color: rgba(110, 231, 183, 0.65);
	color: #fff;
	box-shadow: 0 4px 18px rgba(16, 185, 129, 0.28), inset 0 1px 0 rgba(255, 255, 255, 0.12);
	transform: translateY(-1px);
}

.kenh-congtrinh-btn.active .kenh-congtrinh-btn-icon {
	background: rgba(255, 255, 255, 0.22);
}

.kenh-congtrinh-btn:focus {
	outline: none;
}

.kenh-congtrinh-btn:focus-visible {
	outline: 2px solid rgba(52, 211, 153, 0.75);
	outline-offset: 3px;
}

/* Bộ lọc loại trong danh sách Quản lý công trình trên kênh (nền sáng) */
.ctrk-mgmt-toolbar .kenh-congtrinh-type-btns {
	margin-top: 10px;
	margin-bottom: 8px;
	gap: 8px;
}
.ctrk-mgmt-toolbar > .mailbox-desc {
	color: #5a6f82 !important;
	opacity: 1 !important;
}
.ctrk-mgmt-toolbar .kenh-congtrinh-btn {
	padding: 7px 12px;
	font-size: 12px;
	font-weight: 600;
	gap: 6px;
	border: 1px solid #c5d0da;
	border-radius: 999px;
	background: #fff;
	color: #1a2b3c;
	box-shadow: 0 1px 2px rgba(26, 43, 60, 0.06);
	transform: none;
}
.ctrk-mgmt-toolbar .kenh-congtrinh-btn .kenh-congtrinh-btn-icon {
	width: 22px;
	height: 22px;
	font-size: 14px;
	background: #e8eef3;
	color: #0b6e99;
}
.ctrk-mgmt-toolbar .kenh-congtrinh-btn .kenh-congtrinh-btn-label {
	color: inherit;
}
.ctrk-mgmt-toolbar .kenh-congtrinh-btn:hover {
	background: #e6f4fa;
	border-color: #0b6e99;
	color: #0b6e99;
	transform: none;
	box-shadow: 0 2px 8px rgba(11, 110, 153, 0.12);
}
.ctrk-mgmt-toolbar .kenh-congtrinh-btn:hover .kenh-congtrinh-btn-icon {
	background: rgba(11, 110, 153, 0.15);
	color: #0b6e99;
}
.ctrk-mgmt-toolbar .kenh-congtrinh-btn.active {
	background: linear-gradient(145deg, #12b981 0%, #059669 100%);
	border-color: #047857;
	color: #fff;
	box-shadow: 0 2px 10px rgba(5, 150, 105, 0.28);
	transform: none;
}
.ctrk-mgmt-toolbar .kenh-congtrinh-btn.active .kenh-congtrinh-btn-icon {
	background: rgba(255, 255, 255, 0.22);
	color: #fff;
}
.ctrk-mgmt-toolbar .kenh-congtrinh-btn:focus-visible {
	outline: 2px solid rgba(11, 110, 153, 0.55);
	outline-offset: 2px;
}

.mailbox-list-item .ctrk-list-meta {
	margin-top: 4px;
}
.mailbox-list-item .ctrk-list-meta .hochua-list-compact-line {
	font-size: 12px;
	line-height: 1.4;
}

/* Bảng kênh / công trình trên kênh: căn theo kiểu dữ liệu */
.kenh-congtrinh-data-table th.kenh-ct-align-left,
.kenh-congtrinh-data-table td.kenh-ct-align-left,
.trambom-kenh-data-table th.kenh-ct-align-left,
.trambom-kenh-data-table td.kenh-ct-align-left {
	text-align: left;
}

.kenh-congtrinh-data-table th.kenh-ct-align-center,
.kenh-congtrinh-data-table td.kenh-ct-align-center,
.trambom-kenh-data-table th.kenh-ct-align-center,
.trambom-kenh-data-table td.kenh-ct-align-center {
	text-align: center;
}

.kenh-congtrinh-data-table th.kenh-ct-align-right,
.kenh-congtrinh-data-table td.kenh-ct-align-right,
.trambom-kenh-data-table th.kenh-ct-align-right,
.trambom-kenh-data-table td.kenh-ct-align-right {
	text-align: right;
	font-variant-numeric: tabular-nums;
}

/* ============================================
   ALERT BADGE
   ============================================ */

.menu-badge {
	position: absolute;
	top: -4px;
	right: 0px;
	background: #dc3545;
	color: #fff;
	border-radius: 10px;
	padding: 2px 6px;
	font-size: 0.7rem;
	font-weight: 600;
	min-width: 18px;
	text-align: center;
	display: none;
}

/* ============================================
   12. FENGWU DATA PANEL
   ============================================ */
.fengwu-data-overlay {
	position: fixed;
	inset: 0;
	background: rgba(0, 0, 0, 0.6);
	backdrop-filter: blur(3px);
	-webkit-backdrop-filter: blur(3px);
	display: flex;
	align-items: center;
	justify-content: flex-end;
	padding: 16px;
	z-index: 10060;
	opacity: 0;
	visibility: hidden;
	pointer-events: none;
	transition: opacity 0.2s ease, visibility 0.2s ease;
}

.fengwu-data-overlay.show {
	opacity: 1;
	visibility: visible;
	pointer-events: auto;
}

.fengwu-data-panel {
	width: min(520px, 100%);
	height: min(84vh, 760px);
	background: rgba(17, 26, 28, 0.98);
	border: 1px solid rgba(255, 255, 255, 0.12);
	border-radius: 12px;
	box-shadow: 0 18px 40px rgba(0, 0, 0, 0.45);
	display: flex;
	flex-direction: column;
	overflow: hidden;
}

.fengwu-data-header {
	padding: 14px 16px;
	border-bottom: 1px solid rgba(255, 255, 255, 0.12);
	display: flex;
	align-items: flex-start;
	justify-content: space-between;
	gap: 12px;
}

.fengwu-data-header h5 {
	color: #fff;
	font-size: 16px;
	font-weight: 600;
}

.fengwu-data-subtitle {
	margin-top: 4px;
	color: rgba(255, 255, 255, 0.7);
	font-size: 12px;
}

.fengwu-data-close {
	background: transparent;
	border: none;
	color: rgba(255, 255, 255, 0.8);
	width: 32px;
	height: 32px;
	border-radius: 8px;
	display: inline-flex;
	align-items: center;
	justify-content: center;
}

.fengwu-data-close:hover {
	background: rgba(255, 255, 255, 0.12);
}

.fengwu-data-body {
	padding: 12px 14px 14px;
	display: flex;
	flex-direction: column;
	gap: 10px;
	flex: 1;
	min-height: 0;
}

.fengwu-data-summary {
	font-size: 12px;
	color: rgba(255, 255, 255, 0.85);
}

.fengwu-data-tabs {
	display: flex;
	gap: 8px;
}

.fengwu-tab-btn {
	border: 1px solid rgba(255, 255, 255, 0.2);
	background: rgba(255, 255, 255, 0.06);
	color: rgba(255, 255, 255, 0.85);
	border-radius: 999px;
	font-size: 12px;
	font-weight: 600;
	padding: 6px 12px;
}

.fengwu-tab-btn.active {
	background: rgba(0, 212, 255, 0.25);
	border-color: rgba(0, 212, 255, 0.75);
	color: #fff;
}

.fengwu-data-loading {
	display: none;
	font-size: 12px;
	color: #cbd5e1;
	background: rgba(59, 130, 246, 0.14);
	border: 1px solid rgba(96, 165, 250, 0.45);
	border-radius: 8px;
	padding: 8px 10px;
}

.fengwu-data-tab-content {
	flex: 1;
	min-height: 0;
}

#fengwuDataChart {
	width: 100% !important;
	height: 100% !important;
}

.fengwu-data-table-container {
	height: 100%;
	overflow: auto;
	border: 1px solid rgba(255, 255, 255, 0.1);
	border-radius: 8px;
}

.fengwu-data-table thead th {
	position: sticky;
	top: 0;
	background: #0f172a;
	z-index: 1;
}

@media (max-width: 991.98px) {
	.fengwu-data-overlay {
		align-items: flex-end;
		justify-content: center;
		padding: 0;
	}

	.fengwu-data-panel {
		width: 100%;
		height: min(76vh, 620px);
		border-radius: 16px 16px 0 0;
		border-left: none;
		border-right: none;
		border-bottom: none;
	}
}

.fengwu-legend-panel {
	position: absolute;
	left: 20px;
	bottom: 138px;
	z-index: 998;
	background: rgba(255, 255, 255, 0.95);
	color: #0f172a;
	border-radius: 8px;
	border: 1px solid rgba(15, 23, 42, 0.12);
	box-shadow: 0 4px 14px rgba(0, 0, 0, 0.25);
	padding: 10px 12px;
	min-width: 180px;
	max-width: 260px;
	font-size: 12px;
}

.fengwu-legend-title {
	font-weight: 700;
	font-size: 12px;
	margin-bottom: 8px;
}

.fengwu-legend-row {
	display: flex;
	align-items: center;
	gap: 8px;
	margin-bottom: 4px;
}

.fengwu-legend-row:last-child {
	margin-bottom: 0;
}

.fengwu-legend-color {
	display: inline-block;
	width: 14px;
	height: 14px;
	border: 1px solid rgba(0, 0, 0, 0.15);
	border-radius: 2px;
}

.fengwu-legend-label {
	line-height: 1.25;
}

@media (max-width: 991.98px) {
	.fengwu-legend-panel {
		display: none !important;
	}
}

.fengwu-mobile-timeline-toggle {
	display: none;
}

@media (max-width: 991.98px) {
	.fengwu-mobile-timeline-toggle {
		position: fixed;
		left: 50%;
		bottom: 12px;
		transform: translateX(-50%);
		z-index: 1002;
		display: none;
		border: 1px solid rgba(56, 189, 248, 0.55);
		border-radius: 999px;
		background: rgba(15, 23, 42, 0.92);
		color: #e2e8f0;
		padding: 8px 14px;
		min-width: 180px;
		box-shadow: 0 8px 20px rgba(0, 0, 0, 0.35);
		align-items: center;
		justify-content: space-between;
		gap: 10px;
	}

	.fengwu-mobile-timeline-toggle.show {
		display: inline-flex;
	}

	.fengwu-mobile-timeline-title {
		font-size: 11px;
		font-weight: 700;
		text-transform: uppercase;
		letter-spacing: 0.4px;
		color: #7dd3fc;
	}

	.fengwu-mobile-chip-time {
		font-size: 12px;
		font-weight: 600;
		color: #fff;
	}

	#fengwu-modern-timeline.visible {
		transform: translateY(100%);
		visibility: hidden;
		opacity: 0;
		pointer-events: none;
	}

	#fengwu-modern-timeline.visible.mobile-open {
		transform: translateY(0);
		visibility: visible;
		opacity: 1;
		pointer-events: all;
	}

	#fengwu-modern-timeline .timeline-container {
		border-radius: 12px 12px 0 0;
		padding: 10px 12px;
	}
}

/* Nhóm 4 - giao diện nhập tham số vận hành */
.tb-op-layout-grid {
	display: grid;
	grid-template-columns: 1fr 3fr;
	gap: 12px;
	align-items: start;
}

.tb-op-calc-mode-group {
	display: flex;
	gap: 14px;
	flex-wrap: wrap;
}

.tb-op-calc-mode-option {
	display: flex;
	align-items: center;
	gap: 6px;
	cursor: pointer;
	color: rgba(255, 255, 255, 0.88);
	font-size: 13px;
	line-height: 1.4;
}

.tb-op-calc-mode-option input[type="radio"] {
	flex-shrink: 0;
}

.tb-op-day-board {
	display: grid;
	grid-template-columns: repeat(7, minmax(90px, 1fr));
	gap: 8px;
}

.tb-op-selected-row {
	display: grid;
	grid-template-columns: 1fr 180px auto;
	gap: 8px;
	align-items: end;
	margin-top: 10px;
}

.tb-op-chart-grid {
	display: grid;
	grid-template-columns: 2fr 1fr;
	gap: 12px;
	align-items: stretch;
}

.tb-op-chart-panel,
.tb-op-table-panel {
	background: rgba(0, 0, 0, 0.2);
	border: 1px solid rgba(255, 255, 255, 0.08);
	border-radius: 8px;
	padding: 8px;
	height: 340px;
}

.tb-op-chart-canvas {
	width: 100%;
	height: 100%;
}

.tb-op-table-panel {
	display: flex;
	flex-direction: column;
}

.tb-op-table-scroll {
	flex: 1;
	min-height: 0;
	overflow-y: auto;
	overflow-x: auto;
}

.tb-op-param-panel,
.tb-op-schedule-panel {
	background: rgba(0, 0, 0, 0.22);
	border: 1px solid rgba(255, 255, 255, 0.1);
	border-radius: 10px;
	padding: 10px;
}

.tb-op-param-item {
	background: rgba(255, 255, 255, 0.035);
	border: 1px solid rgba(255, 255, 255, 0.08);
	border-radius: 10px;
	padding: 8px 10px;
	margin-bottom: 8px;
}

.tb-op-param-item:last-child {
	margin-bottom: 0;
}

.tb-op-param-label {
	display: block;
	font-size: 11px;
	font-weight: 600;
	color: rgba(255, 255, 255, 0.72);
	margin-bottom: 6px;
	line-height: 1.35;
}

.tb-op-param-input {
	display: block;
	width: 100%;
	height: 28px;
	padding: 5px 10px;
	border-radius: 8px;
	border: 1px solid rgba(0, 212, 255, 0.65);
	background: rgba(7, 22, 30, 0.72);
	color: rgba(255, 255, 255, 0.95);
	font-size: 13px;
	font-weight: 600;
	line-height: 1;
	position: relative;
	z-index: 2;
	pointer-events: auto;
	transition: border-color .2s ease, box-shadow .2s ease, background-color .2s ease;
	touch-action: manipulation;
}

.tb-op-param-input:focus {
	outline: none;
	border-color: #00d4ff;
	box-shadow: 0 0 0 3px rgba(0, 212, 255, 0.18);
	background: rgba(7, 22, 30, 0.9);
}

.tb-op-param-input::placeholder {
	color: rgba(255, 255, 255, 0.5);
}

.tb-op-param-input,
#tb-op-selected-date-hours {
	pointer-events: auto !important;
	-webkit-user-select: text !important;
	user-select: text !important;
}

.tb-op-param-input::-webkit-outer-spin-button,
.tb-op-param-input::-webkit-inner-spin-button {
	-webkit-appearance: none;
	margin: 0;
}

@media (max-width: 1200px) {
	.tb-op-layout-grid {
		grid-template-columns: 1fr;
	}
}

@media (max-width: 768px) {
	.tb-op-calc-mode-group {
		flex-direction: column;
		gap: 8px;
	}

	.tb-op-calc-mode-option {
		font-size: 12px;
		align-items: flex-start;
	}

	.tb-op-day-board {
		grid-template-columns: repeat(2, minmax(0, 1fr));
	}

	.tb-op-selected-row {
		grid-template-columns: 1fr;
	}

	.tb-op-selected-row .trambom-report-btn {
		width: 100%;
	}

	.tb-op-chart-grid {
		grid-template-columns: 1fr;
	}

	.tb-op-chart-panel {
		height: 240px;
	}

	.tb-op-table-panel {
		height: 300px;
	}

	.tb-op-table-scroll table {
		font-size: 12px;
	}

	.tb-op-table-scroll table th,
	.tb-op-table-scroll table td {
		padding: 6px 8px;
		vertical-align: top;
	}

	.tb-op-table-scroll table td:first-child {
		white-space: normal;
		word-break: break-word;
		min-width: 92px;
	}

	.tb-op-table-scroll table td:nth-child(2),
	.tb-op-table-scroll table td:nth-child(3),
	.tb-op-table-scroll table td:nth-child(4),
	.tb-op-table-scroll table td:nth-child(5) {
		white-space: nowrap;
	}
}

/* Kịch bản vận hành: xếp dọc tham số → lịch → biểu đồ → bảng */
.tb-op-scenario-stack {
	display: flex;
	flex-direction: column;
	gap: 16px;
}

.tb-op-scenario-block {
	display: flex;
	flex-direction: column;
	gap: 10px;
}

.tb-op-scenario-block-title {
	font-size: 13px;
	font-weight: 700;
	color: #E9ECEF;
	letter-spacing: 0.02em;
}

.tb-op-scenario-intro {
	margin: 0;
	font-size: 12px;
	line-height: 1.45;
	color: rgba(255, 255, 255, 0.72);
}

.tb-op-schedule-heading {
	font-size: 12px;
	font-weight: 700;
	margin-bottom: 4px;
	color: rgba(255, 255, 255, 0.88);
}

.tb-op-schedule-hint {
	font-size: 12px;
	margin-bottom: 8px;
	color: rgba(255, 255, 255, 0.65);
	line-height: 1.4;
}

.tb-op-param-panel--stack {
	display: flex;
	flex-direction: column;
	gap: 10px;
}

.tb-op-day-btn {
	display: flex;
	flex-direction: column;
	align-items: flex-start;
	text-align: left;
	gap: 2px;
	border: 1px solid rgba(255, 255, 255, 0.12);
	background: rgba(0, 0, 0, 0.22);
	color: #E9ECEF;
	border-radius: 8px;
	padding: 8px 9px;
	min-height: 66px;
	cursor: pointer;
	transition: border-color .15s ease, background-color .15s ease;
}

.tb-op-day-btn:hover {
	border-color: rgba(77, 171, 247, 0.55);
}

.tb-op-day-btn.is-active {
	border-color: #4DABF7;
	background: rgba(77, 171, 247, 0.22);
}

.tb-op-day-btn.has-hours:not(.is-active) {
	border-color: rgba(99, 230, 190, 0.8);
	background: rgba(99, 230, 190, 0.14);
}

.tb-op-day-tag {
	font-size: 11px;
	opacity: 0.85;
}

.tb-op-day-date {
	font-size: 12px;
	font-weight: 700;
}

.tb-op-day-hours {
	font-size: 11px;
	margin-top: 2px;
	color: rgba(255, 255, 255, 0.55);
}

.tb-op-day-btn.has-hours .tb-op-day-hours,
.tb-op-day-btn.is-active .tb-op-day-hours {
	color: #63E6BE;
}

.tb-op-selected-field {
	min-width: 0;
}

.tb-op-selected-actions {
	display: flex;
	align-items: flex-end;
}

.tb-op-calc-actions {
	margin-top: 12px;
	display: flex;
	gap: 8px;
	align-items: center;
	flex-wrap: wrap;
}

.tb-op-table-empty {
	color: rgba(255, 255, 255, 0.55);
}

.tb-op-chart-panel--full,
.tb-op-table-panel--full {
	width: 100%;
	min-height: 0;
}

.tb-op-chart-panel--full .tb-op-chart-canvas {
	width: 100% !important;
	min-height: 260px;
}

/* === dienbien.css appended for dss-namrom === */
@charset "UTF-8";

.boxdraw {
	background: rgba(56, 135, 190, 0.1);
	border: 2px solid #3887be;
	position: absolute;
	top: 0;
	left: 0;
	width: 0;
	height: 0;
}
.resizable {    
    background-color: lightblue;
    position: relative;
    overflow: hidden;
    border: 2px solid #007BFF;
}
        
.resizer {
    width: 5px;
    height: 100%;
    background-color: #007BFF;
    position: absolute;
    right: 0;
    top: 0;
    cursor: ew-resize; /* Chỉ cho phép resize theo chiều ngang */
}

#container_semicircle {
    width: 260px;
	height: 80px;
	position: absolute;
	z-index: 110;
	right: 50px;
	top: 70px;
	visibility: hidden;	
}        

#controls {
    text-align: center;
    margin-top: 20px;
    position: absolute;
    z-index: 110;
    top: 150px;
    right: 115px;
    visibility: hidden;
}
#controls button {
    padding: 5px;
    margin: 0 2px;
    font-size: 15px;
    cursor: pointer;
}
        
#overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    cursor: pointer;
}         

/* Đặt vị trí button "Bản đồ ngập đô thị" ở trên cùng */
.toggle-button {
	transform: translateX(-50%); /* Giữ button ở giữa */
	display: flex;
	align-items: center;
	gap: 5px;
	padding: 5px 10px;
	font-size: 14px;
	background-color: #1a73e8;
	color: white;
	border: none;
	border-radius: 5px;
	cursor: pointer;
	transition: background-color 0.3s;
	z-index: 100;
	margin-left: 90px;
}

.toggle-button:hover {
	background-color: #0c5fc0;
}

.icon {
	font-size: 20px;
}

/* Container của các lựa chọn */
.container {
	display: none;
	position: absolute;
	width: 700px;
	max-height: 600px; /* Giới hạn chiều cao của container */
	background-color: transparent;
	box-shadow: 0 0 10px rgba(0, 0, 0, 0.1);
	border-radius: 10px;
	overflow-y: auto;
	z-index: 10;
}

.content {
	display: flex;
	flex: 1;
	overflow-y: auto; /* Cho phép cuộn nếu nội dung quá lớn */
}

.column {
	flex: 1;
	display: flex;
	flex-direction: column;
	padding: 10px;
}

.column-left {
	background-color: #e8f0fe;
	gap: 10px;
}

.column-right {
	display: flex;
	flex-direction: row;
	flex: 2;
	gap: 10px;
	padding: 10px;
	background-color: #f1f3f4;
}

.hour-subcolumn {
	flex: 1;
	display: flex;
	flex-direction: column;
	gap: 5px;
}

.button {
	background-color: white;
	color: black;
	border: 2px solid transparent;
	padding: 5px;
	text-align: center;
	font-size: 14px;
	border-radius: 5px;
	cursor: pointer;
	transition: background-color 0.3s, border-color 0.3s, color 0.3s;
}

.button:hover {
	background-color: #f0f0f0;
}

.button.selected {
	background-color: #d0e7ff;
	border-color: #1a73e8;
	color: #1a73e8;
}

.footer {
	display: flex;
	justify-content: space-between;
	padding: 10px;
	background-color: #f1f3f4;
	border-top: 1px solid #ddd;
}

.footer button {
	flex: 1;
	margin: 0 5px;
	padding: 5px;
	font-size: 16px;
	border-radius: 5px;
	cursor: pointer;
	border: none;
	transition: background-color 0.3s;
}

.footer button:hover {
	background-color: #e0e0e0;
}

.clear-button {
	background-color: #ffcccc;
}

.apply-button {
	background-color: #cce5ff;
}            

#loading {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    font-size: 24px;
    color: green;
    background: white;
    padding: 10px;
    border-radius: 5px;
    box-shadow: 0 0 10px rgba(0,0,0,0.5);
    z-index: 1000;
}
  

/* dss-namrom Google shell helpers */
#loading {
	position: fixed;
	top: 50%;
	left: 50%;
	transform: translate(-50%, -50%);
	z-index: 9999;
	background: rgba(0,0,0,0.75);
	color: #fff;
	padding: 12px 20px;
	border-radius: 8px;
}
.namrom-scenario-form {
	padding: 8px 12px;
	font-size: 13px;
}
.namrom-scenario-form .form-control,
.namrom-scenario-form .form-select {
	font-size: 13px;
}
#stationDetailContent .main-content.detaildg {
	/* Chỉ cuộn ở .mailbox-detail-content bên ngoài — tránh 2 thanh cuộn lồng nhau */
	max-height: none;
	height: auto !important;
	overflow: visible;
	padding: 8px;
}
#namromHiddenHosts { display: none !important; }

/* Report PDF viewer (jsreport) — ported from irrigation-bacninh */
body.report-pdf-open {
	overflow: hidden !important;
}

.report-pdf-overlay {
	position: fixed;
	inset: 0;
	z-index: 11000;
	display: none;
	align-items: stretch;
	justify-content: flex-end;
	box-sizing: border-box;
	padding: 12px;
}

.report-pdf-overlay.is-open {
	display: flex;
}

.report-pdf-backdrop {
	position: absolute;
	inset: 0;
	background: rgba(32, 33, 36, 0.28);
}

.report-pdf-panel {
	position: relative;
	z-index: 1;
	width: min(1080px, calc(100vw - 24px));
	max-width: 100%;
	height: calc(100vh - 24px);
	background: #fff;
	border: 1px solid #dadce0;
	border-radius: 12px;
	box-shadow: 0 8px 28px rgba(60, 64, 67, 0.22);
	display: flex;
	flex-direction: column;
	min-width: 0;
	min-height: 0;
	overflow: hidden;
}

.report-pdf-header {
	flex-shrink: 0;
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 12px;
	padding: 10px 14px;
	background: #fff;
	border-bottom: 1px solid #e8eaed;
}

.report-pdf-header h3 {
	margin: 0;
	color: #202124;
	font-size: 15px;
	font-weight: 600;
	line-height: 1.3;
	min-width: 0;
	overflow: hidden;
	text-overflow: ellipsis;
	white-space: nowrap;
}

.report-pdf-header-actions {
	display: inline-flex;
	align-items: center;
	gap: 8px;
	flex-shrink: 0;
}

.report-pdf-icon-btn {
	display: inline-flex;
	align-items: center;
	gap: 6px;
	min-height: 34px;
	padding: 6px 12px;
	border-radius: 20px;
	border: 1px solid #dadce0;
	background: #fff;
	color: #1967d2;
	cursor: pointer;
	font-size: 13px;
	font-weight: 600;
}

.report-pdf-icon-btn:hover {
	background: #e8f0fe;
	border-color: #1a73e8;
	color: #174ea6;
}

.report-pdf-close-btn {
	min-width: 34px;
	justify-content: center;
	padding: 6px 8px;
	color: #5f6368;
	border-radius: 50%;
}

.report-pdf-close-btn:hover {
	background: #f1f3f4;
	border-color: #dadce0;
	color: #202124;
}

.report-pdf-viewport {
	position: relative;
	flex: 1;
	min-height: 0;
	overflow: auto;
	padding: 16px;
	background: #f1f3f4;
}

.report-pdf-viewport--scroll {
	display: block;
	align-items: stretch;
	justify-content: flex-start;
}

.report-pdf-viewport--flip {
	display: flex;
	align-items: center;
	justify-content: center;
	overflow: hidden;
	background: #eef3fb;
}

.report-pdf-simple {
	display: block;
	width: 100%;
}

.report-pdf-pages {
	display: flex;
	flex-direction: column;
	align-items: center;
	gap: 18px;
	width: 100%;
	padding-bottom: 28px;
}

.report-pdf-page-img,
.report-pdf-simple img {
	display: block;
	width: min(920px, 100%);
	height: auto;
	background: #fff;
	border: 1px solid #e8eaed;
	border-radius: 6px;
	box-shadow: 0 1px 3px rgba(60, 64, 67, 0.12), 0 8px 24px rgba(60, 64, 67, 0.08);
}

.report-pdf-flip-wrap {
	display: flex;
	align-items: center;
	justify-content: center;
	transform-origin: center center;
	transition: transform 0.15s ease-out;
}

.report-pdf-loader {
	position: absolute;
	inset: 0;
	display: none;
	flex-direction: column;
	align-items: center;
	justify-content: center;
	background: rgba(255, 255, 255, 0.94);
	z-index: 5;
	padding: 20px;
	text-align: center;
}

.report-pdf-spinner {
	width: 46px;
	height: 46px;
	border: 3px solid #d2e3fc;
	border-top-color: #1a73e8;
	border-radius: 50%;
	animation: report-pdf-spin 1s linear infinite;
	margin-bottom: 14px;
}

@keyframes report-pdf-spin {
	to { transform: rotate(360deg); }
}

.report-pdf-loader-text {
	color: #3c4043;
	font-size: 14px;
	line-height: 1.45;
	max-width: 480px;
}

.report-pdf-toolbar {
	flex-shrink: 0;
	min-height: 52px;
	background: #fff;
	display: flex;
	align-items: center;
	justify-content: center;
	flex-wrap: wrap;
	gap: 10px 14px;
	padding: 8px 14px;
	border-top: 1px solid #e8eaed;
}

.report-pdf-tool-btn {
	background: #fff;
	border: 1px solid #dadce0;
	color: #3c4043;
	cursor: pointer;
	padding: 8px 12px;
	border-radius: 20px;
	font-size: 14px;
	min-width: 38px;
	min-height: 36px;
	display: inline-flex;
	align-items: center;
	justify-content: center;
	gap: 6px;
}

.report-pdf-tool-btn:hover {
	background: #e8f0fe;
	color: #174ea6;
	border-color: #1a73e8;
}

.report-pdf-flip-toggle span {
	font-size: 12px;
	font-weight: 600;
}

.report-pdf-flip-toggle.is-active {
	background: #1a73e8;
	border-color: #1a73e8;
	color: #fff;
}

.report-pdf-flip-toggle.is-active:hover {
	background: #1557b0;
	border-color: #1557b0;
	color: #fff;
}

.report-pdf-toolbar-divider {
	width: 1px;
	height: 28px;
	background: #dadce0;
}

.report-pdf-zoom-controls,
.report-pdf-nav-controls {
	display: inline-flex;
	align-items: center;
	gap: 8px;
}

.report-pdf-zoom-level,
.report-pdf-page-info {
	min-width: 52px;
	text-align: center;
	color: #202124;
	font-size: 13px;
	font-weight: 600;
}

.report-pdf-overlay:fullscreen .report-pdf-panel,
.report-pdf-overlay:-webkit-full-screen .report-pdf-panel {
	width: 100%;
	height: 100%;
	border-radius: 0;
}

@media (max-width: 768px) {
	.report-pdf-overlay {
		padding: 0;
	}
	.report-pdf-panel {
		width: 100%;
		height: 100%;
		border-radius: 0;
	}
	.report-pdf-header h3 {
		font-size: 13px;
		white-space: normal;
	}
	.report-pdf-icon-btn span {
		display: none;
	}
	.report-pdf-flip-toggle {
		display: none !important;
	}
	.report-pdf-toolbar > .report-pdf-tool-btn:last-child {
		display: none !important;
	}
	.report-pdf-nav-controls + .report-pdf-toolbar-divider {
		display: none;
	}
	.report-pdf-toolbar {
		flex-wrap: nowrap;
		justify-content: center;
		gap: 6px 8px;
		padding: 6px 10px;
		min-height: 46px;
	}
	.report-pdf-tool-btn {
		padding: 6px 10px;
		min-width: 34px;
		min-height: 34px;
		font-size: 13px;
	}
	.report-pdf-zoom-level,
	.report-pdf-page-info {
		min-width: 44px;
		font-size: 12px;
	}
	.report-pdf-toolbar-divider {
		height: 24px;
	}
}

