:root {
    --ecab-bg: #ffffff;
    --ecab-surface: #ffffff;
    --ecab-text: #0f0f10;
    --ecab-muted: #60646c;
    --ecab-border: #d9d9de;
    --ecab-accent: #111111;
    --ecab-success: #12b76a;
    --ecab-danger: #f04438;
    --ecab-shadow: 0 12px 28px rgba(0, 0, 0, 0.18);
}

.ecab-dark {
    --ecab-bg: #000000;
    --ecab-surface: #0a0a0b;
    --ecab-text: #ffffff;
    --ecab-muted: #a2a2a8;
    --ecab-border: #25252a;
    --ecab-accent: #ffffff;
    --ecab-shadow: 0 16px 32px rgba(0, 0, 0, 0.55);
}

.ecab-ui {
    color: var(--ecab-text);
    font-family: Inter, system-ui, -apple-system, "Segoe UI", sans-serif;
    transition: background-color 0.25s ease, color 0.25s ease;
    background: var(--ecab-bg);
}

.ecab-icon-btn,
.ecab-online-btn,
.ecab-btn {
    border: 0;
    border-radius: 999px;
    cursor: pointer;
    transition: transform 0.15s ease, opacity 0.15s ease, background-color 0.2s ease;
}

.ecab-icon-btn {
    width: 40px;
    height: 40px;
    background: var(--ecab-surface);
    color: var(--ecab-text);
    border: 0;
}

.ecab-online-btn {
    width: 44px;
    height: 28px;
    padding: 0;
    font-size: 0;
    color: #fff;
    border: 0;
    position: relative;
    border-radius: 8px;
    transition: background-color 0.05s linear, border-color 0.05s linear;
}

.ecab-online-btn::after {
    content: "";
    width: 20px;
    height: 20px;
    border-radius: 50%;
    background: #ffffff;
    position: absolute;
    top: 50%;
    left: 4px;
    transform: translateY(-50%);
    transition: left 0.05s linear;
}

.ecab-online-btn.is-online {
    background: var(--ecab-success);
}

.ecab-online-btn.is-offline {
    background: var(--ecab-danger);
}

.ecab-status-dot {
    font-size: 0.82rem;
    color: var(--ecab-muted);
}

.ecab-driver-dashboard {
    min-height: 100vh;
}

/*
 * Theme / WooCommerce / Elementor often style generic `button` / `.button` (pink/purple).
 * Scope hard resets to the driver dashboard only — map tiles stay as-is.
 */
#ecab-driver-dashboard button {
    -webkit-tap-highlight-color: transparent;
}

#ecab-driver-dashboard button,
#ecab-driver-dashboard #ecab-sheet-handle {
    appearance: none;
    -webkit-appearance: none;
    background-image: none !important;
    text-shadow: none !important;
    filter: none !important;
}

/* Earnings (header): kill theme borders / shadows on every state */
#ecab-driver-dashboard #ecab-earnings-cta,
#ecab-driver-dashboard #ecab-earnings-cta:hover,
#ecab-driver-dashboard #ecab-earnings-cta:focus,
#ecab-driver-dashboard #ecab-earnings-cta:active {
    background: rgba(255, 255, 255, 0.96) !important;
    color: #000 !important;
    border: 0 !important;
    border-color: transparent !important;
    box-shadow: none !important;
    outline: none !important;
}

.ecab-dark #ecab-driver-dashboard #ecab-earnings-cta,
.ecab-dark #ecab-driver-dashboard #ecab-earnings-cta:hover,
.ecab-dark #ecab-driver-dashboard #ecab-earnings-cta:focus,
.ecab-dark #ecab-driver-dashboard #ecab-earnings-cta:active {
    background: rgba(0, 0, 0, 0.88) !important;
    color: #fff !important;
    border: 0 !important;
    border-color: transparent !important;
    box-shadow: none !important;
    outline: none !important;
}

/* Drag handle */
#ecab-driver-dashboard #ecab-sheet-handle,
#ecab-driver-dashboard #ecab-sheet-handle:hover,
#ecab-driver-dashboard #ecab-sheet-handle:focus,
#ecab-driver-dashboard #ecab-sheet-handle:active {
    background: rgba(0, 0, 0, 0.15) !important;
    color: transparent !important;
    font-size: 0 !important;
    line-height: 0 !important;
    border: 0 !important;
    border-color: transparent !important;
    box-shadow: none !important;
    outline: none !important;
}

.ecab-dark #ecab-driver-dashboard #ecab-sheet-handle,
.ecab-dark #ecab-driver-dashboard #ecab-sheet-handle:hover,
.ecab-dark #ecab-driver-dashboard #ecab-sheet-handle:focus,
.ecab-dark #ecab-driver-dashboard #ecab-sheet-handle:active {
    background: rgba(255, 255, 255, 0.2) !important;
    border: 0 !important;
    box-shadow: none !important;
    outline: none !important;
}

