@import url('https://fonts.googleapis.com/css2?family=Outfit:wght@400;500;600;700;800;900&family=Inter:wght@300;400;500;600;700&family=JetBrains+Mono:wght@400;500;700&display=swap');

:root {
    --p-color: #ff8c42;
    --p-hover: #ff7a2e;
    --s-color: #3b82f6;
    --accent-green: #10b981;
    --accent-red: #ef4444;
    --b-body: #f8fafc;
    --b-surface: #ffffff;
    --b-surface2: #f1f5f9;
    --b-board: #0f172a;
    --b-board-row: rgba(255, 255, 255, 0.04);
    --b-board-row-hover: rgba(255, 255, 255, 0.08);
    --t-main: #0f172a;
    --t-muted: #64748b;
    --t-board-main: #f8fafc;
    --t-board-muted: #94a3b8;
    --border: #e2e8f0;
    --border-glass: rgba(255, 255, 255, 0.6);
    --radius-sm: 8px;
    --radius-md: 12px;
    --radius-lg: 18px;
    --radius-xl: 24px;
    --shadow-sm: 0 2px 8px -2px rgba(15, 23, 42, 0.06);
    --shadow-md: 0 10px 25px -5px rgba(15, 23, 42, 0.08), 0 4px 10px -2px rgba(15, 23, 42, 0.04);
    --shadow-lg: 0 20px 40px -10px rgba(15, 23, 42, 0.15);
}

.agglo-lumiere-container {
    margin-top: 0px;
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
    background: var(--b-body);
    color: var(--t-main);
    display: flex;
    flex-direction: column;
    overflow: hidden;
    position: relative;
    border-radius: var(--radius-lg);
    border: 1px solid var(--border);
    box-shadow: var(--shadow-lg);
}


/* Exemple dans plugin/Agglobus/assets/css/public.css */
body.plugin-agglobus #banner,
body.plugin-agglobus .search-hero-wrapper {
    /*background: url('/theme/LumiereChild/banner-bus.jpg') no-repeat center center !important;
    background-size: cover !important;*/
    display: none;
}

body.plugin-agglobus #pageTitle {
    /*background: url('/theme/LumiereChild/banner-bus.jpg') no-repeat center center !important;
    background-size: cover !important;*/
    display: none;
}

/* --- HEADER BAR --- */
.agglo-header {
    background: rgba(255, 255, 255, 0.85);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    padding: 12px 24px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-bottom: 1px solid var(--border);
    z-index: 20;
}

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

