/* Deliverate Premium Slate Stylesheet */

:root {
    --bg-color: #0f1015;
    --card-bg: #161720;
    --card-border: rgba(255, 255, 255, 0.08);
    --input-bg: #1d1e2a;
    --text-primary: #f5f6fa;
    --text-secondary: #a0a5c0;
    --color-primary: #00adb5;
    --color-primary-glow: rgba(0, 173, 181, 0.25);
    --color-lab: #ff5722;
    --color-lab-glow: rgba(255, 87, 34, 0.25);
    --color-courier: #4caf50;
    --color-courier-glow: rgba(76, 175, 80, 0.25);
    --color-danger: #e53935;
    --color-warning: #fb8c00;
    --color-info: #1e88e5;
    --shadow-sm: 0 4px 6px -1px rgba(0, 0, 0, 0.2), 0 2px 4px -1px rgba(0, 0, 0, 0.14);
    --shadow-md: 0 8px 16px -2px rgba(0, 0, 0, 0.3), 0 4px 8px -2px rgba(0, 0, 0, 0.2);
    --font-sans: 'Outfit', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
    --border-radius-sm: 8px;
    --border-radius-md: 16px;
    --border-radius-lg: 24px;
}

* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

body {
    background-color: var(--bg-color);
    color: var(--text-primary);
    font-family: var(--font-sans);
    line-height: 1.5;
    -webkit-font-smoothing: antialiased;
    overflow-x: hidden;
}

/* Scrollbar styles */
::-webkit-scrollbar {
    width: 8px;
    height: 8px;
}
::-webkit-scrollbar-track {
    background: var(--bg-color);
}
::-webkit-scrollbar-thumb {
    background: #2a2c3d;
    border-radius: 4px;
}
::-webkit-scrollbar-thumb:hover {
    background: #3c3f58;
}

/* Helpers */
.d-none {
    display: none !important;
}
.text-muted {
    color: var(--text-secondary) !important;
}
.color-success {
    color: var(--color-courier) !important;
}
.color-danger {
    color: var(--color-danger) !important;
}
.font-orange {
    color: var(--color-lab) !important;
}
.btn-block {
    width: 100%;
}

/* Screens control */
.screen {
    display: none;
    opacity: 0;
    transition: opacity 0.3s ease;
    min-height: 100vh;
}
.screen.active {
    display: block;
    opacity: 1;
}

/* 1. LOGIN SCREEN */
#login-screen {
    justify-content: center;
    align-items: center;
    background: radial-gradient(circle at top right, rgba(0, 173, 181, 0.08), transparent 45%),
                radial-gradient(circle at bottom left, rgba(255, 87, 34, 0.05), transparent 40%),
                var(--bg-color);
}
#login-screen.active {
    display: flex;
}

.login-card {
    background: rgba(22, 23, 32, 0.7);
    border: 1px solid var(--card-border);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    width: 100%;
    max-width: 440px;
    padding: 40px 32px;
    border-radius: var(--border-radius-lg);
    box-shadow: var(--shadow-md);
    margin: 20px;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}
.login-card:hover {
    box-shadow: 0 12px 24px -4px rgba(0, 173, 181, 0.15);
    transform: translateY(-2px);
}