/* Online / offline switch (keep green/red fill, strip pink ring from theme) */
#ecab-driver-dashboard #ecab-online-toggle.ecab-online-btn,
#ecab-driver-dashboard #ecab-online-toggle.ecab-online-btn:hover,
#ecab-driver-dashboard #ecab-online-toggle.ecab-online-btn:focus,
#ecab-driver-dashboard #ecab-online-toggle.ecab-online-btn:active {
    border: 0 !important;
    border-color: transparent !important;
    box-shadow: none !important;
    outline: none !important;
}

#ecab-driver-dashboard #ecab-online-toggle.ecab-online-btn:focus-visible {
    outline: 2px solid rgba(255, 255, 255, 0.9) !important;
    outline-offset: 2px;
}

/* Settings + Earnings : bordure selon le thème (noir en mode clair, blanc en mode sombre) */
#ecab-driver-dashboard .ecab-switch-btn,
#ecab-driver-dashboard .ecab-switch-btn:hover,
#ecab-driver-dashboard .ecab-switch-btn:focus,
#ecab-driver-dashboard .ecab-switch-btn:active,
#ecab-driver-dashboard .ecab-history-tab,
#ecab-driver-dashboard .ecab-history-tab:hover,
#ecab-driver-dashboard .ecab-history-tab:focus,
#ecab-driver-dashboard .ecab-history-tab:active {
    background: var(--ecab-surface) !important;
    color: var(--ecab-text) !important;
    border: 1px solid var(--ecab-text) !important;
    box-shadow: none !important;
    outline: none !important;
}

#ecab-driver-dashboard .ecab-history-tab.is-active {
    background: var(--ecab-accent) !important;
    color: #fff !important;
    border-color: var(--ecab-accent) !important;
}

.ecab-dark #ecab-driver-dashboard .ecab-history-tab.is-active {
    background: #ffffff !important;
    color: #000000 !important;
    border-color: #ffffff !important;
}

#ecab-driver-dashboard button:focus {
    outline: none;
}

#ecab-driver-dashboard button:focus-visible:not(.ecab-online-btn):not(#ecab-earnings-cta):not(#ecab-sheet-handle) {
    outline: 2px solid var(--ecab-text);
    outline-offset: 2px;
}

#ecab-driver-dashboard #ecab-earnings-cta:focus-visible {
    outline: 2px solid var(--ecab-text) !important;
    outline-offset: 2px;
}

#ecab-driver-dashboard select:focus {
    outline: none;
}

#ecab-driver-dashboard select:focus-visible {
    outline: 2px solid var(--ecab-text);
    outline-offset: 2px;
}

#ecab-driver-dashboard .ecab-round-btn {
    box-shadow: none !important;
}

.ecab-map-wrap {
    position: relative;
    min-height: 100vh;
    isolation: isolate;
}

/* Keep map under UI layers so header/earnings stay clickable when sheet is tall */
.ecab-map-wrap .ecab-map {
    position: relative;
    z-index: 1;
}

.ecab-map-full {
    width: 100%;
    min-height: 100vh;
    border-radius: 0;
}

.ecab-map {
    background: #e9eaef;
}

.ecab-dark .ecab-map {
    background: #121214;
}

.ecab-overlay-top {
    position: absolute;
    top: 12px;
    left: 12px;
    right: 12px;
    z-index: 100;
    display: grid;
    grid-template-columns: 44px 1fr 44px;
    align-items: center;
    background: rgba(0, 0, 0, 0.66);
    backdrop-filter: blur(8px);
    border: 0;
    border-radius: 16px;
    padding: 8px;
}

.ecab-title {
    margin: 0;
    text-align: center;
    color: #fff;
    font-size: 1rem;
    letter-spacing: 0.02em;
}

.ecab-earnings-cta {
    border: 0;
    background: rgba(255, 255, 255, 0.96);
    color: #000;
    border-radius: 14px;
    padding: 8px 12px;
    cursor: pointer;
    display: grid;
    gap: 2px;
    align-content: center;
    justify-items: center;
}

.ecab-earnings-label {
    font-size: 0.78rem;
    opacity: 0.9;
}

.ecab-earnings-amount {
    font-size: 1.05rem;
    font-weight: 900;
    letter-spacing: 0.02em;
    line-height: 1.1;
}

.ecab-earnings-cta:active {
    transform: scale(0.99);
}

.ecab-dark .ecab-earnings-cta {
    background: rgba(0, 0, 0, 0.82);
    color: #fff;
}

.ecab-history-tabs {
    display: flex;
    gap: 8px;
    margin-bottom: 10px;
}

.ecab-history-tab {
    flex: 1;
    border: 0;
    background: var(--ecab-surface);
    color: var(--ecab-text);
    border-radius: 12px;
    padding: 10px 10px;
    cursor: pointer;
    font-weight: 800;
}

