/* =============================================================================
   GPS Modern Views — stiluri pentru inlocuitorii Silverlight
   Tema: Black (dark)
   ============================================================================= */

/* ── Container principal ─────────────────────────────────────────────────────── */
.gps-status-root {
    display: flex;
    width: 100%;
    height: 100%;
    min-height: 580px;
    background: #102430;
    font-family: "Segoe UI", Arial, sans-serif;
    font-size: 13px;
    color: #d8e4ec;
    box-sizing: border-box;
}

/* Varianta IDrive (tema deschisa) */
.gps-status-root.gps-theme-idrive {
    background: #f0f4f7;
    color: #1a2530;
}

/* ── Panoul stang: arbore vehicule ───────────────────────────────────────────── */
.gps-tree-panel {
    width: 230px;
    min-width: 180px;
    flex-shrink: 0;
    background: #0b1c28;
    border-right: 1px solid #1a3345;
    display: flex;
    flex-direction: column;
    overflow: hidden;
    color: #c8d8e4;
}
.gps-theme-idrive .gps-tree-panel {
    background: #e8f0f7;
    border-right-color: #c0d0dc;
}

.gps-tree-search-wrap {
    position: relative;
    margin: 8px;
    display: flex;
    align-items: center;
}
.gps-tree-search {
    flex: none;
    width: 100%;
    padding: 5px 26px 5px 9px;
    background: #132030;
    border: 1px solid #214055;
    border-radius: 4px;
    color: #c8d8e4;
    font-size: 12px;
    outline: none;
    width: 100%;
    box-sizing: border-box;
}
.gps-tree-search:focus { border-color: #4a8ab0; }
.gps-tree-search-clear {
    position: absolute;
    right: 5px;
    background: none;
    border: none;
    color: #6a90aa;
    font-size: 16px;
    line-height: 1;
    cursor: pointer;
    padding: 0 2px;
}
.gps-tree-search-clear:hover { color: #d8e4ec; }
.gps-theme-idrive .gps-tree-search {
    background: #fff;
    border-color: #aabfcc;
    color: #1a2530;
}
.gps-theme-idrive .gps-tree-search-clear { color: #6a90aa; }
.gps-theme-idrive .gps-tree-search-clear:hover { color: #1a2530; }

.gps-tree-all-row {
    display: flex;
    align-items: center;
    gap: 7px;
    padding: 5px 10px 7px;
    border-bottom: 1px solid #1a3345;
    font-size: 12px;
    cursor: pointer;
}
.gps-tree-all-row label {
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 6px;
    user-select: none;
}
.gps-theme-idrive .gps-tree-all-row { border-bottom-color: #c0d0dc; }

.gps-tree-groups {
    flex: 1;
    overflow-y: auto;
    overflow-x: hidden;
}
.gps-tree-groups::-webkit-scrollbar { width: 4px; }
.gps-tree-groups::-webkit-scrollbar-track { background: transparent; }
.gps-tree-groups::-webkit-scrollbar-thumb { background: #2a4a60; border-radius: 2px; }

.gps-tree-group-header {
    display: flex;
    align-items: center;
    gap: 5px;
    padding: 6px 10px 5px;
    font-size: 10px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.6px;
    color: #6a90aa;
    cursor: pointer;
    user-select: none;
    transition: background 0.1s;
}
.gps-tree-group-header:hover { background: #132030; }
.gps-theme-idrive .gps-tree-group-header { color: #3a6080; }
.gps-theme-idrive .gps-tree-group-header:hover { background: #dce8f0; }

.gps-chevron { font-size: 9px; color: #4a6a80; }
.gps-tree-count { color: #4a6a80; font-weight: 400; }

.gps-tree-items { padding-bottom: 4px; }

.gps-tree-item {
    padding: 0;
}
.gps-tree-item label {
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 4px 8px 4px 18px;
    font-size: 12px;
    cursor: pointer;
    line-height: 1.4;
    transition: background 0.1s;
}
.gps-tree-item label:hover { background: #132030; }
.gps-tree-item label:has(input[type="radio"]:checked) { background: #0a3050; color: #7ad0ff; }
.gps-theme-idrive .gps-tree-item label:hover { background: #dce8f0; }
.gps-theme-idrive .gps-tree-item label:has(input[type="radio"]:checked) { background: #c0d8f0; color: #1a4070; }

.gps-veh-dot {
    width: 7px;
    height: 7px;
    border-radius: 50%;
    background: #3a5570;
    flex-shrink: 0;
    display: inline-block;
    transition: background 0.3s;
}

/* ── Panoul drept: harta + tabel ─────────────────────────────────────────────── */
.gps-content-panel {
    flex: 1;
    display: flex;
    flex-direction: column;
    overflow: hidden;
    min-width: 0;
}

/* ── Harta ───────────────────────────────────────────────────────────────────── */
.gps-map-wrapper {
    flex: 1;
    position: relative;
    min-height: 280px;
}
#gps-map {
    width: 100%;
    height: 100%;
    background: #0b1c28;
}

/* ── Spinner ─────────────────────────────────────────────────────────────────── */
.gps-spinner {
    position: absolute;
    top: 10px;
    right: 10px;
    width: 18px;
    height: 18px;
    border: 2px solid rgba(255, 255, 255, 0.12);
    border-top-color: #4a8ab0;
    border-radius: 50%;
    animation: gps-spin 0.7s linear infinite;
    z-index: 1000;
    pointer-events: none;
}
@keyframes gps-spin { to { transform: rotate(360deg); } }

/* ── Tabel status ────────────────────────────────────────────────────────────── */
.gps-table-panel {
    height: 210px;
    min-height: 160px;
    flex-shrink: 0;
    display: flex;
    flex-direction: column;
    background: #091822;
    border-top: 2px solid #1a3345;
}
.gps-theme-idrive .gps-table-panel {
    background: #f5f9fc;
    border-top-color: #c0d0dc;
}

.gps-table-toolbar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 5px 12px;
    background: #0b1c28;
    border-bottom: 1px solid #1a3345;
    font-size: 11px;
    color: #5a7a90;
    flex-shrink: 0;
}
.gps-theme-idrive .gps-table-toolbar {
    background: #e8f0f7;
    border-bottom-color: #c0d0dc;
    color: #4a6a80;
}

#gps-count { font-weight: 700; color: #90b8cc; font-size: 12px; }
.gps-theme-idrive #gps-count { color: #2a5070; }

#gps-refresh-time { color: #a0c0d4; font-weight: 600; }
.gps-theme-idrive #gps-refresh-time { color: #2a5070; }

.gps-table-scroll {
    flex: 1;
    overflow-y: auto;
    overflow-x: auto;
}
.gps-table-scroll::-webkit-scrollbar { width: 5px; height: 5px; }
.gps-table-scroll::-webkit-scrollbar-track { background: #091822; }
.gps-table-scroll::-webkit-scrollbar-thumb { background: #1e3a50; border-radius: 3px; }
.gps-theme-idrive .gps-table-scroll::-webkit-scrollbar-track { background: #f5f9fc; }
.gps-theme-idrive .gps-table-scroll::-webkit-scrollbar-thumb { background: #a0bece; }

.gps-status-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 12px;
}

.gps-status-table thead th {
    position: sticky;
    top: 0;
    z-index: 2;
    background: #0d2030;
    color: #5a7a90;
    font-weight: 700;
    font-size: 10px;
    text-transform: uppercase;
    letter-spacing: 0.4px;
    padding: 6px 10px;
    text-align: left;
    border-bottom: 1px solid #1a3345;
    white-space: nowrap;
}
.gps-theme-idrive .gps-status-table thead th {
    background: #d8e8f4;
    color: #3a5a70;
    border-bottom-color: #b0c8d8;
}

.gps-status-table td {
    padding: 5px 10px;
    border-bottom: 1px solid #0f2030;
    color: #c0d0dc;
    white-space: nowrap;
    vertical-align: middle;
}
.gps-theme-idrive .gps-status-table td {
    color: #1a2d3a;
    border-bottom-color: #d0e0ea;
}

.gps-tbl-row { cursor: pointer; transition: background 0.1s; }
.gps-tbl-row:nth-child(even)            { background: #0c1e2c; }
.gps-tbl-row:hover                      { background: #122838 !important; }
.gps-tbl-row.gps-tbl-active             { background: #1a3850 !important; }
.gps-theme-idrive .gps-tbl-row:nth-child(even) { background: #eef4f8; }
.gps-theme-idrive .gps-tbl-row:hover          { background: #dceaf4 !important; }
.gps-theme-idrive .gps-tbl-row.gps-tbl-active { background: #c8dcea !important; }

.gps-tbl-addr {
    max-width: 240px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}
.gps-tbl-center { text-align: center; }
.gps-tbl-right  { text-align: right; }

.gps-tbl-badge {
    display: inline-block;
    width: 8px;
    height: 8px;
    border-radius: 50%;
    margin-right: 6px;
    vertical-align: middle;
    flex-shrink: 0;
}

.gps-tbl-motor-on  { color: #3CB44B; font-size: 13px; }
.gps-tbl-motor-off { color: #334455; font-size: 13px; }

/* ── Markere Leaflet ─────────────────────────────────────────────────────────── */
.gps-marker {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 60px;
    max-width: 90px;
    padding: 2px 7px;
    border-radius: 10px;
    font-size: 10px;
    font-weight: 700;
    color: #fff;
    white-space: nowrap;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.55);
    border: 1.5px solid rgba(255, 255, 255, 0.22);
    text-shadow: 0 1px 2px rgba(0, 0, 0, 0.5);
    overflow: hidden;
    text-overflow: ellipsis;
    cursor: pointer;
    transition: opacity 0.15s;
}
.gps-marker:hover { opacity: 0.88; }

/* ── Popup harta ─────────────────────────────────────────────────────────────── */
.gps-popup {
    font-family: "Segoe UI", Arial, sans-serif;
    font-size: 12px;
    min-width: 210px;
}
.gps-popup-title {
    font-weight: 700;
    font-size: 14px;
    margin-bottom: 8px;
    color: #1a3045;
    border-bottom: 1px solid #d8e8f0;
    padding-bottom: 6px;
}
.gps-popup-tbl {
    border-collapse: collapse;
    width: 100%;
}
.gps-popup-tbl td {
    padding: 3px 5px;
    vertical-align: top;
    font-size: 12px;
}
.gps-popup-lbl {
    color: #7090a8;
    font-weight: 600;
    white-space: nowrap;
    padding-right: 10px !important;
}
.gps-popup-dot {
    display: inline-block;
    width: 7px;
    height: 7px;
    border-radius: 50%;
    margin-right: 4px;
    vertical-align: middle;
}
.gps-popup-addr {
    white-space: normal;
    word-break: break-word;
}
.gps-popup-maps-link {
    display: inline-block;
    margin-top: 6px;
    color: #1a73e8;
    text-decoration: none;
    font-size: 12px;
    font-weight: 600;
}
.gps-popup-maps-link:hover { text-decoration: underline; color: #0d5bba; }

/* =============================================================================
   GPS Timeline View
   ============================================================================= */

/* ── Container principal ─────────────────────────────────────────────────────── */
.gps-tl-root {
    display: flex;
    width: 100%;
    height: 100%;
    min-height: 580px;
    background: #102430;
    font-family: "Segoe UI", Arial, sans-serif;
    font-size: 13px;
    color: #d8e4ec;
    box-sizing: border-box;
}

.gps-tl-root.gps-theme-idrive {
    background: #f0f4f7;
    color: #1a2530;
}

/* ── Panoul drept ────────────────────────────────────────────────────────────── */
.gps-tl-main {
    flex: 1;
    display: flex;
    flex-direction: column;
    overflow: hidden;
    min-width: 0;
}

/* ── Toolbar ─────────────────────────────────────────────────────────────────── */
.gps-tl-toolbar {
    display: flex;
    align-items: center;
    gap: 14px;
    padding: 8px 14px;
    background: #0b1c28;
    border-bottom: 1px solid #1a3345;
    flex-shrink: 0;
    flex-wrap: wrap;
}
.gps-theme-idrive .gps-tl-toolbar {
    background: #e8f0f7;
    border-bottom-color: #c0d0dc;
}

.gps-tl-lbl {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 12px;
    color: #7090a8;
}
.gps-theme-idrive .gps-tl-lbl { color: #3a6080; }

.gps-dt-group {
    display: inline-flex;
    align-items: center;
    gap: 4px;
}

.gps-tl-datepicker {
    padding: 4px 6px;
    background: #132030;
    border: 1px solid #214055;
    border-radius: 4px;
    color: #c8d8e4;
    font-size: 12px;
    outline: none;
    width: 88px;
    box-sizing: border-box;
}
.gps-tl-datepicker:focus { border-color: #4a8ab0; }
.gps-tl-date { width: 120px; }
.gps-date-wrap { display: inline-flex; align-items: center; gap: 2px; }
.gps-date-ico {
    position: relative;
    overflow: hidden;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 3px 5px;
    border: 1px solid #214055;
    border-radius: 3px;
    color: #a0b8c8;
    font-size: 13px;
    line-height: 1;
    cursor: pointer;
    user-select: none;
    flex-shrink: 0;
}
.gps-date-ico:hover { background: #1a3a50; color: #d0e4f0; }
.gps-date-nat {
    position: fixed;
    top: -9999px; left: -9999px;
    width: 1px; height: 1px;
    opacity: 0;
    pointer-events: none;
    border: none; padding: 0; margin: 0;
}
.gps-theme-idrive .gps-date-ico { border-color: #90b8cc; color: #2a6080; background: transparent; }
.gps-theme-idrive .gps-date-ico:hover { background: #d0e8f4; }
.gps-tl-time { width: 74px; }
.gps-theme-idrive .gps-tl-datepicker {
    background: #fff;
    border-color: #aabfcc;
    color: #1a2530;
}

.gps-tl-btn {
    padding: 5px 16px;
    background: #1a5070;
    border: none;
    border-radius: 4px;
    color: #d8f0ff;
    font-size: 12px;
    font-weight: 700;
    cursor: pointer;
    transition: background 0.15s;
}
.gps-tl-btn:hover { background: #226090; }
.gps-tl-btn-day { padding: 5px 10px; font-weight: 400; background: #153040; }
.gps-tl-btn-day:hover { background: #1e4860; }
.gps-theme-idrive .gps-tl-btn { background: #2a7aaa; color: #fff; }
.gps-theme-idrive .gps-tl-btn:hover { background: #1a6090; }

.gps-tl-period {
    font-size: 11px;
    color: #5a7a90;
    margin-left: 6px;
}
.gps-theme-idrive .gps-tl-period { color: #4a6a80; }

/* ── Canvas ──────────────────────────────────────────────────────────────────── */
.gps-tl-canvas {
    flex: 1;
    overflow-y: auto;
    overflow-x: hidden;
    padding: 10px 14px 20px;
    background: #112030;
    position: relative;
}
.gps-theme-idrive .gps-tl-canvas { background: #f4f8fb; }
.gps-tl-canvas::-webkit-scrollbar { width: 5px; }
.gps-tl-canvas::-webkit-scrollbar-track { background: transparent; }
.gps-tl-canvas::-webkit-scrollbar-thumb { background: #2a4a60; border-radius: 3px; }

.gps-tl-empty {
    color: #7a9ab0;
    font-size: 13px;
    text-align: center;
    margin-top: 60px;
}
.gps-theme-idrive .gps-tl-empty { color: #4a6a80; }

/* ── Ruler ───────────────────────────────────────────────────────────────────── */
.gps-tl-ruler {
    position: relative;
    height: 24px;
    margin-left: 130px;
    margin-bottom: 6px;
    border-bottom: 1px solid #4a7a98;
}
.gps-theme-idrive .gps-tl-ruler { border-bottom-color: #7aaac4; }

.gps-tl-tick {
    position: absolute;
    top: 0;
    transform: translateX(-50%);
    font-size: 10px;
    color: #90c8e8;
    white-space: nowrap;
    user-select: none;
    font-weight: 600;
}
.gps-tl-tick::after {
    content: '';
    display: block;
    width: 1px;
    height: 7px;
    background: #4a7a98;
    margin: 1px auto 0;
}
.gps-theme-idrive .gps-tl-tick { color: #1a5070; font-weight: 600; }
.gps-theme-idrive .gps-tl-tick::after { background: #7aaac4; }

/* ── Vehicle row ─────────────────────────────────────────────────────────────── */
.gps-tl-row {
    display: flex;
    align-items: center;
    margin-bottom: 8px;
    min-height: 22px;
}

.gps-tl-row-label {
    width: 124px;
    min-width: 124px;
    font-size: 11px;
    font-weight: 700;
    color: #90b8cc;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    padding-right: 6px;
    line-height: 22px;
}
.gps-theme-idrive .gps-tl-row-label { color: #2a5070; }

/* ── Track ───────────────────────────────────────────────────────────────────── */
.gps-tl-track {
    flex: 1;
    position: relative;
    height: 20px;
    background: #132030;
    border-radius: 3px;
    overflow: visible;
}
.gps-theme-idrive .gps-tl-track { background: #d8eaf4; }

/* ── Segment bar ─────────────────────────────────────────────────────────────── */
.gps-tl-seg {
    position: absolute;
    top: 0;
    height: 100%;
    border-radius: 2px;
    cursor: pointer;
    transition: opacity 0.1s, filter 0.1s;
    min-width: 2px;
}
.gps-tl-seg:hover {
    opacity: 0.85;
    filter: brightness(1.15);
    z-index: 10;
}

/* ── Tooltip ─────────────────────────────────────────────────────────────────── */
.gps-tl-tooltip {
    position: absolute;
    bottom: calc(100% + 6px);
    left: 50%;
    transform: translateX(-50%);
    background: #0a1820;
    color: #c8d8e4;
    border: 1px solid #2a4a60;
    border-radius: 5px;
    padding: 7px 10px;
    font-size: 11px;
    line-height: 1.5;
    white-space: nowrap;
    z-index: 9000;
    pointer-events: none;
    box-shadow: 0 4px 14px rgba(0,0,0,0.7);
    min-width: 180px;
}
.gps-theme-idrive .gps-tl-tooltip {
    background: #fff;
    color: #1a2530;
    border-color: #9ab8cc;
    box-shadow: 0 4px 14px rgba(0,0,0,0.2);
}

/* ── Legend ──────────────────────────────────────────────────────────────────── */
.gps-tl-legend {
    display: flex;
    gap: 20px;
    margin-top: 16px;
    padding-top: 10px;
    border-top: 1px solid #1a3345;
    margin-left: 130px;
    flex-wrap: wrap;
}
.gps-theme-idrive .gps-tl-legend { border-top-color: #b0c8d8; }

.gps-tl-legend-item {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 11px;
    color: #6a8a9a;
}
.gps-theme-idrive .gps-tl-legend-item { color: #3a5a70; }

.gps-tl-legend-dot {
    width: 12px;
    height: 12px;
    border-radius: 2px;
    flex-shrink: 0;
}

/* ── Navigation buttons (±1d / ±7d) ─────────────────────────────────────────── */
.gps-tl-nbtn {
    padding: 4px 8px;
    background: transparent;
    border: 1px solid #2a4a60;
    border-radius: 3px;
    color: #6a9ab8;
    font-size: 13px;
    font-weight: 700;
    cursor: pointer;
    line-height: 1;
    transition: background 0.12s, color 0.12s;
}
.gps-tl-nbtn:hover { background: #1a3a50; color: #a0ccdf; }
.gps-tl-nbtn:disabled { opacity: 0.3; cursor: not-allowed; pointer-events: none; }
.gps-theme-idrive .gps-tl-nbtn { border-color: #90b8cc; color: #2a6080; background: transparent; }
.gps-theme-idrive .gps-tl-nbtn:hover { background: #d0e8f4; }
.gps-tl-sep { display: inline-block; width: 1px; height: 18px; background: #2a4a60; margin: 0 2px; align-self: center; }
.gps-theme-idrive .gps-tl-sep { background: #a0b8cc; }

/* ── Zoom buttons ────────────────────────────────────────────────────────────── */
.gps-tl-zbtn {
    padding: 3px 9px;
    background: #1a3a50;
    border: 1px solid #2a5570;
    border-radius: 3px;
    color: #90c0d8;
    font-size: 14px;
    font-weight: 700;
    cursor: pointer;
    line-height: 1;
    transition: background 0.12s;
    margin-left: 3px;
}
.gps-tl-zbtn:hover { background: #245878; }
.gps-theme-idrive .gps-tl-zbtn { background: #c8dce8; border-color: #90b0c4; color: #1a4060; }
.gps-theme-idrive .gps-tl-zbtn:hover { background: #aecadc; }

/* ── Drag cursor ─────────────────────────────────────────────────────────────── */
.gps-tl-track { cursor: grab; }
.gps-tl-canvas.gps-tl-grabbing .gps-tl-track,
.gps-tl-canvas.gps-tl-grabbing .gps-tl-seg  { cursor: grabbing; }

/* ══════════════════════════════════════════════════════════════════════════════
   TRASEU (Urmarire traseu cu redare animata)
   ══════════════════════════════════════════════════════════════════════════════ */

/* ── Layout ──────────────────────────────────────────────────────────────────── */
.gps-tr-root {
    display: flex;
    flex-direction: row;
    width: 100%;
    min-height: 500px;
    overflow: hidden;
    font-family: 'Segoe UI', Arial, sans-serif;
    color: #d8e4ec;
    font-size: 13px;
    box-sizing: border-box;
}

.gps-tr-main {
    display: flex;
    flex-direction: column;
    flex: 1;
    min-width: 0;
    min-height: 0;
    overflow: hidden;
}

/* ── Toolbar ─────────────────────────────────────────────────────────────────── */
.gps-tr-toolbar {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 6px;
    padding: 6px 10px;
    background: #0d1e2c;
    border-bottom: 1px solid #1e3a50;
    flex-shrink: 0;
}

.gps-tr-info {
    font-size: 11px;
    color: #6a9ab8;
    margin-left: 6px;
}

/* ── Map ─────────────────────────────────────────────────────────────────────── */
.gps-tr-map-wrapper {
    flex: 1;
    position: relative;
    min-height: 200px;
    background: #0d1e2c;
}

#gps-tr-map {
    width: 100%;
    height: 100%;
}

/* ── Playback bar ────────────────────────────────────────────────────────────── */
.gps-tr-playbar {
    display: flex;
    align-items: center;
    gap: 4px;
    padding: 5px 10px;
    background: #0d1e2c;
    border-top: 1px solid #1e3a50;
    flex-shrink: 0;
    flex-wrap: wrap;
}

.gps-tr-pbtn {
    padding: 4px 9px;
    background: #1a3a50;
    border: 1px solid #2a5570;
    border-radius: 3px;
    color: #90c0d8;
    font-size: 13px;
    cursor: pointer;
    line-height: 1.2;
    min-width: 28px;
    transition: background 0.12s;
}
.gps-tr-pbtn:hover:not(:disabled) { background: #245878; }
.gps-tr-pbtn:disabled { opacity: 0.35; cursor: not-allowed; }

.gps-tr-play-btn  { color: #3CB44B; border-color: #2a6a35; min-width: 32px; }
.gps-tr-speed-btn { color: #e8c060; border-color: #6a5010; min-width: 32px; font-weight: 700; }

.gps-tr-slider {
    flex: 1;
    min-width: 80px;
    height: 4px;
    accent-color: #6600ff;
    cursor: pointer;
}
.gps-tr-slider:disabled { opacity: 0.35; cursor: not-allowed; }

.gps-tr-timelabel {
    font-size: 11px;
    color: #90c8e8;
    white-space: nowrap;
    min-width: 140px;
    font-family: monospace;
}

/* ── Fullscreen button ───────────────────────────────────────────────────────── */
.gps-tr-fullscreen-btn {
    position: absolute;
    top: 8px;
    right: 8px;
    z-index: 1000;
    width: 30px;
    height: 30px;
    padding: 0;
    background: rgba(13, 30, 44, 0.85);
    border: 1px solid #2a5570;
    border-radius: 4px;
    color: #90c0d8;
    font-size: 16px;
    line-height: 1;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.12s;
}
.gps-tr-fullscreen-btn:hover { background: rgba(36, 88, 120, 0.95); color: #fff; }

/* ── Fullscreen mode ────────────────────────────────────────────────────────── */
.gps-tr-root.gps-tr-fs {
    position: fixed !important;
    top: 0 !important;
    left: 0 !important;
    width: 100vw !important;
    height: 100vh !important;
    z-index: 9990;
    margin: 0 !important;
    border-radius: 0 !important;
}

/* ── Moving vehicle marker ───────────────────────────────────────────────────── */
.gps-tr-moving-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    /* Leaflet seteaza transform:translate() pe acest element pentru pozitionare.
       Rotatia se aplica pe elementul intern .gps-tr-marker-arrow. */
}
.gps-tr-marker-arrow {
    font-size: 22px;
    color: #ff4400;
    text-shadow: 0 0 4px #fff, 0 0 10px #ff8800, 0 0 18px #ff4400;
    line-height: 1;
    display: block;
    transform-origin: center center;
    transition: transform 0.12s linear;
    will-change: transform;
}

/* ── IDrive theme overrides ──────────────────────────────────────────────────── */
.gps-theme-idrive .gps-tr-toolbar,
.gps-theme-idrive .gps-tr-playbar  { background: #e8f0f8; border-color: #a0b8cc; }
.gps-theme-idrive .gps-tr-map-wrapper { background: #e0ecf8; }
.gps-theme-idrive .gps-tr-pbtn     { background: #c8dce8; border-color: #90b0c4; color: #1a4060; }
.gps-theme-idrive .gps-tr-pbtn:hover:not(:disabled) { background: #aecadc; }
.gps-theme-idrive .gps-tr-play-btn  { color: #1a6a30; border-color: #5a9a60; }
.gps-theme-idrive .gps-tr-speed-btn { color: #805010; border-color: #c09040; }
.gps-theme-idrive .gps-tr-timelabel { color: #1a3a60; }
.gps-theme-idrive .gps-tr-info      { color: #3a6080; }

/* Toolbar extra toggles */
.gps-tr-extra-sep {
    color: #4a7090;
    margin: 0 6px;
    font-size: 14px;
    line-height: 1;
}
.gps-tr-extra-lbl {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    font-size: 12px;
    color: #8fc8e8;
    cursor: pointer;
    user-select: none;
    margin-right: 6px;
}
.gps-tr-extra-lbl input[type=checkbox] {
    margin: 0;
    cursor: pointer;
}

/* Bottom panel: chart + segments table */
.gps-tr-bottom {
    display: flex;
    flex-direction: row;
    height: 220px;
    min-height: 180px;
    background: #0a1e2d;
    border-top: 1px solid #1e4060;
    overflow: hidden;
}
.gps-tr-chart-panel,
.gps-tr-segs-panel {
    display: flex;
    flex-direction: column;
    overflow: hidden;
    min-width: 0;
}
.gps-tr-chart-panel { flex: 1 1 0; }
.gps-tr-segs-panel  { flex: 1 1 0; }
.gps-tr-chart-panel {
    border-right: 1px solid #1e4060;
}
.gps-tr-panel-title {
    font-size: 11px;
    font-weight: 700;
    color: #6a9ab8;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    padding: 4px 8px;
    background: #071828;
    border-bottom: 1px solid #1e4060;
    flex-shrink: 0;
}
.gps-tr-chart {
    flex: 1 1 auto;
    overflow: hidden;
    position: relative;
    background: #071828;
}
.gps-tr-chart svg {
    display: block;
    width: 100%;
    height: 100%;
}

/* Segments table */
.gps-tr-segs {
    flex: 1 1 auto;
    overflow-y: auto;
    overflow-x: hidden;
}
.gps-tr-seg-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 11px;
    color: #c8dce8;
}
.gps-tr-seg-table th {
    position: sticky;
    top: 0;
    background: #0d2235;
    color: #6a9ab8;
    font-weight: 600;
    text-align: left;
    padding: 4px 6px;
    border-bottom: 1px solid #1e4060;
    white-space: nowrap;
}
.gps-tr-seg-row {
    cursor: pointer;
    transition: background 0.12s;
}
.gps-tr-seg-row:hover {
    background: #0d2235;
}
.gps-tr-seg-row.selected {
    background: #0a3a1a;
    color: #80ee80;
}
.gps-tr-seg-row td {
    padding: 3px 6px;
    border-bottom: 1px solid #122030;
    vertical-align: top;
}
.gps-tr-seg-time {
    white-space: nowrap;
    color: #a0c8e0;
}
.gps-tr-seg-addr {
    max-width: 160px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}
/* Tooltip permanent cu numarul traseului — centrat pe cercul de start */
.gps-tr-route-label {
    background: transparent !important;
    border: none !important;
    box-shadow: none !important;
    color: #fff;
    font-weight: bold;
    font-size: 10px;
    padding: 0 !important;
    pointer-events: none;
}
.gps-tr-route-label::before { display: none !important; }
.gps-tr-seg-num {
    white-space: nowrap;
    text-align: center;
    color: #8ab8d8;
    width: 24px;
}
.gps-tr-seg-km {
    white-space: nowrap;
    text-align: right;
    color: #a0d8a0;
}
.gps-tr-seg-dur {
    white-space: nowrap;
    color: #e8c060;
    text-align: right;
}
.gps-tr-no-data {
    color: #4a7090;
    font-size: 12px;
    padding: 12px 8px;
    text-align: center;
}

/* IDrive theme overrides for bottom panel */
.gps-theme-idrive .gps-tr-bottom        { background: #e8f0f8; border-color: #a0b8cc; }
.gps-theme-idrive .gps-tr-chart-panel   { border-color: #a0b8cc; }
.gps-theme-idrive .gps-tr-panel-title   { background: #d0e0ec; color: #3a6080; border-color: #a0b8cc; }
.gps-theme-idrive .gps-tr-chart         { background: #d8ecf8; }
.gps-theme-idrive .gps-tr-seg-table     { color: #1a3a60; }
.gps-theme-idrive .gps-tr-seg-table th  { background: #c8dce8; color: #2a5070; border-color: #a0b8cc; }
.gps-theme-idrive .gps-tr-seg-row:hover { background: #c0d8ec; }
.gps-theme-idrive .gps-tr-seg-row.selected { background: #b0e0b0; color: #1a4a1a; }
.gps-theme-idrive .gps-tr-seg-row td    { border-color: #c0d0dc; }
.gps-theme-idrive .gps-tr-seg-time      { color: #2a5070; }
.gps-theme-idrive .gps-tr-seg-dur       { color: #805010; }
.gps-theme-idrive .gps-tr-extra-lbl     { color: #2a5070; }
.gps-theme-idrive .gps-tr-extra-sep     { color: #7090a8; }

/* ══════════════════════════════════════════════════════════════════════════════
   CUSTOM DATE+TIME PICKER (gps-datetimepicker.js)
   ══════════════════════════════════════════════════════════════════════════════ */

/* Input display — inlocuieste vizual datetime-local-ul */
.gps-dtp-display {
    cursor: pointer !important;
    min-width: 140px;
    user-select: none;
}
.gps-dtp-display:focus { outline: none; border-color: #4a8ab0; }

/* Panel flotant */
.gps-dtp-panel {
    position: absolute;
    z-index: 19999;
    width: 220px;
    background: #0d1e2c;
    border: 1px solid #2a5570;
    border-radius: 6px;
    box-shadow: 0 6px 24px rgba(0,0,0,0.65);
    font-family: 'Segoe UI', Arial, sans-serif;
    font-size: 12px;
    color: #c8dce8;
    padding: 6px;
    box-sizing: border-box;
    user-select: none;
}

/* Antet luna */
.gps-dtp-hdr {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 6px;
}
.gps-dtp-mname {
    font-weight: 700;
    font-size: 12px;
    color: #90c8e8;
}
.gps-dtp-nav {
    background: none;
    border: 1px solid #2a5570;
    border-radius: 3px;
    color: #90c0d8;
    cursor: pointer;
    font-size: 14px;
    line-height: 1;
    padding: 2px 6px;
    transition: background 0.1s;
}
.gps-dtp-nav:hover { background: #1a3a50; }

/* Grid zile */
.gps-dtp-grid {
    display: grid;
    grid-template-columns: repeat(7, 1fr);
    gap: 1px;
    margin-bottom: 6px;
}
.gps-dtp-dn {
    text-align: center;
    font-size: 10px;
    color: #4a8ab0;
    padding: 2px 0;
    font-weight: 600;
}
.gps-dtp-dc { /* celula goala */ }
.gps-dtp-d {
    text-align: center;
    padding: 4px 2px;
    border-radius: 3px;
    cursor: pointer;
    font-size: 11px;
    transition: background 0.1s;
}
.gps-dtp-d:hover       { background: #1a3a50; color: #fff; }
.gps-dtp-d.gps-dtp-today  { color: #6af; font-weight: 700; }
.gps-dtp-d.gps-dtp-sel    { background: #6600ff; color: #fff !important; border-radius: 3px; }
.gps-dtp-d.gps-dtp-x      { color: #2a4050; cursor: default; }
.gps-dtp-d.gps-dtp-x:hover { background: none; }

/* Selectie ora:minut — rand cu slider + spinner */
.gps-dtp-trow {
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 4px 8px;
    border-top: 1px solid #1e3a50;
}
.gps-dtp-tlbl {
    font-size: 11px;
    color: #6a9ab8;
    width: 24px;
    flex-shrink: 0;
}
.gps-dtp-slider {
    flex: 1 1 0;
    min-width: 0;
    height: 4px;
    accent-color: #4a8ab0;
    cursor: pointer;
}
.gps-dtp-tc {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1px;
    flex-shrink: 0;
}
.gps-dtp-tb {
    background: #132030;
    border: 1px solid #214055;
    border-radius: 3px;
    color: #90c0d8;
    cursor: pointer;
    font-size: 9px;
    line-height: 1;
    padding: 1px 6px;
    transition: background 0.1s;
}
.gps-dtp-tb:hover { background: #1e4060; }
.gps-dtp-tv {
    font-size: 14px;
    font-weight: 700;
    color: #d8f0ff;
    min-width: 26px;
    text-align: center;
    letter-spacing: 1px;
    cursor: ns-resize;
}

/* Buton Alege */
.gps-dtp-foot {
    display: flex;
    justify-content: center;
    padding-top: 6px;
    border-top: 1px solid #1e3a50;
    margin-top: 4px;
}
.gps-dtp-ok {
    background: #1a5070;
    border: none;
    border-radius: 4px;
    color: #d8f0ff;
    cursor: pointer;
    font-size: 12px;
    font-weight: 700;
    padding: 5px 28px;
    transition: background 0.12s;
}
.gps-dtp-ok:hover { background: #226090; }

/* ══════════════════════════════════════════════════════════════════════════════
   PUNCTE DE INTERES
   ══════════════════════════════════════════════════════════════════════════════ */

/* ── Container principal ── */
.gps-poi-root {
    display: flex;
    flex-direction: column;
    width: 100%;
    height: 100%;
    min-height: 580px;
    overflow: hidden;
    font-family: 'Segoe UI', Arial, sans-serif;
    font-size: 13px;
    color: #d8e4ec;
    background: #0d1e2c;
    box-sizing: border-box;
}
.gps-poi-view { display: flex; flex-direction: column; height: 100%; overflow: hidden; }

/* ── Toolbar ── */
.gps-poi-toolbar {
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 7px 10px;
    background: #0a1825;
    border-bottom: 1px solid #1e3a50;
    flex-shrink: 0;
    flex-wrap: wrap;
}
.gps-poi-tb-sep { flex: 1; }
.gps-poi-edit-title { font-size: 13px; font-weight: 700; color: #90c8e8; margin-left: 8px; }

/* ── Butoane ── */
.gps-poi-btn {
    background: #132030; border: 1px solid #2a5070; border-radius: 4px;
    color: #90c8e8; cursor: pointer; font-size: 12px; padding: 4px 12px;
    transition: background 0.1s; white-space: nowrap;
}
.gps-poi-btn:hover:not(:disabled) { background: #1e4060; }
.gps-poi-btn:disabled { opacity: 0.5; cursor: default; }
.gps-poi-btn-primary { background: #1a5070; border-color: #3a8ab0; color: #d8f0ff; }
.gps-poi-btn-primary:hover:not(:disabled) { background: #226090; }
.gps-poi-btn-danger  { background: #6b1a1a; border-color: #a03030; color: #ffd8d8; }
.gps-poi-btn-danger:hover:not(:disabled)  { background: #8b2020; }

/* ── Filtre toolbar ── */
.gps-poi-search {
    background: #0a1520; border: 1px solid #2a5070; border-radius: 4px;
    color: #c0d8e8; font-size: 12px; padding: 4px 8px; outline: none; width: 180px;
}
.gps-poi-search:focus { border-color: #4a8ab0; }
.gps-poi-search::placeholder { color: #3a6070; }
.gps-poi-filter-sel {
    background: #0a1520; border: 1px solid #2a5070; border-radius: 4px;
    color: #c0d8e8; font-size: 12px; padding: 4px 6px; outline: none;
}

/* ── Tabel grid ── */
.gps-poi-table-wrap {
    flex: 1; overflow-y: auto; overflow-x: auto; min-height: 0;
}
.gps-poi-table {
    width: 100%; border-collapse: collapse; font-size: 12px;
}
.gps-poi-th {
    background: #0a1825; color: #6a9ab8; font-size: 11px; font-weight: 700;
    text-transform: uppercase; padding: 7px 10px; border-bottom: 2px solid #1e3a50;
    text-align: left; white-space: nowrap; position: sticky; top: 0; z-index: 1;
}
.gps-poi-th.sortable { cursor: pointer; user-select: none; }
.gps-poi-th.sortable:hover { color: #90c8e8; }
.gps-poi-th.sort-asc::after  { content: ' ▲'; color: #4a8ab0; }
.gps-poi-th.sort-desc::after { content: ' ▼'; color: #4a8ab0; }
.gps-poi-th-act { width: 160px; }
.gps-poi-td {
    padding: 6px 10px; border-bottom: 1px solid #0f2030;
    color: #c0d8e8; vertical-align: middle;
}
.gps-poi-row:hover .gps-poi-td { background: #112030; }
.gps-poi-tip-cerc    { color: #4ab0d8; }
.gps-poi-tip-poligon { color: #9ab048; }
.gps-poi-act-cell    { white-space: nowrap; }
.gps-poi-loading { text-align: center; color: #3a6070; padding: 20px; }
.gps-poi-dot {
    display: inline-block; width: 10px; height: 10px; border-radius: 50%;
    border: 2px solid transparent; margin-right: 5px; vertical-align: middle; opacity: 0.9;
}
.gps-poi-act-btn {
    background: #132030; border: 1px solid #2a5070; border-radius: 3px;
    color: #90c8e8; cursor: pointer; font-size: 11px; padding: 2px 8px;
    margin-right: 4px; transition: background 0.1s;
}
.gps-poi-act-btn:hover { background: #1e4060; }
.gps-poi-btn-del { border-color: #6b1a1a; color: #e88080; }
.gps-poi-btn-del:hover { background: #4a1010; }

/* ── Paginare ── */
.gps-poi-pager {
    display: flex; align-items: center; gap: 4px; padding: 6px 10px;
    background: #0a1825; border-top: 1px solid #1e3a50; flex-shrink: 0;
    flex-wrap: wrap;
}
.gps-poi-pager-info { font-size: 11px; color: #4a7a98; margin-right: 8px; }
.gps-poi-pg-btn {
    background: #132030; border: 1px solid #2a5070; border-radius: 3px;
    color: #90c8e8; cursor: pointer; font-size: 11px; padding: 2px 8px; min-width: 28px;
}
.gps-poi-pg-btn:hover:not(:disabled) { background: #1e4060; }
.gps-poi-pg-btn.active { background: #1a5070; border-color: #3a8ab0; color: #d8f0ff; font-weight: 700; }
.gps-poi-pg-btn:disabled { opacity: 0.4; cursor: default; }

/* ── Formular add/edit ── */
.gps-poi-edit-content {
    display: flex; flex: 1; overflow: hidden; min-height: 0;
}
.gps-poi-form-panel {
    width: 340px; min-width: 280px; max-width: 380px; flex-shrink: 0;
    background: #0d1e2c; border-right: 1px solid #1e3a50;
    overflow-y: auto; padding: 10px 14px;
}
.gps-poi-form-row {
    display: flex; align-items: center; gap: 8px; margin-bottom: 8px;
}
.gps-poi-form-lbl {
    width: 90px; min-width: 90px; font-size: 12px; color: #6a9ab8; flex-shrink: 0;
}
.gps-poi-req { color: #e05050; }
.gps-poi-input {
    flex: 1; background: #0a1520; border: 1px solid #2a5070; border-radius: 4px;
    color: #c0d8e8; font-size: 12px; padding: 4px 8px; outline: none; min-width: 0;
}
.gps-poi-input:focus { border-color: #4a8ab0; }
.gps-poi-input-num {
    flex: 1; background: #0a1520; border: 1px solid #2a5070; border-radius: 4px;
    color: #c0d8e8; font-size: 12px; padding: 4px 8px; outline: none; min-width: 0;
}
.gps-poi-input-num:focus { border-color: #4a8ab0; }
.gps-poi-color {
    width: 44px; height: 28px; border: 1px solid #2a5070; border-radius: 4px;
    cursor: pointer; background: none; padding: 2px;
}
.gps-poi-geo-sec {
    margin-top: 10px; padding: 8px 10px;
    background: #0a1825; border: 1px solid #1e3a50; border-radius: 6px;
}
.gps-poi-sec-title {
    font-size: 11px; font-weight: 700; color: #4a8ab0; text-transform: uppercase;
    margin-bottom: 8px;
}
.gps-poi-form-hint { font-size: 11px; color: #3a6070; margin-top: 6px; }
.gps-poi-form-btns { display: flex; gap: 8px; margin-top: 14px; }
.gps-poi-form-err {
    background: #4a1010; border: 1px solid #8b2020; border-radius: 4px;
    color: #ffd8d8; font-size: 12px; padding: 6px 10px; margin-top: 8px;
}

/* Tabel puncte poligon */
.gps-poi-pts-table { width: 100%; border-collapse: collapse; font-size: 11px; }
.gps-poi-pts-table th { color: #4a7a98; padding: 3px 6px; border-bottom: 1px solid #1e3a50; text-align: left; }
.gps-poi-pts-table td { color: #c0d8e8; padding: 3px 6px; border-bottom: 1px solid #0f2030; }
.gps-poi-pt-del {
    background: none; border: none; color: #e06060; cursor: pointer; font-size: 12px; padding: 0 4px;
}
.gps-poi-pt-del:hover { color: #ff4040; }

/* ── Harta edit ── */
.gps-poi-map-panel { flex: 1; position: relative; min-width: 0; }
#gps-poi-edit-map  { width: 100%; height: 100%; }

/* ── Confirmare stergere ── */
.gps-poi-overlay {
    position: fixed; top: 0; left: 0; width: 100%; height: 100%;
    background: rgba(0,0,0,0.55); z-index: 9000;
    display: flex; align-items: center; justify-content: center;
}
.gps-poi-confirm-box {
    background: #0d1e2c; border: 1px solid #2a5070; border-radius: 8px;
    padding: 24px 28px; max-width: 380px; text-align: center;
    box-shadow: 0 8px 32px rgba(0,0,0,0.6);
}
.gps-poi-confirm-icon { font-size: 32px; margin-bottom: 10px; }
.gps-poi-confirm-msg { font-size: 14px; color: #c0d8e8; margin-bottom: 18px; line-height: 1.5; }
.gps-poi-confirm-msg small { color: #6a9ab8; font-size: 12px; }
.gps-poi-confirm-btns { display: flex; gap: 10px; justify-content: center; }

/* ── Layout lista: tabel stanga + harta dreapta ── */
.gps-poi-list-content {
    display: flex; flex: 1; min-height: 0; overflow: hidden;
}
.gps-poi-list-panel {
    display: flex; flex-direction: column;
    width: 46%; min-width: 280px; max-width: 600px;
    border-right: 1px solid #1e3a50; overflow: hidden; flex-shrink: 0;
}
/* Harta lista — ocupa restul latimii */
.gps-poi-list-map-wrap { flex: 1; min-width: 0; position: relative; }
#gps-poi-list-map { width: 100%; height: 100%; }
.gps-poi-btn-active { background: #1a5070 !important; border-color: #3a8ab0 !important; color: #d8f0ff !important; }
.gps-poi-btn-sm { font-size: 11px; padding: 2px 8px; }
/* Row selectat in tabel */
.gps-poi-row-selected .gps-poi-td { background: #0e2e48 !important; }
.gps-poi-row { cursor: pointer; }

/* ── Cautare cu buton X ── */
.gps-poi-search-wrap { position: relative; display: flex; align-items: center; }
.gps-poi-search-clear {
    position: absolute; right: 5px;
    background: none; border: none; color: #4a7a98; cursor: pointer;
    font-size: 11px; padding: 0 3px; line-height: 1; display: none;
}
.gps-poi-search-clear:hover { color: #90c8e8; }
.gps-poi-search { padding-right: 20px; }

/* ── Butoane overlay harta (fullscreen, toggle) ── */
.gps-poi-map-ctrl-btn {
    position: absolute; z-index: 1000;
    background: rgba(10,24,37,0.85); border: 1px solid #2a5070; border-radius: 4px;
    color: #90c8e8; cursor: pointer; font-size: 13px; padding: 3px 9px;
    transition: background 0.1s; white-space: nowrap;
}
.gps-poi-map-ctrl-btn:hover { background: rgba(26,80,112,0.92); }
.gps-poi-map-ctrl-btn.active { background: rgba(26,80,112,0.92); border-color: #3a8ab0; color: #d8f0ff; }
/* Pozitie: colt dreapta-sus al hartii */
.gps-poi-map-ctrl-tr { top: 8px; right: 8px; }

/* ── Panel adaugare grup nou (inline) ── */
.gps-poi-add-grup-panel {
    margin-left: 98px; margin-bottom: 8px;
    background: #0a1520; border: 1px solid #2a5070; border-radius: 6px;
    padding: 10px 12px;
}
.gps-poi-add-grup-title {
    font-size: 11px; font-weight: 700; color: #4a8ab0;
    text-transform: uppercase; margin-bottom: 8px;
}
.gps-poi-add-grup-err {
    background: #4a1010; border: 1px solid #8b2020; border-radius: 4px;
    color: #ffd8d8; font-size: 11px; padding: 4px 8px; margin-bottom: 6px;
}

/* ── Modal import ── */
.gps-poi-import-box {
    background: #0d1e2c; border: 1px solid #2a5070; border-radius: 8px;
    padding: 22px 26px; width: 500px; max-width: 96vw;
    box-shadow: 0 8px 32px rgba(0,0,0,0.6);
}
.gps-poi-import-title { font-size: 14px; font-weight: 700; color: #90c8e8; margin-bottom: 10px; }
.gps-poi-import-info {
    font-size: 11px; color: #4a7a98; margin-bottom: 10px; line-height: 1.7;
    background: #0a1520; border: 1px solid #1e3a50; border-radius: 4px; padding: 8px 10px;
}
.gps-poi-import-info code { color: #80c0e0; font-size: 11px; }
.gps-poi-import-progress {
    height: 5px; background: #1e3a50; border-radius: 3px; margin: 10px 0;
}
.gps-poi-import-progress-bar {
    height: 100%; background: #4a8ab0; border-radius: 3px; width: 0%; transition: width 0.3s;
}
.gps-poi-import-status { font-size: 12px; color: #6a9ab8; min-height: 18px; }
.gps-poi-import-log {
    max-height: 180px; overflow-y: auto;
    background: #0a1520; border: 1px solid #1e3a50; border-radius: 4px;
    padding: 6px 8px; font-size: 11px; font-family: monospace;
    margin-top: 8px; display: none;
}
.gps-poi-import-log-ok   { color: #4ab070; }
.gps-poi-import-log-err  { color: #e08080; }
.gps-poi-import-log-warn { color: #e0b050; }

/* ── Geocoding (navigare pe harta dupa adresa) ── */
.gps-poi-geocode-wrap {
    display: flex; align-items: center; gap: 4px; flex: 1;
}
.gps-poi-geocode-results {
    margin-left: 98px; margin-bottom: 8px;
    background: #0a1520; border: 1px solid #2a5070; border-radius: 4px;
    max-height: 150px; overflow-y: auto; font-size: 12px;
}
.gps-poi-geocode-item {
    padding: 6px 10px; cursor: pointer; color: #c0d8e8;
    border-bottom: 1px solid #1e3a50;
}
.gps-poi-geocode-item:last-child { border-bottom: none; }
.gps-poi-geocode-item:hover { background: #112030; }
.gps-poi-geocode-item small { color: #4a7a98; font-size: 11px; }
.gps-poi-geocode-none { padding: 8px 10px; color: #4a7a98; font-size: 11px; }

/* ── Label context pe harta lista ── */
.gps-poi-list-lbl {
    background: rgba(10,24,37,0.85); border: none; color: #d8f0ff;
    font-size: 10px; font-weight: 700; padding: 1px 5px; border-radius: 3px;
    white-space: nowrap;
}

/* ── Formular fieldset ── */
.gps-poi-fieldset {
    border: 1px solid #1e3a50; border-radius: 6px;
    padding: 10px 12px; margin-bottom: 10px; background: #0a1825;
}
.gps-poi-fieldset-title {
    font-size: 11px; font-weight: 700; color: #4a8ab0;
    text-transform: uppercase; margin-bottom: 10px; letter-spacing: 0.5px;
}

/* Color picker row */
.gps-poi-color-row { display: flex; align-items: center; gap: 8px; flex: 1; }
.gps-poi-color-preview {
    width: 22px; height: 22px; border-radius: 4px;
    border: 1px solid #2a5070; background: #3388ff; flex-shrink: 0;
}
.gps-poi-color-hint { font-size: 11px; color: #3a6070; }

/* Raza slider */
.gps-poi-raza-slider {
    flex: 1; min-width: 0; height: 4px; accent-color: #4a8ab0; cursor: pointer; margin-left: 6px;
}

/* Hint harta */
.gps-poi-map-hint {
    display: flex; align-items: center; gap: 6px;
    background: #0f2030; border: 1px solid #1e4060; border-radius: 4px;
    padding: 6px 10px; margin-bottom: 8px; font-size: 12px; color: #6a9ab8;
}
.gps-poi-hint-icon { font-size: 16px; color: #4a8ab0; }

/* Overlay hint pe harta edit */
.gps-poi-map-overlay-hint {
    position: absolute; bottom: 30px; left: 50%; transform: translateX(-50%);
    background: rgba(10,24,37,0.88); border: 1px solid #2a5070; border-radius: 20px;
    color: #90c8e8; font-size: 12px; padding: 6px 16px; z-index: 1000;
    pointer-events: none; white-space: nowrap;
}
.gps-poi-map-panel { flex: 1; position: relative; min-width: 0; }
#gps-poi-edit-map  { width: 100%; height: 100%; }

/* Label numere puncte poligon pe harta */
.gps-poi-pt-lbl {
    background: rgba(10,24,37,0.8); border: none; color: #90c8e8;
    font-size: 10px; font-weight: 700; padding: 1px 4px; border-radius: 3px;
}
.gps-poi-pts-empty { color: #3a6070; font-size: 11px; padding: 6px 8px; text-align: center; }

/* ══════════════════════════════════════════════════════════════════════════════
   ALERTE
   ══════════════════════════════════════════════════════════════════════════════ */

.gps-al-root {
    display: flex;
    flex-direction: row;
    width: 100%;
    height: 100%;
    min-height: 0;
    overflow: hidden;
    font-family: 'Segoe UI', Arial, sans-serif;
}

.gps-al-main {
    display: flex;
    flex-direction: column;
    flex: 1;
    min-width: 0;
    min-height: 0;
    overflow: hidden;
}

.gps-al-toolbar {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 6px;
    padding: 6px 10px;
    background: #0d1e2c;
    border-bottom: 1px solid #1e3a50;
    flex-shrink: 0;
}

.gps-al-info {
    font-size: 11px;
    color: #6a9ab8;
    margin-left: 6px;
}

.gps-al-map-wrapper {
    flex: 0 0 55%;
    position: relative;
    min-height: 150px;
}

#gps-al-map {
    width: 100%;
    height: 100%;
}

.gps-al-table-panel {
    flex: 1;
    min-height: 100px;
    border-top: 1px solid #1e3a50;
    overflow: hidden;
    display: flex;
    flex-direction: column;
}

.gps-al-table-panel .gps-table-scroll {
    flex: 1;
    overflow: auto;
}

.gps-al-row { cursor: pointer; transition: background 0.1s; }
.gps-al-row:hover { background: #1a3a50 !important; }
.gps-al-row-active { background: #1e4a6a !important; }
.gps-al-row-expanded { background: #152d42 !important; }

/* Sortare coloane alerte */
.gps-al-th { cursor: default; white-space: nowrap; }
.gps-al-th.sortable { cursor: pointer; user-select: none; }
.gps-al-th.sortable:hover { background: #1a3a50; }
.gps-al-th.sort-asc::after  { content: ' \25B2'; font-size: 9px; color: #4ab4e8; }
.gps-al-th.sort-desc::after { content: ' \25BC'; font-size: 9px; color: #4ab4e8; }

/* Coloana expand INFOEXTRA */
.gps-al-th-exp { width: 20px; padding: 0 !important; }
.gps-al-td-exp { width: 20px; padding: 2px 4px !important; text-align: center; }
.gps-al-exp-icon { color: #4ab4e8; font-size: 10px; cursor: pointer; }
.gps-al-exp-icon:hover { color: #8dd4f8; }

/* Rand INFOEXTRA expandat */
.gps-al-extra-row { background: #0d2030 !important; }
.gps-al-extra-td {
    padding: 6px 12px 6px 28px !important;
    color: #8ab4cc;
    font-size: 11px;
    font-style: italic;
    border-top: 1px dashed #1e3a50;
}

/* Rand gol */
.gps-al-empty { text-align: center; color: #456; padding: 16px !important; }


/* Separator toolbar */
.gps-al-tb-sep { flex: 1; }

/* Buton live activ */
.gps-tl-btn.active { background: #1a6030; border-color: #2a9050; color: #8de8a8; }
.gps-tl-btn.active:hover { background: #1e7038; }

/* Select interval live */
.gps-tl-sel {
    background: #0d2030; color: #c8e0f0; border: 1px solid #2a5070;
    border-radius: 3px; padding: 2px 4px; font-size: 11px;
}

.gps-theme-idrive .gps-al-toolbar { background: #e8f0f8; border-color: #a0b8cc; }
.gps-theme-idrive .gps-al-info    { color: #3a6080; }
.gps-theme-idrive .gps-al-table-panel { border-color: #a0b8cc; }
.gps-theme-idrive .gps-al-row:hover { background: #d0e8f4 !important; }
.gps-theme-idrive .gps-al-row-active { background: #b8d8f0 !important; }
.gps-theme-idrive .gps-al-extra-row  { background: #e0eef8 !important; }
.gps-theme-idrive .gps-al-extra-td   { color: #3a6080; border-color: #a0b8cc; }
.gps-theme-idrive .gps-al-tree-hdr   { background: #d8e8f4; border-color: #a0b8cc; }
.gps-theme-idrive .gps-al-selall-lbl { color: #2a5070; }
.gps-theme-idrive .gps-tl-sel        { background: #fff; color: #1a3a50; border-color: #a0b8cc; }



/* Fullscreen mode — Alerte */
.gps-al-fullscreen {
    position: fixed !important;
    top: 0; left: 0;
    width: 100vw !important;
    height: 100vh !important;
    z-index: 10000;
    background: #0a1520;
}
.gps-al-fullscreen .gps-al-map-wrapper {
    flex: 1 1 auto !important;
}

/* ══════════════════════════════════════════════════════════════════════════════
   LOCALIZARE — Harta live (MapView=0), fara tabel, cu tracking si POI layer
   ══════════════════════════════════════════════════════════════════════════════ */

.gps-loc-root {
    display: flex;
    flex-direction: row;
    width: 100%;
    height: 100%;
    min-height: 580px;
    overflow: hidden;
    font-family: 'Segoe UI', Arial, sans-serif;
    background: #102430;
    color: #d8e4ec;
    font-size: 13px;
    box-sizing: border-box;
}
.gps-loc-root.gps-theme-idrive {
    background: #f0f4f7;
    color: #1a2530;
}

.gps-loc-map-wrapper {
    flex: 1;
    position: relative;
    min-width: 0;
    min-height: 400px;
    overflow: hidden;
}

#gps-loc-map {
    position: absolute;
    top: 0; left: 0; right: 0; bottom: 0;
    background: #0b1c28;
}

/* ── Bara tracking ───────────────────────────────────────────────────────────── */
.gps-loc-tracking-bar {
    position: absolute;
    top: 10px;
    left: 50%;
    transform: translateX(-50%);
    z-index: 1000;
    background: rgba(13,30,44,0.92);
    color: #90e0b0;
    font-size: 12px;
    padding: 6px 12px;
    border-radius: 20px;
    border: 1px solid #2a6a4a;
    display: flex;
    align-items: center;
    gap: 10px;
    white-space: nowrap;
    box-shadow: 0 2px 8px rgba(0,0,0,0.5);
}

.gps-loc-stop-btn {
    padding: 2px 8px;
    background: transparent;
    border: 1px solid #4a9a6a;
    border-radius: 10px;
    color: #90e0b0;
    font-size: 11px;
    cursor: pointer;
    transition: background 0.12s;
}
.gps-loc-stop-btn:hover { background: #1a4a30; }

/* ── Legenda in panoul stang ─────────────────────────────────────────────────── */
.gps-loc-legend {
    padding: 8px 10px;
    border-top: 1px solid #1e3a50;
    margin-top: auto;
    display: flex;
    flex-direction: column;
    gap: 4px;
    flex-shrink: 0;
}

.gps-loc-leg-item {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 11px;
    color: #90a8b8;
}

.gps-loc-leg-dot {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    flex-shrink: 0;
}

/* ── Popup butoane ───────────────────────────────────────────────────────────── */
.gps-loc-popup-btn {
    padding: 3px 10px;
    background: #1a3a50;
    border: 1px solid #2a5a70;
    border-radius: 4px;
    color: #90c8e8;
    font-size: 11px;
    cursor: pointer;
    width: 100%;
    text-align: center;
    transition: background 0.12s;
}
.gps-loc-popup-btn:hover { background: #245878; }
.gps-loc-popup-btn-stop  { border-color: #4a9a6a; color: #90e0b0; }
.gps-loc-popup-btn-stop:hover { background: #1a4a30; }

/* ── Buton ecran complet ─────────────────────────────────────────────────────── */
.gps-loc-fs-btn {
    position: absolute;
    top: 6px;
    left: 50%;
    transform: translateX(-50%);
    z-index: 800;
    background: rgba(10,30,45,0.80);
    border: none;
    color: #8fc8e8;
    font-size: 15px;
    line-height: 1;
    width: 26px;
    height: 26px;
    border-radius: 4px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0;
    transition: background 0.12s, color 0.12s;
}
.gps-loc-fs-btn:hover { background: rgba(30,70,100,0.95); color: #fff; }

/* Clasa aplicata pe #gps-loc-root cand e fullscreen */
.gps-loc-fullscreen {
    position: fixed !important;
    top: 0 !important;
    left: 0 !important;
    right: 0 !important;
    bottom: 0 !important;
    width: 100vw !important;
    height: 100vh !important;
    z-index: 9990 !important;
    margin: 0 !important;
    border-radius: 0 !important;
}

/* ── Indicator ultima actualizare ────────────────────────────────────────────── */
.gps-loc-refresh-time {
    position: absolute;
    top: 6px;
    right: 10px;
    background: rgba(10,30,45,0.80);
    color: #8fc8e8;
    font-size: 11px;
    padding: 2px 8px;
    border-radius: 4px;
    pointer-events: none;
    z-index: 800;
}

/* ── IDrive overrides ────────────────────────────────────────────────────────── */
.gps-theme-idrive .gps-loc-tracking-bar {
    background: rgba(220,238,250,0.95);
    color: #1a6a40;
    border-color: #80c0a0;
}
.gps-theme-idrive .gps-loc-stop-btn    { border-color: #60a080; color: #1a6a40; }
.gps-theme-idrive .gps-loc-stop-btn:hover { background: #c0e8d0; }
.gps-theme-idrive .gps-loc-legend      { border-color: #a0b8cc; }
.gps-theme-idrive .gps-loc-leg-item    { color: #3a5a70; }
.gps-theme-idrive .gps-loc-popup-btn   { background: #c8dce8; border-color: #90b0c4; color: #1a4060; }
.gps-theme-idrive .gps-loc-popup-btn:hover { background: #aecadc; }

/* ══════════════════════════════════════════════════════════════════════════════
   Analiza Combustibil (MapView = 6)
   ══════════════════════════════════════════════════════════════════════════════ */

/* Root layout */
.gps-ac-root {
    display: flex;
    flex-direction: row;
    width: 100%;
    height: 100%;
    overflow: hidden;
    background: #0a1820;
    color: #c8dce8;
    font-size: 13px;
}

/* Right panel */
.gps-ac-main {
    flex: 1;
    display: flex;
    flex-direction: column;
    min-width: 0;
    overflow: hidden;
}

/* ── Toolbar ─────────────────────────────────────────────────────────────────── */
.gps-ac-toolbar {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 6px;
    padding: 6px 10px;
    background: #0d1e2c;
    border-bottom: 1px solid #1e3a50;
    flex-shrink: 0;
}

/* Primary / secondary action buttons */
.gps-btn-primary {
    padding: 4px 14px;
    background: #1a6090;
    border: 1px solid #2a80b0;
    border-radius: 4px;
    color: #d8eef8;
    font-size: 13px;
    cursor: pointer;
    white-space: nowrap;
}
.gps-btn-primary:hover { background: #226090; }

.gps-btn-secondary {
    padding: 4px 10px;
    background: #102030;
    border: 1px solid #2a4a60;
    border-radius: 4px;
    color: #8ab4cc;
    font-size: 13px;
    cursor: pointer;
    white-space: nowrap;
}
.gps-btn-secondary:hover { background: #1a3040; }

/* Zoom control */
.gps-ac-zoom-wrap {
    display: inline-flex;
    align-items: center;
    gap: 3px;
    margin-left: 4px;
}
.gps-ac-zoom-lbl {
    min-width: 46px;
    text-align: center;
    font-size: 12px;
    color: #8ab4cc;
}

/* ── Totals ──────────────────────────────────────────────────────────────────── */
.gps-ac-totals {
    display: flex;
    flex-direction: row;
    flex-wrap: wrap;
    gap: 6px;
    padding: 6px 10px;
    background: #0d1e2c;
    border-bottom: 1px solid #1e3a50;
    flex-shrink: 0;
}

.gps-ac-total-box {
    display: flex;
    flex-direction: column;
    align-items: center;
    min-width: 90px;
    padding: 4px 10px;
    background: #0a2535;
    border: 1px solid #1e3a50;
    border-radius: 5px;
}
.gps-ac-total-val {
    font-size: 18px;
    font-weight: 600;
    color: #4ab4e8;
    line-height: 1.2;
}
.gps-ac-total-lbl {
    font-size: 10px;
    color: #6a8a9a;
    text-align: center;
    margin-top: 2px;
    white-space: nowrap;
}

/* ── Series toggles ──────────────────────────────────────────────────────────── */
.gps-ac-toggles {
    display: flex;
    flex-direction: row;
    flex-wrap: wrap;
    gap: 4px;
    padding: 5px 10px;
    background: #0d1e2c;
    border-bottom: 1px solid #1e3a50;
    flex-shrink: 0;
}

.gps-ac-tog {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    padding: 3px 8px;
    background: #102030;
    border: 1px solid #2a4050;
    border-radius: 3px;
    color: #6a8a9a;
    font-size: 12px;
    cursor: pointer;
    user-select: none;
    transition: background 0.1s, color 0.1s;
}
.gps-ac-tog input[type=checkbox] { margin: 0; cursor: pointer; }
.gps-ac-tog.active {
    background: #0d2a3a;
    border-color: #2a6a8a;
    color: #8ad4f0;
}
.gps-ac-tog:hover { background: #1a3040; }

/* ── Chart container ─────────────────────────────────────────────────────────── */
.gps-ac-chart-wrap {
    flex: 1;
    position: relative;
    min-height: 0;
    padding: 8px;
    background: #0a1820;
    overflow: hidden;
}
.gps-ac-chart-wrap canvas {
    width: 100% !important;
    height: 100% !important;
}

.gps-ac-empty {
    position: absolute;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #5a8a9a;
    font-size: 14px;
    pointer-events: none;
}

/* ── IDrive theme overrides ──────────────────────────────────────────────────── */
.gps-theme-idrive .gps-ac-root        { background: #f0f6fb; color: #1a3a50; }
.gps-theme-idrive .gps-ac-toolbar     { background: #e8f0f8; border-color: #a0b8cc; }
.gps-theme-idrive .gps-ac-totals      { background: #e8f0f8; border-color: #a0b8cc; }
.gps-theme-idrive .gps-ac-toggles     { background: #e8f0f8; border-color: #a0b8cc; }
.gps-theme-idrive .gps-ac-total-box   { background: #f4f8fb; border-color: #b0c8d8; }
.gps-theme-idrive .gps-ac-total-val   { color: #1a6090; }
.gps-theme-idrive .gps-ac-total-lbl   { color: #4a6a80; }
.gps-theme-idrive .gps-ac-tog         { background: #e0eef8; border-color: #90b8cc; color: #3a5a70; }
.gps-theme-idrive .gps-ac-tog.active  { background: #c8dce8; border-color: #5090b8; color: #1a4060; }
.gps-theme-idrive .gps-ac-zoom-lbl    { color: #2a6080; }
.gps-theme-idrive .gps-ac-chart-wrap  { background: #f4f8fb; }
.gps-theme-idrive .gps-ac-empty       { color: #7a9ab0; }
.gps-theme-idrive .gps-btn-primary    { background: #2a7aaa; border-color: #4a9ac8; color: #fff; }
.gps-theme-idrive .gps-btn-primary:hover { background: #1a6090; }
.gps-theme-idrive .gps-btn-secondary  { background: #d0e4f0; border-color: #90b0c4; color: #1a4060; }
.gps-theme-idrive .gps-btn-secondary:hover { background: #b8cede; }

/* =============================================================================
   Analiza KM — MapView=13
   ============================================================================= */

/* ── Root layout (identic .gps-ac-root) ────────────────────────────────────── */
.gps-ak-root {
    display: flex;
    flex-direction: row;
    width: 100%;
    overflow: hidden;
    background: #0a1820;
    color: #c0d8e8;
    font-family: Arial, sans-serif;
    font-size: 13px;
    box-sizing: border-box;
}

/* ── Panou stanga arbore ────────────────────────────────────────────────────── */
.gps-ak-root .gps-tree-panel {
    width: 220px;
    min-width: 180px;
    max-width: 280px;
    background: #0d1e2c;
    border-right: 1px solid #1e3a50;
    overflow-y: auto;
    flex-shrink: 0;
    display: flex;
    flex-direction: column;
}

/* ── Panou drept ────────────────────────────────────────────────────────────── */
.gps-ak-main {
    flex: 1;
    display: flex;
    flex-direction: column;
    min-width: 0;
    overflow: hidden;
}

/* ── Toolbar ────────────────────────────────────────────────────────────────── */
.gps-ak-toolbar {
    display: flex;
    flex-direction: row;
    flex-wrap: wrap;
    align-items: center;
    gap: 6px;
    padding: 6px 10px;
    background: #0d1e2c;
    border-bottom: 1px solid #1e3a50;
    flex-shrink: 0;
}

/* ── Butoane sort ───────────────────────────────────────────────────────────── */
.gps-ak-sort-wrap {
    display: inline-flex;
    gap: 3px;
    margin-left: 6px;
}
.gps-ak-sort-btn {
    min-width: 50px;
}
.gps-ak-sort-btn.active {
    background: #0d2a3a;
    border-color: #2a6a8a;
    color: #8ad4f0;
}

/* ── Toggle Durata ──────────────────────────────────────────────────────────── */
.gps-ak-dur-toggle {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    padding: 3px 8px;
    background: #102030;
    border: 1px solid #2a4050;
    border-radius: 3px;
    color: #6a8a9a;
    font-size: 12px;
    cursor: pointer;
    user-select: none;
}
.gps-ak-dur-toggle input[type=checkbox] { margin: 0; cursor: pointer; }

/* ── Container grafic ───────────────────────────────────────────────────────── */
.gps-ak-chart-wrap {
    flex: 1;
    position: relative;
    min-height: 0;
    padding: 8px;
    background: #0a1820;
    overflow: hidden;
}
.gps-ak-chart-wrap canvas {
    width: 100% !important;
    height: 100% !important;
}

.gps-ak-empty {
    position: absolute;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #5a8a9a;
    font-size: 14px;
    pointer-events: none;
}

/* ── IDrive theme overrides ─────────────────────────────────────────────────── */
.gps-theme-idrive .gps-ak-root         { background: #f0f6fb; color: #1a3a50; }
.gps-theme-idrive .gps-ak-root .gps-tree-panel { background: #e8f0f8; border-color: #a0b8cc; }
.gps-theme-idrive .gps-ak-toolbar      { background: #e8f0f8; border-color: #a0b8cc; }
.gps-theme-idrive .gps-ak-chart-wrap   { background: #f4f8fb; }
.gps-theme-idrive .gps-ak-empty        { color: #7a9ab0; }
.gps-theme-idrive .gps-ak-sort-btn.active { background: #c8dce8; border-color: #5090b8; color: #1a4060; }
.gps-theme-idrive .gps-ak-dur-toggle   { background: #e0eef8; border-color: #90b8cc; color: #3a5a70; }


/* =============================================================================
   ANALIZA COSTURI — gps-costuri-*
   ============================================================================= */

/* ── Root layout ─────────────────────────────────────────────────────────────── */
.gps-costuri-root {
    display: flex;
    flex-direction: row;
    width: 100%;
    overflow: hidden;
    background: #0a1820;
    color: #c0d8e8;
    font-family: Arial, sans-serif;
    font-size: 13px;
    box-sizing: border-box;
}

/* ── Panou stanga arbore ─────────────────────────────────────────────────────── */
.gps-costuri-root .gps-tree-panel {
    width: 220px;
    min-width: 180px;
    max-width: 280px;
    background: #0d1e2c;
    border-right: 1px solid #1e3a50;
    overflow-y: auto;
    flex-shrink: 0;
    display: flex;
    flex-direction: column;
}

/* ── Panou drept ─────────────────────────────────────────────────────────────── */
.gps-costuri-main {
    flex: 1;
    display: flex;
    flex-direction: column;
    min-width: 0;
    overflow: hidden;
}

/* ── Toolbar date + navigare ─────────────────────────────────────────────────── */
.gps-costuri-toolbar {
    display: flex;
    flex-direction: row;
    flex-wrap: wrap;
    align-items: center;
    gap: 6px;
    padding: 6px 10px;
    background: #0d1e2c;
    border-bottom: 1px solid #1e3a50;
    flex-shrink: 0;
}

/* ── Bara navigare drill-down ────────────────────────────────────────────────── */
.gps-costuri-nav {
    display: flex;
    flex-direction: row;
    align-items: center;
    gap: 8px;
    padding: 4px 10px;
    background: #0d2030;
    border-bottom: 1px solid #1e3a50;
    flex-shrink: 0;
}
.gps-costuri-chart-title {
    font-size: 12px;
    color: #8ad4f0;
    font-weight: bold;
}

/* ── Toggleuri 7 serii ───────────────────────────────────────────────────────── */
.gps-costuri-toggles {
    display: flex;
    flex-direction: row;
    flex-wrap: wrap;
    gap: 4px;
    padding: 4px 10px;
    background: #0d1e2c;
    border-bottom: 1px solid #1e3a50;
    flex-shrink: 0;
}
.gps-costuri-toggle {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    padding: 2px 8px;
    background: #102030;
    border: 1px solid #2a4050;
    border-radius: 3px;
    color: #6a8a9a;
    font-size: 12px;
    cursor: pointer;
    user-select: none;
}
.gps-costuri-toggle input[type=checkbox] { margin: 0; cursor: pointer; }

/* ── Bara sortare (vizibila in modul vehicule) ───────────────────────────────── */
.gps-costuri-sort-bar {
    display: flex;
    flex-direction: row;
    flex-wrap: wrap;
    align-items: center;
    gap: 3px;
    padding: 4px 10px;
    background: #0a1820;
    border-bottom: 1px solid #1e3a50;
    flex-shrink: 0;
}
.gps-costuri-sort-label {
    color: #5a8a9a;
    font-size: 11px;
    margin-right: 4px;
}
.gps-costuri-sort-btn {
    min-width: 50px;
}
.gps-costuri-sort-btn.active {
    background: #0d2a3a;
    border-color: #2a6a8a;
    color: #8ad4f0;
}

/* ── Container grafic ────────────────────────────────────────────────────────── */
.gps-costuri-chart-wrap {
    flex: 1;
    position: relative;
    min-height: 0;
    padding: 8px;
    background: #0a1820;
    overflow: hidden;
}
.gps-costuri-chart-wrap canvas {
    width: 100% !important;
    height: 100% !important;
}
.gps-costuri-empty {
    position: absolute;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #5a8a9a;
    font-size: 14px;
    pointer-events: none;
}

/* ── Bara totaluri ───────────────────────────────────────────────────────────── */
.gps-costuri-totals {
    display: flex;
    flex-direction: row;
    flex-wrap: wrap;
    gap: 12px;
    padding: 5px 12px;
    background: #0d1e2c;
    border-top: 1px solid #1e3a50;
    flex-shrink: 0;
    font-size: 12px;
    color: #6a8a9a;
}
.gps-costuri-total-item strong {
    color: #c0d8e8;
    margin-left: 2px;
}

/* ── IDrive theme overrides ──────────────────────────────────────────────────── */
.gps-theme-idrive .gps-costuri-root         { background: #f0f6fb; color: #1a3a50; }
.gps-theme-idrive .gps-costuri-root .gps-tree-panel { background: #e8f0f8; border-color: #a0b8cc; }
.gps-theme-idrive .gps-costuri-toolbar      { background: #e8f0f8; border-color: #a0b8cc; }
.gps-theme-idrive .gps-costuri-nav          { background: #d8e8f4; border-color: #a0b8cc; }
.gps-theme-idrive .gps-costuri-chart-title  { color: #1a4070; }
.gps-theme-idrive .gps-costuri-toggles      { background: #e8f0f8; border-color: #a0b8cc; }
.gps-theme-idrive .gps-costuri-toggle       { background: #e0eef8; border-color: #90b8cc; color: #3a5a70; }
.gps-theme-idrive .gps-costuri-sort-bar     { background: #f4f8fb; border-color: #a0b8cc; }
.gps-theme-idrive .gps-costuri-sort-btn.active { background: #c8dce8; border-color: #5090b8; color: #1a4060; }
.gps-theme-idrive .gps-costuri-chart-wrap   { background: #f4f8fb; }
.gps-theme-idrive .gps-costuri-empty        { color: #7a9ab0; }
.gps-theme-idrive .gps-costuri-totals       { background: #e8f0f8; border-color: #a0b8cc; color: #3a5a70; }
.gps-theme-idrive .gps-costuri-total-item strong { color: #1a3a50; }

/* ═══════════════════════════════════════════════════════════════════════════════
   Analiza Emisii (.gps-emisii-*)
   ═══════════════════════════════════════════════════════════════════════════════ */

/* ── Root layout ─────────────────────────────────────────────────────────────── */
.gps-emisii-root {
    display: flex;
    flex-direction: row;
    width: 100%;
    overflow: hidden;
    background: #0a1820;
    color: #c0d8e8;
    font-family: Arial, sans-serif;
    font-size: 13px;
    box-sizing: border-box;
}

/* ── Panou stanga arbore ─────────────────────────────────────────────────────── */
.gps-emisii-root .gps-tree-panel {
    width: 220px;
    min-width: 180px;
    max-width: 280px;
    background: #0d1e2c;
    border-right: 1px solid #1e3a50;
    overflow-y: auto;
    flex-shrink: 0;
    display: flex;
    flex-direction: column;
    color: #c0d8e8;
}

/* ── Panou drept ─────────────────────────────────────────────────────────────── */
.gps-emisii-main {
    flex: 1;
    display: flex;
    flex-direction: column;
    min-width: 0;
    overflow: hidden;
}

/* ── Toolbar date + navigare + mod vizualizare ───────────────────────────────── */
.gps-emisii-toolbar {
    display: flex;
    flex-direction: row;
    flex-wrap: wrap;
    align-items: center;
    gap: 6px;
    padding: 6px 10px;
    background: #0d1e2c;
    border-bottom: 1px solid #1e3a50;
    flex-shrink: 0;
    color: #c0d8e8;
}
/* separator vizual intre grup date si butoanele de mod */
.gps-emisii-toolbar-sep {
    display: inline-block;
    width: 1px;
    height: 18px;
    background: #2a4a60;
    margin: 0 2px;
    align-self: center;
}
/* buton mod activ */
.gps-emisii-mode-btn.active {
    background: #0d2a3a;
    border-color: #2a6a8a;
    color: #8ad4f0;
}

/* ── Bara navigare drill-down ────────────────────────────────────────────────── */
.gps-emisii-nav {
    display: flex;
    flex-direction: row;
    align-items: center;
    gap: 8px;
    padding: 4px 10px;
    background: #0d2030;
    border-bottom: 1px solid #1e3a50;
    flex-shrink: 0;
    color: #c0d8e8;
}
.gps-emisii-chart-title {
    font-size: 12px;
    color: #8ad4f0;
    font-weight: bold;
}

/* ── Toggle Nr. Vehicule ─────────────────────────────────────────────────────── */
.gps-emisii-toggles {
    display: flex;
    flex-direction: row;
    flex-wrap: wrap;
    gap: 4px;
    padding: 4px 10px;
    background: #0d1e2c;
    border-bottom: 1px solid #1e3a50;
    flex-shrink: 0;
    color: #c0d8e8;
}
.gps-emisii-toggle {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    padding: 2px 8px;
    background: #102030;
    border: 1px solid #2a4050;
    border-radius: 3px;
    color: #8ab4c8;
    font-size: 12px;
    cursor: pointer;
    user-select: none;
}
.gps-emisii-toggle input[type=checkbox] { margin: 0; cursor: pointer; }

/* ── Bara sortare (vizibila in modul vehicule) ───────────────────────────────── */
.gps-emisii-sort-bar {
    display: flex;
    flex-direction: row;
    flex-wrap: wrap;
    align-items: center;
    gap: 3px;
    padding: 4px 10px;
    background: #0a1820;
    border-bottom: 1px solid #1e3a50;
    flex-shrink: 0;
    color: #c0d8e8;
}
.gps-emisii-sort-label {
    color: #7aacbe;
    font-size: 11px;
    margin-right: 4px;
}
.gps-emisii-sort-btn {
    min-width: 50px;
}
.gps-emisii-sort-btn.active {
    background: #0d2a3a;
    border-color: #2a6a8a;
    color: #8ad4f0;
}

/* ── Container grafic ────────────────────────────────────────────────────────── */
.gps-emisii-chart-wrap {
    flex: 1;
    position: relative;
    min-height: 0;
    padding: 8px;
    background: #0a1820;
    overflow: hidden;
}
.gps-emisii-chart-wrap canvas {
    width: 100% !important;
    height: 100% !important;
}
.gps-emisii-empty {
    position: absolute;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #5a8a9a;
    font-size: 14px;
    pointer-events: none;
}

/* ── IDrive theme overrides ──────────────────────────────────────────────────── */
.gps-theme-idrive .gps-emisii-root             { background: #f0f6fb; color: #1a3a50; }
.gps-theme-idrive .gps-emisii-root .gps-tree-panel { background: #e8f0f8; border-color: #a0b8cc; color: #1a3a50; }
.gps-theme-idrive .gps-emisii-toolbar          { background: #e8f0f8; border-color: #a0b8cc; color: #1a3a50; }
.gps-theme-idrive .gps-emisii-toolbar-sep      { background: #a0b8cc; }
.gps-theme-idrive .gps-emisii-mode-btn.active  { background: #c8dce8; border-color: #5090b8; color: #1a4060; }
.gps-theme-idrive .gps-emisii-nav              { background: #d8e8f4; border-color: #a0b8cc; color: #1a3a50; }
.gps-theme-idrive .gps-emisii-chart-title      { color: #1a4070; }
.gps-theme-idrive .gps-emisii-toggles          { background: #e8f0f8; border-color: #a0b8cc; color: #1a3a50; }
.gps-theme-idrive .gps-emisii-toggle           { background: #e0eef8; border-color: #90b8cc; color: #3a5a70; }
.gps-theme-idrive .gps-emisii-sort-bar         { background: #f4f8fb; border-color: #a0b8cc; color: #1a3a50; }
.gps-theme-idrive .gps-emisii-sort-label       { color: #3a6080; }
.gps-theme-idrive .gps-emisii-sort-btn.active  { background: #c8dce8; border-color: #5090b8; color: #1a4060; }
.gps-theme-idrive .gps-emisii-chart-wrap       { background: #f4f8fb; }
.gps-theme-idrive .gps-emisii-empty            { color: #7a9ab0; }

/* ═══ Analiza Accidente ═══════════════════════════════════════════════════════ */
.gps-acc-root {
    display: flex;
    width: 100%;
    background: #0a1820;
    color: #c0d8e8;
    overflow: hidden;
    font-size: 13px;
}
.gps-acc-root .gps-tree-panel { color: #c0d8e8; }
.gps-acc-main {
    flex: 1;
    display: flex;
    flex-direction: column;
    overflow: hidden;
    min-width: 0;
}
.gps-acc-toolbar {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 4px;
    padding: 6px 8px;
    background: #0d2030;
    border-bottom: 1px solid #1a3a50;
    color: #c0d8e8;
}
.gps-acc-toolbar-sep {
    display: inline-block;
    width: 1px;
    height: 18px;
    background: #2a4a60;
    margin: 0 4px;
}
.gps-acc-mode-btn.active {
    background: #1a4060;
    border-color: #3a7090;
    color: #e0f0ff;
}
.gps-acc-nav {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 4px 8px;
    background: #0d2030;
    border-bottom: 1px solid #1a3a50;
    color: #c0d8e8;
    min-height: 30px;
}
.gps-acc-chart-title {
    font-size: 13px;
    font-weight: bold;
    color: #7aacbe;
}
.gps-acc-toggles {
    display: flex;
    flex-wrap: wrap;
    gap: 4px;
    padding: 5px 8px;
    background: #0d2030;
    border-bottom: 1px solid #1a3a50;
    color: #8ab4c8;
}
.gps-acc-toggle {
    display: flex;
    align-items: center;
    gap: 4px;
    padding: 2px 8px;
    background: #112535;
    border: 1px solid #2a4a60;
    border-radius: 4px;
    cursor: pointer;
    font-size: 12px;
    color: #8ab4c8;
}
.gps-acc-toggle.active { background: #1a3a50; border-color: #3a6080; }
.gps-acc-sort-bar {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 4px;
    padding: 4px 8px;
    background: #091820;
    border-bottom: 1px solid #1a3a50;
    color: #7aacbe;
}
.gps-acc-sort-label { font-size: 12px; color: #7aacbe; margin-right: 4px; }
.gps-acc-sort-btn.active { background: #1a3a50; border-color: #3a6080; color: #e0f0ff; }
.gps-acc-chart-wrap {
    flex: 1;
    position: relative;
    min-height: 200px;
    padding: 8px;
    background: #0a1820;
    overflow: hidden;
}
.gps-acc-chart-wrap canvas { width: 100% !important; height: 100% !important; }
.gps-acc-empty {
    position: absolute;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #5a8a9a;
    font-size: 14px;
    pointer-events: none;
}
.gps-theme-idrive .gps-acc-root             { background: #f0f6fb; color: #1a3a50; }
.gps-theme-idrive .gps-acc-root .gps-tree-panel { background: #e8f0f8; border-color: #a0b8cc; color: #1a3a50; }
.gps-theme-idrive .gps-acc-toolbar          { background: #e8f0f8; border-color: #a0b8cc; color: #1a3a50; }
.gps-theme-idrive .gps-acc-toolbar-sep      { background: #a0b8cc; }
.gps-theme-idrive .gps-acc-mode-btn.active  { background: #c8dce8; border-color: #5090b8; color: #1a4060; }
.gps-theme-idrive .gps-acc-nav              { background: #d8e8f4; border-color: #a0b8cc; color: #1a3a50; }
.gps-theme-idrive .gps-acc-chart-title      { color: #1a4070; }
.gps-theme-idrive .gps-acc-toggles          { background: #e8f0f8; border-color: #a0b8cc; color: #1a3a50; }
.gps-theme-idrive .gps-acc-toggle           { background: #e0eef8; border-color: #90b8cc; color: #3a5a70; }
.gps-theme-idrive .gps-acc-toggle.active    { background: #c8dce8; border-color: #5090b8; color: #1a4060; }
.gps-theme-idrive .gps-acc-sort-bar         { background: #f4f8fb; border-color: #a0b8cc; color: #1a3a50; }
.gps-theme-idrive .gps-acc-sort-label       { color: #3a6080; }
.gps-theme-idrive .gps-acc-sort-btn.active  { background: #c8dce8; border-color: #5090b8; color: #1a4060; }
.gps-theme-idrive .gps-acc-chart-wrap       { background: #f4f8fb; }
.gps-theme-idrive .gps-acc-empty            { color: #7a9ab0; }

/* ── Comportament Sofer ────────────────────────────────────────────────────── */
.gps-cs-root {
    display: flex;
    width: 100%;
    background: #0a1820;
    color: #c0d8e8;
    overflow: hidden;
    font-size: 13px;
}
.gps-cs-root .gps-tree-panel { color: #c0d8e8; }
.gps-cs-main {
    flex: 1;
    display: flex;
    flex-direction: column;
    overflow: hidden;
    min-width: 0;
}
.gps-cs-toolbar {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 4px;
    padding: 6px 8px;
    background: #0d2030;
    border-bottom: 1px solid #1a3a50;
    color: #c0d8e8;
}
.gps-cs-toolbar-sep {
    display: inline-block;
    width: 1px;
    height: 18px;
    background: #2a4a60;
    margin: 0 4px;
}
.gps-cs-mode-btn.active {
    background: #1a4060;
    border-color: #3a7090;
    color: #e0f0ff;
}
.gps-cs-nav {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 4px 8px;
    background: #0d2030;
    border-bottom: 1px solid #1a3a50;
    color: #c0d8e8;
    min-height: 30px;
}
.gps-cs-chart-title {
    font-size: 13px;
    font-weight: bold;
    color: #7aacbe;
}
.gps-cs-toggles {
    display: flex;
    flex-wrap: wrap;
    gap: 4px;
    padding: 5px 8px;
    background: #0d2030;
    border-bottom: 1px solid #1a3a50;
    color: #8ab4c8;
}
.gps-cs-toggle {
    display: flex;
    align-items: center;
    gap: 4px;
    padding: 2px 8px;
    background: #112535;
    border: 1px solid #2a4a60;
    border-radius: 4px;
    cursor: pointer;
    font-size: 12px;
    color: #8ab4c8;
}
.gps-cs-sort-bar {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 4px;
    padding: 4px 8px;
    background: #091820;
    border-bottom: 1px solid #1a3a50;
    color: #7aacbe;
}
.gps-cs-sort-label { font-size: 12px; color: #7aacbe; margin-right: 4px; }
.gps-cs-sort-btn.active { background: #1a3a50; border-color: #3a6080; color: #e0f0ff; }
.gps-cs-sort-dir { background: #112535; border-color: #2a4a60; color: #8ab4c8; }
.gps-cs-chart-wrap {
    flex: 1;
    position: relative;
    min-height: 200px;
    padding: 8px;
    background: #0a1820;
    overflow: hidden;
}
.gps-cs-chart-wrap canvas { width: 100% !important; height: 100% !important; }
.gps-cs-empty {
    position: absolute;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #5a8a9a;
    font-size: 14px;
    pointer-events: none;
}
.gps-theme-idrive .gps-cs-root             { background: #f0f6fb; color: #1a3a50; }
.gps-theme-idrive .gps-cs-root .gps-tree-panel { background: #e8f0f8; border-color: #a0b8cc; color: #1a3a50; }
.gps-theme-idrive .gps-cs-toolbar          { background: #e8f0f8; border-color: #a0b8cc; color: #1a3a50; }
.gps-theme-idrive .gps-cs-toolbar-sep      { background: #a0b8cc; }
.gps-theme-idrive .gps-cs-mode-btn.active  { background: #c8dce8; border-color: #5090b8; color: #1a4060; }
.gps-theme-idrive .gps-cs-nav              { background: #d8e8f4; border-color: #a0b8cc; color: #1a3a50; }
.gps-theme-idrive .gps-cs-chart-title      { color: #1a4070; }
.gps-theme-idrive .gps-cs-toggles          { background: #e8f0f8; border-color: #a0b8cc; color: #1a3a50; }
.gps-theme-idrive .gps-cs-toggle           { background: #e0eef8; border-color: #90b8cc; color: #3a5a70; }
.gps-theme-idrive .gps-cs-sort-bar         { background: #f4f8fb; border-color: #a0b8cc; color: #1a3a50; }
.gps-theme-idrive .gps-cs-sort-label       { color: #3a6080; }
.gps-theme-idrive .gps-cs-sort-btn.active  { background: #c8dce8; border-color: #5090b8; color: #1a4060; }
.gps-theme-idrive .gps-cs-sort-dir         { background: #e0eef8; border-color: #90b8cc; color: #3a5a70; }
.gps-theme-idrive .gps-cs-chart-wrap       { background: #f4f8fb; }
.gps-theme-idrive .gps-cs-empty            { color: #7a9ab0; }

/* ── Scoring ────────────────────────────────────────────────────────────────── */
.gps-sc-root {
    display: flex;
    flex-direction: row;
    width: 100%;
    overflow: hidden;
    background: #0a1820;
    color: #c0d8e8;
    font-family: Arial, sans-serif;
    font-size: 13px;
    box-sizing: border-box;
}
.gps-sc-root .gps-tree-panel {
    width: 220px;
    min-width: 180px;
    max-width: 280px;
    background: #0d1e2c;
    border-right: 1px solid #1e3a50;
    color: #c0d8e8;
    overflow-y: auto;
    flex-shrink: 0;
    display: flex;
    flex-direction: column;
}
.gps-sc-main {
    flex: 1;
    display: flex;
    flex-direction: column;
    overflow: hidden;
    min-width: 0;
}
.gps-sc-toolbar {
    display: flex;
    flex-direction: row;
    flex-wrap: wrap;
    align-items: center;
    gap: 6px;
    padding: 6px 10px;
    background: #0d1e2c;
    border-bottom: 1px solid #1e3a50;
    color: #c0d8e8;
    flex-shrink: 0;
}
.gps-sc-mode-btn.active { background: #1a4a7a; border-color: #4a90d9; color: #d0e8ff; }
.gps-sc-nav {
    display: flex;
    flex-direction: row;
    align-items: center;
    gap: 8px;
    padding: 4px 10px;
    background: #0d2030;
    border-bottom: 1px solid #1a3a50;
    color: #c0d8e8;
    flex-shrink: 0;
}
.gps-sc-chart-title { color: #8ad4f0; font-weight: bold; font-size: 12px; }
.gps-sc-view-bar {
    display: flex;
    align-items: center;
    gap: 4px;
    padding: 4px 10px;
    background: #0d1e2c;
    border-bottom: 1px solid #1e3a50;
    color: #c0d8e8;
    flex-shrink: 0;
}
.gps-sc-view-label { color: #7090a8; margin-right: 4px; font-size: 12px; }
.gps-sc-view-btn.active { background: #1a4a7a; border-color: #4a90d9; color: #d0e8ff; }
.gps-sc-sort-bar {
    display: flex;
    align-items: center;
    gap: 4px;
    padding: 4px 10px;
    background: #0d2030;
    border-bottom: 1px solid #1a3a50;
    color: #c0d8e8;
    flex-shrink: 0;
}
.gps-sc-sort-label { color: #7090a8; margin-right: 4px; font-size: 12px; }
.gps-sc-sort-btn.active { background: #1a4a7a; border-color: #4a90d9; color: #d0e8ff; }
.gps-sc-sort-dir { background: #1e2a40; border-color: #2a4060; color: #a0c8e8; }
.gps-sc-pies-area {
    flex: 1;
    overflow-y: auto;
    padding: 8px;
    background: #0a1820;
    color: #c0d8e8;
}
.gps-sc-pies-row {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    justify-content: center;
    padding: 8px 0;
}
.gps-sc-pie-wrap {
    display: flex;
    flex-direction: column;
    align-items: center;
    flex: 1 1 160px;
    max-width: 220px;
    min-width: 140px;
    background: #0d1e2c;
    border: 1px solid #1e3a50;
    border-radius: 6px;
    padding: 8px;
    color: #c0d8e8;
}
.gps-sc-pie-title {
    font-size: 11px;
    font-weight: bold;
    color: #8ad4f0;
    margin-bottom: 6px;
    text-align: center;
    white-space: nowrap;
}
.gps-sc-pie-wrap canvas { max-width: 100%; }
.gps-sc-chart-wrap {
    flex: 1;
    overflow: hidden;
    padding: 8px;
    position: relative;
    min-height: 300px;
    background: #0a1820;
}
.gps-sc-chart-wrap canvas { width: 100% !important; height: 100% !important; }
.gps-sc-empty {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #5a7a9a;
    font-size: 14px;
    padding: 40px;
    background: #0a1820;
}
.gps-theme-idrive .gps-sc-root             { background: #f0f6fb; color: #1a3a50; }
.gps-theme-idrive .gps-sc-root .gps-tree-panel { width: 220px; background: #e8f0f8; border-color: #a0b8cc; color: #1a3a50; }
.gps-theme-idrive .gps-sc-toolbar          { background: #e8f0f8; border-color: #a0b8cc; color: #1a3a50; }
.gps-theme-idrive .gps-sc-mode-btn.active  { background: #c8dce8; border-color: #5090b8; color: #1a4060; }
.gps-theme-idrive .gps-sc-nav              { background: #d8e8f4; border-color: #a0b8cc; color: #1a3a50; }
.gps-theme-idrive .gps-sc-chart-title      { color: #1a4070; }
.gps-theme-idrive .gps-sc-view-bar         { background: #e8f0f8; border-color: #a0b8cc; color: #1a3a50; }
.gps-theme-idrive .gps-sc-view-label       { color: #3a6080; }
.gps-theme-idrive .gps-sc-view-btn.active  { background: #c8dce8; border-color: #5090b8; color: #1a4060; }
.gps-theme-idrive .gps-sc-sort-bar         { background: #f4f8fb; border-color: #a0b8cc; color: #1a3a50; }
.gps-theme-idrive .gps-sc-sort-label       { color: #3a6080; }
.gps-theme-idrive .gps-sc-sort-btn.active  { background: #c8dce8; border-color: #5090b8; color: #1a4060; }
.gps-theme-idrive .gps-sc-sort-dir         { background: #e0eef8; border-color: #90b8cc; color: #3a5a70; }
.gps-theme-idrive .gps-sc-pies-area        { background: #f4f8fb; color: #1a3a50; }
.gps-theme-idrive .gps-sc-pie-wrap         { background: #e8f0f8; border-color: #a0b8cc; color: #1a3a50; }
.gps-theme-idrive .gps-sc-pie-title        { color: #1a4070; }
.gps-theme-idrive .gps-sc-chart-wrap       { background: #f4f8fb; }
.gps-theme-idrive .gps-sc-empty            { background: #f4f8fb; color: #7a9ab0; }

/* ── Statistici ──────────────────────────────────────────────────────────────── */
.gps-stat-root {
    display: flex;
    flex-direction: row;
    width: 100%;
    overflow: hidden;
    background: #0a1820;
    color: #c0d8e8;
    font-family: Arial, sans-serif;
    font-size: 13px;
    box-sizing: border-box;
}
.gps-stat-root .gps-tree-panel {
    width: 220px;
    min-width: 180px;
    max-width: 280px;
    background: #0d1e2c;
    border-right: 1px solid #1e3a50;
    color: #c0d8e8;
    overflow-y: auto;
    flex-shrink: 0;
    display: flex;
    flex-direction: column;
}
.gps-stat-main {
    flex: 1;
    display: flex;
    flex-direction: column;
    overflow: hidden;
    min-width: 0;
}
.gps-stat-toolbar {
    display: flex;
    flex-direction: row;
    flex-wrap: wrap;
    align-items: center;
    gap: 6px;
    padding: 6px 10px;
    background: #0d1e2c;
    border-bottom: 1px solid #1e3a50;
    color: #c0d8e8;
    flex-shrink: 0;
}
.gps-stat-mode-btn.active { background: #1a4a7a; border-color: #4a90d9; color: #d0e8ff; }
.gps-stat-toggles {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 6px 14px;
    padding: 5px 10px;
    background: #0d2030;
    border-bottom: 1px solid #1a3a50;
    color: #c0d8e8;
    flex-shrink: 0;
}
.gps-stat-toggle {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    padding: 2px 8px;
    background: #102030;
    border: 1px solid #2a4050;
    border-radius: 3px;
    font-size: 12px;
    cursor: pointer;
    color: #c0d8e8;
    user-select: none;
}
.gps-stat-toggle input[type=checkbox] { margin: 0; cursor: pointer; }
.gps-stat-sort-bar {
    display: flex;
    align-items: center;
    gap: 4px;
    padding: 4px 10px;
    background: #0d2030;
    border-bottom: 1px solid #1a3a50;
    color: #c0d8e8;
    flex-shrink: 0;
}
.gps-stat-sort-label { color: #7090a8; margin-right: 4px; font-size: 12px; }
.gps-stat-sort-btn.active { background: #1a4a7a; border-color: #4a90d9; color: #d0e8ff; }
.gps-stat-sort-dir { background: #1e2a40; border-color: #2a4060; color: #a0c8e8; }
.gps-stat-nav {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 4px 10px;
    background: #0d2030;
    border-bottom: 1px solid #1a3a50;
    color: #c0d8e8;
    flex-shrink: 0;
}
.gps-stat-nav-title { color: #8ad4f0; font-weight: bold; font-size: 12px; }
.gps-stat-gauges-row {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    padding: 8px 10px;
    background: #0a1820;
    border-bottom: 1px solid #1e3a50;
    flex-shrink: 0;
}
.gps-stat-gauge-box {
    display: flex;
    flex-direction: column;
    align-items: center;
    flex: 1 1 90px;
    min-width: 80px;
    max-width: 130px;
    background: #0d1e2c;
    border: 1px solid #1e3a50;
    border-radius: 5px;
    padding: 6px 8px;
    color: #c0d8e8;
}
.gps-stat-gauge-val {
    font-size: 14px;
    font-weight: bold;
    color: #8ad4f0;
    white-space: nowrap;
}
.gps-stat-gauge-lbl {
    font-size: 10px;
    color: #6090a8;
    text-align: center;
    margin-top: 2px;
}
.gps-stat-chart-wrap {
    flex: 1;
    overflow: hidden;
    padding: 8px;
    position: relative;
    min-height: 200px;
    background: #0a1820;
}
.gps-stat-chart-wrap canvas { width: 100% !important; height: 100% !important; }
.gps-stat-empty {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #5a7a9a;
    font-size: 14px;
    padding: 40px;
    background: #0a1820;
}
/* IDrive overrides */
.gps-theme-idrive .gps-stat-root             { background: #f0f6fb; color: #1a3a50; }
.gps-theme-idrive .gps-stat-root .gps-tree-panel { width: 220px; background: #e8f0f8; border-color: #a0b8cc; color: #1a3a50; }
.gps-theme-idrive .gps-stat-toolbar          { background: #e8f0f8; border-color: #a0b8cc; color: #1a3a50; }
.gps-theme-idrive .gps-stat-mode-btn.active  { background: #c8dce8; border-color: #5090b8; color: #1a4060; }
.gps-theme-idrive .gps-stat-toggles         { background: #f0f6fb; border-color: #a0b8cc; color: #1a3a50; }
.gps-theme-idrive .gps-stat-toggle          { background: #e0eef8; border-color: #90b8cc; color: #3a5a70; }
.gps-theme-idrive .gps-stat-sort-bar        { background: #f4f8fb; border-color: #a0b8cc; color: #1a3a50; }
.gps-theme-idrive .gps-stat-sort-label      { color: #3a6080; }
.gps-theme-idrive .gps-stat-sort-btn.active { background: #c8dce8; border-color: #5090b8; color: #1a4060; }
.gps-theme-idrive .gps-stat-sort-dir        { background: #e0eef8; border-color: #90b8cc; color: #3a5a70; }
.gps-theme-idrive .gps-stat-nav             { background: #e8f0f8; border-color: #a0b8cc; color: #1a3a50; }
.gps-theme-idrive .gps-stat-nav-title       { color: #1a4070; }
.gps-theme-idrive .gps-stat-gauges-row      { background: #f4f8fb; border-color: #a0b8cc; }
.gps-theme-idrive .gps-stat-gauge-box       { background: #e8f0f8; border-color: #a0b8cc; color: #1a3a50; }
.gps-theme-idrive .gps-stat-gauge-val       { color: #1a4070; }
.gps-theme-idrive .gps-stat-gauge-lbl       { color: #3a6080; }
.gps-theme-idrive .gps-stat-chart-wrap      { background: #f4f8fb; }

/* =============================================================================
   Foaie de Parcurs — stiluri pentru view-ul RptFoaieParcurs Leaflet
   ============================================================================= */

.gps-fp-root {
    display: flex;
    flex-direction: row;
    width: 100%;
    min-height: 500px;
    overflow: hidden;
    font-family: 'Segoe UI', Arial, sans-serif;
    color: #d8e4ec;
    font-size: 13px;
    box-sizing: border-box;
}

.gps-fp-main {
    display: flex;
    flex-direction: column;
    flex: 1;
    min-width: 0;
    min-height: 0;
    overflow: hidden;
}

/* ── Toolbar ──────────────────────────────────────────────────────────────── */
.gps-fp-toolbar {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 6px;
    padding: 6px 10px;
    background: #0d1e2c;
    border-bottom: 1px solid #1e3a50;
    flex-shrink: 0;
}

.gps-fp-info {
    font-size: 11px;
    color: #6a9ab8;
    margin-left: 6px;
}

.gps-fp-export-btn {
    background: #123a20;
    border-color: #2a6a35;
    color: #60cc80;
}
.gps-fp-export-btn:hover { background: #1a5230; }

/* ── Map ──────────────────────────────────────────────────────────────────── */
.gps-fp-map-wrapper {
    flex: 3;
    position: relative;
    min-height: 200px;
    background: #0d1e2c;
}

#gps-fp-map {
    width: 100%;
    height: 100%;
}

/* ── Fullscreen mode ──────────────────────────────────────────────────────── */
.gps-fp-root.gps-fp-fs {
    position: fixed !important;
    top: 0 !important;
    left: 0 !important;
    width: 100vw !important;
    height: 100vh !important;
    z-index: 9990;
    margin: 0 !important;
    border-radius: 0 !important;
}

/* ── Bottom panel: trips table ────────────────────────────────────────────── */
.gps-fp-bottom {
    flex: 2;
    display: flex;
    flex-direction: column;
    min-height: 140px;
    max-height: 280px;
    background: #0a1e2d;
    border-top: 1px solid #1e4060;
    overflow: hidden;
}

.gps-fp-segs-panel {
    display: flex;
    flex-direction: column;
    flex: 1;
    overflow: hidden;
    min-width: 0;
}

.gps-fp-segs {
    flex: 1;
    overflow-y: auto;
    overflow-x: auto;
}

/* ── Table ────────────────────────────────────────────────────────────────── */
.gps-fp-seg-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 11px;
    color: #c8dce8;
}
.gps-fp-seg-table th {
    position: sticky;
    top: 0;
    background: #0d2235;
    color: #6a9ab8;
    font-weight: 600;
    text-align: left;
    padding: 4px 6px;
    border-bottom: 1px solid #1e4060;
    white-space: nowrap;
}
.gps-fp-seg-row {
    cursor: pointer;
    transition: background 0.12s;
}
.gps-fp-seg-row:hover    { background: #0d2235; }
.gps-fp-seg-row.selected { background: #0a3a1a; color: #80ee80; }
.gps-fp-seg-row.selected .gps-fp-seg-time { color: #80ee80; }
.gps-fp-seg-row.selected .gps-fp-seg-dur  { color: #80ee80; }
.gps-fp-seg-row td {
    padding: 3px 6px;
    border-bottom: 1px solid #122030;
    vertical-align: top;
}
.gps-fp-seg-nr   { color: #6a9ab8; text-align: center; width: 28px; }
.gps-fp-seg-time { white-space: nowrap; color: #a0c8e0; }
.gps-fp-seg-addr {
    max-width: 200px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}
.gps-fp-seg-dur  { white-space: nowrap; color: #e8c060; text-align: right; }
.gps-fp-seg-total td { background: #071828; }

.gps-fp-no-data {
    color: #4a7090;
    font-size: 12px;
    padding: 12px 8px;
    text-align: center;
}

/* ── IDrive theme overrides ───────────────────────────────────────────────── */
.gps-theme-idrive .gps-fp-toolbar    { background: #e8f0f8; border-color: #a0b8cc; }
.gps-theme-idrive .gps-fp-map-wrapper { background: #e0ecf8; }
.gps-theme-idrive .gps-fp-info       { color: #3a6080; }
.gps-theme-idrive .gps-fp-bottom     { background: #e8f0f8; border-color: #a0b8cc; }
.gps-theme-idrive .gps-fp-seg-table  { color: #1a3a60; }
.gps-theme-idrive .gps-fp-seg-table th { background: #c8dce8; color: #2a5070; border-color: #a0b8cc; }
.gps-theme-idrive .gps-fp-seg-row:hover { background: #c0d8ec; }
.gps-theme-idrive .gps-fp-seg-row.selected { background: #b0d8b8; color: #1a5a20; }
.gps-theme-idrive .gps-fp-seg-nr     { color: #3a6080; }
.gps-theme-idrive .gps-fp-seg-time   { color: #1a4060; }
.gps-theme-idrive .gps-fp-seg-dur    { color: #805010; }
.gps-theme-idrive .gps-fp-no-data    { color: #6090b0; }
.gps-theme-idrive .gps-stat-empty           { background: #f4f8fb; color: #7a9ab0; }

/* ── RptFoaieParcurs — harta Leaflet inline in RadGrid nested view ─────────── */
.gps-rpt-inline-map-wrap {
    width: 100%;
    padding: 4px 0;
}
.gps-rpt-inline-map {
    width: 100%;
    height: 490px;
    background: #1e2a38;
}

/* ── TraseePopup — fereastra dedicata "Afisare Trasee" ──────────────────────── */
#gps-tp-root {
    display: flex;
    flex-direction: column;
    overflow: hidden;
    background: #1a2530;
}
#gps-tp-map {
    flex: 1;
    min-height: 0;
}
.gps-tp-status {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    background: rgba(26,37,48,0.92);
    color: #c8d8e8;
    padding: 12px 24px;
    border-radius: 6px;
    font-size: 13px;
    z-index: 1000;
    pointer-events: none;
}
.gps-tp-bottom {
    height: 200px;
    flex-shrink: 0;
    display: flex;
    flex-direction: row;
    border-top: 1px solid #2a4060;
    background: #14202c;
}
.gps-tp-panel {
    flex: 1;
    display: flex;
    flex-direction: column;
    overflow: hidden;
    min-width: 0;
}
.gps-tp-panel + .gps-tp-panel {
    border-left: 1px solid #2a4060;
}
.gps-tp-chart {
    flex: 1;
    min-height: 0;
    overflow: hidden;
}
.gps-tp-segs {
    flex: 1;
    overflow-y: auto;
}
.gps-tp-tbl {
    width: 100%;
    border-collapse: collapse;
    font-size: 11px;
    color: #c8d8e8;
}
.gps-tp-tbl th {
    background: #1e3a50;
    color: #8ab8d8;
    font-weight: normal;
    padding: 4px 6px;
    text-align: left;
    position: sticky;
    top: 0;
}
.gps-tp-tbl td {
    padding: 4px 6px;
    border-bottom: 1px solid #1e2d3a;
}
.gps-tp-seg-row:hover td { background: #1e3a50; }
.gps-tp-addr { max-width: 180px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.gps-tp-start-num {
    width: 22px; height: 22px; border-radius: 50%; border: 2px solid;
    display: flex; align-items: center; justify-content: center;
    font-size: 11px; font-weight: bold; color: #fff;
    box-shadow: 0 1px 4px rgba(0,0,0,0.6);
}
.gps-tp-marker {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 22px;
    height: 22px;
    border-radius: 50%;
    background: rgba(255,255,255,0.9);
    box-shadow: 0 1px 4px rgba(0,0,0,0.5);
}
.gps-tp-arrow {
    font-size: 13px;
    color: #e53935;
    display: inline-block;
    line-height: 1;
}