.login-header {
    text-align: center;
    margin-bottom: 32px;
}
.login-header .logo-icon {
    font-size: 54px;
    color: var(--color-primary);
    text-shadow: 0 0 15px var(--color-primary-glow);
    margin-bottom: 12px;
    animation: pulseGlow 2.5s infinite ease-in-out;
}
.login-header h1 {
    font-weight: 800;
    font-size: 32px;
    letter-spacing: -0.5px;
    color: var(--text-primary);
    margin-bottom: 8px;
    background: linear-gradient(135deg, var(--text-primary) 30%, #a0c4ff 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}
.login-header p {
    color: var(--text-secondary);
    font-size: 14px;
    font-weight: 400;
}

.form-group {
    margin-bottom: 20px;
}
.form-group label {
    display: block;
    font-size: 13px;
    font-weight: 600;
    color: var(--text-secondary);
    margin-bottom: 8px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.role-selector-pills {
    display: flex;
    gap: 8px;
    background: var(--input-bg);
    padding: 6px;
    border-radius: var(--border-radius-md);
    border: 1px solid rgba(255, 255, 255, 0.05);
}

.role-pill {
    flex: 1;
    display: flex !important;
    flex-direction: column !important;
    align-items: center !important;
    justify-content: center !important;
    padding: 12px 4px;
    border-radius: var(--border-radius-sm);
    cursor: pointer;
    transition: all 0.25s ease;
    color: var(--text-secondary);
    position: relative;
    text-align: center;
    border: 1px solid transparent;
}
.role-pill input[type="radio"] {
    position: absolute;
    opacity: 0;
    width: 0;
    height: 0;
}
.role-pill span.material-symbols-outlined {
    font-size: 22px;
    margin-bottom: 6px;
    display: block;
}
.role-pill span:not(.material-symbols-outlined) {
    font-size: 11px;
    font-weight: 600;
    display: block;
    white-space: nowrap;
}
.role-pill.active {
    background: var(--card-bg);
    color: var(--color-primary);
    box-shadow: var(--shadow-sm);
    border: 1px solid rgba(0, 173, 181, 0.25);
}
.role-pill:hover:not(.active) {
    color: var(--text-primary);
    background: rgba(255, 255, 255, 0.02);
}

.form-control {
    width: 100%;
    background-color: var(--input-bg);
    border: 1px solid rgba(255, 255, 255, 0.08);
    color: var(--text-primary);
    padding: 12px 16px;
    font-size: 15px;
    border-radius: var(--border-radius-md);
    outline: none;
    font-family: var(--font-sans);
    transition: all 0.2s ease;
}
.form-control:focus {
    border-color: var(--color-primary);
    box-shadow: 0 0 0 3px var(--color-primary-glow);
}
select.form-control {
    appearance: none;
    background-image: url("data:image/svg+xml;utf8,<svg fill='%23ffffff' height='24' viewBox='0 0 24 24' width='24' xmlns='http://www.w3.org/2000/svg'><path d='M7 10l5 5 5-5z'/><path d='M0 0h24v24H0z' fill='none'/></svg>");
    background-repeat: no-repeat;
    background-position: right 12px center;
    padding-right: 40px;
}

.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    font-family: var(--font-sans);
    font-weight: 600;
    font-size: 14px;
    padding: 12px 24px;
    border-radius: var(--border-radius-md);
    border: none;
    cursor: pointer;
    transition: all 0.25s ease;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}
.btn-primary {
    background-color: var(--color-primary);
    color: #121214;
    box-shadow: 0 4px 12px var(--color-primary-glow);
}
.btn-primary:hover {
    background-color: #00c2cb;
    box-shadow: 0 6px 16px rgba(0, 173, 181, 0.4);
    transform: translateY(-1px);
}
.btn-primary:active {
    transform: translateY(0);
}
.btn-secondary {
    background-color: rgba(255, 255, 255, 0.08);
    color: var(--text-primary);
    border: 1px solid rgba(255, 255, 255, 0.1);
}
.btn-secondary:hover {
    background-color: rgba(255, 255, 255, 0.12);
    border-color: rgba(255, 255, 255, 0.2);
}
.btn-success {
    background-color: var(--color-courier);
    color: #121214;
    box-shadow: 0 4px 12px var(--color-courier-glow);
}
.btn-success:hover {
    background-color: #5ec162;
}
.btn-warning {
    background-color: var(--color-warning);
    color: #121214;
    box-shadow: 0 4px 12px rgba(251, 140, 0, 0.25);
}
.btn-warning:hover {
    background-color: #ffa01a;
}
.btn-lg {
    padding: 16px 28px;
    font-size: 15px;
}

/* 2. MAIN APP SCREEN Layout */
.top-bar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: rgba(22, 23, 32, 0.8);
    border-bottom: 1px solid var(--card-border);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    padding: 12px 24px;
    position: sticky;
    top: 0;
    z-index: 100;
}

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

.logo-badge {
    background-color: var(--color-primary-glow);
    border-radius: 50%;
    width: 38px;
    height: 38px;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 1px solid rgba(0, 173, 181, 0.2);
}
.logo-badge span {
    color: var(--color-primary);
    font-size: 20px;
}

.header-titles h2 {
    font-size: 16px;
    font-weight: 800;
    color: var(--color-primary);
    line-height: 1.2;
}
.header-titles span {
    font-size: 11px;
    color: var(--text-secondary);
    font-weight: 500;
}

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

.icon-button {
    background: transparent;
    border: none;
    color: var(--text-secondary);
    width: 38px;
    height: 38px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.2s ease;
}
.icon-button span {
    font-size: 22px;
}
.icon-button:hover {
    background-color: rgba(255, 255, 255, 0.05);
    color: var(--text-primary);
}
.icon-button.active {
    color: var(--color-primary);
}
.icon-button.logout {
    color: var(--color-danger);
}
.icon-button.logout:hover {
    background-color: rgba(229, 57, 53, 0.1);
}

.notification-bell-container {
    position: relative;
    cursor: pointer;
}
.notification-bell-container .badge {
    position: absolute;
    top: -2px;
    right: -2px;
    background-color: var(--color-danger);
    color: white;
    font-size: 10px;
    font-weight: 700;
    min-width: 16px;
    height: 16px;
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0 4px;
    border: 2px solid var(--card-bg);
}

.app-container {
    width: 100%;
    max-width: 840px;
    margin: 0 auto;
    padding: 16px 20px 60px 20px;
}

/* Admin Tabs Row */
.role-tabs-bar {
    display: flex;
    background: var(--card-bg);
    border: 1px solid var(--card-border);
    border-radius: var(--border-radius-md);
    margin-bottom: 20px;
    overflow: hidden;
}
.role-tab {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    background: transparent;
    border: none;
    color: var(--text-secondary);
    padding: 14px 10px;
    cursor: pointer;
    font-family: var(--font-sans);
    font-weight: 500;
    font-size: 12px;
    transition: all 0.2s ease;
}
.role-tab span.material-symbols-outlined {
    font-size: 18px;
}
.role-tab.active {
    background-color: rgba(255, 255, 255, 0.03);
    color: var(--color-primary);
    font-weight: 700;
    border-bottom: 2px solid var(--color-primary);
}
.role-tab:hover:not(.active) {
    color: var(--text-primary);
    background-color: rgba(255, 255, 255, 0.01);
}

/* 3. MAP CONTAINER */
.map-section {
    margin-bottom: 24px;
}
.map-section .section-title {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 8px;
}
.pulse-indicator {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background-color: var(--color-primary);
    box-shadow: 0 0 0 0 var(--color-primary-glow);
    animation: indicatorPulse 1.5s infinite;
}
.map-section h3 {
    font-size: 13px;
    font-weight: 700;
    color: var(--text-secondary);
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.map-wrapper {
    position: relative;
    width: 100%;
    height: 240px;
    background-color: rgba(22, 23, 32, 0.5);
    border: 1px solid var(--card-border);
    border-radius: var(--border-radius-lg);
    overflow: hidden;
    box-shadow: var(--shadow-sm);
}

#map-canvas {
    width: 100%;
    height: 100%;
    display: block;
}

/* Map Overlays */
.map-overlay-lab {
    position: absolute;
    top: 12px;
    right: 12px;
    background: rgba(22, 23, 32, 0.85);
    border: 1px solid rgba(255, 87, 34, 0.25);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    border-radius: var(--border-radius-md);
    padding: 6px 12px;
    display: flex;
    align-items: center;
    gap: 8px;
    max-width: 180px;
    box-shadow: var(--shadow-sm);
}
.map-overlay-lab .marker-icon {
    color: var(--color-lab);
    font-size: 18px;
}
.overlay-text {
    display: flex;
    flex-direction: column;
}
.overlay-text strong {
    font-size: 11px;
    font-weight: 700;
    color: var(--text-primary);
}
.overlay-text span {
    font-size: 8px;
    color: var(--text-secondary);
    white-space: nowrap;
}

.map-overlay-tracking {
    position: absolute;
    bottom: 8px;
    left: 8px;
    right: 8px;
    background: rgba(22, 23, 32, 0.9);
    border: 1px solid rgba(0, 173, 181, 0.2);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    border-radius: var(--border-radius-md);
    padding: 10px 14px;
    box-shadow: var(--shadow-md);
    animation: slideUp 0.3s ease;
}

.tracking-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 6px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
    padding-bottom: 6px;
}
.tracking-title {
    display: flex;
    align-items: center;
    gap: 6px;
}
.tracking-title span {
    color: var(--color-primary);
    font-size: 16px;
}
.tracking-title h4 {
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.status-badge {
    font-size: 9px;
    font-weight: 700;
    padding: 3px 8px;
    border-radius: 6px;
    text-transform: uppercase;
}
.status-badge.pending {
    background-color: rgba(255, 255, 255, 0.1);
    color: var(--text-secondary);
}
.status-badge.assigned {
    background-color: rgba(251, 140, 0, 0.15);
    color: var(--color-warning);
}
.status-badge.picked_up {
    background-color: rgba(0, 173, 181, 0.15);
    color: var(--color-primary);
}
.status-badge.delivered {
    background-color: rgba(76, 175, 80, 0.15);
    color: var(--color-courier);
}

.tracking-body {
    display: flex;
    justify-content: space-between;
    align-items: center;
}
.tracking-details {
    display: flex;
    flex-direction: column;
    gap: 2px;
}
.tracking-details strong {
    font-size: 12px;
    font-weight: 600;
}
.tracking-details span {
    font-size: 10px;
    color: var(--text-secondary);
    white-space: nowrap;
    text-overflow: ellipsis;
    overflow: hidden;
    max-width: 280px;
}

.tracking-distance {
    display: flex;
    flex-direction: column;
    align-items: flex-end;
}
.tracking-distance span {
    font-size: 15px;
    font-weight: 800;
    color: var(--color-primary);
}
.tracking-distance small {
    font-size: 8px;
    color: var(--text-secondary);
    text-transform: uppercase;
}

.map-overlay-standby {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    background: rgba(22, 23, 32, 0.8);
    border: 1px solid var(--card-border);
    border-radius: var(--border-radius-sm);
    padding: 6px 14px;
    font-size: 10px;
    font-weight: 500;
    color: var(--text-secondary);
    text-align: center;
    box-shadow: var(--shadow-sm);
}

/* 4. CARDS & PANELS */
.panel-tab-content {
    display: none;
    flex-direction: column;
    gap: 16px;
}
.panel-tab-content.active {
    display: flex;
}

.card {
    background-color: var(--card-bg);
    border: 1px solid var(--card-border);
    border-radius: var(--border-radius-md);
    padding: 20px;
    box-shadow: var(--shadow-sm);
}

.card-header-simple {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 16px;
}
.card-header-simple span {
    font-size: 20px;
}
.card-header-simple .icon-primary {
    color: var(--color-primary);
}
.card-header-simple h4 {
    font-size: 14px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

/* Client Identity Box */
.verified-session-box {
    display: flex;
    align-items: center;
    gap: 10px;
    background: rgba(0, 173, 181, 0.06);
    border: 1px solid rgba(0, 173, 181, 0.15);
    border-radius: var(--border-radius-md);
    padding: 12px 16px;
    margin-bottom: 12px;
}
.verified-session-box span {
    color: var(--color-primary);
    font-size: 24px;
}
.verified-text strong {
    display: block;
    font-size: 13px;
    font-weight: 700;
    color: var(--color-primary);
}
.verified-text span {
    font-size: 10px;
    color: var(--text-secondary);
}

.clinic-details-info {
    font-size: 12px;
    color: var(--text-primary);
    margin-bottom: 14px;
}
.clinic-details-info p {
    margin-bottom: 4px;
}

.subscription-status-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: rgba(255, 255, 255, 0.02);
    border-radius: var(--border-radius-md);
    padding: 10px 14px;
    border: 1px solid rgba(255, 255, 255, 0.03);
}
.sub-info {
    display: flex;
    align-items: center;
    gap: 10px;
}
.sub-info span {
    font-size: 20px;
}
.sub-text strong {
    display: block;
    font-size: 12px;
    font-weight: 700;
}
.sub-text span {
    font-size: 10px;
    color: var(--text-secondary);
}

.badge {
    font-size: 10px;
    font-weight: 700;
    padding: 4px 10px;
    border-radius: var(--border-radius-sm);
    text-transform: uppercase;
}
.badge.active {
    background-color: rgba(76, 175, 80, 0.15);
    color: var(--color-courier);
    border: 1px solid rgba(76, 175, 80, 0.25);
}
.badge.expired {
    background-color: rgba(229, 57, 53, 0.15);
    color: var(--color-danger);
    border: 1px solid rgba(229, 57, 53, 0.25);
}

/* Sample type Selection Chips */
.chips-container {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-top: 4px;
}
.chip {
    background-color: var(--input-bg);
    border: 1px solid rgba(255, 255, 255, 0.06);
    color: var(--text-secondary);
    font-family: var(--font-sans);
    font-size: 11px;
    font-weight: 600;
    padding: 8px 14px;
    border-radius: var(--border-radius-sm);
    cursor: pointer;
    transition: all 0.2s ease;
}
.chip:hover {
    color: var(--text-primary);
    background-color: rgba(255, 255, 255, 0.02);
}
.chip.active {
    background-color: var(--color-primary-glow);
    color: var(--color-primary);
    border-color: rgba(0, 173, 181, 0.3);
}

/* Priority Pills */
.priority-container {
    display: flex;
    gap: 8px;
}
.prio-btn {
    flex: 1;
    background-color: var(--input-bg);
    border: 1px solid transparent;
    color: var(--text-secondary);
    font-family: var(--font-sans);
    font-weight: 700;
    font-size: 11px;
    padding: 10px 4px;
    border-radius: var(--border-radius-md);
    cursor: pointer;
    transition: all 0.25s ease;
}
.prio-btn.prio-normal.active {
    background-color: rgba(30, 136, 229, 0.12);
    color: var(--color-info);
    border-color: rgba(30, 136, 229, 0.3);
}
.prio-btn.prio-alta.active {
    background-color: rgba(251, 140, 0, 0.12);
    color: var(--color-warning);
    border-color: rgba(251, 140, 0, 0.3);
}
.prio-btn.prio-urgente.active {
    background-color: rgba(229, 57, 53, 0.12);
    color: var(--color-danger);
    border-color: rgba(229, 57, 53, 0.3);
}

/* Custom Checkbox */
.checkbox-container {
    display: flex;
    align-items: center;
    position: relative;
    padding-left: 28px;
    cursor: pointer;
    font-size: 12px;
    font-weight: 500;
    user-select: none;
}
.checkbox-container input {
    position: absolute;
    opacity: 0;
    cursor: pointer;
    height: 0;
    width: 0;
}
.checkmark {
    position: absolute;
    top: 50%;
    left: 0;
    transform: translateY(-50%);
    height: 18px;
    width: 18px;
    background-color: var(--input-bg);
    border: 1px solid rgba(255, 255, 255, 0.15);
    border-radius: 4px;
    transition: all 0.2s ease;
}
.checkbox-container:hover input ~ .checkmark {
    border-color: var(--color-primary);
}
.checkbox-container input:checked ~ .checkmark {
    background-color: var(--color-primary);
    border-color: var(--color-primary);
}
.checkmark:after {
    content: "";
    position: absolute;
    display: none;
}
.checkbox-container input:checked ~ .checkmark:after {
    display: block;
}
.checkbox-container .checkmark:after {
    left: 5px;
    top: 2px;
    width: 4px;
    height: 8px;
    border: solid #121214;
    border-width: 0 2px 2px 0;
    transform: rotate(45deg);
}

.custom-pickup-panel {
    background: rgba(255, 255, 255, 0.02);
    border: 1px solid rgba(255, 255, 255, 0.04);
    border-radius: var(--border-radius-md);
    padding: 14px;
    margin-bottom: 12px;
    animation: fadeIn 0.25s ease;
}
.form-row {
    display: flex;
    gap: 12px;
}
.form-row .col {
    flex: 1;
}

.presets-section {
    margin-top: 8px;
}
.presets-section span {
    font-size: 10px;
    color: var(--text-secondary);
    font-weight: 700;
    text-transform: uppercase;
}
.assist-chips {
    display: flex;
    gap: 6px;
    margin-top: 4px;
}
.assist-chip {
    background: var(--input-bg);
    border: 1px solid rgba(255, 255, 255, 0.08);
    color: var(--text-secondary);
    font-family: var(--font-sans);
    font-size: 10px;
    padding: 4px 10px;
    border-radius: 12px;
    cursor: pointer;
    transition: all 0.2s ease;
}
.assist-chip:hover {
    color: var(--text-primary);
    border-color: var(--color-primary);
}

/* Order lists styles */
.order-list {
    display: flex;
    flex-direction: column;
    gap: 10px;
}
.empty-list-state {
    text-align: center;
    color: var(--text-secondary);
    font-size: 12px;
    padding: 30px 0;
}

.order-item-card {
    background: rgba(255, 255, 255, 0.02);
    border: 1px solid rgba(255, 255, 255, 0.04);
    border-radius: var(--border-radius-md);
    padding: 12px 16px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    transition: all 0.2s ease;
}
.order-item-card:hover {
    background: rgba(255, 255, 255, 0.04);
    border-color: rgba(255, 255, 255, 0.08);
}
.order-item-left {
    display: flex;
    flex-direction: column;
    gap: 2px;
}
.order-item-title {
    font-size: 13px;
    font-weight: 600;
}
.order-item-details {
    font-size: 10px;
    color: var(--text-secondary);
}
.order-item-right {
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    gap: 4px;
}
.order-item-right .price {
    font-size: 13px;
    font-weight: 700;
    color: var(--color-primary);
}

.btn-track {
    background: rgba(0, 173, 181, 0.08);
    border: 1px solid rgba(0, 173, 181, 0.2);
    color: var(--color-primary);
    font-family: var(--font-sans);
    font-size: 9px;
    font-weight: 700;
    padding: 3px 8px;
    border-radius: 6px;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 4px;
    text-transform: uppercase;
    transition: all 0.2s ease;
}
.btn-track span {
    font-size: 12px;
}
.btn-track:hover {
    background: var(--color-primary);
    color: #121214;
}
.btn-track.active-tracking {
    background: var(--color-primary);
    color: #121214;
    border-color: var(--color-primary);
}

/* Courier Profile Card styles */
.courier-profile-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 16px;
}
.profile-item {
    display: flex;
    flex-direction: column;
    background: rgba(255, 255, 255, 0.02);
    border: 1px solid rgba(255, 255, 255, 0.03);
    padding: 10px 14px;
    border-radius: var(--border-radius-md);
}
.profile-item span {
    font-size: 10px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 2px;
}
.profile-item strong {
    font-size: 14px;
    font-weight: 700;
}