.ecab-history-tab.is-active {
    border-color: transparent;
}

.ecab-history-amount {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    gap: 10px;
    padding: 10px 12px;
    border: 0;
    border-radius: 14px;
}

.ecab-history-amount-label {
    color: var(--ecab-muted);
    font-weight: 700;
}

.ecab-history-note {
    margin-top: 10px;
    color: var(--ecab-muted);
    font-size: 0.85rem;
}

.ecab-rides-sheet {
    position: fixed;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 50;
    background: rgba(255, 255, 255, 0.94);
    color: var(--ecab-text);
    border: 0;
    border-radius: 16px 16px 0 0;
    box-shadow: var(--ecab-shadow);
    padding: 10px 12px;
    height: 30vh;
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.ecab-dark .ecab-rides-sheet {
    background: rgba(10, 10, 11, 0.82);
}

.ecab-sheet-handle {
    width: 100%;
    max-width: 56px;
    height: 6px;
    margin: 4px auto 10px;
    border-radius: 999px;
    background: rgba(0, 0, 0, 0.15);
    border: 0;
    cursor: ns-resize;
    touch-action: none;
    display: block;
}

.ecab-dark .ecab-sheet-handle {
    background: rgba(255, 255, 255, 0.18);
}

.ecab-rides-head {
    display: flex;
    flex-direction: column;
    align-items: stretch;
    gap: 8px;
}

.ecab-inline-online {
    display: flex;
    align-items: center;
    justify-content: flex-start;
    gap: 10px;
    white-space: nowrap;
}

.ecab-online-toggle-title {
    font-size: 0.86rem;
    color: var(--ecab-text);
    font-weight: 800;
}

.ecab-online-toggle-text {
    font-size: 0.86rem;
    color: var(--ecab-text);
    font-weight: 700;
}

.ecab-rides-head select {
    border: 0;
    background: var(--ecab-surface);
    color: var(--ecab-text);
    border-radius: 10px;
    padding: 8px 10px;
}

.ecab-trips-list {
    flex: 1;
    max-height: none;
    overflow-y: auto;
    padding-right: 4px;
}

.ecab-dispatch-list__items {
    list-style: none;
    margin: 0;
    padding: 0;
}

.ecab-dispatch-list__item {
    border: 0;
    border-radius: 12px;
    margin-bottom: 8px;
    padding: 10px;
    background: rgba(255, 255, 255, 0.94);
}

.ecab-trip-main {
    font-weight: 700;
    margin-bottom: 6px;
}

.ecab-trip-loc {
    font-size: 0.86rem;
    color: var(--ecab-muted);
}

.ecab-trip-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    margin-top: 8px;
}

.ecab-trip-actions .ecab-trip-btn {
    border-radius: 10px;
    border: 0;
    background: var(--ecab-surface) !important;
    color: var(--ecab-text) !important;
    padding: 6px 10px;
    cursor: pointer;
    box-shadow: none !important;
    font-family: inherit;
    font-size: 0.85rem;
    font-weight: 700;
}

.ecab-auth-page {
    min-height: 70vh;
    display: grid;
    place-items: center;
    background: var(--ecab-bg);
    padding: 18px;
}

.ecab-auth-card {
    width: min(100%, 460px);
}

.ecab-auth-head {
    position: relative;
    margin-bottom: 14px;
}

.ecab-auth-head h2 {
    margin: 0;
}

.ecab-auth-head p {
    margin: 4px 0 0;
    color: var(--ecab-muted);
}

.ecab-auth-head .ecab-icon-btn {
    position: absolute;
    top: 0;
    right: 0;
}

.ecab-auth-form {
    display: grid;
    gap: 10px;
}

.ecab-auth-form label {
    font-size: 0.9rem;
    color: var(--ecab-muted);
    display: grid;
    gap: 6px;
}

.ecab-auth-form input {
    border: 1px solid var(--ecab-border);
    border-radius: 10px;
    padding: 10px 12px;
    background: var(--ecab-surface);
    color: var(--ecab-text);
}

.ecab-password-field {
    display: grid;
    gap: 6px;
    font-size: 0.9rem;
    color: var(--ecab-muted);
}

.ecab-password-wrap {
    display: flex;
    align-items: stretch;
    border-radius: 10px;
    border: 1px solid var(--ecab-border);
    overflow: hidden;
    background: var(--ecab-surface);
}

.ecab-password-wrap input {
    flex: 1;
    min-width: 0;
    border: 0 !important;
    border-radius: 0 !important;
    padding: 10px 12px !important;
}

.ecab-password-toggle {
    flex-shrink: 0;
    border: 0;
    border-left: 1px solid var(--ecab-border);
    background: rgba(0, 0, 0, 0.04);
    color: var(--ecab-text);
    padding: 8px 12px;
    font-size: 0.82rem;
    font-weight: 600;
    cursor: pointer;
}