.logo-icon {
    width: 36px;
    height: 36px;
    background: linear-gradient(135deg, var(--p-color) 0%, #ff5e36 100%);
    border-radius: 10px;
    display: grid;
    place-items: center;
    color: #fff;
    font-family: 'Outfit', sans-serif;
    font-weight: 800;
    font-size: 13px;
    box-shadow: 0 4px 12px rgba(255, 140, 66, 0.35);
}

.logo-text {
    font-family: 'Outfit', sans-serif;
    font-weight: 800;
    font-size: 18px;
    letter-spacing: -0.5px;
}

.logo-text span {
    color: var(--p-color);
}

.header-status {
    display: flex;
    align-items: center;
    gap: 14px;
}

.live-pill {
    display: flex;
    align-items: center;
    gap: 7px;
    font-family: 'Outfit', sans-serif;
    font-size: 11px;
    font-weight: 700;
    color: var(--accent-green);
    background: rgba(16, 185, 129, 0.1);
    border: 1px solid rgba(16, 185, 129, 0.25);
    padding: 5px 12px;
    border-radius: 30px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.live-dot {
    width: 7px;
    height: 7px;
    background: var(--accent-green);
    border-radius: 50%;
    box-shadow: 0 0 8px var(--accent-green);
    animation: radarPulse 1.8s infinite;
}

@keyframes radarPulse {
    0% {
        transform: scale(1);
        opacity: 1;
    }

    50% {
        transform: scale(1.4);
        opacity: 0.5;
    }

    100% {
        transform: scale(1);
        opacity: 1;
    }
}

.update-ticker {
    font-size: 11px;
    color: var(--t-muted);
    font-weight: 500;
}

/* --- TOOLBAR / CONTROLS --- */
.agglo-controls {
    padding: 10px 20px;
    background: #ffffff;
    border-bottom: 1px solid var(--border);
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    z-index: 15;
    flex-wrap: wrap;
}

.agglo-controls-left {
    display: flex;
    align-items: center;
    gap: 12px;
    flex: 1;
    min-width: 280px;
}

.drawer-toggle-btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 8px 14px;
    border-radius: var(--radius-md);
    background: var(--b-surface2);
    border: 1px solid var(--border);
    color: var(--t-main);
    font-family: 'Outfit', sans-serif;
    font-size: 13px;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.2s ease;
    flex-shrink: 0;
}

.drawer-toggle-btn:hover {
    background: #ffffff;
    border-color: var(--p-color);
    color: var(--p-color);
}

.drawer-toggle-btn.active {
    background: rgba(255, 140, 66, 0.1);
    border-color: rgba(255, 140, 66, 0.35);
    color: var(--p-color);
}

.agglo-controls-right {
    display: flex;
    align-items: center;
    gap: 10px;
    flex-shrink: 0;
}

/* --- MAP VIEW SWITCH (PLAN / SATELLITE / NUIT HORS CARTE) --- */
.map-view-switch {
    display: flex;
    background: var(--b-surface2);
    border: 1px solid var(--border);
    border-radius: var(--radius-md);
    padding: 3px;
    gap: 2px;
}

.view-switch-btn {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 6px 12px;
    background: transparent;
    border: none;
    border-radius: 8px;
    font-family: 'Outfit', sans-serif;
    font-size: 12px;
    font-weight: 700;
    color: var(--t-muted);
    cursor: pointer;
    transition: all 0.2s ease;
}

.view-switch-btn:hover {
    color: var(--t-main);
}

.view-switch-btn.active {
    background: #ffffff;
    color: var(--p-color);
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.08);
}

.view-switch-btn i {
    font-size: 12px;
}

/* --- NAVIGATION CARTE (RECENTRER / ZOOM HORS CARTE) --- */
.map-nav-tools {
    display: flex;
    align-items: center;
    gap: 6px;
}

.tool-btn-icon {
    width: 34px;
    height: 34px;
    padding: 0 !important;
    margin: 0 !important;
    border-radius: 10px;
    background: var(--b-surface2);
    border: 1px solid var(--border);
    color: var(--t-main);
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    cursor: pointer;
    font-size: 13px;
    line-height: 1 !important;
    box-sizing: border-box !important;
    transition: all 0.2s ease;
}

.tool-btn-icon i {
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    width: 100% !important;
    height: 100% !important;
    margin: 0 !important;
    padding: 0 !important;
    line-height: 1 !important;
    vertical-align: 0 !important;
}

.tool-btn-icon:hover {
    background: #ffffff;
    border-color: var(--p-color);
    color: var(--p-color);
    transform: translateY(-1px);
    box-shadow: var(--shadow-sm);
}

.tool-zoom-group {
    display: flex;
    background: var(--b-surface2);
    border: 1px solid var(--border);
    border-radius: 10px;
    overflow: hidden;
}

.tool-zoom-group .tool-btn-icon {
    border: none;
    border-radius: 0;
    background: transparent;
}

.tool-zoom-group .tool-btn-icon:first-child {
    border-right: 1px solid var(--border);
}

.tool-zoom-group .tool-btn-icon:hover {
    background: #ffffff;
    transform: none;
}

.search-box-v3 {
    flex: 1;
    display: flex;
    align-items: center;
    gap: 10px;
    background: var(--b-surface2);
    border: 1px solid transparent;
    border-radius: var(--radius-md);
    padding: 0 14px;
    transition: all 0.2s ease;
}

.search-box-v3:focus-within {
    background: #fff;
    border-color: var(--p-color);
    box-shadow: 0 0 0 3px rgba(255, 140, 66, 0.15);
}

.search-box-v3 input {
    background: none;
    border: none;
    outline: none;
    padding: 10px 0;
    width: 100%;
    font-size: 13px;
    font-weight: 500;
    color: var(--t-main);
}

.search-box-v3 input::placeholder {
    color: #94a3b8;
}

.search-box-v3 i {
    color: #94a3b8;
    font-size: 13px;
}