/* Simulation Controls */
.simulation-actions {
    background: rgba(255, 255, 255, 0.02);
    border: 1px solid rgba(255, 255, 255, 0.04);
    border-radius: var(--border-radius-md);
    padding: 14px;
    margin-bottom: 16px;
}
.sim-order-info {
    display: flex;
    flex-direction: column;
    margin-bottom: 12px;
}
.sim-order-info strong {
    font-size: 13px;
    font-weight: 700;
}
.sim-order-info span {
    font-size: 10px;
    color: var(--text-secondary);
}
.sim-button-row {
    display: flex;
    gap: 12px;
}
.sim-button-row .btn {
    flex: 1;
}

/* Terminal logs console design */
.terminal-logs {
    background-color: #0b0c10;
    border-radius: var(--border-radius-md);
    border: 1px solid rgba(255, 255, 255, 0.06);
    overflow: hidden;
    font-family: 'Courier New', Courier, monospace;
}
.terminal-header {
    display: flex;
    align-items: center;
    gap: 6px;
    background-color: #12131a;
    padding: 10px 14px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.04);
}
.terminal-header .circle {
    width: 10px;
    height: 10px;
    border-radius: 50%;
}
.terminal-header .circle.red { background-color: #ff5f56; }
.terminal-header .circle.yellow { background-color: #ffbd2e; }
.terminal-header .circle.green { background-color: #27c93f; }
.terminal-title {
    font-size: 10px;
    color: var(--text-secondary);
    font-weight: 700;
    margin-left: 6px;
    text-transform: uppercase;
}
.terminal-body {
    padding: 12px 14px;
    height: 140px;
    overflow-y: auto;
    display: flex;
    flex-direction: column;
    gap: 6px;
}
.terminal-line {
    font-size: 11px;
    color: #4af626; /* neon green */
    line-height: 1.4;
}
.terminal-line.text-muted {
    color: var(--text-secondary);
}

/* Admin Manage subscriptions table */
.table-responsive {
    width: 100%;
    overflow-x: auto;
}
.subscriptions-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 12px;
    text-align: left;
}
.subscriptions-table th {
    color: var(--text-secondary);
    text-transform: uppercase;
    font-weight: 700;
    padding: 10px 8px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}
.subscriptions-table td {
    padding: 12px 8px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.04);
    vertical-align: middle;
}
.subscriptions-table tr:hover {
    background-color: rgba(255, 255, 255, 0.01);
}

.table-btn {
    background: transparent;
    border: 1px solid rgba(255, 255, 255, 0.1);
    color: var(--text-primary);
    padding: 4px 8px;
    border-radius: 6px;
    cursor: pointer;
    font-family: var(--font-sans);
    font-size: 10px;
    font-weight: 600;
    transition: all 0.2s ease;
}
.table-btn:hover {
    border-color: var(--color-primary);
    color: var(--color-primary);
}
.table-btn.btn-action-renew {
    background-color: var(--color-primary-glow);
    border-color: rgba(0, 173, 181, 0.3);
    color: var(--color-primary);
}
.table-btn.btn-action-renew:hover {
    background-color: var(--color-primary);
    color: #121214;
}
.table-btn.btn-action-delete:hover {
    background-color: var(--color-danger) !important;
    color: #121214 !important;
    border-color: var(--color-danger) !important;
}

/* Switch Styles (manual subscription toggling) */
.switch {
    position: relative;
    display: inline-block;
    width: 34px;
    height: 20px;
}
.switch input {
    opacity: 0;
    width: 0;
    height: 0;
}
.slider {
    position: absolute;
    cursor: pointer;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: #2a2c3d;
    transition: .3s;
    border-radius: 20px;
}
.slider:before {
    position: absolute;
    content: "";
    height: 14px;
    width: 14px;
    left: 3px;
    bottom: 3px;
    background-color: white;
    transition: .3s;
    border-radius: 50%;
}
input:checked + .slider {
    background-color: var(--color-courier);
}
input:focus + .slider {
    box-shadow: 0 0 1px var(--color-courier);
}
input:checked + .slider:before {
    transform: translateX(14px);
}

.admin-creation-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 16px;
}
@media (max-width: 680px) {
    .admin-creation-grid {
        grid-template-columns: 1fr;
    }
}
.col-card {
    height: 100%;
}

.order-assign-row {
    display: flex;
    gap: 8px;
    margin-top: 6px;
    width: 100%;
}
.order-assign-row select {
    flex: 1;
    font-size: 11px;
    padding: 6px 12px;
}
.order-assign-row .btn {
    font-size: 10px;
    padding: 6px 12px;
}

/* 5. NOTIFICATIONS MODAL */
.modal-backdrop {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: rgba(10, 11, 16, 0.85);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    justify-content: center;
    align-items: center;
    z-index: 200;
    opacity: 0;
    transition: opacity 0.25s ease;
    padding: 20px;
    overflow-y: auto; /* Allow backdrop to scroll if card is too large */
    pointer-events: auto; /* Restore clickability within pointer-events: none containers */
}
.modal-backdrop.active {
    display: flex;
    opacity: 1;
}

.modal-card {
    background-color: var(--card-bg);
    border: 1px solid var(--card-border);
    width: 100%;
    max-width: 500px;
    max-height: calc(100vh - 40px); /* Restrict max height of card */
    border-radius: var(--border-radius-lg);
    box-shadow: var(--shadow-md);
    overflow: hidden;
    display: flex;
    flex-direction: column; /* Force flex child alignment */
    animation: zoomIn 0.25s cubic-bezier(0.16, 1, 0.3, 1);
}
.modal-card.modal-small {
    max-width: 380px;
}

.modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 16px 20px;
    border-bottom: 1px solid var(--card-border);
    flex-shrink: 0; /* Keep header from shrinking */
}
.modal-title-row {
    display: flex;
    align-items: center;
    gap: 8px;
}
.modal-title-row span {
    color: var(--color-primary);
}
.modal-title-row h3 {
    font-size: 15px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}
.close-modal-btn {
    background: transparent;
    border: none;
    color: var(--text-secondary);
    cursor: pointer;
    width: 32px;
    height: 32px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s ease;
}
.close-modal-btn:hover {
    background-color: rgba(255, 255, 255, 0.05);
    color: var(--text-primary);
}

.modal-body {
    padding: 20px;
    flex: 1;
    overflow-y: auto; /* Scroll strictly inside the body */
}

.modal-footer {
    padding: 14px 20px;
    border-top: 1px solid var(--card-border);
    display: flex;
    justify-content: flex-end;
    gap: 12px;
    flex-shrink: 0; /* Keep footer from shrinking */
}

