.driver-active .driver-overlay,.driver-active *{pointer-events:none}.driver-active .driver-active-element,.driver-active .driver-active-element *,.driver-popover,.driver-popover *{pointer-events:auto}@keyframes animate-fade-in{0%{opacity:0}to{opacity:1}}.driver-fade .driver-overlay{animation:animate-fade-in .2s ease-in-out}.driver-fade .driver-popover{animation:animate-fade-in .2s}.driver-popover{all:unset;box-sizing:border-box;color:#2d2d2d;margin:0;padding:15px;border-radius:5px;min-width:250px;max-width:300px;box-shadow:0 1px 10px #0006;z-index:1000000000;position:fixed;top:0;right:0;background-color:#fff}.driver-popover *{font-family:Helvetica Neue,Inter,ui-sans-serif,"Apple Color Emoji",Helvetica,Arial,sans-serif}.driver-popover-title{font:19px/normal sans-serif;font-weight:700;display:block;position:relative;line-height:1.5;zoom:1;margin:0}.driver-popover-close-btn{all:unset;position:absolute;top:0;right:0;width:32px;height:28px;cursor:pointer;font-size:18px;font-weight:500;color:#d2d2d2;z-index:1;text-align:center;transition:color;transition-duration:.2s}.driver-popover-close-btn:hover,.driver-popover-close-btn:focus{color:#2d2d2d}.driver-popover-title[style*=block]+.driver-popover-description{margin-top:5px}.driver-popover-description{margin-bottom:0;font:14px/normal sans-serif;line-height:1.5;font-weight:400;zoom:1}.driver-popover-footer{margin-top:15px;text-align:right;zoom:1;display:flex;align-items:center;justify-content:space-between}.driver-popover-progress-text{font-size:13px;font-weight:400;color:#727272;zoom:1}.driver-popover-footer button{all:unset;display:inline-block;box-sizing:border-box;padding:3px 7px;text-decoration:none;text-shadow:1px 1px 0 #fff;background-color:#fff;color:#2d2d2d;font:12px/normal sans-serif;cursor:pointer;outline:0;zoom:1;line-height:1.3;border:1px solid #ccc;border-radius:3px}.driver-popover-footer .driver-popover-btn-disabled{opacity:.5;pointer-events:none}:not(body):has(>.driver-active-element){overflow:hidden!important}.driver-no-interaction,.driver-no-interaction *{pointer-events:none!important}.driver-popover-footer button:hover,.driver-popover-footer button:focus{background-color:#f7f7f7}.driver-popover-navigation-btns{display:flex;flex-grow:1;justify-content:flex-end}.driver-popover-navigation-btns button+button{margin-left:4px}.driver-popover-arrow{content:"";position:absolute;border:5px solid #fff}.driver-popover-arrow-side-over{display:none}.driver-popover-arrow-side-left{left:100%;border-right-color:transparent;border-bottom-color:transparent;border-top-color:transparent}.driver-popover-arrow-side-right{right:100%;border-left-color:transparent;border-bottom-color:transparent;border-top-color:transparent}.driver-popover-arrow-side-top{top:100%;border-right-color:transparent;border-bottom-color:transparent;border-left-color:transparent}.driver-popover-arrow-side-bottom{bottom:100%;border-left-color:transparent;border-top-color:transparent;border-right-color:transparent}.driver-popover-arrow-side-center{display:none}.driver-popover-arrow-side-left.driver-popover-arrow-align-start,.driver-popover-arrow-side-right.driver-popover-arrow-align-start{top:15px}.driver-popover-arrow-side-top.driver-popover-arrow-align-start,.driver-popover-arrow-side-bottom.driver-popover-arrow-align-start{left:15px}.driver-popover-arrow-align-end.driver-popover-arrow-side-left,.driver-popover-arrow-align-end.driver-popover-arrow-side-right{bottom:15px}.driver-popover-arrow-side-top.driver-popover-arrow-align-end,.driver-popover-arrow-side-bottom.driver-popover-arrow-align-end{right:15px}.driver-popover-arrow-side-left.driver-popover-arrow-align-center,.driver-popover-arrow-side-right.driver-popover-arrow-align-center{top:50%;margin-top:-5px}.driver-popover-arrow-side-top.driver-popover-arrow-align-center,.driver-popover-arrow-side-bottom.driver-popover-arrow-align-center{left:50%;margin-left:-5px}.driver-popover-arrow-none{display:none}

/* ============================================
   AutoLibs Custom Tour Styling
   ============================================ */

/* Enhanced Popover Styling */
.driver-popover {
    border-radius: 12px !important;
    padding: 20px !important;
    max-width: 340px !important;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.15), 0 4px 12px rgba(0, 0, 0, 0.1) !important;
    border: 1px solid rgba(0, 0, 0, 0.08) !important;
}