.ecab-dark .ecab-password-toggle {
    border-left-color: rgba(255, 255, 255, 0.15);
    background: rgba(255, 255, 255, 0.06);
}

.ecab-reg-review-text {
    margin-bottom: 12px;
    line-height: 1.5;
    font-size: 0.92rem;
}

.ecab-reg-review-thumbs {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(88px, 1fr));
    gap: 10px;
    margin-top: 4px;
}

.ecab-reg-review-fig {
    margin: 0;
    text-align: center;
}

.ecab-reg-review-fig figcaption {
    font-size: 0.72rem;
    color: var(--ecab-muted);
    margin-bottom: 4px;
    line-height: 1.25;
}

.ecab-reg-review-thumb-img {
    width: 100%;
    max-width: 96px;
    height: 72px;
    object-fit: cover;
    border-radius: 8px;
    border: 1px solid rgba(0, 0, 0, 0.12);
    display: block;
    margin: 0 auto;
}

.ecab-dark .ecab-reg-review-thumb-img {
    border-color: rgba(255, 255, 255, 0.15);
}

.ecab-reg-review-fig--file .ecab-reg-review-file-name {
    font-size: 0.75rem;
    word-break: break-word;
    display: block;
    padding: 6px 4px;
    color: var(--ecab-text);
}

.ecab-auth-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    font-size: 0.85rem;
}

.ecab-btn {
    padding: 11px 16px;
    font-weight: 700;
}

.ecab-btn-primary {
    background: var(--ecab-accent);
    color: #fff;
}

.ecab-auth-footer {
    margin: 12px 0 0;
    color: var(--ecab-muted);
    text-align: center;
}

.ecab-round-btn {
    width: 36px;
    height: 36px;
    border-radius: 10px;
    border: 0;
    background: rgba(255, 255, 255, 0.12);
    color: #fff;
    cursor: pointer;
}

.ecab-overlay-top .ecab-round-btn {
    background: rgba(255, 255, 255, 0.92);
    border: 0;
    color: #000;
}

.ecab-dark .ecab-overlay-top .ecab-round-btn {
    background: rgba(0, 0, 0, 0.85);
    color: #fff;
}

.ecab-settings-drawer {
    position: fixed;
    inset: 0;
    z-index: 200;
    background: rgba(0, 0, 0, 0.55);
    display: none;
    align-items: flex-end;
    justify-content: center;
    padding: 12px;
}

.ecab-settings-drawer.is-open {
    display: flex;
}

.ecab-settings-card {
    width: min(540px, 100%);
    background: var(--ecab-surface);
    border: 0;
    border-radius: 14px;
    padding: 12px;
}

.ecab-settings-head {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 10px;
}

.ecab-settings-head .ecab-settings-title {
    margin: 0;
    font-size: 1.15rem;
    font-weight: 700;
    color: var(--ecab-text) !important;
}

.ecab-settings-head .ecab-round-btn {
    color: var(--ecab-text);
    background: var(--ecab-surface);
    border-color: transparent;
}

.ecab-field {
    display: grid;
    gap: 6px;
    margin-bottom: 10px;
    font-size: 0.9rem;
}

.ecab-settings-card--profile {
    max-height: min(92vh, 900px);
    display: flex;
    flex-direction: column;
}

.ecab-settings-scroll {
    overflow-y: auto;
    flex: 1;
    padding-right: 4px;
    margin-right: -4px;
}

.ecab-settings-hero {
    display: flex;
    flex-direction: column;
    gap: 12px;
    margin-bottom: 16px;
}

.ecab-settings-avatar-block {
    display: flex;
    align-items: center;
    gap: 14px;
}

.ecab-settings-avatar {
    width: 96px;
    height: 96px;
    border-radius: 50%;
    object-fit: cover;
    background: rgba(0, 0, 0, 0.06);
    border: 2px solid rgba(0, 0, 0, 0.1);
}

.ecab-dark .ecab-settings-avatar {
    background: rgba(255, 255, 255, 0.08);
    border-color: rgba(255, 255, 255, 0.15);
}

.ecab-settings-firstname {
    font-size: 1.2rem;
    font-weight: 700;
    line-height: 1.2;
    color: var(--ecab-text);
}

.ecab-settings-collapse {
    margin-bottom: 10px;
    border: 1px solid rgba(0, 0, 0, 0.1);
    border-radius: 12px;
    overflow: hidden;
}

.ecab-dark .ecab-settings-collapse {
    border-color: rgba(255, 255, 255, 0.12);
}

.ecab-settings-collapse__btn {
    width: 100%;
    text-align: left;
    padding: 12px 14px;
    font-weight: 700;
    font-size: 0.95rem;
    background: var(--ecab-surface);
    border: 0;
    color: var(--ecab-text);
    cursor: pointer;
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 10px;
}