#clear-search {
    background: none;
    border: none;
    color: var(--t-muted);
    cursor: pointer;
    font-size: 14px;
    padding: 2px;
}

.btn-v3 {
    padding: 9px 16px;
    border-radius: var(--radius-md);
    font-family: 'Outfit', sans-serif;
    font-weight: 700;
    font-size: 13px;
    cursor: pointer;
    border: none;
    display: flex;
    align-items: center;
    gap: 8px;
    transition: all 0.2s ease;
}

.btn-v3.primary {
    background: var(--p-color);
    color: #ffffff;
    box-shadow: 0 4px 12px rgba(255, 140, 66, 0.25);
}

.btn-v3.primary:hover {
    background: var(--p-hover);
    transform: translateY(-1px);
    box-shadow: 0 6px 16px rgba(255, 140, 66, 0.35);
}

/* --- MAIN CONTAINER --- */
.agglo-main {
    display: flex;
    height: 540px;
    min-height: 480px;
    position: relative;
    overflow: hidden;
    border-bottom: 1px solid var(--border);
}

/* --- SIDEBAR GAUCHE (TIROIR RETRACTABLE) --- */
.agglo-sidebar {
    width: 340px;
    min-width: 340px;
    background: #ffffff;
    border-right: 1px solid var(--border);
    display: flex;
    flex-direction: column;
    z-index: 10;
    transition: width 0.3s cubic-bezier(0.16, 1, 0.3, 1), min-width 0.3s cubic-bezier(0.16, 1, 0.3, 1), transform 0.3s cubic-bezier(0.16, 1, 0.3, 1), opacity 0.25s ease;
    overflow: hidden;
    flex-shrink: 0;
}

.agglo-sidebar.collapsed {
    width: 0 !important;
    min-width: 0 !important;
    transform: translateX(-100%);
    opacity: 0;
    border-right: none;
    pointer-events: none;
}

.sidebar-header-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 14px 18px;
    border-bottom: 1px solid #f1f5f9;
}

.sidebar-header-actions {
    display: flex;
    align-items: center;
    gap: 6px;
}

.sidebar-title {
    font-family: 'Outfit', sans-serif;
    font-size: 12px;
    font-weight: 700;
    color: var(--t-muted);
    text-transform: uppercase;
    letter-spacing: 0.8px;
}

/* --- SEARCH RESULTS SPLIT & CARDS --- */
.search-category-title {
    font-family: 'Outfit', sans-serif;
    font-size: 11px;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.8px;
    color: var(--t-muted);
    padding: 10px 18px 6px;
    background: #f8fafc;
    border-top: 1px solid #f1f5f9;
    border-bottom: 1px solid #f1f5f9;
    display: flex;
    align-items: center;
    gap: 6px;
}

.search-stop-card {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 10px 18px;
    cursor: pointer;
    border-bottom: 1px solid #f8fafc;
    transition: all 0.2s ease;
}

.search-stop-card:hover {
    background: #f8fafc;
    transform: translateX(2px);
}

.search-stop-icon {
    width: 32px;
    height: 32px;
    border-radius: 10px;
    background: rgba(16, 185, 129, 0.12);
    color: #10b981;
    display: grid;
    place-items: center;
    font-size: 13px;
    flex-shrink: 0;
}

.btn-icon-tiny {
    background: var(--b-surface2);
    border: none;
    color: var(--p-color);
    width: 28px;
    height: 28px;
    border-radius: 50%;
    cursor: pointer;
    display: grid;
    place-items: center;
    font-size: 12px;
    transition: 0.2s;
}

.btn-icon-tiny:hover {
    background: #e2e8f0;
}

.line-card-v3 {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 18px;
    cursor: pointer;
    border-bottom: 1px solid #f8fafc;
    transition: all 0.2s ease;
    position: relative;
}

.line-card-v3:hover {
    background: #f8fafc;
}

.line-card-v3.active {
    background: rgba(255, 140, 66, 0.05);
}

.line-card-v3.active::before {
    content: '';
    position: absolute;
    left: 0;
    top: 0;
    bottom: 0;
    width: 3px;
    background: var(--lc, var(--p-color));
}