.driver-popover * {
    font-family: 'Manrope', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif !important;
}

.driver-popover-title {
    font-size: 17px !important;
    font-weight: 700 !important;
    color: #0f172a !important;
    margin-bottom: 8px !important;
}

.driver-popover-description {
    font-size: 14px !important;
    line-height: 1.6 !important;
    color: #475569 !important;
}

.driver-popover-progress-text {
    font-size: 12px !important;
    color: #94a3b8 !important;
    font-weight: 500 !important;
}

/* Enhanced Button Styling - Fix for blurry buttons */
.driver-popover-footer button {
    padding: 8px 16px !important;
    font-size: 13px !important;
    font-weight: 600 !important;
    border-radius: 8px !important;
    border: none !important;
    text-shadow: none !important;
    -webkit-font-smoothing: antialiased !important;
    -moz-osx-font-smoothing: grayscale !important;
    transform: translateZ(0) !important;
    backface-visibility: hidden !important;
}

.driver-popover-prev-btn {
    background: #f1f5f9 !important;
    color: #475569 !important;
}

.driver-popover-prev-btn:hover {
    background: #e2e8f0 !important;
    color: #1e293b !important;
}

.driver-popover-next-btn,
.driver-popover-done-btn {
    background: linear-gradient(135deg, #1e40af 0%, #6d28d9 100%) !important;
    color: white !important;
}

.driver-popover-next-btn:hover,
.driver-popover-done-btn:hover {
    box-shadow: 0 4px 12px rgba(30, 64, 175, 0.4) !important;
    transform: translateZ(0) translateY(-1px) !important;
}

/* Close Button Styling */
.driver-popover-close-btn {
    width: 28px !important;
    height: 28px !important;
    border-radius: 6px !important;
    background: #f1f5f9 !important;
    color: #64748b !important;
    font-size: 16px !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    top: 12px !important;
    right: 12px !important;
}

.driver-popover-close-btn:hover {
    background: #e2e8f0 !important;
    color: #0f172a !important;
}

/* Arrow styling */
.driver-popover-arrow {
    border-width: 8px !important;
}

/* Highlighted Element Background */
.driver-active-element {
    background: #ffffff !important;
    border-radius: 8px !important;
}

/* ============================================
   Dark Mode Support
   ============================================ */

html[data-theme="dark"] .driver-popover {
    background-color: #1e293b !important;
    border-color: #475569 !important;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.5), 0 4px 12px rgba(0, 0, 0, 0.3) !important;
}

html[data-theme="dark"] .driver-popover-title {
    color: #f8fafc !important;
}

html[data-theme="dark"] .driver-popover-description {
    color: #cbd5e1 !important;
}

html[data-theme="dark"] .driver-popover-progress-text {
    color: #64748b !important;
}

html[data-theme="dark"] .driver-popover-prev-btn {
    background: #334155 !important;
    color: #e2e8f0 !important;
}

html[data-theme="dark"] .driver-popover-prev-btn:hover {
    background: #475569 !important;
    color: #f8fafc !important;
}

html[data-theme="dark"] .driver-popover-close-btn {
    background: #334155 !important;
    color: #94a3b8 !important;
}

html[data-theme="dark"] .driver-popover-close-btn:hover {
    background: #475569 !important;
    color: #f8fafc !important;
}

html[data-theme="dark"] .driver-popover-arrow {
    border-color: #1e293b !important;
}

html[data-theme="dark"] .driver-popover-arrow-side-left {
    border-left-color: #1e293b !important;
    border-right-color: transparent !important;
    border-bottom-color: transparent !important;
    border-top-color: transparent !important;
}

html[data-theme="dark"] .driver-popover-arrow-side-right {
    border-right-color: #1e293b !important;
    border-left-color: transparent !important;
    border-bottom-color: transparent !important;
    border-top-color: transparent !important;
}

html[data-theme="dark"] .driver-popover-arrow-side-top {
    border-top-color: #1e293b !important;
    border-right-color: transparent !important;
    border-bottom-color: transparent !important;
    border-left-color: transparent !important;
}

html[data-theme="dark"] .driver-popover-arrow-side-bottom {
    border-bottom-color: #1e293b !important;
    border-left-color: transparent !important;
    border-top-color: transparent !important;
    border-right-color: transparent !important;
}

/* Dark mode highlighted element - much brighter for visibility */
html[data-theme="dark"] .driver-active-element {
    background: #f1f5f9 !important;
    box-shadow: 0 0 0 6px rgba(96, 165, 250, 0.5), 0 0 20px rgba(96, 165, 250, 0.3) !important;
}

/* Force dark text on highlighted elements in dark mode */
html[data-theme="dark"] .driver-active-element,
html[data-theme="dark"] .driver-active-element * {
    color: #1e293b !important;
}

/* Navigation links specifically need dark text on light background */
html[data-theme="dark"] .driver-active-element.nav-link,
html[data-theme="dark"] .nav-link.driver-active-element,
html[data-theme="dark"] a.nav-link.driver-active-element,
html[data-theme="dark"] .driver-active-element a,
html[data-theme="dark"] .driver-active-element .nav-link,
html[data-theme="dark"] .driver-active-element .nav-text {
    color: #1e40af !important;
    background: #f1f5f9 !important;
}

html[data-theme="dark"] .driver-active-element.nav-link .nav-icon,
html[data-theme="dark"] .nav-link.driver-active-element .nav-icon,
html[data-theme="dark"] .driver-active-element .nav-icon {
    background: #dbeafe !important;
}

html[data-theme="dark"] .driver-active-element svg,
html[data-theme="dark"] .driver-active-element.nav-link svg,
html[data-theme="dark"] .nav-link.driver-active-element svg {
    stroke: #3b82f6 !important;
}

html[data-theme="dark"] .driver-active-element .stat-value,
html[data-theme="dark"] .driver-active-element .stat-label,
html[data-theme="dark"] .driver-active-element h1,
html[data-theme="dark"] .driver-active-element h2,
html[data-theme="dark"] .driver-active-element h3,
html[data-theme="dark"] .driver-active-element p,
html[data-theme="dark"] .driver-active-element span {
    color: #1e293b !important;
}

/* Ensure nav brand is also readable */
html[data-theme="dark"] .driver-active-element.nav-brand,
html[data-theme="dark"] .nav-brand.driver-active-element,
html[data-theme="dark"] a.nav-brand.driver-active-element {
    background: #f1f5f9 !important;
}

html[data-theme="dark"] .driver-active-element.nav-brand *,
html[data-theme="dark"] .nav-brand.driver-active-element *,
html[data-theme="dark"] a.nav-brand.driver-active-element * {
    color: #1e293b !important;
}

/* Page header elements in dark mode - ensure readable text */
html[data-theme="dark"] .driver-active-element.page-header,
html[data-theme="dark"] .page-header.driver-active-element {
    background: #f1f5f9 !important;
    border-radius: 12px !important;
    padding: 1rem !important;
}

html[data-theme="dark"] .driver-active-element.page-header *,
html[data-theme="dark"] .page-header.driver-active-element *,
html[data-theme="dark"] .driver-active-element.page-header h1,
html[data-theme="dark"] .page-header.driver-active-element h1,
html[data-theme="dark"] .driver-active-element.page-header p,
html[data-theme="dark"] .page-header.driver-active-element p,
html[data-theme="dark"] .driver-active-element.page-header .header-subtitle,
html[data-theme="dark"] .page-header.driver-active-element .header-subtitle,
html[data-theme="dark"] .driver-active-element.page-header .header-content h1,
html[data-theme="dark"] .page-header.driver-active-element .header-content h1,
html[data-theme="dark"] .driver-active-element.page-header .header-content p,
html[data-theme="dark"] .page-header.driver-active-element .header-content p,
html[data-theme="dark"] .driver-active-element.page-header .header-content .header-subtitle,
html[data-theme="dark"] .page-header.driver-active-element .header-content .header-subtitle {
    color: #1e293b !important;
}

html[data-theme="dark"] .driver-active-element.page-header button,
html[data-theme="dark"] .page-header.driver-active-element button {
    color: #ffffff !important;
}

html[data-theme="dark"] .driver-active-element.page-header svg,
html[data-theme="dark"] .page-header.driver-active-element svg {
    stroke: currentColor !important;
}

/* Organisation page specific cards */
html[data-theme="dark"] .driver-active-element.org-info-card,
html[data-theme="dark"] .org-info-card.driver-active-element {
    background: #f1f5f9 !important;
}

html[data-theme="dark"] .driver-active-element.org-info-card *,
html[data-theme="dark"] .org-info-card.driver-active-element * {
    color: #1e293b !important;
}

html[data-theme="dark"] .driver-active-element.locations-grid,
html[data-theme="dark"] .locations-grid.driver-active-element {
    background: #f1f5f9 !important;
    border-radius: 12px !important;
    padding: 1rem !important;
}

html[data-theme="dark"] .driver-active-element.location-card,
html[data-theme="dark"] .location-card.driver-active-element {
    background: #ffffff !important;
    border-color: #e2e8f0 !important;
}

html[data-theme="dark"] .driver-active-element.location-card *,
html[data-theme="dark"] .location-card.driver-active-element * {
    color: #1e293b !important;
}

/* Reports page specific cards */
html[data-theme="dark"] .driver-active-element.kpi-grid,
html[data-theme="dark"] .kpi-grid.driver-active-element {
    background: #f1f5f9 !important;
    border-radius: 12px !important;
    padding: 1rem !important;
}

html[data-theme="dark"] .driver-active-element.kpi-card,
html[data-theme="dark"] .kpi-card.driver-active-element {
    background: #ffffff !important;
}

html[data-theme="dark"] .driver-active-element.kpi-card *,
html[data-theme="dark"] .kpi-card.driver-active-element * {
    color: #1e293b !important;
}

html[data-theme="dark"] .driver-active-element.two-column-grid,
html[data-theme="dark"] .two-column-grid.driver-active-element {
    background: #f1f5f9 !important;
    border-radius: 12px !important;
    padding: 1rem !important;
}

/* Reports page header */
html[data-theme="dark"] .driver-active-element.reports-header,
html[data-theme="dark"] .reports-header.driver-active-element {
    background: #f1f5f9 !important;
    border-radius: 12px !important;
    padding: 1rem !important;
}

html[data-theme="dark"] .driver-active-element.reports-header *,
html[data-theme="dark"] .reports-header.driver-active-element *,
html[data-theme="dark"] .driver-active-element.reports-header h1,
html[data-theme="dark"] .reports-header.driver-active-element h1,
html[data-theme="dark"] .driver-active-element.reports-header p,
html[data-theme="dark"] .reports-header.driver-active-element p,
html[data-theme="dark"] .driver-active-element.reports-header label,
html[data-theme="dark"] .reports-header.driver-active-element label,
html[data-theme="dark"] .driver-active-element.reports-header .header-content h1,
html[data-theme="dark"] .reports-header.driver-active-element .header-content h1,
html[data-theme="dark"] .driver-active-element.reports-header .header-content p,
html[data-theme="dark"] .reports-header.driver-active-element .header-content p {
    color: #1e293b !important;
}

html[data-theme="dark"] .driver-active-element.reports-header input,
html[data-theme="dark"] .reports-header.driver-active-element input,
html[data-theme="dark"] .driver-active-element.reports-header .date-input,
html[data-theme="dark"] .reports-header.driver-active-element .date-input {
    background: #ffffff !important;
    border-color: #e2e8f0 !important;
    color: #1e293b !important;
}

html[data-theme="dark"] .driver-active-element.reports-header button,
html[data-theme="dark"] .reports-header.driver-active-element button {
    background: linear-gradient(135deg, #1e40af 0%, #6d28d9 100%) !important;
    color: #ffffff !important;
}

/* Reports page - funnel container */
html[data-theme="dark"] .driver-active-element.funnel-container,
html[data-theme="dark"] .funnel-container.driver-active-element {
    background: #f1f5f9 !important;
    border-radius: 12px !important;
    padding: 1rem !important;
}

html[data-theme="dark"] .driver-active-element.funnel-container *,
html[data-theme="dark"] .funnel-container.driver-active-element * {
    color: #1e293b !important;
}

/* Reports page - employee list */
html[data-theme="dark"] .driver-active-element.employee-list,
html[data-theme="dark"] .employee-list.driver-active-element {
    background: #f1f5f9 !important;
    border-radius: 12px !important;
    padding: 1rem !important;
}

html[data-theme="dark"] .driver-active-element.employee-list *,
html[data-theme="dark"] .employee-list.driver-active-element * {
    color: #1e293b !important;
}

/* Reports page - service list */
html[data-theme="dark"] .driver-active-element.service-list,
html[data-theme="dark"] .service-list.driver-active-element {
    background: #f1f5f9 !important;
    border-radius: 12px !important;
    padding: 1rem !important;
}

html[data-theme="dark"] .driver-active-element.service-list *,
html[data-theme="dark"] .service-list.driver-active-element * {
    color: #1e293b !important;
}

/* Reports page - vehicle list */
html[data-theme="dark"] .driver-active-element.vehicle-list,
html[data-theme="dark"] .vehicle-list.driver-active-element {
    background: #f1f5f9 !important;
    border-radius: 12px !important;
    padding: 1rem !important;
}

html[data-theme="dark"] .driver-active-element.vehicle-list *,
html[data-theme="dark"] .vehicle-list.driver-active-element * {
    color: #1e293b !important;
}

/* Reports page - full width report section (cancellations) */
html[data-theme="dark"] .driver-active-element.report-section,
html[data-theme="dark"] .report-section.driver-active-element {
    background: #f1f5f9 !important;
    border-radius: 12px !important;
    padding: 1rem !important;
}

html[data-theme="dark"] .driver-active-element.report-section *,
html[data-theme="dark"] .report-section.driver-active-element * {
    color: #1e293b !important;
}