.ecab-settings-collapse__btn::after {
    content: '▾';
    opacity: 0.55;
    font-size: 0.85rem;
    transition: transform 0.2s ease;
}

.ecab-settings-collapse__btn[aria-expanded='true']::after {
    transform: rotate(-180deg);
}

.ecab-settings-collapse__panel {
    padding: 4px 14px 14px;
    border-top: 1px solid rgba(0, 0, 0, 0.08);
}

.ecab-dark .ecab-settings-collapse__panel {
    border-top-color: rgba(255, 255, 255, 0.1);
}

.ecab-settings-drawer .ecab-profile-doc-link {
    color: var(--ecab-text);
    text-decoration: underline;
    text-underline-offset: 2px;
}

.ecab-settings-section--flush {
    border-bottom: 0;
    margin-bottom: 0;
    padding-bottom: 0;
}

.ecab-settings-footer-logout {
    margin-top: 18px;
    padding-top: 14px;
    border-top: 1px solid rgba(0, 0, 0, 0.08);
}

.ecab-dark .ecab-settings-footer-logout {
    border-top-color: rgba(255, 255, 255, 0.1);
}

.ecab-settings-signout {
    display: block;
    text-align: center;
    text-decoration: none !important;
    width: 100%;
    box-sizing: border-box;
}

.ecab-settings-section {
    margin-bottom: 16px;
    padding-bottom: 12px;
    border-bottom: 1px solid rgba(0, 0, 0, 0.08);
}

.ecab-dark .ecab-settings-section {
    border-bottom-color: rgba(255, 255, 255, 0.1);
}

.ecab-settings-section__title {
    margin: 0 0 8px;
    font-size: 0.85rem;
    font-weight: 800;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    color: var(--ecab-muted);
}

.ecab-profile-hint,
.ecab-profile-mini {
    font-size: 0.78rem;
    color: var(--ecab-muted);
    margin: 0 0 8px;
    line-height: 1.35;
}

.ecab-profile-mini {
    margin-top: -4px;
}

.ecab-field-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 8px;
}

@media (max-width: 480px) {
    .ecab-field-row {
        grid-template-columns: 1fr;
    }
}

.ecab-field--row {
    display: flex;
    flex-direction: row;
    align-items: center;
    gap: 10px;
}

.ecab-field--row input[type="checkbox"] {
    width: auto;
}

.ecab-input {
    width: 100%;
    box-sizing: border-box;
    padding: 8px 10px;
    border-radius: 10px;
    border: 1px solid rgba(0, 0, 0, 0.12);
    background: rgba(255, 255, 255, 0.95);
    color: var(--ecab-text);
    font-size: 0.95rem;
}

.ecab-dark .ecab-input {
    border-color: rgba(255, 255, 255, 0.2);
    background: #121214;
    color: #fff;
}

.ecab-profile-actions {
    margin: 12px 0 4px;
}

.ecab-profile-save-btn {
    width: 100%;
}

.ecab-profile-status {
    font-size: 0.82rem;
    min-height: 1.2em;
    margin-bottom: 8px;
    color: var(--ecab-muted);
}

.ecab-profile-status--error {
    color: #b91c1c;
    font-weight: 700;
}

.ecab-dark .ecab-profile-status--error {
    color: #fca5a5;
}

.ecab-profile-doc {
    display: block;
    margin-top: 4px;
    font-size: 0.82rem;
}

.ecab-profile-doc-link {
    color: inherit;
    font-weight: 700;
}

.ecab-switch-btn {
    border: 1px solid var(--ecab-text);
    background: var(--ecab-surface);
    color: var(--ecab-text);
    border-radius: 10px;
    padding: 8px 10px;
    cursor: pointer;
    text-align: left;
    box-shadow: none;
}

.ecab-dark .ecab-switch-btn {
    border-color: #ffffff;
    background: #121214;
    color: #ffffff;
}

.ecab-auth-page .ecab-icon-btn,
.ecab-auth-page .ecab-icon-btn:hover,
.ecab-auth-page .ecab-icon-btn:focus {
    background: var(--ecab-surface) !important;
    color: var(--ecab-text) !important;
    border: 1px solid var(--ecab-text) !important;
    box-shadow: none !important;
    text-decoration: none !important;
}

.ecab-dark .ecab-auth-page .ecab-icon-btn,
.ecab-dark .ecab-auth-page .ecab-icon-btn:hover,
.ecab-dark .ecab-auth-page .ecab-icon-btn:focus {
    border-color: #ffffff !important;
    color: #ffffff !important;
    background: #121214 !important;
}

.ecab-icon-btn:hover,
.ecab-online-btn:hover,
.ecab-btn:hover {
    transform: translateY(-1px);
}

.ecab-draggable {
    cursor: grab;
}