/* Sidebar Drawer */
.sidebar-drawer {
    position: fixed;
    top: 0;
    left: -285px; /* Hidden by default */
    width: 280px;
    height: 100vh;
    background: rgba(22, 23, 32, 0.96);
    border-right: 1px solid var(--card-border);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    z-index: 300;
    transition: left 0.3s cubic-bezier(0.1, 0.9, 0.2, 1);
    display: flex;
    flex-direction: column;
    box-shadow: 8px 0 24px rgba(0, 0, 0, 0.4);
    pointer-events: auto; /* Enable click/touch interaction */
}
.sidebar-drawer.active {
    left: 0;
}
.drawer-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.6);
    backdrop-filter: blur(3px);
    -webkit-backdrop-filter: blur(3px);
    z-index: 290;
    display: none;
    opacity: 0;
    transition: opacity 0.3s ease;
    pointer-events: auto; /* Enable click/touch interaction */
}
.drawer-overlay.active {
    display: block;
    opacity: 1;
}
.drawer-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 24px 20px;
    border-bottom: 1px solid var(--card-border);
}
.drawer-user-info {
    display: flex;
    align-items: center;
    gap: 12px;
}
.drawer-user-info .avatar {
    font-size: 30px;
    color: var(--color-primary);
    background: var(--color-primary-glow);
    padding: 8px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
}
.drawer-user-info .user-text {
    display: flex;
    flex-direction: column;
}
.drawer-user-info .user-text strong {
    font-size: 14px;
    color: var(--text-primary);
    font-weight: 600;
}
.drawer-user-info .user-text span {
    font-size: 11px;
    color: var(--text-secondary);
}
.close-drawer-btn {
    background: transparent;
    border: none;
    color: var(--text-secondary);
    cursor: pointer;
    width: 32px;
    height: 32px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s ease;
}
.close-drawer-btn:hover {
    background-color: rgba(255, 255, 255, 0.05);
    color: var(--text-primary);
}
.drawer-body {
    padding: 16px 8px;
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 4px;
}
.drawer-menu-item {
    display: flex;
    align-items: center;
    gap: 14px;
    padding: 12px 16px;
    border-radius: var(--border-radius-md);
    cursor: pointer;
    color: var(--text-secondary);
    transition: all 0.2s ease;
    font-size: 14px;
    font-weight: 500;
}
.drawer-menu-item:hover {
    background: rgba(255, 255, 255, 0.04);
    color: var(--text-primary);
}
.drawer-menu-item span.material-symbols-outlined {
    font-size: 22px;
    color: var(--text-secondary);
    transition: color 0.2s ease;
}
.drawer-menu-item:hover span.material-symbols-outlined {
    color: var(--color-primary);
}
.drawer-menu-item.logout {
    margin-top: auto;
    color: var(--color-danger);
    border: 1px solid rgba(229, 57, 53, 0.15);
}
.drawer-menu-item.logout:hover {
    background: rgba(229, 57, 53, 0.1);
    color: #ff6b6b;
    border-color: rgba(229, 57, 53, 0.3);
}
.drawer-menu-item.logout span.material-symbols-outlined {
    color: var(--color-danger);
}
.drawer-divider {
    height: 1px;
    background: var(--card-border);
    margin: 8px 16px;
}
.drawer-menu-item .badge {
    margin-left: auto;
    background: var(--color-danger);
    color: white;
    font-size: 10px;
    font-weight: 700;
    padding: 2px 6px;
    border-radius: 10px;
}

.notifications-history-list {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.notification-item {
    background: rgba(255, 255, 255, 0.02);
    border: 1px solid rgba(255, 255, 255, 0.03);
    border-radius: var(--border-radius-md);
    padding: 12px 14px;
    display: flex;
    gap: 10px;
}
.notification-item.unread {
    background: rgba(0, 173, 181, 0.04);
    border-color: rgba(0, 173, 181, 0.12);
}
.notification-item-icon {
    color: var(--color-primary);
    font-size: 20px;
}
.notification-item-body {
    display: flex;
    flex-direction: column;
    gap: 2px;
}
.notification-item-body strong {
    font-size: 12px;
    font-weight: 700;
}
.notification-item-body p {
    font-size: 11px;
    color: var(--text-secondary);
}
.notification-item-body small {
    font-size: 9px;
    color: var(--text-secondary);
}

/* Animations */
@keyframes indicatorPulse {
    0% {
        box-shadow: 0 0 0 0 rgba(0, 173, 181, 0.5);
    }
    70% {
        box-shadow: 0 0 0 8px rgba(0, 173, 181, 0);
    }
    100% {
        box-shadow: 0 0 0 0 rgba(0, 173, 181, 0);
    }
}

@keyframes pulseGlow {
    0%, 100% {
        filter: drop-shadow(0 0 5px var(--color-primary-glow));
    }
    50% {
        filter: drop-shadow(0 0 15px rgba(0, 173, 181, 0.6));
    }
}

@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

@keyframes slideUp {
    from { transform: translateY(15px); opacity: 0; }
    to { transform: translateY(0); opacity: 1; }
}

@keyframes zoomIn {
    from { transform: scale(0.95); opacity: 0; }
    to { transform: scale(1); opacity: 1; }
}

/* Responsive adjustments for mobile viewports */
@media (max-width: 500px) {
    .app-container {
        padding: 8px 8px 40px 8px;
    }
    .map-section {
        margin-bottom: 12px;
    }
    .map-wrapper {
        height: 155px; /* Reduced height from 240px to fit on small screens */
        border-radius: var(--border-radius-md);
    }
    .map-overlay-lab {
        top: 6px;
        right: 6px;
        padding: 4px 8px;
        max-width: 120px;
    }
    .map-overlay-lab .overlay-text span {
        display: none; /* Hide subtitle to save space */
    }
    .map-overlay-tracking {
        bottom: 4px;
        left: 4px;
        right: 4px;
        padding: 6px 10px;
    }
    .tracking-header {
        margin-bottom: 4px;
        padding-bottom: 4px;
    }
    .tracking-distance span {
        font-size: 13px;
    }
    .card {
        padding: 12px 14px;
        border-radius: var(--border-radius-md);
    }
    .top-bar {
        padding: 8px 12px;
    }
    .role-tabs-bar {
        margin-bottom: 12px;
    }
    .role-tab {
        padding: 10px 4px;
        font-size: 11px;
        gap: 4px;
    }
    .role-tab span.material-symbols-outlined {
        font-size: 15px;
    }
    .card-header-simple {
        margin-bottom: 10px;
    }
    .card-header-simple span {
        font-size: 16px;
    }
    .card-header-simple h4 {
        font-size: 12px;
    }
}

/* --- ADMIN PANEL SUBTABS & REPORTS STYLES --- */
.admin-subtabs-bar {
    display: flex;
    gap: 8px;
    background: var(--input-bg);
    border: 1px solid var(--card-border);
    border-radius: var(--border-radius-md);
    padding: 6px;
    margin-bottom: 20px;
}
.admin-subtab, .courier-subtab {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    background: transparent;
    border: none;
    color: var(--text-secondary);
    padding: 12px 6px;
    cursor: pointer;
    font-family: var(--font-sans);
    font-weight: 600;
    font-size: 13px;
    border-radius: var(--border-radius-sm);
    transition: all 0.25s ease;
}
.admin-subtab span.material-symbols-outlined, .courier-subtab span.material-symbols-outlined {
    font-size: 18px;
}
.admin-subtab.active, .courier-subtab.active {
    background-color: var(--card-bg);
    color: var(--color-primary);
    box-shadow: var(--shadow-sm);
    border: 1px solid rgba(0, 173, 181, 0.15);
}
.admin-subtab:hover:not(.active), .courier-subtab:hover:not(.active) {
    color: var(--text-primary);
    background-color: rgba(255, 255, 255, 0.02);
}

.admin-subtab-content, .courier-subtab-content {
    display: none;
    flex-direction: column;
    gap: 16px;
}
.admin-subtab-content.active, .courier-subtab-content.active {
    display: flex;
}

/* KPI report cards */
.reports-kpi-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 12px;
    margin-bottom: 8px;
}
@media (max-width: 500px) {
    .reports-kpi-grid {
        grid-template-columns: 1fr;
    }
}
.kpi-card {
    background-color: var(--card-bg);
    border: 1px solid var(--card-border);
    border-radius: var(--border-radius-md);
    padding: 14px 16px;
    display: flex;
    align-items: center;
    gap: 12px;
    box-shadow: var(--shadow-sm);
}
.kpi-icon-box {
    width: 42px;
    height: 42px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
}
.kpi-icon-box.kpi-trips {
    background-color: rgba(30, 136, 229, 0.1);
    color: var(--color-info);
}
.kpi-icon-box.kpi-earnings {
    background-color: rgba(76, 175, 80, 0.1);
    color: var(--color-courier);
}
.kpi-icon-box.kpi-distance {
    background-color: rgba(255, 87, 34, 0.1);
    color: var(--color-lab);
}
.kpi-text-box {
    display: flex;
    flex-direction: column;
}
.kpi-text-box span {
    font-size: 10px;
    color: var(--text-secondary);
    text-transform: uppercase;
    font-weight: 700;
}
.kpi-text-box strong {
    font-size: 16px;
    font-weight: 800;
    color: var(--text-primary);
}

.filter-row-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 12px;
}
@media (max-width: 500px) {
    .filter-row-grid {
        grid-template-columns: 1fr;
    }
}


/* --- FLEET MAINTENANCE AND FUEL SYSTEM STYLES --- */

.fleet-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 16px;
    margin-top: 12px;
}

.maintenance-card {
    background: rgba(255, 255, 255, 0.02);
    border: 1px solid rgba(255, 255, 255, 0.05);
    border-radius: var(--border-radius-md);
    padding: 16px;
    display: flex;
    flex-direction: column;
    gap: 12px;
    position: relative;
    transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
    overflow: hidden;
}

.maintenance-card:hover {
    transform: translateY(-2px);
    border-color: rgba(255, 255, 255, 0.1);
    background: rgba(255, 255, 255, 0.03);
    box-shadow: var(--shadow-md);
}

.maintenance-card.status-ok {
    border-left: 4px solid var(--color-courier);
}

.maintenance-card.status-warning {
    border-left: 4px solid var(--color-warning);
    box-shadow: 0 0 10px rgba(251, 140, 0, 0.05);
}

.maintenance-card.status-critical {
    border-left: 4px solid var(--color-danger);
    background: linear-gradient(135deg, rgba(229, 57, 53, 0.03) 0%, rgba(22, 23, 32, 0.8) 100%);
    box-shadow: 0 0 15px rgba(229, 57, 53, 0.1);
    animation: criticalPulseCard 3s infinite ease-in-out;
}

@keyframes criticalPulseCard {
    0%, 100% {
        border-color: rgba(229, 57, 53, 0.2);
    }
    50% {
        border-color: rgba(229, 57, 53, 0.6);
        box-shadow: 0 0 20px rgba(229, 57, 53, 0.18);
    }
}

.maint-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
}

.maint-driver-info {
    display: flex;
    flex-direction: column;
}

.maint-driver-name {
    font-size: 14px;
    font-weight: 700;
    color: var(--text-primary);
}

.maint-vehicle-name {
    font-size: 11px;
    color: var(--text-secondary);
}

.maint-plate-badge {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    color: var(--text-primary);
    padding: 2px 6px;
    border-radius: 4px;
    font-size: 10px;
    font-weight: 700;
    font-family: monospace;
    letter-spacing: 0.5px;
}