.line-badge-v3 {
    width: 36px;
    height: 36px;
    border-radius: 10px;
    background: var(--lc, var(--p-color));
    display: grid;
    place-items: center;
    color: #ffffff;
    font-family: 'Outfit', sans-serif;
    font-weight: 800;
    font-size: 14px;
    flex-shrink: 0;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.15);
}

.l-info {
    flex: 1;
    min-width: 0;
}

.l-name {
    font-weight: 600;
    font-size: 13px;
    color: var(--t-main);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.l-meta {
    font-size: 11px;
    color: var(--t-muted);
    margin-top: 1px;
}

.multi-toggle {
    margin-left: auto;
    width: 18px;
    height: 18px;
    border: 2px solid var(--border);
    border-radius: 5px;
    display: grid;
    place-items: center;
    font-size: 10px;
    transition: 0.2s;
}

.line-card-v3.active .multi-toggle {
    background: var(--p-color);
    border-color: var(--p-color);
    color: #fff;
}

/* --- CARTE & OVERLAYS --- */
.agglo-content {
    flex: 1;
    position: relative;
    overflow: hidden;
}

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

/* --- SIMULATION DU MODE NUIT (SANS CLÉ API NI FILIGRANE) --- */
#agglobus-map.map-night-mode,
.leaflet-container.map-night-mode {
    background-color: #0f172a !important;
}

.map-night-mode .leaflet-tile-pane {
    filter: brightness(0.65) invert(1) contrast(2.2) hue-rotate(205deg) saturate(0.35) brightness(0.75);
    transition: filter 0.3s ease;
}

.map-night-mode .leaflet-control-attribution {
    background: rgba(15, 23, 42, 0.85) !important;
    color: #94a3b8 !important;
    border-radius: 4px;
}

.map-night-mode .leaflet-control-attribution a {
    color: #38bdf8 !important;
}

.map-night-mode .leaflet-popup-content-wrapper {
    background: #1e293b;
    color: #f1f5f9;
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.5);
}

.map-night-mode .leaflet-popup-tip {
    background: #1e293b;
}

/* --- DETAIL PANEL SORTI DU CONTENEUR CARTE (EN DESSOUS) --- */
.detail-bottom-section,
.detail-panel-v3 {
    position: relative;
    width: 100%;
    margin-top: 24px;
    margin-bottom: 40px;
    background: #ffffff;
    border-radius: var(--radius-lg);
    border: 1px solid var(--border);
    display: flex;
    flex-direction: column;
    overflow: hidden;
    box-shadow: var(--shadow-lg);
    animation: fadeInSlideUp 0.3s ease-out;
    z-index: 5;
}

.detail-bottom-section.hidden,
.detail-panel-v3.hidden {
    display: none !important;
}