.ecab-draggable:active {
    cursor: grabbing;
}

@media (min-width: 900px) {
    .ecab-rides-sheet {
        left: 16px;
        right: 16px;
        bottom: 16px;
        max-width: 560px;
    }
}

.ecab-online-btn.is-online::after {
    left: 20px;
}

.ecab-dark .ecab-overlay-top {
    background: rgba(0, 0, 0, 0.7);
}

.ecab-dark .ecab-online-pill {
    background: rgba(0, 0, 0, 0.85);
}

.ecab-dark .ecab-dispatch-list__item {
    background: rgba(10, 10, 11, 0.82);
}

.ecab-dark .ecab-trip-actions .ecab-trip-btn,
.ecab-dark .ecab-rides-head select {
    background: #121214;
    color: #fff;
}

.ecab-dark .ecab-online-btn {
    border-color: transparent;
}

.ecab-dark .ecab-online-btn::after {
    background: #fff;
}

.ecab-map-wrap:-webkit-full-screen .ecab-rides-sheet,
.ecab-map-wrap:fullscreen .ecab-rides-sheet {
    position: absolute;
    bottom: 8px;
    left: 8px;
    right: 8px;
    max-width: none;
    max-height: 60vh;
}

.ecab-map-wrap:-webkit-full-screen .ecab-overlay-top,
.ecab-map-wrap:fullscreen .ecab-overlay-top {
    top: 8px;
    left: 8px;
    right: 8px;
}

.ecab-map-wrap:-webkit-full-screen .ecab-online-pill,
.ecab-map-wrap:fullscreen .ecab-online-pill {
    top: 56px;
    right: 12px;
}

.ecab-map-wrap .gm-style-mtc button,
.ecab-map-wrap .gm-control-active {
    color: #111 !important;
}

.ecab-dark .ecab-map-wrap .gm-style-mtc button,
.ecab-dark .ecab-map-wrap .gm-control-active {
    color: #fff !important;
    background: #0f1115 !important;
    border-color: #2a2a30 !important;
}

/* Barre « course active » (style Uber) — au-dessus du panneau courses */
.ecab-active-ride {
    position: fixed;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 60;
    padding: 10px 12px calc(10px + env(safe-area-inset-bottom, 0));
    pointer-events: auto;
}

.ecab-active-ride[hidden] {
    display: none !important;
}

.ecab-active-ride__inner {
    max-width: 560px;
    margin: 0 auto;
    background: rgba(255, 255, 255, 0.96);
    color: var(--ecab-text);
    border-radius: 14px 14px 0 0;
    box-shadow: var(--ecab-shadow);
    border: 1px solid var(--ecab-border);
    padding: 10px 12px 12px;
}

.ecab-dark .ecab-active-ride__inner {
    background: rgba(10, 10, 11, 0.94);
    border-color: var(--ecab-border);
}

.ecab-active-ride__kicker {
    font-size: 0.72rem;
    font-weight: 800;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    color: var(--ecab-muted);
}

.ecab-active-ride__status {
    font-size: 0.95rem;
    font-weight: 800;
    margin-top: 2px;
}