.maint-stats {
    display: flex;
    flex-direction: column;
    gap: 4px;
    background: rgba(255, 255, 255, 0.01);
    padding: 8px 10px;
    border-radius: var(--border-radius-sm);
    border: 1px solid rgba(255, 255, 255, 0.02);
}

.maint-stat-row {
    display: flex;
    justify-content: space-between;
    font-size: 11px;
}

.maint-stat-label {
    color: var(--text-secondary);
}

.maint-stat-value {
    font-weight: 600;
    color: var(--text-primary);
}

.maint-progress-section {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.maint-progress-header {
    display: flex;
    justify-content: space-between;
    font-size: 10px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.3px;
}

.maint-progress-label {
    color: var(--text-secondary);
}

.maint-progress-value {
    font-size: 11px;
}

.status-ok .maint-progress-value { color: var(--color-courier); }
.status-warning .maint-progress-value { color: var(--color-warning); }
.status-critical .maint-progress-value { color: var(--color-danger); }

.maint-progress-bar {
    width: 100%;
    height: 8px;
    background: #1e202c;
    border-radius: 4px;
    overflow: hidden;
    border: 1px solid rgba(255, 255, 255, 0.03);
}

.maint-progress-fill {
    height: 100%;
    border-radius: 4px;
    transition: width 0.5s ease;
}

.status-ok .maint-progress-fill {
    background-color: var(--color-courier);
    box-shadow: 0 0 6px rgba(76, 175, 80, 0.3);
}

.status-warning .maint-progress-fill {
    background-color: var(--color-warning);
    box-shadow: 0 0 6px rgba(251, 140, 0, 0.3);
}

.status-critical .maint-progress-fill {
    background-color: var(--color-danger);
    box-shadow: 0 0 8px rgba(229, 57, 53, 0.5);
    animation: criticalPulseFill 1.5s infinite;
}

@keyframes criticalPulseFill {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.6; }
}

.maint-badge {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    padding: 3px 8px;
    border-radius: 6px;
    font-size: 9px;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.status-ok .maint-badge {
    background-color: rgba(76, 175, 80, 0.1);
    color: var(--color-courier);
    border: 1px solid rgba(76, 175, 80, 0.2);
}

.status-warning .maint-badge {
    background-color: rgba(251, 140, 0, 0.1);
    color: var(--color-warning);
    border: 1px solid rgba(251, 140, 0, 0.2);
}

.status-critical .maint-badge {
    background-color: rgba(229, 57, 53, 0.15);
    color: var(--color-danger);
    border: 1px solid rgba(229, 57, 53, 0.3);
    animation: criticalBlinkText 1.5s infinite;
}

@keyframes criticalBlinkText {
    0%, 100% { opacity: 1; transform: scale(1); }
    50% { opacity: 0.7; transform: scale(0.96); }
}

.maint-actions-row {
    display: flex;
    gap: 6px;
    margin-top: 4px;
}

.btn-maint {
    flex: 1;
    padding: 8px 4px;
    font-size: 9px;
    font-weight: 700;
    border-radius: var(--border-radius-sm);
    text-transform: uppercase;
    letter-spacing: 0.3px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 4px;
    cursor: pointer;
    transition: all 0.2s ease;
    border: 1px solid transparent;
}

.btn-maint span {
    font-size: 12px;
}

.btn-maint-config {
    background-color: rgba(255, 255, 255, 0.03);
    border-color: rgba(255, 255, 255, 0.08);
    color: var(--text-secondary);
}

.btn-maint-config:hover {
    background-color: rgba(255, 255, 255, 0.08);
    color: var(--text-primary);
    border-color: rgba(255, 255, 255, 0.15);
}

.btn-maint-fuel {
    background-color: rgba(0, 173, 181, 0.08);
    border-color: rgba(0, 173, 181, 0.2);
    color: var(--color-primary);
}

.btn-maint-fuel:hover {
    background-color: var(--color-primary);
    color: #121214;
    border-color: var(--color-primary);
}

.btn-maint-reset {
    background-color: rgba(76, 175, 80, 0.08);
    border-color: rgba(76, 175, 80, 0.2);
    color: var(--color-courier);
}

.btn-maint-reset:hover {
    background-color: var(--color-courier);
    color: #121214;
    border-color: var(--color-courier);
}


/* --- MOTORCYCLE DAILY CHECKLIST STYLES --- */

.checklist-item-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 10px 0;
    border-bottom: 1px solid rgba(255, 255, 255, 0.04);
}

.checklist-item-row:last-of-type {
    border-bottom: none;
}

.checklist-item-label {
    font-size: 13px;
    font-weight: 500;
    color: var(--text-primary);
}

.checklist-item-options {
    display: flex;
    gap: 6px;
    background: var(--input-bg);
    padding: 3px;
    border-radius: var(--border-radius-sm);
    border: 1px solid rgba(255, 255, 255, 0.05);
}

.checklist-pill {
    position: relative;
    cursor: pointer;
}

.checklist-pill input[type="radio"] {
    position: absolute;
    opacity: 0;
    width: 0;
    height: 0;
}

.checklist-pill span {
    display: block;
    padding: 4px 12px;
    border-radius: 4px;
    font-size: 11px;
    font-weight: 700;
    color: var(--text-secondary);
    transition: all 0.2s ease;
    text-transform: uppercase;
    border: 1px solid transparent;
}

/* OK Pill checked state */
.checklist-pill.ok-pill input:checked ~ span {
    background-color: rgba(76, 175, 80, 0.15);
    color: var(--color-courier);
    border: 1px solid rgba(76, 175, 80, 0.25);
    box-shadow: 0 0 8px rgba(76, 175, 80, 0.1);
}

/* FAIL Pill checked state */
.checklist-pill.fail-pill input:checked ~ span {
    background-color: rgba(229, 57, 53, 0.15);
    color: var(--color-danger);
    border: 1px solid rgba(229, 57, 53, 0.25);
    box-shadow: 0 0 8px rgba(229, 57, 53, 0.1);
}

.checklist-pill:hover span {
    color: var(--text-primary);
}

.badge-danger-glow {
    background-color: var(--color-danger);
    color: white;
    box-shadow: 0 0 10px rgba(229, 57, 53, 0.4);
}

/* Location Selection Groups for Client Form */
.location-selection-group {
    background: rgba(255, 255, 255, 0.02);
    border: 1px solid rgba(255, 255, 255, 0.05);
    border-radius: var(--border-radius-md);
    padding: 12px;
}
.location-group-header {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 10px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.04);
    padding-bottom: 6px;
}
.location-group-header h5 {
    font-size: 13px;
    font-weight: 700;
    color: var(--text-primary);
}
.location-action-buttons {
    display: flex;
    gap: 8px;
    margin-top: 8px;
}
.btn-outline-primary {
    background: rgba(0, 173, 181, 0.05);
    border: 1px solid rgba(0, 173, 181, 0.2);
    color: var(--color-primary);
    cursor: pointer;
    transition: all 0.2s ease;
    border-radius: var(--border-radius-sm);
}
.btn-outline-primary:hover, .btn-outline-primary.active-mode {
    background: var(--color-primary);
    color: #121214;
    border-color: var(--color-primary);
    box-shadow: 0 0 10px rgba(0, 173, 181, 0.3);
}
.btn-outline-secondary {
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.08);
    color: var(--text-secondary);
    cursor: pointer;
    transition: all 0.2s ease;
    border-radius: var(--border-radius-sm);
}
.btn-outline-secondary:hover {
    background: rgba(255, 255, 255, 0.08);
    color: var(--text-primary);
}

/* Helper mode text toast */
.map-helper-toast {
    position: absolute;
    bottom: 20px;
    left: 50%;
    transform: translateX(-50%);
    background: rgba(18, 18, 20, 0.9);
    border: 1px solid var(--color-primary);
    box-shadow: 0 4px 20px rgba(0, 10, 15, 0.4);
    padding: 8px 16px;
    border-radius: var(--border-radius-sm);
    font-size: 11px;
    font-weight: 700;
    color: var(--color-primary);
    pointer-events: auto;
    z-index: 10;
    animation: pulseGlow 1.5s infinite;
    display: flex;
    align-items: center;
    gap: 12px;
}
.map-helper-toast .btn-cancel-selection {
    background: #ff3b30;
    border: none;
    color: #ffffff;
    font-size: 10px;
    font-weight: 600;
    padding: 2px 8px;
    border-radius: 4px;
    cursor: pointer;
    transition: background 0.2s;
}
.map-helper-toast .btn-cancel-selection:hover {
    background: #e03126;
}

@keyframes pulseGlow {
    0% { box-shadow: 0 4px 20px rgba(0, 173, 181, 0.2); }
    50% { box-shadow: 0 4px 25px rgba(0, 173, 181, 0.5); }
    100% { box-shadow: 0 4px 20px rgba(0, 173, 181, 0.2); }
}

/* Custom Mapbox Markers Styles */
.mapboxgl-marker {
    cursor: pointer;
}

.custom-marker {
    width: 20px;
    height: 20px;
    border-radius: 50%;
    border: 2.5px solid #ffffff;
    box-shadow: 0 0 10px rgba(0, 0, 0, 0.5);
    transition: transform 0.2s ease;
    position: relative;
}

.custom-marker:hover {
    transform: scale(1.2);
}

.marker-clinic {
    background-color: var(--color-primary);
    box-shadow: 0 0 12px var(--color-primary-glow);
}

.marker-lab {
    background-color: var(--color-lab);
    box-shadow: 0 0 12px var(--color-lab-glow);
}

.marker-courier {
    background-color: var(--color-courier);
    box-shadow: 0 0 12px var(--color-courier-glow);
    width: 24px;
    height: 24px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #ffffff;
    border-radius: 50%;
    border: 2.5px solid #ffffff;
}

.marker-courier::after {
    content: "🏍️";
    font-size: 13px;
}

.marker-dest {
    background-color: var(--color-lab);
    box-shadow: 0 0 12px var(--color-lab-glow);
}

/* Pulsing halo around markers */
.pulse-halo {
    position: absolute;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    border: 2px solid var(--color-primary);
    animation: markerPulse 1.8s infinite ease-out;
    pointer-events: none;
    top: 50%;
    left: 50%;
    margin-top: -18px;
    margin-left: -18px;
    box-sizing: border-box;
}