@keyframes fadeInSlideUp {
    from {
        opacity: 0;
        transform: translateY(12px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.detail-header {
    padding: 20px 28px;
    display: flex;
    align-items: center;
    gap: 16px;
    border-bottom: 1px solid #f1f5f9;
    background: #ffffff;
}

.detail-badge {
    width: 44px;
    height: 44px;
    border-radius: 12px;
    background: var(--lc, var(--p-color));
    display: grid;
    place-items: center;
    color: #fff;
    font-family: 'Outfit', sans-serif;
    font-weight: 800;
    font-size: 16px;
    flex-shrink: 0;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.12);
}

.detail-titles {
    flex: 1;
    min-width: 0;
}

.detail-titles h3 {
    font-size: 16px;
    font-family: 'Outfit', sans-serif;
    font-weight: 800;
    color: var(--t-main);
    letter-spacing: -0.3px;
    margin: 0 0 2px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.detail-direction {
    font-size: 12px;
    color: var(--t-muted);
    font-weight: 500;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

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

.header-action-btn {
    width: 34px;
    height: 34px;
    padding: 0 !important;
    margin: 0 !important;
    border-radius: 10px;
    background: var(--b-surface2);
    border: 1px solid var(--border);
    cursor: pointer;
    color: var(--t-muted);
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    font-size: 13px;
    line-height: 1 !important;
    box-sizing: border-box !important;
    transition: all 0.2s ease;
}

.header-action-btn i {
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    width: 100% !important;
    height: 100% !important;
    margin: 0 !important;
    padding: 0 !important;
    line-height: 1 !important;
    vertical-align: 0 !important;
}

.header-action-btn.switch-dir:hover {
    background: #e0f2fe;
    border-color: #bae6fd;
    color: #0284c7;
    transform: translateY(-1px);
}

.header-action-btn.close-detail-btn:hover {
    background: #fee2e2;
    border-color: #fca5a5;
    color: #ef4444;
    transform: translateY(-1px);
}

/* ONGLETS DU PANNEAU */
.detail-tabs {
    display: flex;
    background: var(--b-surface2);
    padding: 5px;
    border-radius: 12px;
    margin: 14px 28px 16px;
    gap: 6px;
}

.tab-btn {
    flex: 1;
    border: none;
    background: none;
    padding: 9px 12px;
    border-radius: 8px;
    font-size: 12px;
    font-weight: 700;
    color: var(--t-muted);
    cursor: pointer;
    font-family: 'Outfit', sans-serif;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    transition: all 0.2s ease;
    white-space: nowrap;
}

.tab-btn.active {
    background: #ffffff;
    color: var(--p-color);
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.06);
}

.tab-body {
    padding: 0 28px 28px;
}

.tab-pane {
    display: none;
}

.tab-pane.active {
    display: block;
    animation: fadeInSlide 0.25s ease-out;
}

@keyframes fadeInSlide {
    from {
        opacity: 0;
        transform: translateY(4px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* ==========================================================================
   BANDEAU DES CORRESPONDANCES (TRANSFER HUB)
   ========================================================================== */
.transfer-hub {
    background: linear-gradient(135deg, rgba(255, 140, 66, 0.06) 0%, rgba(59, 130, 246, 0.06) 100%);
    border: 1px solid rgba(255, 140, 66, 0.15);
    border-radius: var(--radius-md);
    padding: 14px 18px;
    margin: 16px 28px 10px;
}

.transfer-hub-label {
    font-family: 'Outfit', sans-serif;
    font-size: 10px;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.8px;
    color: var(--t-muted);
    margin-bottom: 8px;
    display: flex;
    align-items: center;
    gap: 6px;
}

.transfer-pills-row {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
}

.transfer-pill {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    background: #ffffff;
    border: 1px solid var(--border);
    padding: 4px 10px;
    border-radius: 20px;
    font-size: 12px;
    font-weight: 700;
    color: var(--t-main);
    cursor: pointer;
    box-shadow: var(--shadow-sm);
    transition: all 0.2s ease;
}

.transfer-pill:hover {
    transform: translateY(-1px);
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.1);
}

.transfer-pill.active {
    background: var(--p-color);
    border-color: var(--p-color);
    color: #ffffff;
}

.transfer-pill-badge {
    width: 20px;
    height: 20px;
    border-radius: 6px;
    background: var(--pill-color, var(--p-color));
    color: #fff;
    display: grid;
    place-items: center;
    font-size: 10px;
    font-weight: 900;
}

/* ==========================================================================
   GRAND TABLEAU DES DÉPARTS (STATION DEPARTURE BOARD)
   ========================================================================== */
.station-board {
    background: var(--b-board);
    border-radius: var(--radius-md);
    padding: 14px;
    color: var(--t-board-main);
    box-shadow: 0 10px 30px rgba(15, 23, 42, 0.2);
    border: 1px solid rgba(255, 255, 255, 0.08);
    margin-bottom: 12px;
}

.board-top-bar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding-bottom: 10px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    margin-bottom: 8px;
}

.board-title {
    font-family: 'Outfit', sans-serif;
    font-size: 11px;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 1px;
    color: #38bdf8;
    display: flex;
    align-items: center;
    gap: 7px;
}

.board-live-indicator {
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: var(--accent-green);
    box-shadow: 0 0 8px var(--accent-green);
    animation: radarPulse 1.5s infinite;
}

.board-clock {
    font-family: 'JetBrains Mono', monospace;
    font-size: 11px;
    font-weight: 700;
    color: #94a3b8;
}

.board-columns-header {
    display: grid;
    grid-template-columns: 46px 1fr 58px 74px;
    gap: 8px;
    padding: 6px 8px;
    font-family: 'Outfit', sans-serif;
    font-size: 10px;
    font-weight: 800;
    color: var(--t-board-muted);
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.board-rows {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.board-row {
    display: grid;
    grid-template-columns: 46px 1fr 58px 74px;
    gap: 8px;
    align-items: center;
    padding: 8px;
    border-radius: 8px;
    background: var(--b-board-row);
    transition: all 0.2s ease;
    cursor: pointer;
}

.board-row:hover {
    background: var(--b-board-row-hover);
    transform: translateX(2px);
}

.board-line-tag {
    width: 32px;
    height: 24px;
    border-radius: 6px;
    background: var(--lc, var(--p-color));
    color: #ffffff;
    display: grid;
    place-items: center;
    font-family: 'Outfit', sans-serif;
    font-weight: 800;
    font-size: 12px;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
}

.board-destination {
    min-width: 0;
}

.board-dest-name {
    font-size: 12px;
    font-weight: 600;
    color: #ffffff;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.board-sched-time {
    font-family: 'JetBrains Mono', monospace;
    font-size: 12px;
    font-weight: 600;
    color: #38bdf8;
}

.board-countdown {
    text-align: right;
}

.countdown-pill {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 3px 7px;
    border-radius: 6px;
    font-family: 'Outfit', sans-serif;
    font-size: 11px;
    font-weight: 800;
    white-space: nowrap;
}

.countdown-pill.approaching {
    background: rgba(16, 185, 129, 0.2);
    color: #34d399;
    border: 1px solid rgba(16, 185, 129, 0.4);
    animation: radarPulse 2s infinite;
}

.countdown-pill.soon {
    background: rgba(245, 158, 11, 0.15);
    color: #fbbf24;
    border: 1px solid rgba(245, 158, 11, 0.3);
}

.countdown-pill.normal {
    background: rgba(148, 163, 184, 0.12);
    color: #cbd5e1;
}

/* ==========================================================================
   GRILLE HORAIRE COMPLÈTE (TOUTE LA JOURNÉE)
   ========================================================================== */
.all-day-cta-btn {
    width: 100%;
    margin-top: 10px;
    padding: 10px 14px;
    background: var(--b-surface2);
    border: 1px dashed var(--border);
    border-radius: 10px;
    font-size: 12px;
    font-weight: 600;
    color: var(--p-color);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    transition: 0.2s;
}

.all-day-cta-btn:hover {
    background: #fff;
    border-color: var(--p-color);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
}

.sched-filters {
    display: flex;
    gap: 6px;
    overflow-x: auto;
    padding-bottom: 8px;
    margin-bottom: 12px;
    scrollbar-width: thin;
}

.sched-filter-btn {
    border: 1px solid var(--border);
    background: var(--b-surface2);
    padding: 4px 10px;
    border-radius: 20px;
    font-size: 11px;
    font-weight: 600;
    cursor: pointer;
    white-space: nowrap;
    transition: 0.2s;
}

.sched-filter-btn:hover {
    background: #fff;
}

.sched-filter-btn.active {
    background: var(--p-color);
    border-color: var(--p-color);
    color: #fff;
}

.sched-hour-block {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    padding: 8px 0;
    border-bottom: 1px solid #f1f5f9;
}

.sched-hour-badge {
    font-family: 'Outfit', sans-serif;
    font-weight: 800;
    font-size: 12px;
    color: var(--t-muted);
    min-width: 36px;
    padding-top: 4px;
}

.sched-hour-pills {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    flex: 1;
}

.sched-pill {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    padding: 3px 8px;
    background: var(--b-surface2);
    border-radius: 6px;
    font-size: 11px;
    font-weight: 600;
}

.sched-pill.upcoming-soon {
    background: rgba(16, 185, 129, 0.12);
    border: 1px solid #10b981;
    color: #065f46;
}

.sched-pill-line {
    font-size: 9px;
    font-weight: 800;
    padding: 1px 5px;
    border-radius: 4px;
}

/* ==========================================================================
   TIMELINE ITINÉRAIRE
   ========================================================================== */
.v3-timeline {
    position: relative;
    padding-left: 20px;
    margin-top: 6px;
}

.v3-timeline::before {
    content: '';
    position: absolute;
    left: 5px;
    top: 12px;
    bottom: 12px;
    width: 2px;
    background: #e2e8f0;
}

.stop-v3 {
    position: relative;
    padding: 9px 0;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 12px;
    transition: all 0.2s;
}

.stop-v3-dot {
    position: absolute;
    left: -20px;
    top: 15px;
    width: 12px;
    height: 12px;
    border-radius: 50%;
    border: 2px solid #cbd5e1;
    background: #ffffff;
    z-index: 1;
    transition: all 0.2s;
}

.stop-v3:hover .stop-v3-dot {
    border-color: var(--p-color);
    background: var(--p-color);
    transform: scale(1.15);
}

.stop-v3.active .stop-v3-dot {
    background: var(--accent-green);
    border-color: var(--accent-green);
    box-shadow: 0 0 0 4px rgba(16, 185, 129, 0.2);
}

.stop-v3.active span {
    font-weight: 800;
    color: var(--accent-green);
}

.stop-v3-name {
    font-size: 13px;
    font-weight: 500;
}

/* ==========================================================================
   MARQUEURS DE BUS SUR LA CARTE
   ========================================================================== */
.bus-marker-icon {
    display: flex !important;
    align-items: center;
    justify-content: center;
    transition: transform 5s linear !important;
    z-index: 1000 !important;
}

.leaflet-zoom-anim .bus-marker-icon,
.leaflet-pan-anim .bus-marker-icon,
.leaflet-drag-anim .bus-marker-icon {
    transition: none !important;
}

.bus-dot {
    width: 28px;
    height: 28px;
    border-radius: 50%;
    border: 2.5px solid white;
    color: white;
    font-family: 'Outfit', sans-serif;
    font-size: 11px;
    font-weight: 900;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.35);
    cursor: pointer;
    pointer-events: auto;
    transition: transform 0.2s;
}

.bus-dot:hover {
    transform: scale(1.2);
}

.hidden {
    display: none !important;
}

.scrollable {
    flex: 1;
    overflow-y: auto;
    scrollbar-width: thin;
    scrollbar-color: #cbd5e1 transparent;
}

/* ==========================================================================
   RESPONSIVE DESIGN (MOBILE & TABLETTE)
   ========================================================================== */
@media (max-width: 1000px) {
    .agglo-sidebar {
        width: 300px;
    }
}

@media (max-width: 768px) {
    .agglo-lumiere-container {
        border-radius: 16px;
    }

    .agglo-header {
        padding: 10px 14px;
    }

    .header-status {
        display: none;
    }

    .agglo-controls {
        padding: 10px 14px;
        flex-direction: column;
        align-items: stretch;
        gap: 8px;
    }

    .agglo-controls-left {
        width: 100%;
        min-width: 0;
    }

    .agglo-controls-right {
        width: 100%;
        justify-content: space-between;
    }

    .view-switch-btn span {
        display: none;
    }

    .btn-v3 {
        justify-content: center;
        width: 100%;
    }

    .agglo-main {
        height: 420px;
        position: relative;
    }

    /* agglo-sidebar mobile handled via bottom sheet at bottom of css */

    .detail-bottom-section,
    .detail-panel-v3 {
        width: 100%;
        position: relative;
    }

    .detail-tabs {
        margin: 10px 14px 12px;
        overflow-x: auto;
    }

    .tab-body {
        padding: 0 14px 20px;
    }

    .detail-header {
        padding: 14px;
    }
}
/* ==========================================================================
   MARQUEUR GPS POINT BLEU PULSANT (Google / Apple Maps standard)
   ========================================================================== */
.user-gps-marker-container {
    background: transparent !important;
    border: none !important;
}

.user-gps-pulse-marker {
    position: relative;
    width: 24px;
    height: 24px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.user-gps-dot {
    width: 14px;
    height: 14px;
    background: #0284c7;
    border: 2.5px solid #ffffff;
    border-radius: 50%;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.4);
    z-index: 2;
}

.user-gps-ring {
    position: absolute;
    width: 32px;
    height: 32px;
    border-radius: 50%;
    background: rgba(2, 132, 199, 0.3);
    animation: userGpsPulseAnim 2s infinite ease-out;
    z-index: 1;
}

@keyframes userGpsPulseAnim {
    0% { transform: scale(0.5); opacity: 1; }
    100% { transform: scale(2.2); opacity: 0; }
}

/* ==========================================================================
   AGGLOBUS - FAVORIS, BOTTOM SHEET MOBILE & ANIMATION BUS
   ========================================================================== */

/* Animation fluide du bus le long des rues */
.bus-marker-icon {
    transition: transform 4.8s cubic-bezier(0.25, 1, 0.5, 1) !important;
}

.bus-dot {
    box-shadow: 0 3px 8px rgba(0,0,0,0.3);
    animation: busPulse 2s infinite ease-in-out;
}

@keyframes busPulse {
    0%, 100% { transform: scale(1); }
    50% { transform: scale(1.08); }
}

/* Bouton Favori Etoile */
.btn-fav-star {
    background: transparent;
    border: none;
    cursor: pointer;
    color: #cbd5e1;
    font-size: 1.15rem;
    padding: 6px;
    border-radius: 8px;
    transition: all 0.2s ease;
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

.btn-fav-star:hover {
    color: #f59e0b;
    transform: scale(1.15);
}

.btn-fav-star.active {
    color: #f59e0b;
}

/* Onglets de filtrage dans la sidebar */
.agglo-sidebar-tabs {
    display: flex;
    background: #f1f5f9;
    border-radius: 10px;
    padding: 3px;
    margin: 10px 14px;
    gap: 4px;
}

.sidebar-tab-btn {
    flex: 1;
    border: none;
    background: transparent;
    padding: 7px 10px;
    font-size: 0.85rem;
    font-weight: 600;
    color: #64748b;
    border-radius: 8px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    transition: all 0.2s ease;
}

.sidebar-tab-btn.active {
    background: #ffffff;
    color: #0f172a;
    box-shadow: 0 1px 4px rgba(0,0,0,0.08);
}

.fav-badge {
    background: #f59e0b;
    color: #ffffff;
    font-size: 0.7rem;
    padding: 1px 6px;
    border-radius: 999px;
    font-weight: 700;
}

/* Bottom Sheet mobile */
@media (max-width: 768px) {
    .agglo-sheet-backdrop {
        position: fixed !important;
        top: 0 !important;
        left: 0 !important;
        right: 0 !important;
        bottom: 0 !important;
        background: rgba(15, 23, 42, 0.6) !important;
        backdrop-filter: blur(4px) !important;
        -webkit-backdrop-filter: blur(4px) !important;
        z-index: 99998 !important;
        opacity: 0 !important;
        pointer-events: none !important;
        transition: opacity 0.3s ease !important;
    }

    .agglo-sheet-backdrop.active {
        opacity: 1 !important;
        pointer-events: auto !important;
    }

    .agglo-sheet-handle-bar {
        display: flex !important;
        justify-content: center !important;
        align-items: center !important;
        padding: 12px 0 8px !important;
        cursor: pointer !important;
        background: #ffffff !important;
        border-radius: 24px 24px 0 0 !important;
        border-bottom: 1px solid #f1f5f9 !important;
        touch-action: none !important;
    }

    .agglo-sheet-handle {
        width: 48px;
        height: 5px;
        border-radius: 999px;
        background: #cbd5e1;
    }

    .agglo-sidebar {
        position: fixed !important;
        left: 0 !important;
        right: 0 !important;
        bottom: 0 !important;
        top: auto !important;
        width: 100% !important;
        max-width: 100% !important;
        height: 75vh !important;
        max-height: 75vh !important;
        z-index: 99999 !important;
        background: #ffffff !important;
        border-radius: 24px 24px 0 0 !important;
        box-shadow: 0 -12px 40px rgba(0, 0, 0, 0.35) !important;
        transform: translateY(105%) !important;
        transition: transform 0.35s cubic-bezier(0.16, 1, 0.3, 1), opacity 0.2s ease !important;
        opacity: 0 !important;
        pointer-events: none !important;
        display: flex !important;
        flex-direction: column !important;
        border: none !important;
    }

    .agglo-sidebar.sheet-open {
        transform: translateY(0) !important;
        opacity: 1 !important;
        pointer-events: auto !important;
    }
}

@media (min-width: 769px) {
    .agglo-sheet-backdrop { display: none !important; }
    .agglo-sheet-handle-bar { display: none !important; }
}