.ecab-active-ride__addr {
    font-size: 0.82rem;
    color: var(--ecab-muted);
    margin-top: 4px;
    line-height: 1.35;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.ecab-active-ride__actions {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    margin-top: 10px;
}

/* Boutons type WooCommerce / rose — barre active + panneau live */
.ecab-active-ride__actions .ecab-trip-btn,
.ecab-live-ride__actions .ecab-trip-btn {
    flex: 1 1 auto;
    min-width: calc(33.33% - 6px);
    font-size: 0.78rem;
    padding: 8px 8px;
    background: linear-gradient(180deg, #fce7f3 0%, #fbcfe8 100%) !important;
    color: #831843 !important;
    border: 1px solid #f472b6 !important;
    box-shadow: none !important;
}

.ecab-dark .ecab-active-ride__actions .ecab-trip-btn,
.ecab-dark .ecab-live-ride__actions .ecab-trip-btn {
    background: linear-gradient(180deg, #3b0764 0%, #4c0519 100%) !important;
    color: #fce7f3 !important;
    border: 1px solid #f472b6 !important;
}

.ecab-active-ride__actions .ecab-trip-btn:active,
.ecab-live-ride__actions .ecab-trip-btn:active {
    transform: scale(0.98);
}

@media (min-width: 900px) {
    .ecab-active-ride {
        left: 16px;
        right: 16px;
        bottom: 16px;
        padding-bottom: 16px;
    }

    .ecab-active-ride__inner {
        border-radius: 14px;
    }
}

.ecab-map-wrap:-webkit-full-screen .ecab-active-ride,
.ecab-map-wrap:fullscreen .ecab-active-ride {
    position: absolute;
    bottom: 8px;
    left: 8px;
    right: 8px;
    z-index: 60;
}

/* Carte liste : client + heure + prévision gain */
.ecab-trip-card__top {
    margin-bottom: 8px;
}

.ecab-trip-meta__status {
    display: inline-block;
    font-size: 0.68rem;
    font-weight: 800;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    color: var(--ecab-muted);
    margin-bottom: 4px;
}

.ecab-trip-meta__name {
    font-weight: 800;
    font-size: 0.95rem;
    line-height: 1.25;
}

.ecab-trip-meta__when {
    font-size: 0.82rem;
    color: var(--ecab-muted);
    margin-top: 4px;
}

.ecab-trip-meta__earn {
    font-size: 0.8rem;
    font-weight: 700;
    color: var(--ecab-text, #111);
    margin-top: 6px;
}

.ecab-dark .ecab-trip-meta__earn {
    color: var(--ecab-text, #f5f5f5);
}

.ecab-trip-link {
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    box-sizing: border-box;
}

.ecab-active-ride__expand {
    width: 100%;
    margin-bottom: 8px;
}

/* Mode plein écran « live ride » */
.ecab-live-ride {
    position: fixed;
    inset: 0;
    z-index: 150;
    padding: env(safe-area-inset-top, 0) 12px env(safe-area-inset-bottom, 0);
    background: rgba(255, 255, 255, 0.97);
    color: var(--ecab-text);
    overflow: auto;
}

.ecab-dark .ecab-live-ride {
    background: rgba(0, 0, 0, 0.94);
}

.ecab-live-ride__inner {
    max-width: 560px;
    margin: 0 auto;
    min-height: 100%;
    display: flex;
    flex-direction: column;
    padding-bottom: 24px;
}

.ecab-live-ride__head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 10px 0 12px;
}

.ecab-live-ride__badge {
    font-size: 0.72rem;
    font-weight: 800;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    color: var(--ecab-muted);
}

.ecab-live-ride__close {
    border: 0;
    border-radius: 10px;
    padding: 8px 14px;
    font-size: 1.2rem;
    line-height: 1;
    cursor: pointer;
    background: var(--ecab-surface);
    color: var(--ecab-text);
}

.ecab-live-ride__name {
    font-size: 1.15rem;
    font-weight: 800;
}

.ecab-live-ride__when {
    font-size: 0.88rem;
    color: var(--ecab-muted);
    margin-top: 4px;
}

.ecab-live-ride__addr {
    margin-top: 8px;
    font-size: 0.88rem;
    line-height: 1.35;
}

.ecab-live-ride__actions {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-top: 16px;
}

.ecab-dashboard--live .ecab-rides-sheet {
    opacity: 0.25;
    pointer-events: none;
}

.ecab-dashboard--live .ecab-overlay-top {
    opacity: 0.35;
    pointer-events: none;
}

/* Modales (cancel / end ride) */
.ecab-modal {
    position: fixed;
    inset: 0;
    z-index: 220;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 16px;
}

.ecab-modal[hidden] {
    display: none !important;
}

.ecab-modal__backdrop {
    position: absolute;
    inset: 0;
    background: rgba(0, 0, 0, 0.5);
}

.ecab-modal__box {
    position: relative;
    z-index: 1;
    width: min(100%, 420px);
    padding: 16px 18px;
    border-radius: 14px;
    background: var(--ecab-surface);
    color: var(--ecab-text);
    box-shadow: var(--ecab-shadow);
}

.ecab-modal__box h3 {
    margin: 0 0 8px;
    font-size: 1.05rem;
}

.ecab-modal__hint {
    margin: 0 0 10px;
    font-size: 0.86rem;
    color: var(--ecab-muted);
}

.ecab-modal__textarea {
    width: 100%;
    box-sizing: border-box;
    border-radius: 10px;
    border: 1px solid var(--ecab-border);
    padding: 10px;
    font: inherit;
    background: var(--ecab-bg);
    color: var(--ecab-text);
    resize: vertical;
    min-height: 72px;
}

.ecab-modal__actions {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-top: 14px;
    justify-content: flex-end;
}

.ecab-modal__btn-back {
    background: var(--ecab-surface) !important;
    color: var(--ecab-text) !important;
    border: 1px solid var(--ecab-text) !important;
}

.ecab-modal__btn-danger {
    background: #fef2f2 !important;
    color: #b42318 !important;
    border: 1px solid #f04438 !important;
}

.ecab-modal__btn-primary {
    background: var(--ecab-accent) !important;
    color: #fff !important;
    border: 1px solid var(--ecab-accent) !important;
}

.ecab-dark .ecab-modal__btn-primary {
    background: #fff !important;
    color: #000 !important;
    border-color: #fff !important;
}

/* -------------------------------------------------------------------------
   Thème « shell » : pages flux chauffeur + option « tout le site » (fond noir, blanc)
   ------------------------------------------------------------------------- */
body.ecab-dispatch-shell-theme {
    background-color: #000000 !important;
    color: #ffffff !important;
}

body.ecab-dispatch-shell-theme #page,
body.ecab-dispatch-shell-theme .site,
body.ecab-dispatch-shell-theme .site-content,
body.ecab-dispatch-shell-theme #content,
body.ecab-dispatch-shell-theme main,
body.ecab-dispatch-shell-theme .content-area,
body.ecab-dispatch-shell-theme article,
body.ecab-dispatch-shell-theme .entry-content {
    background-color: transparent !important;
    color: inherit;
}

body.ecab-dispatch-shell-theme a {
    color: #ffffff;
    text-decoration-color: rgba(255, 255, 255, 0.55);
}

body.ecab-dispatch-shell-theme a:hover,
body.ecab-dispatch-shell-theme a:focus {
    color: #ffffff;
    text-decoration-color: #ffffff;
}

body.ecab-dispatch-shell-theme .ecab-auth-card--framed {
    border: 1px solid #ffffff;
    border-radius: 16px;
    padding: 20px 22px;
    background: var(--ecab-surface);
    box-shadow: 0 0 0 1px rgba(255, 255, 255, 0.06);
}

.ecab-auth-notice {
    padding: 10px 12px;
    border-radius: 10px;
    margin-bottom: 14px;
    font-size: 0.9rem;
    line-height: 1.4;
}

.ecab-auth-notice--success {
    border: 1px solid rgba(18, 183, 106, 0.65);
    background: rgba(18, 183, 106, 0.12);
    color: var(--ecab-text);
}

.ecab-auth-notice--error {
    border: 1px solid rgba(240, 68, 56, 0.65);
    background: rgba(240, 68, 56, 0.12);
    color: var(--ecab-text);
}

.ecab-auth-muted {
    color: var(--ecab-muted);
    font-size: 0.88rem;
}

.ecab-dark .ecab-btn-primary,
body.ecab-dispatch-shell-theme .ecab-btn-primary {
    background: #ffffff !important;
    color: #000000 !important;
    border: 1px solid #ffffff !important;
}

.ecab-dark .ecab-btn-primary:hover,
body.ecab-dispatch-shell-theme .ecab-btn-primary:hover {
    opacity: 0.92;
}

.ecab-dark .ecab-auth-form input,
body.ecab-dispatch-shell-theme .ecab-auth-form input {
    border-color: rgba(255, 255, 255, 0.55) !important;
    background: #0a0a0b !important;
    color: #ffffff !important;
}

.ecab-dark .ecab-icon-btn,
body.ecab-dispatch-shell-theme .ecab-icon-btn {
    border: 1px solid rgba(255, 255, 255, 0.35);
}

.ecab-btn-danger {
    background: transparent !important;
    color: #f04438 !important;
    border: 1px solid #f04438 !important;
    padding: 10px 14px;
    font-weight: 700;
    border-radius: 10px;
    cursor: pointer;
    margin-top: 16px;
}

.ecab-dark .ecab-btn-danger,
body.ecab-dispatch-shell-theme .ecab-btn-danger {
    color: #fca5a5 !important;
    border-color: #fca5a5 !important;
}

.ecab-settings-signout {
    display: inline-block;
    margin-top: 4px;
    text-decoration: none !important;
    text-align: center;
    width: 100%;
    box-sizing: border-box;
}

.ecab-auth-title,
.ecab-pending-title,
h2.ecab-auth-title {
    color: var(--ecab-text) !important;
}

body.ecab-dispatch-shell-theme .entry-title,
body.ecab-dispatch-shell-theme .entry-header h1,
body.ecab-dispatch-shell-theme .wp-block-post-title,
body.ecab-dispatch-shell-theme .elementor-heading-title {
    color: #ffffff !important;
}

.ecab-pending-subtitle {
    margin: 1.25rem 0 0.5rem;
    font-size: 1rem;
    color: var(--ecab-text);
}

.ecab-pending-actions-bar {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 10px;
    margin-top: 1rem;
    padding-top: 1rem;
    border-top: 1px solid var(--ecab-border);
}

.ecab-pending-edit-open {
    border: 1px solid var(--ecab-text) !important;
    background: var(--ecab-surface) !important;
    color: var(--ecab-text) !important;
}

.ecab-dark .ecab-pending-edit-open {
    border-color: #ffffff !important;
    color: #ffffff !important;
    background: #121214 !important;
}

.ecab-pending-cancel-inline {
    margin: 0;
}

.ecab-btn-danger--compact {
    margin-top: 0 !important;
    padding: 10px 14px !important;
}

.ecab-pending-edit-panel {
    margin-top: 1rem;
    padding-top: 1rem;
    border-top: 1px solid var(--ecab-border);
}

.ecab-pending-edit-form {
    margin-top: 0.75rem;
}