.pulse-halo-courier {
    border-color: var(--color-courier);
    width: 44px;
    height: 44px;
    margin-top: -22px;
    margin-left: -22px;
}

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

/* --- DIDI PREMIUM LAYOUT OVERRIDES --- */

/* Hide traditional top bar inside client and courier screens */
.role-client .top-bar,
.role-courier .top-bar {
    display: none !important;
}

/* Expand main app container to full screen viewport */
.role-client .app-container,
.role-courier .app-container {
    max-width: none !important;
    width: 100vw !important;
    height: 100vh !important;
    margin: 0 !important;
    padding: 0 !important;
    position: relative;
    overflow: hidden;
}

/* Make map cover whole background absolute */
.role-client .map-section,
.role-courier .map-section {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    width: 100vw;
    height: 100vh;
    margin: 0 !important;
    z-index: 1;
}

/* Hide standard text header for maps */
.role-client .map-section .section-title,
.role-courier .map-section .section-title {
    display: none !important;
}

/* Force map wrappers to fill window */
.role-client .map-wrapper,
.role-courier .map-wrapper {
    width: 100vw !important;
    height: 100vh !important;
    border: none !important;
    border-radius: 0 !important;
    box-shadow: none !important;
}

/* Floating overlay layout for panel contents */
.role-client .panel-contents,
.role-courier .panel-contents {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 2;
    pointer-events: none; /* Let clicks pass through to map */
}

.role-client .panel-tab-content,
.role-courier .panel-tab-content {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
}

/* Floating Action Circle Buttons */
.map-floating-btn {
    width: 48px;
    height: 48px;
    border-radius: 50%;
    background: #ffffff;
    border: none;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    color: #161720;
    transition: all 0.2s ease;
    pointer-events: auto; /* Active clickability */
}
.map-floating-btn:hover {
    transform: scale(1.05);
    background: #f5f6fa;
}

/* Top Left Menu/Back button overlay */
.btn-logout-float {
    position: absolute;
    top: 20px;
    left: 20px;
    z-index: 10;
}

/* Top Right Notifications center */
.map-floating-bell {
    position: absolute;
    top: 20px;
    right: 20px;
    z-index: 10;
    pointer-events: auto;
}
.map-floating-bell .badge {
    position: absolute;
    top: -2px;
    right: -2px;
    background-color: var(--color-danger);
    color: white;
    font-size: 9px;
    font-weight: 700;
    min-width: 16px;
    height: 16px;
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0 4px;
    border: 2px solid #ffffff;
}

/* Floating Safety Capsule */
.didi-safety-pill {
    position: absolute;
    bottom: 290px;
    left: 20px;
    background: #ffffff;
    color: #161720;
    padding: 8px 14px;
    border-radius: 20px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.12);
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 12px;
    font-weight: 700;
    z-index: 10;
    pointer-events: auto;
}
.didi-safety-pill .safety-icon {
    font-size: 16px;
}
.didi-safety-pill .chevron-icon {
    font-size: 16px;
    color: #b0b0b0;
    margin-left: 4px;
}

.client-safety-pill {
    bottom: 170px;
}

.client-right-actions {
    position: absolute;
    top: 100px;
    right: 20px;
    display: flex;
    flex-direction: column;
    gap: 12px;
    z-index: 10;
    pointer-events: auto;
}

/* Centering / GPS Button client */
.btn-gps-float {
    position: absolute;
    bottom: 170px;
    right: 20px;
    z-index: 10;
}

/* Clinic identity top center pill */
.clinic-badge-float {
    position: absolute;
    top: 20px;
    left: 50%;
    transform: translateX(-50%);
    background: rgba(22, 23, 32, 0.85);
    border: 1px solid rgba(0, 173, 181, 0.25);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    color: var(--text-primary);
    padding: 10px 18px;
    border-radius: 24px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
    display: flex;
    align-items: center;
    gap: 8px;
    font-weight: 700;
    font-size: 13px;
    z-index: 10;
    pointer-events: auto;
    cursor: pointer;
    transition: all 0.2s ease;
}
.clinic-badge-float:hover {
    background: rgba(22, 23, 32, 0.95);
    transform: translateX(-50%) scale(1.02);
}
.clinic-badge-float span.material-symbols-outlined {
    color: var(--color-primary);
    font-size: 18px;
}

/* Driver Earnings center pill */
.earnings-bubble-float {
    position: absolute;
    top: 20px;
    left: 50%;
    transform: translateX(-50%);
    background: #232538;
    color: #ffffff;
    padding: 10px 20px;
    border-radius: 24px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
    display: flex;
    align-items: center;
    gap: 8px;
    font-weight: 700;
    font-size: 15px;
    z-index: 10;
    pointer-events: auto;
    border: 1px solid rgba(255, 255, 255, 0.1);
}
.earnings-bubble-float span.material-symbols-outlined {
    font-size: 20px;
    color: #ffb74d;
}

/* Passenger "¿A dónde vamos?" Floating Search Card */
.client-search-card {
    position: absolute;
    bottom: 20px;
    left: 20px;
    right: 20px;
    background: #ffffff;
    border-radius: 20px;
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.15);
    padding: 16px 20px;
    z-index: 10;
    pointer-events: auto;
    color: #161720;
    cursor: pointer;
    transition: all 0.2s ease;
}
.client-search-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.2);
}
.search-card-header {
    display: flex;
    align-items: center;
    gap: 12px;
    border-bottom: 1px solid #f0f0f5;
    padding-bottom: 12px;
}
.search-card-header .search-icon {
    font-size: 26px;
    color: #555;
}
.search-title-col {
    display: flex;
    flex-direction: column;
}
.search-title {
    font-size: 20px;
    font-weight: 800;
    color: #111;
}
.search-promo-subtitle {
    font-size: 11px;
    color: #2e7d32;
    font-weight: 600;
}
.search-card-shortcuts {
    display: flex;
    flex-direction: column;
    gap: 10px;
    margin-top: 12px;
}
.shortcut-item {
    display: flex;
    align-items: center;
    gap: 10px;
    color: #333;
    font-size: 13px;
    font-weight: 600;
    transition: all 0.2s ease;
}
.shortcut-item:hover {
    color: var(--color-primary);
}
.shortcut-icon {
    color: #b0b0b0;
    font-size: 18px;
}

/* Horizontal Promo cards grid */
.client-promos-grid {
    position: absolute;
    bottom: 15px;
    left: 20px;
    right: 20px;
    height: 85px;
    display: flex;
    gap: 10px;
    z-index: 10;
    pointer-events: auto;
}
.promo-card {
    border-radius: 14px;
    overflow: hidden;
    padding: 10px 14px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    position: relative;
    cursor: pointer;
    transition: all 0.2s ease;
}
.promo-card:hover {
    transform: scale(1.02);
}
.promo-card h3 {
    font-size: 12px;
    font-weight: 800;
    line-height: 1.3;
    margin-bottom: 2px;
}
.orange-card {
    flex: 1.1;
    background: linear-gradient(135deg, #ff5e36 0%, #ff833d 100%);
    color: #ffffff;
}
.promo-tag {
    font-size: 8px;
    font-weight: 700;
    text-transform: uppercase;
    background: rgba(255, 255, 255, 0.2);
    padding: 2px 6px;
    border-radius: 4px;
    align-self: flex-start;
    margin-bottom: 4px;
}
.promo-btn-capsule {
    font-size: 8px;
    font-weight: 700;
    background: #ffffff;
    color: #ff5e36;
    padding: 3px 8px;
    border-radius: 10px;
    align-self: flex-start;
    margin-top: 4px;
}

.promo-subgrid {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 8px;
}
.promo-subgrid .promo-card {
    flex: 1;
    padding: 8px 12px;
}
.peach-card {
    background: #fce4ec;
    color: #880e4f;
}
.peach-card h3 {
    font-size: 10px;
}
.promo-subtag {
    font-size: 7px;
    font-weight: 700;
    color: #ad1457;
}
.white-card {
    background: #ffffff;
    border: 1px solid #e0e0e0;
    color: #161720;
}
.white-card h3 {
    font-size: 10px;
}
.promo-accent {
    font-size: 7px;
    font-weight: 700;
    color: #ff5722;
}

/* Slide-up Bottom sheet style for request form */
.client-bottom-sheet {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    background: #ffffff;
    border-top-left-radius: 24px;
    border-top-right-radius: 24px;
    padding: 16px 20px 32px 20px;
    box-shadow: 0 -4px 20px rgba(0, 0, 0, 0.15);
    z-index: 20;
    pointer-events: auto;
    color: #161720;
    max-height: 80vh;
    overflow-y: auto;
    transform: translateY(100%);
    transition: transform 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}
.client-bottom-sheet.active {
    transform: translateY(0);
}
.client-bottom-sheet .sheet-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-bottom: 1px solid #f0f0f5;
    padding-bottom: 10px;
    margin-bottom: 14px;
}
.client-bottom-sheet .sheet-header h3 {
    font-size: 16px;
    font-weight: 800;
    color: #111;
}
.close-sheet-btn {
    background: transparent;
    border: none;
    cursor: pointer;
    color: #555;
    width: 32px;
    height: 32px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
}
.close-sheet-btn:hover {
    background: #f0f0f5;
}

.client-bottom-sheet .form-control {
    background-color: #f5f5fa;
    border: 1px solid #e0e0e8;
    color: #111;
}
.client-bottom-sheet .form-control::placeholder {
    color: #888;
}
.client-bottom-sheet label {
    color: #555;
    font-weight: 600;
}
/* Unified Route Selection Card */
.unified-route-card {
    display: flex;
    background: #ffffff;
    border: 1px solid #e2e8f0;
    border-radius: 16px;
    padding: 16px 12px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.05);
    margin-bottom: 16px;
    position: relative;
}

.route-connector-col {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: space-between;
    width: 24px;
    padding: 10px 0;
    flex-shrink: 0;
}

.connector-dot {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    transition: all 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    position: relative;
    z-index: 2;
}

.connector-dot.origin {
    background-color: var(--color-primary, #00adb5);
    border: 2px solid #ffffff;
    box-shadow: 0 0 0 2px var(--color-primary, #00adb5);
}

.connector-dot.origin.focused {
    transform: scale(1.3);
    box-shadow: 0 0 0 2px var(--color-primary, #00adb5), 0 0 10px var(--color-primary, #00adb5);
}

.connector-dot.destination {
    background-color: var(--color-lab, #ff5722);
    border: 2px solid #ffffff;
    box-shadow: 0 0 0 2px var(--color-lab, #ff5722);
}

.connector-dot.destination.focused {
    transform: scale(1.3);
    box-shadow: 0 0 0 2px var(--color-lab, #ff5722), 0 0 10px var(--color-lab, #ff5722);
}

.connector-line {
    flex-grow: 1;
    width: 0;
    border-left: 2px dashed #cbd5e1;
    margin: 4px 0;
    z-index: 1;
}

.route-inputs-col {
    flex-grow: 1;
    display: flex;
    flex-direction: column;
    padding-left: 8px;
}

.route-input-row {
    display: flex;
    flex-direction: column;
    position: relative;
}

.route-input-row .form-group {
    margin-bottom: 6px;
    position: relative;
}

.route-input-row label {
    font-size: 10px;
    font-weight: 700;
    color: #64748b;
    text-transform: uppercase;
    margin-bottom: 2px;
    display: block;
}

.route-input {
    border: none !important;
    background: transparent !important;
    padding: 6px 0 !important;
    font-size: 14px !important;
    font-weight: 600 !important;
    color: #1e293b !important;
    border-radius: 0 !important;
    box-shadow: none !important;
    height: auto !important;
    transition: all 0.2s ease;
}

.route-input:focus {
    outline: none !important;
}

.route-divider {
    height: 1px;
    background-color: #f1f5f9;
    margin: 8px 0;
}

/* Shortcut pills styling */
.input-shortcut-pills {
    display: flex;
    gap: 8px;
    margin-top: 4px;
    flex-wrap: wrap;
}

.shortcut-pill {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    background: #f1f5f9;
    border: 1px solid #e2e8f0;
    border-radius: 20px;
    padding: 4px 10px;
    font-size: 11px;
    font-weight: 600;
    color: #475569;
    cursor: pointer;
    transition: all 0.2s ease;
}

.shortcut-pill span.material-symbols-outlined {
    font-size: 14px;
}

.shortcut-pill:hover {
    background: #e2e8f0;
    color: #1e293b;
    border-color: #cbd5e1;
}

.shortcut-pill:active {
    transform: scale(0.95);
}

/* Light theme search autocomplete overrides */
.client-bottom-sheet .autocomplete-suggestions {
    background: #ffffff;
    border: 1px solid #e2e8f0;
    border-radius: 12px;
    box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
    z-index: 100;
}
.client-bottom-sheet .prio-btn {
    background-color: #f5f5fa;
    border: 1px solid #e0e0e8;
}

/* Driver / Courier Bottom Sheet & Actions styling */
.courier-bottom-sheet {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    background: #ffffff;
    border-top-left-radius: 24px;
    border-top-right-radius: 24px;
    padding: 16px 20px 32px 20px;
    box-shadow: 0 -4px 20px rgba(0, 0, 0, 0.15);
    z-index: 10;
    pointer-events: auto;
    color: #111111;
    animation: slideUpSheet 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}

.sheet-drag-handle {
    width: 40px;
    height: 4px;
    background: #e0e0e0;
    border-radius: 2px;
    margin: 0 auto 12px auto;
}

.didi-promo-banner {
    background: linear-gradient(90deg, #ff5e36 0%, #ff8d3f 100%);
    border-radius: 12px;
    padding: 10px 14px;
    margin-bottom: 12px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    position: relative;
    color: white;
}
.promo-banner-content {
    display: flex;
    flex-direction: column;
}
.promo-banner-title {
    font-size: 13px;
    font-weight: 800;
}
.promo-banner-subtitle {
    font-size: 10px;
    opacity: 0.9;
}
.promo-banner-btn {
    background: white;
    color: #ff5e36;
    border: none;
    border-radius: 14px;
    padding: 4px 10px;
    font-size: 9px;
    font-weight: 700;
    cursor: pointer;
}
.promo-banner-close {
    background: transparent;
    border: none;
    color: white;
    cursor: pointer;
    padding: 4px;
}

.btn-didi-connect {
    background: #ff7043;
    color: #ffffff;
    border: none;
    padding: 12px 24px;
    border-radius: 24px;
    font-family: var(--font-sans);
    font-weight: 700;
    font-size: 15px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    box-shadow: 0 4px 12px rgba(255, 112, 67, 0.3);
    transition: all 0.2s ease;
}
.btn-didi-connect:hover {
    background: #f4511e;
    box-shadow: 0 6px 16px rgba(244, 81, 30, 0.4);
}
.btn-didi-connect.stop-btn {
    background: var(--color-danger);
    box-shadow: 0 4px 12px rgba(229, 57, 53, 0.3);
}
.btn-didi-connect.stop-btn:hover {
    background: #d32f2f;
    box-shadow: 0 6px 16px rgba(211, 47, 47, 0.4);
}

.sim-order-info-didi {
    display: flex;
    flex-direction: column;
    gap: 2px;
    font-family: var(--font-sans);
}
.sim-order-info-didi strong {
    font-size: 16px;
    font-weight: 800;
    color: #111111;
}
.sim-order-info-didi .text-muted {
    font-size: 11px;
    color: #777777 !important;
}

.courier-right-actions {
    position: absolute;
    top: 100px;
    right: 20px;
    display: flex;
    flex-direction: column;
    gap: 12px;
    z-index: 10;
    pointer-events: auto;
}

/* Autocomplete Geocoding Suggestions wrapper and list */
.autocomplete-wrapper {
    position: relative;
}
.autocomplete-suggestions {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: var(--input-bg, #ffffff);
    border: 1px solid var(--card-border, #e0e0e8);
    border-radius: var(--border-radius-md, 8px);
    margin-top: 4px;
    max-height: 200px;
    overflow-y: auto;
    z-index: 2100;
    box-shadow: var(--shadow-md, 0 4px 12px rgba(0, 0, 0, 0.15));
    display: none;
}
.autocomplete-suggestions.active {
    display: block;
}
.autocomplete-suggestion-item {
    padding: 10px 14px;
    font-size: 13px;
    font-family: var(--font-sans);
    color: var(--text-primary, #111111);
    cursor: pointer;
    transition: background-color 0.2s ease;
    border-bottom: 1px solid var(--card-border, #f0f0f5);
}
.autocomplete-suggestion-item:last-child {
    border-bottom: none;
}
.autocomplete-suggestion-item:hover {
    background-color: var(--card-bg, #f5f5fa);
}

/* Specific overrides for the light-themed Client Bottom Sheet */
.client-bottom-sheet .autocomplete-suggestions {
    background: #ffffff;
    border-color: #e0e0e8;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}




.client-bottom-sheet .autocomplete-suggestion-item {
    color: #111111;
    border-bottom-color: #f0f0f5;
}
.client-bottom-sheet .autocomplete-suggestion-item:hover {
    background-color: #f5f5fa;
}

/* --- CLIENT PANEL STEP JOURNEY STYLES --- */
.client-sheet-panel {
    display: none;
}
.client-sheet-panel.active {
    display: block;
}

/* Trip summary box with dotted route indicator */
.trip-summary-box {
    background: #f5f5fa;
    border-radius: 12px;
    padding: 12px 16px;
    margin-bottom: 16px;
    position: relative;
}
.trip-summary-box.compact {
    padding: 10px 12px;
    background: #fafafa;
    border: 1px solid #eeeeee;
}
.summary-item {
    display: flex;
    align-items: center;
    gap: 12px;
}
.summary-details {
    display: flex;
    flex-direction: column;
}
.summary-details strong {
    font-size: 11px;
    color: #888888;
    text-transform: uppercase;
}
.summary-details span {
    font-size: 13px;
    color: #111111;
    font-weight: 600;
}
.icon-dot {
    font-size: 18px;
}
.icon-dot.origin {
    color: var(--color-primary);
}
.icon-dot.destination {
    color: #ff5e36;
}
.summary-line {
    width: 2px;
    height: 14px;
    border-left: 2px dotted #cccccc;
    margin-left: 8px;
    margin-top: 2px;
    margin-bottom: 2px;
}

/* Trip details grid (3 columns) */
.trip-details-grid {
    display: flex;
    gap: 8px;
    margin-bottom: 20px;
}
.trip-detail-card {
    flex: 1;
    background: #f5f5fa;
    border: 1px solid #e8e8f0;
    border-radius: 10px;
    padding: 8px;
    display: flex;
    align-items: center;
    gap: 6px;
}
.trip-detail-card span {
    font-size: 20px;
    color: var(--color-primary);
}
.detail-col {
    display: flex;
    flex-direction: column;
}
.detail-col span {
    font-size: 8px;
    color: #777777;
    text-transform: uppercase;
    font-weight: 700;
}
.detail-col strong {
    font-size: 12px;
    color: #111111;
    font-weight: 800;
}

/* Radar Animation for searching state */
.searching-radar {
    position: relative;
    width: 80px;
    height: 80px;
    margin: 0 auto;
    display: flex;
    align-items: center;
    justify-content: center;
}
.radar-circle {
    position: absolute;
    width: 100%;
    height: 100%;
    border-radius: 50%;
    background: rgba(0, 173, 181, 0.15);
    animation: radar-pulse 1.8s infinite ease-out;
}
.radar-circle-outer {
    position: absolute;
    width: 100%;
    height: 100%;
    border-radius: 50%;
    background: rgba(0, 173, 181, 0.08);
    animation: radar-pulse 1.8s infinite 0.6s ease-out;
}
.radar-icon {
    font-size: 36px;
    color: var(--color-primary);
    z-index: 2;
    animation: bounce 2s infinite ease-in-out;
}
@keyframes radar-pulse {
    0% {
        transform: scale(0.6);
        opacity: 1;
    }
    100% {
        transform: scale(2.0);
        opacity: 0;
    }
}

/* Linear loading bar */
.loading-bar-container {
    width: 80%;
    height: 4px;
    background: #e0e0e0;
    border-radius: 2px;
    overflow: hidden;
    margin: 12px auto;
}
.loading-bar-fill {
    width: 30%;
    height: 100%;
    background: var(--color-primary);
    border-radius: 2px;
    animation: loading-slide 1.5s infinite linear;
}
@keyframes loading-slide {
    0% {
        transform: translateX(-100%);
    }
    100% {
        transform: translateX(330%);
    }
}

/* Driver details card floating in the active tracking view */
.driver-card-floating {
    display: flex;
    align-items: center;
    background: #f5f5fa;
    border: 1px solid #e8e8f0;
    border-radius: 14px;
    padding: 12px 14px;
    gap: 12px;
    width: 100%;
}
.driver-avatar-box {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: #00adb5;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #ffffff;
}
.driver-avatar-icon {
    font-size: 24px;
}
.driver-text-details {
    flex-grow: 1;
    display: flex;
    flex-direction: column;
}
.driver-text-details h4 {
    font-size: 14px;
    font-weight: 800;
    color: #111111;
}
.driver-text-details span {
    font-size: 10px;
    color: #666666;
}
.driver-rating-eta {
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    background: #ffffff;
    border-radius: 8px;
    padding: 4px 8px;
    border: 1px solid #e0e0e8;
    min-width: 65px;
}
.eta-label {
    font-size: 7px;
    text-transform: uppercase;
    color: #888888;
    font-weight: 700;
}
.eta-value {
    font-size: 13px;
    color: #00adb5;
    font-weight: 800;
}

/* Horizontal ride timeline progress bar */
.ride-timeline-progress {
    display: flex;
    align-items: center;
    justify-content: space-between;
    position: relative;
    padding: 0 4px;
    width: 100%;
}
.timeline-step {
    display: flex;
    flex-direction: column;
    align-items: center;
    z-index: 2;
    width: 60px;
}
.step-circle {
    width: 28px;
    height: 28px;
    border-radius: 50%;
    background: #e0e0e8;
    color: #888888;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
}
.step-circle span {
    font-size: 16px;
}
.timeline-step span {
    font-size: 8px;
    font-weight: 700;
    margin-top: 4px;
    color: #888888;
    text-align: center;
    white-space: nowrap;
}
.timeline-line {
    flex-grow: 1;
    height: 3px;
    background: #e0e0e8;
    margin-top: -12px; /* Center with the circles */
    z-index: 1;
    transition: all 0.3s ease;
}
.timeline-step.completed .step-circle {
    background: #00adb5;
    color: #ffffff;
}
.timeline-step.completed span {
    color: #00adb5;
}
.timeline-line.completed {
    background: #00adb5;
}

/* Success Checkmark Card */
.success-checkmark-box {
    width: 70px;
    height: 70px;
    border-radius: 50%;
    background: rgba(76, 175, 80, 0.12);
    margin: 0 auto;
    display: flex;
    align-items: center;
    justify-content: center;
}
.success-checkmark-box .check-icon {
    font-size: 44px;
    color: #4caf50;
    animation: scale-up 0.5s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}
@keyframes scale-up {
    0% { transform: scale(0.5); opacity: 0; }
    100% { transform: scale(1.0); opacity: 1; }
}

/* Custom Mapbox Markers styling */
.custom-marker {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    border: 2px solid #ffffff;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.5);
    cursor: pointer;
    background-size: 60%;
    background-repeat: no-repeat;
    background-position: center;
    position: relative;
    transition: transform 0.2s ease;
}
.custom-marker:hover {
    transform: scale(1.15);
    z-index: 9999 !important;
}

.marker-lab {
    background-color: var(--color-lab); /* #ff5722 */
    border-color: #ffffff;
    background-image: url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" height="24" viewBox="0 -960 960 960" width="24" fill="white"><path d="M480-120q-75 0-127.5-52.5T300-300q0-35 14-65.5t38-51.5l128-171v-172h-40v-80h240v80h-40v172l128 171q24 21 38 51.5t14 65.5q0 75-52.5 127.5T480-120Z"/></svg>');
}

.marker-clinic {
    background-color: var(--color-primary); /* #00adb5 */
    border-color: #ffffff;
    background-image: url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" height="24" viewBox="0 -960 960 960" width="24" fill="white"><path d="M240-200h120v-240h240v240h120v-360L480-740 240-560v360Z"/></svg>');
}

.marker-dest {
    background-color: var(--color-warning); /* #fb8c00 */
    border-color: #ffffff;
    background-image: url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" height="24" viewBox="0 -960 960 960" width="24" fill="white"><path d="M480-480q33 0 56.5-23.5T560-560q0-33-23.5-56.5T480-640q-33 0-56.5 23.5T400-560q0 33 23.5 56.5T480-480Zm0 400Q319-216 239.5-342.5T160-556q0-150 96.5-237T480-880q164 0 260.5 87T837-556q0 129.5-79.5 256T480-80Zm0-80q124-106 182-198.5t58-157.5q0-112-66-174T480-672q-106 0-172 62T242-436q0 65 58 157.5T480-160Z"/></svg>');
}

.marker-courier {
    background-color: var(--color-courier); /* #4caf50 */
    border-color: #ffffff;
    background-image: url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" height="24" viewBox="0 -960 960 960" width="24" fill="white"><path d="M240-160q-50 0-85-35t-35-85q0-50 35-85t85-35q31 0 55.5 13.5T332-350h138l-60-120H280q-50 0-85-35t-35-85q0-50 35-85t85-35q45 0 78.5 28T398-720h262q17 0 28.5 11.5T700-680q0 17-11.5 28.5T660-640H520v60l80 160h60q50 0 85 35t35 85q0 50-35 85t-85 35q-50 0-85-35t-35-85q0-7 1-15h-88q-10 44-46.5 72T240-160Zm0-80q17 0 28.5-11.5T280-280q0-17-11.5-28.5T240-320q-17 0-28.5 11.5T200-280q0 17 11.5 28.5T240-240Zm420 0q17 0 28.5-11.5T700-280q0-17-11.5-28.5T660-320q-17 0-28.5 11.5T620-280q0 17 11.5 28.5T660-240Z"/></svg>');
}

/* Pulsating Halos for active locations */
.pulse-halo {
    position: absolute;
    top: -8px;
    left: -8px;
    width: 44px;
    height: 44px;
    border-radius: 50%;
    background: rgba(0, 173, 181, 0.25);
    animation: marker-pulse-glow 1.8s infinite ease-out;
    pointer-events: none;
    z-index: -1;
}
.pulse-halo-courier {
    background: rgba(76, 175, 80, 0.25);
}
@keyframes marker-pulse-glow {
    0% {
        transform: scale(0.6);
        opacity: 1;
    }
    100% {
        transform: scale(1.8);
        opacity: 0;
    }
}


/* Simplified Solicitar Viaje trigger button */
.client-search-button-card {
    position: absolute;
    bottom: 24px;
    left: 20px;
    right: 20px;
    z-index: 10;
    pointer-events: auto;
    transition: all 0.3s ease;
}
.client-search-button-card #btn-trigger-solicitar-viaje {
    box-shadow: 0 6px 20px rgba(0, 10, 15, 0.4);
    font-size: 15px;
    font-weight: 700;
    padding: 14px;
    border-radius: 16px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    background: linear-gradient(135deg, var(--color-primary) 0%, #007c82 100%);
    border: none;
    color: var(--text-primary);
    width: 100%;
    cursor: pointer;
    transition: all 0.2s ease;
    animation: buttonPulse 2.5s infinite;
}
.client-search-button-card #btn-trigger-solicitar-viaje:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(0, 173, 181, 0.5);
}

@keyframes buttonPulse {
    0% { box-shadow: 0 6px 20px rgba(0, 173, 181, 0.3); }
    50% { box-shadow: 0 6px 25px rgba(0, 173, 181, 0.65); }
    100% { box-shadow: 0 6px 20px rgba(0, 173, 181, 0.3); }
}

/* Premium dark-glassmorphic confirmation card */
.map-overlay-confirm {
    position: absolute;
    bottom: 8px;
    left: 8px;
    right: 8px;
    background: rgba(22, 23, 32, 0.95);
    border: 1px solid rgba(0, 173, 181, 0.25);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    border-radius: var(--border-radius-md);
    padding: 14px 18px;
    box-shadow: var(--shadow-md);
    z-index: 15;
    animation: slideUp 0.3s ease;
    color: var(--text-primary);
    pointer-events: auto;
}

.confirm-header {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 12px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
    padding-bottom: 8px;
}
.confirm-header h4 {
    font-size: 13px;
    font-weight: 700;
    margin: 0;
    color: var(--color-primary);
    text-transform: uppercase;
    letter-spacing: 0.5px;
}
.back-confirm-btn {
    background: none;
    border: none;
    color: var(--text-secondary);
    cursor: pointer;
    padding: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: color 0.2s;
}
.back-confirm-btn:hover {
    color: var(--text-primary);
}
.back-confirm-btn span {
    font-size: 20px;
}

.confirm-route-details {
    margin-bottom: 12px;
    background: rgba(0, 0, 0, 0.2);
    border-radius: var(--border-radius-sm);
    padding: 10px;
    border: 1px solid rgba(255, 255, 255, 0.02);
}
.confirm-route-item {
    display: flex;
    align-items: flex-start;
    gap: 8px;
}
.confirm-icon {
    font-size: 16px;
    margin-top: 2px;
}
.confirm-icon.origin {
    color: var(--color-primary);
}
.confirm-icon.destination {
    color: #ff5722;
}
.confirm-addr-text {
    font-size: 11px;
    color: var(--text-secondary);
    line-height: 1.4;
    overflow: hidden;
    text-overflow: ellipsis;
    display: -webkit-box;
    -webkit-line-clamp: 1;
    -webkit-box-orient: vertical;
}

.confirm-stats-row {
    display: flex;
    justify-content: space-between;
    gap: 8px;
    margin-bottom: 14px;
    background: rgba(255, 255, 255, 0.02);
    border-radius: var(--border-radius-sm);
    padding: 8px 12px;
    border: 1px solid rgba(255, 255, 255, 0.03);
}
.confirm-stat-item {
    display: flex;
    align-items: center;
    gap: 6px;
}
.confirm-stat-item span.material-symbols-outlined {
    font-size: 18px;
    color: var(--color-primary);
}
.confirm-stat-item div {
    display: flex;
    flex-direction: column;
}
.confirm-stat-item .stat-label {
    font-size: 8px;
    color: var(--text-secondary);
    text-transform: uppercase;
}
.confirm-stat-item strong {
    font-size: 11px;
    font-weight: 700;
}
