/* TIKUR AZMUD Design System - Uber Theme */
:root {
    /* Colors - High Contrast Black/White */
    --primary-color: #000000;
    --primary-hover: #333333;
    --secondary-color: #276EF1;
    /* Uber Blue for links/accents if needed, otherwise Black */
    --accent-color: #000000;

    --bg-color: #FFFFFF;
    /* Uber uses lots of white or very light gray #F6F6F6 */
    --surface-color: #FFFFFF;

    --text-primary: #000000;
    --text-secondary: #5E5E5E;
    /* Dark Gray */
    --text-muted: #AFAFAF;

    --border-color: #E2E2E2;

    --success-color: #059c5b;
    /* Uber Green */
    --warning-color: #FFC043;
    --danger-color: #E11900;

    /* Typography - Inter (Clean Sans) */
    --font-family: 'Inter', system-ui, -apple-system, sans-serif;

    /* Spacing & Radius - Boxy/Minimal */
    --radius-sm: 4px;
    --radius-md: 8px;
    /* Slightly rounded */
    --radius-lg: 12px;

    --shadow-sm: none;
    /* Flat design */
    --shadow-md: 0 4px 16px rgba(0, 0, 0, 0.08);
    /* Subtle lift for floating elements */
}

/* Reset & Base */
* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

body {
    font-family: var(--font-family);
    background-color: var(--bg-color);
    color: var(--text-primary);
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
}

h1,
h2,
h3,
h4 {
    color: var(--text-primary);
    font-weight: 700;
    /* Bold headings */
    line-height: 1.2;
    margin-bottom: 1rem;
    letter-spacing: -0.02em;
    /* Tight spacing like Uber Move */
}

h1 {
    font-size: 36px;
}

h2 {
    font-size: 28px;
}

h3 {
    font-size: 20px;
}

a {
    color: var(--text-primary);
    text-decoration: none;
    font-weight: 500;
}

a:hover {
    text-decoration: underline;
}

/* Components */
.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 2rem;
}

/* Navbar - Black Header */
.navbar {
    background-color: #000000;
    color: #FFFFFF;
    padding: 1.2rem 0;
    position: sticky;
    top: 0;
    z-index: 100;
    width: 100%;
    max-width: 100%;
    box-sizing: border-box;
    left: 0;
    right: 0;
}

.nav-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 2rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
    box-sizing: border-box;
    width: 100%;
}

.nav-brand {
    font-size: 1.5rem;
    font-weight: 500;
    color: #FFFFFF;
    letter-spacing: -1px;
}

.nav-brand:hover {
    color: #FFFFFF;
    text-decoration: none;
}

.nav-links {
    display: flex;
    gap: 2rem;
}

/* Default Desktop Nav */
.desktop-nav {
    display: flex;
    gap: 2rem;
    align-items: center;
}

/* Default Mobile Drawer (Hidden on Desktop) */
.mobile-nav-drawer {
    display: none;
}

.nav-links a {
    color: #FFFFFF;
    font-weight: 500;
    opacity: 0.9;
}

.nav-links a:hover {
    opacity: 1;
    text-decoration: none;
}

/* Buttons - Solid Black */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 12px 24px;
    border-radius: 9999px;
    /* Pill shape (Uber often uses this or 8px) OR 8px for square look. Let's go with 8px for web platform */
    border-radius: var(--radius-md);
    font-weight: 500;
    cursor: pointer;
    border: none;
    transition: background-color 0.2s;
    font-size: 1rem;
    text-decoration: none !important;
}

.btn-primary {
    background-color: #000000;
    color: #FFFFFF;
}

.btn-primary:hover {
    background-color: #333333;
}

.btn-secondary {
    background-color: #EEEEEE;
    color: #000000;
}

.btn-secondary:hover {
    background-color: #E0E0E0;
}

.btn-danger {
    background-color: var(--danger-color);
    color: white;
}

.btn-warning {
    background-color: var(--warning-color);
    color: black;
}

.btn-outline {
    border: 1px solid #E2E2E2;
    background: transparent;
    color: var(--text-primary);
}

.btn-outline:hover {
    background: #F6F6F6;
}

.btn-block {
    width: 100%;
}

/* Cards - Minimalist */
.card {
    background: var(--surface-color);
    border: 1px solid var(--border-color);
    /* Visible border instead of shadow */
    border-radius: var(--radius-lg);
    padding: 2rem;
    margin-bottom: 2rem;
}

/* For grids, we might want to align heights */

/* Forms */
input,
select,
textarea {
    width: 100%;
    padding: 12px 16px;
    /* Larger touch targets */
    border: 2px solid transparent;
    background-color: #F6F6F6;
    /* Gray background inputs */
    border-radius: var(--radius-md);
    font-family: inherit;
    font-size: 1rem;
    color: var(--text-primary);
    margin-bottom: 1rem;
    transition: border-color 0.2s, background-color 0.2s;
}

input:focus,
select:focus,
textarea:focus {
    outline: none;
    background-color: #FFFFFF;
    border-color: #000000;
    /* Black focus border */
}

/* Utilities */
.grid-2 {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 2rem;
}

.grid-3 {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 2rem;
}

.flex-between {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.text-center {
    text-align: center;
}

.text-muted {
    color: var(--text-secondary);
}

.text-sm {
    font-size: 0.875rem;
}

.mb-2 {
    margin-bottom: 1rem;
}

.mb-4 {
    margin-bottom: 2rem;
}

/* Alerts */
.alert {
    padding: 1rem;
    border-radius: var(--radius-md);
    margin-bottom: 1rem;
    background: #F6F6F6;
    border-left: 4px solid #333;
}

.alert-success {
    border-left-color: var(--success-color);
    background: #E6F6EC;
}

.alert-warning {
    border-left-color: var(--warning-color);
    background: #FFF8E6;
}

.alert-danger {
    border-left-color: var(--danger-color);
    background: #FDE8E6;
}

/* Badges */
.badge {
    padding: 4px 8px;
    border-radius: 4px;
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.badge-success {
    background: #E6F6EC;
    color: var(--success-color);
}

.badge-warning {
    background: #fef3c7;
    color: #92400e;
}

.badge-danger {
    background: #fee2e2;
    color: #991b1b;
}

.badge-gray {
    background: #EEEEEE;
    color: #555;
}

/* Tables */
table {
    width: 100%;
    border-collapse: collapse;
}

th {
    text-align: left;
    padding: 1rem;
    color: var(--text-secondary);
    font-weight: 500;
    font-size: 0.875rem;
    border-bottom: 1px solid var(--border-color);
}

td {
    padding: 1rem;
    border-bottom: 1px solid #F0F0F0;
    vertical-align: middle;
}

.table-responsive {
    overflow-x: auto;
}

/* Mobile Menu Toggle */
.menu-toggle {
    display: none;
    background: none;
    border: none;
    color: white;
    font-size: 1.5rem;
    cursor: pointer;
    padding: 0.5rem;
}

/* Dropdown Styles (Desktop Default) */
.glass-dropdown {
    position: absolute;
    top: 100%;
    right: -50px;
    width: 320px;
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border: 1px solid rgba(255, 255, 255, 0.5);
    border-radius: 16px;
    box-shadow: 0 10px 40px -10px rgba(0, 0, 0, 0.15), 0 0 0 1px rgba(0, 0, 0, 0.05);
    transform: translateY(-20px) scale(0.95);
    opacity: 0;
    pointer-events: none;
    transition: all 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
    z-index: 2000;
    overflow: hidden;
    margin-top: 15px;
}

.glass-dropdown.active {
    transform: translateY(0) scale(1);
    opacity: 1;
    pointer-events: all;
}

.dropdown-header {
    padding: 12px 16px;
    border-bottom: 1px solid rgba(0, 0, 0, 0.05);
    font-weight: 700;
    color: #111827;
    font-size: 0.95rem;
    background: rgba(255, 255, 255, 0.5);
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.dropdown-list {
    max-height: 350px;
    overflow-y: auto;
}

.dropdown-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 16px;
    border-bottom: 1px solid rgba(0, 0, 0, 0.03);
    cursor: pointer;
    transition: background 0.2s;
    text-decoration: none;
}

.dropdown-item:hover {
    background: rgba(59, 130, 246, 0.05);
}

.dd-avatar {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: #f3f4f6;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #9ca3af;
    flex-shrink: 0;
    object-fit: cover;
}

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

.dd-name {
    color: #1f2937;
    font-weight: 600;
    font-size: 0.9rem;
    margin-bottom: 2px;
    display: flex;
    justify-content: space-between;
}

.dd-preview {
    color: #6b7280;
    font-size: 0.8rem;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.dd-time {
    font-size: 0.7rem;
    color: #9ca3af;
    font-weight: 400;
}

.unread-dot {
    width: 8px;
    height: 8px;
    background: #3b82f6;
    border-radius: 50%;
    margin-left: 8px;
}

/* Responsive */
@media (max-width: 768px) {
    @keyframes mobileDrawerChildIn {
        from {
            opacity: 0;
            transform: translate3d(22px, 0, 0);
        }

        to {
            opacity: 1;
            transform: translate3d(0, 0, 0);
        }
    }

    .menu-toggle {
        display: block;
        min-width: 44px;
        min-height: 44px;
        box-sizing: border-box;
    }

    .grid-2,
    .grid-3 {
        grid-template-columns: 1fr;
    }

    .container,
    .nav-container {
        padding: 0 1rem;
    }


    /* Mobile Navigation - Slide-out Drawer */
    .mobile-nav-drawer {
        display: flex;
        position: fixed;
        top: 0;
        right: 0;
        bottom: 0;
        width: 280px;
        max-width: min(280px, 100vw);
        height: 100vh;
        height: 100dvh;
        box-sizing: border-box;
        /* Full viewport height */
        background: rgba(0, 0, 0, 0.85);
        backdrop-filter: blur(10px);
        -webkit-backdrop-filter: blur(10px);
        display: flex;
        /* Ensure flex context */
        flex-direction: column;
        flex-wrap: nowrap;
        align-items: stretch;
        padding: calc(2rem + env(safe-area-inset-top, 0px)) max(1.5rem, env(safe-area-inset-right, 0px)) max(2rem, env(safe-area-inset-bottom, 0px)) 1.5rem;
        gap: 1.5rem;
        box-shadow: -4px 0 20px rgba(0, 0, 0, 0.5);
        z-index: 1001;
        transform: translate3d(100%, 0, 0);
        transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1);
        border-top: none;
        border-left: 1px solid rgba(255, 255, 255, 0.1);
        overflow-x: hidden;
        overflow-y: auto;
        -webkit-overflow-scrolling: touch;
        overscroll-behavior: contain;
        overscroll-behavior-x: none;
        touch-action: pan-y;
    }

    .mobile-nav-drawer > * {
        min-width: 0;
        max-width: 100%;
        opacity: 0;
        transform: translate3d(22px, 0, 0);
    }

    .mobile-nav-drawer:not(.active) > * {
        animation: none;
        opacity: 0;
        transform: translate3d(22px, 0, 0);
    }

    .mobile-nav-drawer.active > * {
        animation: mobileDrawerChildIn 0.48s cubic-bezier(0.22, 1, 0.36, 1) forwards;
    }

    .mobile-nav-drawer.active > *:nth-child(1) {
        animation-delay: 0.04s;
    }

    .mobile-nav-drawer.active > *:nth-child(2) {
        animation-delay: 0.1s;
    }

    .mobile-nav-drawer.active > *:nth-child(3) {
        animation-delay: 0.16s;
    }

    .mobile-nav-drawer.active > *:nth-child(4) {
        animation-delay: 0.22s;
    }

    .mobile-nav-drawer.active > *:nth-child(5) {
        animation-delay: 0.28s;
    }

    .mobile-nav-drawer.active > *:nth-child(6) {
        animation-delay: 0.34s;
    }

    .mobile-nav-drawer.active > *:nth-child(7) {
        animation-delay: 0.4s;
    }

    .mobile-nav-drawer.active > *:nth-child(8) {
        animation-delay: 0.46s;
    }

    .mobile-nav-drawer.active > *:nth-child(9) {
        animation-delay: 0.52s;
    }

    .mobile-nav-drawer.active > *:nth-child(10) {
        animation-delay: 0.58s;
    }

    .mobile-nav-drawer.active > *:nth-child(11) {
        animation-delay: 0.64s;
    }

    .mobile-nav-drawer.active > *:nth-child(12) {
        animation-delay: 0.7s;
    }

    @media (prefers-reduced-motion: reduce) {
        .mobile-nav-drawer > *,
        .mobile-nav-drawer:not(.active) > *,
        .mobile-nav-drawer.active > * {
            animation: none !important;
            opacity: 1 !important;
            transform: none !important;
            transition: none !important;
        }
    }

    /* Rating Overlay Badge */
    .mobile-rating-badge {
        position: absolute;
        top: 0;
        right: -25px;
        background: #f59e0b;
        /* Amber-500 */
        color: white;
        font-size: 0.75rem;
        font-weight: 700;
        padding: 2px 6px;
        border-radius: 10px;
        border: 2px solid rgba(0, 0, 0, 0.8);
        /* Dark border */
        box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
        display: flex;
        align-items: center;
        gap: 3px;
    }

    .mobile-rating-badge i {
        font-size: 0.65rem;
    }

    /* Helper drawer: rating pill sits on the avatar (bottom-right overlap) */
    .mobile-rating-badge--avatar-corner {
        top: auto;
        left: auto;
        right: -4px;
        bottom: 2px;
        border-radius: 999px;
        padding: 4px 8px;
        font-size: 0.65rem;
        font-weight: 800;
        z-index: 2;
        max-width: calc(100vw - 6rem);
        white-space: nowrap;
        border: 2px solid rgba(0, 0, 0, 0.88);
        box-shadow: 0 2px 10px rgba(0, 0, 0, 0.28);
    }

    .mobile-rating-badge__sep {
        opacity: 0.9;
        font-weight: 700;
        margin: 0 1px;
    }

    .mobile-avatar--helper i {
        font-size: 2rem;
        color: rgba(255, 255, 255, 0.75);
    }

    .mobile-helper-dash-section,
    .mobile-customer-dash-section {
        width: 100%;
        margin: 0.15rem 0 0.85rem;
        padding-bottom: 0.35rem;
        border-bottom: none;
        text-align: left;
    }

    .mobile-helper-dash-label {
        margin: 0 0 0.4rem;
        padding: 0;
        font-size: 0.68rem;
        font-weight: 800;
        text-transform: uppercase;
        letter-spacing: 0.08em;
        color: rgba(255, 255, 255, 0.5);
    }

    .mobile-helper-jobs-link span,
    .mobile-customer-jobs-link span {
        display: inline-flex;
        align-items: center;
        gap: 0.5rem;
        min-width: 0;
    }

    /* Hide the redundant profile link inside drawer */
    .mobile-nav-drawer .nav-profile-link {
        display: none !important;
    }

    .mobile-nav-drawer.active {
        transform: translate3d(0, 0, 0);
    }

    /* Hide Desktop Nav on Mobile */
    .desktop-nav {
        display: none !important;
    }

    /* Backdrop Overlay */
    .nav-overlay {
        position: fixed;
        top: 0;
        left: 0;
        right: 0;
        bottom: 0;
        background: rgba(0, 0, 0, 0.6);
        z-index: 1000;
        opacity: 0;
        pointer-events: none;
        transition: opacity 0.3s ease;
        backdrop-filter: blur(3px);
    }

    .nav-overlay.active {
        opacity: 1;
        pointer-events: auto;
    }

    /* Stop the page behind the drawer from scrolling / rubber-banding (stops “wobbly” menu feel) */
    html.nav-drawer-open,
    body.nav-drawer-open {
        overflow: hidden !important;
        overscroll-behavior: none;
    }

    /* Fullscreen mobile messages panel (reparented under body) — lock page scroll */
    html.chat-overlay-open,
    body.chat-overlay-open {
        overflow: hidden !important;
        overscroll-behavior: none;
    }

    /* Links inside the drawer — pan-y only so the panel doesn’t shift horizontally while scrolling */
    .mobile-nav-drawer a,
    .mobile-nav-drawer a:hover,
    .mobile-nav-drawer a:focus,
    .mobile-nav-drawer a:focus-visible,
    .mobile-nav-drawer a:visited,
    .mobile-nav-drawer a:active {
        text-decoration: none !important;
        text-underline-offset: 0;
    }

    .mobile-nav-drawer a {
        display: block;
        padding: 0.75rem 0;
        font-size: 1.1rem;
        color: #FFFFFF;
        border-bottom: none;
        touch-action: pan-y;
        -webkit-tap-highlight-color: transparent;
    }

    /* Rounded row + press state (same language as broker drawer links) */
    .mobile-nav-drawer a.mobile-helper-jobs-link,
    .mobile-nav-drawer a.mobile-customer-jobs-link,
    .mobile-nav-drawer > a:not(.nav-profile-link) {
        display: flex !important;
        align-items: center;
        gap: 0.65rem;
        min-height: 48px;
        border-radius: 10px;
        padding: 0.45rem 0.5rem !important;
        margin: 0.12rem 0;
        border-bottom: none !important;
        font-size: 1.05rem !important;
        touch-action: pan-y;
        transition: background 0.15s ease, box-shadow 0.15s ease;
    }

    .mobile-nav-drawer a.mobile-helper-jobs-link,
    .mobile-nav-drawer a.mobile-customer-jobs-link {
        justify-content: flex-start;
        font-weight: 600;
    }

    .mobile-nav-drawer > a.btn-outline {
        justify-content: center;
    }

    /* Press feedback — current route uses .is-active (below) so highlight stays */
    .mobile-nav-drawer a.mobile-helper-jobs-link:hover,
    .mobile-nav-drawer a.mobile-helper-jobs-link:active,
    .mobile-nav-drawer a.mobile-customer-jobs-link:hover,
    .mobile-nav-drawer a.mobile-customer-jobs-link:active,
    .mobile-nav-drawer > a:not(.nav-profile-link):hover,
    .mobile-nav-drawer > a:not(.nav-profile-link):active {
        background: rgba(255, 255, 255, 0.12);
        box-shadow: 0 2px 10px rgba(0, 0, 0, 0.22);
    }

    .mobile-nav-drawer a.mobile-helper-jobs-link.is-active,
    .mobile-nav-drawer a.mobile-customer-jobs-link.is-active,
    .mobile-nav-drawer > a:not(.nav-profile-link).is-active {
        background: rgba(255, 255, 255, 0.12);
        box-shadow: 0 2px 10px rgba(0, 0, 0, 0.22);
        font-weight: 600;
    }

    .mobile-nav-drawer a.mobile-helper-jobs-link.is-active:hover,
    .mobile-nav-drawer a.mobile-customer-jobs-link.is-active:hover,
    .mobile-nav-drawer > a:not(.nav-profile-link).is-active:hover {
        background: rgba(255, 255, 255, 0.14);
    }

    .mobile-nav-drawer .btn-mobile-edit {
        transition: background 0.15s ease, box-shadow 0.15s ease;
    }

    .mobile-nav-drawer .btn-mobile-edit:hover,
    .mobile-nav-drawer .btn-mobile-edit:active {
        background: rgba(255, 255, 255, 0.24);
        box-shadow: 0 2px 10px rgba(0, 0, 0, 0.2);
    }

    .mobile-nav-drawer .broker-mobile-drawer-link:hover,
    .mobile-nav-drawer .broker-mobile-drawer-link:active {
        background: rgba(255, 255, 255, 0.14);
        box-shadow: 0 2px 10px rgba(0, 0, 0, 0.2);
    }

    .mobile-nav-drawer .nav-lang {
        margin-right: 0 !important;
        padding-right: 0 !important;
        border-right: none !important;
        justify-content: flex-start;
        align-self: stretch;
        width: 100%;
        flex-wrap: wrap;
        gap: 0.2rem 0.65rem;
        padding-top: 0.35rem;
        padding-bottom: 0.5rem;
    }

    .mobile-nav-drawer .nav-lang a {
        display: inline !important;
        padding: 0.3rem 0.2rem !important;
        border-bottom: none !important;
    }

    .mobile-nav-drawer .mobile-drawer-icon-row {
        display: flex;
        flex-direction: row;
        align-items: center;
        justify-content: flex-start;
        flex-wrap: nowrap;
        column-gap: 0.35rem;
        padding: 0.1rem 0 0.75rem;
        width: 100%;
        box-sizing: border-box;
    }

    /* Icon row only: do not let the global drawer rule `width:100%` on .nav-item-dropdown
       stretch this flex child — that was forcing a huge empty band between bell and messages. */
    .mobile-nav-drawer .mobile-drawer-icon-row .nav-vim-bell-wrap {
        margin-right: 0 !important;
        flex: 0 0 auto;
        width: auto !important;
        max-width: none;
    }

    .mobile-nav-drawer .mobile-drawer-icon-row .nav-item-dropdown {
        margin-right: 0 !important;
        margin-left: 0 !important;
        flex: 0 0 auto;
        width: auto !important;
        max-width: none;
        min-width: 0;
    }

    .mobile-nav-drawer .mobile-drawer-icon-row > .nav-vim-bell-wrap > a,
    .mobile-nav-drawer .mobile-drawer-icon-row .nav-item-dropdown > a[onclick*="toggleChatDropdown"] {
        padding: 0 !important;
    }

    .mobile-nav-drawer .mobile-drawer-icon-row .fa-bell,
    .mobile-nav-drawer .mobile-drawer-icon-row .fa-comment-dots {
        font-size: 1.15rem;
        line-height: 1;
        vertical-align: middle;
    }

    /* Mobile Profile Header Styles */
    .mobile-profile-header {
        text-align: center;
        padding-bottom: 1.5rem;
        border-bottom: 1px solid rgba(255, 255, 255, 0.2);
        margin-bottom: 0.5rem;
        display: flex;
        flex-direction: column;
        align-items: center;
        gap: 0.75rem;
    }

    .mobile-avatar-container {
        margin-bottom: 0.25rem;
    }

    .mobile-avatar {
        width: 80px;
        height: 80px;
        border-radius: 50%;
        object-fit: cover;
        border: 3px solid rgba(255, 255, 255, 0.8);
        box-shadow: 0 4px 6px rgba(0, 0, 0, 0.3);
    }

    .mobile-avatar.placeholder {
        background: rgba(255, 255, 255, 0.1);
        display: flex;
        align-items: center;
        justify-content: center;
    }

    .mobile-avatar.placeholder i {
        font-size: 2.5rem;
        color: rgba(255, 255, 255, 0.7);
    }

    .mobile-user-info {
        color: white;
    }

    .mobile-username {
        font-size: 1.25rem;
        font-weight: 700;
        letter-spacing: -0.025em;
    }

    .mobile-user-role {
        font-size: 0.85rem;
        color: rgba(255, 255, 255, 0.7);
        margin-top: 2px;
    }

    .btn-mobile-edit {
        margin-top: 0.5rem;
        background: rgba(255, 255, 255, 0.15);
        color: white !important;
        border: 1px solid rgba(255, 255, 255, 0.3);
        padding: 0.5rem 1.5rem !important;
        border-radius: 20px;
        font-size: 0.9rem !important;
        text-decoration: none !important;
        transition: background 0.2s;
        display: inline-flex;
        align-items: center;
        gap: 8px;
    }

    .btn-mobile-edit:hover,
    .btn-mobile-edit:focus {
        background: rgba(255, 255, 255, 0.25);
        text-decoration: none !important;
    }

    /* Responsive Utilities for Dashboard Cleanup */
    @media (max-width: 900px) {
        .hide-on-mobile {
            display: none !important;
        }

        .desktop-profile-section {
            display: none !important;
        }
    }

    /* Close Button inside Drawer */
    .nav-close-btn {
        align-self: flex-end;
        background: none;
        border: none;
        color: #FFFFFF;
        font-size: 1.5rem;
        cursor: pointer;
        padding: 0.5rem;
        margin-bottom: 1rem;
        display: block;
    }

    /* Full-width stack items in drawer (not the bell+messages row — those live in .mobile-drawer-icon-row). */
    .nav-lang,
    .nav-profile-link {
        width: 100%;
        justify-content: flex-start;
    }

    /* Adjust dropdowns for mobile */
    .glass-dropdown {
        position: static;
        /* Stack naturally in drawer */
        width: 100%;
        /* Default width inside drawer if not active */
        box-shadow: none;
        border: 1px solid #e5e7eb;
        background: #f9fafb;
        transform: none !important;
        opacity: 1 !important;
        pointer-events: auto !important;
        display: none;
        /* Hidden by default, toggled via JS if needed */
        margin-top: 0.5rem;
    }

    /* Full Screen Chat Dropdown on Mobile */
    .glass-dropdown.active {
        position: fixed !important;
        top: 0 !important;
        left: 0 !important;
        width: 100vw !important;
        height: 100vh !important;
        border-radius: 0 !important;
        transform: none !important;
        background: rgba(0, 0, 0, 0.9) !important;
        /* Transparent Black */
        backdrop-filter: blur(5px);
        display: flex !important;
        flex-direction: column;
        z-index: 99999 !important;
        /* Highest priority */
        margin: 0 !important;
        padding: 0 !important;
        border: none !important;
    }

    .glass-dropdown.active .dropdown-header {
        background: rgba(0, 0, 0, 0.8);
        color: white;
        padding: 1rem 1.5rem;
        border-bottom: 1px solid rgba(255, 255, 255, 0.1);
        font-size: 1.1rem;
        font-weight: 600;
    }

    .glass-dropdown.active .dropdown-list {
        flex: 1;
        max-height: none !important;
        overflow-y: auto;
    }

    .glass-dropdown.active .dropdown-item {
        border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    }

    .glass-dropdown.active .dropdown-item:hover {
        background: rgba(255, 255, 255, 0.1);
    }

    .glass-dropdown.active .dd-name {
        color: #f3f4f6;
        /* Light gray text */
    }

    .glass-dropdown.active .dd-preview,
    .glass-dropdown.active .dd-time {
        color: #9ca3af;
        /* Muted gray */
    }

    .glass-dropdown.active .mobile-chat-close {
        display: block !important;
        color: white !important;
    }

    /* Adjust profile/dashboard links */
    .nav-profile-link {
        border-top: none;
        padding-top: 0.75rem;
        margin-top: 0;
    }
}

/* Skill Components */
.skills-container {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    margin-top: 0.5rem;
}

.skill-tag {
    background: #f3f4f6;
    color: #374151;
    padding: 4px 12px;
    border-radius: 999px;
    font-size: 0.8rem;
    font-weight: 500;
    border: 1px solid #e5e7eb;
    transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
    display: inline-block;
    user-select: none;
}

.skill-tag:hover {
    background: #e5e7eb;
    border-color: #d1d5db;
}

/* Interactive Skill Selection (for forms) */
.skill-selector {
    display: flex;
    flex-wrap: wrap;
    gap: 0.6rem;
    padding: 1.25rem;
    background: #ffffff;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    max-height: 250px;
    overflow-y: auto;
    box-shadow: inset 0 2px 4px rgba(0, 0, 0, 0.02);
}

.skill-checkbox-label {
    position: relative;
    cursor: pointer;
    margin: 0 !important;
}

.skill-checkbox-label input {
    position: absolute;
    opacity: 0;
    cursor: pointer;
    height: 0;
    width: 0;
    margin: 0 !important;
}

.skill-checkbox-label .skill-tag {
    cursor: pointer;
}

.skill-checkbox-label input:checked+.skill-tag {
    background: #000;
    color: #fff;
    border-color: #000;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

.skill-checkbox-label:hover .skill-tag {
    background: #f3f4f6;
    border-color: #000;
}

/* Section Header for Skills */
.skill-section-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-top: 1.5rem;
    margin-bottom: 0.75rem;
}

.skill-section-header h4 {
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    color: var(--text-secondary);
    margin: 0;
    font-weight: 600;
}

/* Match Score Badge */
.match-badge {
    background: #000;
    color: white;
    padding: 4px 10px;
    border-radius: 6px;
    font-size: 0.75rem;
    font-weight: 700;
    display: inline-flex;
    align-items: center;
    gap: 4px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

/* Form Polish */
.form-section {
    background: #FFFFFF;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    padding: 1.5rem;
    margin-bottom: 2rem;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.05);
}

.form-section-title {
    font-size: 1.1rem;
    font-weight: 600;
    margin-bottom: 1.25rem;
    padding-bottom: 0.75rem;
    border-bottom: 1px solid var(--border-color);
    color: var(--primary-color);
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.form-section-title i {
    color: var(--text-secondary);
}

.file-upload-wrapper {
    position: relative;
    overflow: hidden;
    display: inline-block;
    width: 100%;
}

.file-upload-wrapper input[type=file] {
    font-size: 100px;
    position: absolute;
    left: 0;
    top: 0;
    opacity: 0;
    cursor: pointer;
}

.file-upload-btn {
    border: 2px dashed var(--border-color);
    color: var(--text-secondary);
    background-color: #FAFAFA;
    padding: 1.5rem;
    border-radius: var(--radius-md);
    font-size: 0.9rem;
    font-weight: 500;
    cursor: pointer;
    width: 100%;
    text-align: center;
    transition: all 0.2s;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.5rem;
}

.file-upload-wrapper:hover .file-upload-btn {
    border-color: var(--primary-color);
    background-color: #F0F0F0;
    color: var(--primary-color);
}

.helper-steps {
    display: flex;
    justify-content: center;
    margin-bottom: 2rem;
    gap: 1rem;
}

.step-dot {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: #E0E0E0;
}

.step-dot.active {
    background: #000;
}

/* --------------------------------------------------------------------------
   Change password — standalone (/change-password) + profile embed
   -------------------------------------------------------------------------- */

.cp-pw-page {
    max-width: 460px;
    margin: 2.5rem auto 3rem;
    padding: 0 1.25rem;
    font-family: var(--font-family);
}

.cp-pw-shell {
    background: var(--surface-color);
    border: 3px solid #0a0a0a;
    border-radius: 18px;
    overflow: hidden;
    box-shadow: 0 12px 40px rgba(0, 0, 0, 0.12), 0 2px 8px rgba(0, 0, 0, 0.06);
}

.cp-pw-hero {
    background: linear-gradient(135deg, #0b0f19 0%, #1a2236 100%);
    color: #fff;
    text-align: center;
    padding: 2.35rem 1.75rem 2rem;
    border-bottom: 3px solid #0a0a0a;
}

.cp-pw-hero-icon {
    width: 58px;
    height: 58px;
    margin: 0 auto 1.1rem;
    border-radius: 16px;
    background: rgba(255, 255, 255, 0.07);
    border: 1px solid rgba(255, 255, 255, 0.14);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.45rem;
    color: #9ca3af;
}

.cp-pw-title {
    font-size: 1.55rem;
    font-weight: 700;
    margin: 0 0 0.45rem;
    letter-spacing: -0.02em;
    color: #9ca3af;
}

.cp-pw-subtitle {
    margin: 0 auto;
    max-width: 22rem;
    font-size: 0.88rem;
    line-height: 1.55;
    color: #9ca3af;
    font-weight: 400;
}

.cp-pw-body {
    padding: 2rem 2rem 1.75rem;
}

.cp-pw-form .cp-pw-field {
    margin-bottom: 1.2rem;
}

.cp-pw-form .cp-pw-field:last-of-type {
    margin-bottom: 0.25rem;
}

.cp-pw-form .cp-pw-label {
    display: block;
    font-size: 0.82rem;
    font-weight: 600;
    color: #111827;
    margin-bottom: 0.4rem;
    letter-spacing: 0.01em;
}

.cp-pw-form .cp-pw-input {
    width: 100%;
    box-sizing: border-box;
    padding: 0.72rem 0.95rem;
    font-size: 0.92rem;
    font-family: inherit;
    border-radius: 10px;
    border: 2px solid #b91c1c;
    background: #fff5f5;
    color: #111827;
    transition: border-color 0.2s ease, box-shadow 0.2s ease, background-color 0.2s ease;
}

.cp-pw-form .cp-pw-input::placeholder {
    color: #9ca3af;
    letter-spacing: 0.08em;
}

.cp-pw-form .cp-pw-input:hover {
    border-color: #991b1b;
    background: #fff;
}

.cp-pw-form .cp-pw-input:focus {
    outline: none;
    border-color: #7f1d1d;
    background: #fff;
    box-shadow: 0 0 0 3px rgba(185, 28, 28, 0.22);
}

.cp-pw-form .cp-pw-submit {
    width: 100%;
    margin-top: 1.35rem;
    padding: 0.88rem 1.1rem;
    border: none;
    border-radius: 11px;
    background: #0a0a0a;
    color: #fff;
    font-weight: 700;
    font-size: 0.95rem;
    font-family: inherit;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.55rem;
    transition: background 0.2s ease, transform 0.12s ease;
}

.cp-pw-form .cp-pw-submit:hover {
    background: #262626;
}

.cp-pw-form .cp-pw-submit:active {
    transform: scale(0.99);
}

.cp-pw-footer {
    margin-top: 1.85rem;
    padding-top: 1.35rem;
    border-top: 1px solid #e5e7eb;
    text-align: center;
}

.cp-pw-back-link {
    display: inline-flex;
    align-items: center;
    gap: 0.45rem;
    font-size: 0.88rem;
    font-weight: 600;
    color: #4b5563;
    text-decoration: none;
    transition: color 0.15s ease;
}

.cp-pw-back-link:hover {
    color: #0a0a0a;
}

/* Embedded collapsible (edit profile pages) */
.cp-pw-details {
    margin-top: 1.25rem;
    padding-top: 1.25rem;
    border-top: 1px solid #e5e7eb;
}

.cp-pw-details-summary {
    cursor: pointer;
    list-style: none;
    font-weight: 700;
    font-size: 0.92rem;
    color: #111827;
    display: flex;
    align-items: center;
    gap: 0.45rem;
    padding: 0.35rem 0;
    user-select: none;
}

.cp-pw-details-summary::-webkit-details-marker {
    display: none;
}

.cp-pw-details .cp-pw-form--embed {
    margin-top: 1.1rem;
    padding: 1.1rem 1rem 0.25rem;
    border-radius: 12px;
    background: #fafafa;
    border: 1px solid #e5e7eb;
}

.cp-pw-details .cp-pw-form--embed .cp-pw-submit {
    margin-top: 1rem;
}

@media (max-width: 480px) {
    .cp-pw-page {
        margin-top: 1.5rem;
    }

    .cp-pw-body {
        padding: 1.5rem 1.25rem 1.5rem;
    }

    .cp-pw-hero {
        padding: 1.75rem 1.25rem 1.5rem;
    }
}

/* Commission payment job panel (_commission_payment_job_panel.html + _platform_deposit_banks.html) */
.cmp-card {
    display: flex;
    align-items: stretch;
    margin-bottom: 1rem;
    border-radius: 14px;
    overflow: hidden;
    border: 1px solid #e5e5e5;
    background: #fff;
    box-shadow: 0 6px 28px -12px rgba(15, 23, 42, 0.18), 0 1px 3px rgba(0, 0, 0, 0.05);
}

.cmp-card__accent {
    width: 5px;
    flex-shrink: 0;
    background: linear-gradient(180deg, #facc15 0%, #ca8a04 38%, #0a0a0a 100%);
}

.cmp-card--peer-wait {
    margin-bottom: 0.65rem;
}

.cmp-card__accent--success {
    background: linear-gradient(180deg, #4ade80 0%, #16a34a 42%, #0f172a 100%);
}

.cmp-card__head-icon--success {
    background: linear-gradient(145deg, #22c55e 0%, #15803d 100%);
    box-shadow: 0 2px 10px rgba(22, 163, 74, 0.35);
}

.cmp-card__title--success {
    color: #14532d;
}

.cmp-card__lede--success {
    margin: 0.15rem 0 0 0;
    color: #166534;
    font-weight: 600;
    font-size: 0.78rem;
}

.cmp-card__lede--wait-peer {
    margin: 0.35rem 0 0 0;
    color: #334155;
    font-weight: 600;
    font-size: 0.8rem;
    line-height: 1.4;
}

.cmp-card__body {
    flex: 1;
    min-width: 0;
    padding: 0.75rem 0.85rem 0.85rem;
}

.cmp-card__head {
    display: flex;
    align-items: flex-start;
    gap: 0.65rem;
    margin-bottom: 0.55rem;
}

.cmp-card__head-icon {
    width: 36px;
    height: 36px;
    border-radius: 10px;
    background: linear-gradient(145deg, #0a0a0a 0%, #2d2d2d 100%);
    color: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.95rem;
    flex-shrink: 0;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);
}

.cmp-card__head-copy {
    min-width: 0;
}

.cmp-card__title {
    margin: 0;
    font-size: 0.98rem;
    font-weight: 800;
    letter-spacing: -0.02em;
    color: #0a0a0a;
    line-height: 1.2;
}

.cmp-card__lede {
    margin: 0.2rem 0 0 0;
    font-size: 0.76rem;
    color: #64748b;
    line-height: 1.35;
}

.cmp-card__ref-banner {
    margin: 0 0 0.5rem 0;
    padding: 0.45rem 0.55rem;
    font-size: 0.72rem;
    font-weight: 600;
    color: #1e3a5f;
    background: #e0f2fe;
    border: 1px solid #bae6fd;
    border-radius: 8px;
    line-height: 1.35;
}

.cmp-card__formula {
    display: flex;
    flex-wrap: wrap;
    align-items: baseline;
    gap: 0.2rem 0.45rem;
    font-size: 0.72rem;
    color: #64748b;
    margin-bottom: 0.55rem;
    padding: 0.35rem 0.5rem;
    background: linear-gradient(180deg, #f8fafc 0%, #f1f5f9 100%);
    border: 1px solid #e2e8f0;
    border-radius: 9px;
}

.cmp-card__formula-pct {
    font-weight: 800;
    color: #0a0a0a;
    font-variant-numeric: tabular-nums;
}

.cmp-card__formula-of,
.cmp-card__formula-unit {
    color: #64748b;
}

.cmp-card__formula-rate {
    font-weight: 700;
    color: #334155;
    font-variant-numeric: tabular-nums;
}

.cmp-card__formula-sep {
    color: #cbd5e1;
    font-weight: 600;
}

.cmp-card__chips {
    display: flex;
    flex-wrap: wrap;
    gap: 0.4rem;
    margin-bottom: 0.55rem;
}

.cmp-chip {
    border: 1px solid #e5e7eb;
    border-radius: 10px;
    padding: 0.32rem 0.6rem 0.38rem;
    min-width: 0;
    background: #fafafa;
}

/* Glass chips — “You pay” (black frost) & “Available TAP” (green frost) */
.cmp-chip--primary,
.cmp-chip--tap {
    border-radius: 12px;
}

.cmp-chip--primary {
    border: none;
    background: linear-gradient(
        145deg,
        rgba(255, 255, 255, 0.14) 0%,
        rgba(38, 38, 42, 0.52) 38%,
        rgba(15, 15, 18, 0.68) 68%,
        rgba(10, 10, 10, 0.82) 100%
    );
    backdrop-filter: blur(18px) saturate(150%);
    -webkit-backdrop-filter: blur(18px) saturate(150%);
    box-shadow:
        0 8px 28px rgba(0, 0, 0, 0.22),
        inset 0 1px 0 rgba(255, 255, 255, 0.16),
        inset 0 -1px 0 rgba(0, 0, 0, 0.32);
}

.cmp-chip--primary .cmp-chip__lbl,
.cmp-chip--primary .cmp-chip__val {
    color: #f8fafc;
    text-shadow: 0 1px 2px rgba(0, 0, 0, 0.5);
}

.cmp-chip--tap {
    border: none;
    background: linear-gradient(
        145deg,
        rgba(255, 255, 255, 0.35) 0%,
        rgba(167, 243, 208, 0.42) 38%,
        rgba(16, 185, 129, 0.4) 72%,
        rgba(5, 120, 85, 0.48) 100%
    );
    backdrop-filter: blur(18px) saturate(175%);
    -webkit-backdrop-filter: blur(18px) saturate(175%);
    box-shadow:
        0 8px 28px rgba(5, 120, 85, 0.2),
        inset 0 1px 0 rgba(255, 255, 255, 0.55),
        inset 0 -1px 0 rgba(5, 90, 65, 0.18);
}

.cmp-chip--tap .cmp-chip__lbl {
    color: rgba(6, 78, 59, 0.92);
    text-shadow: 0 1px 0 rgba(255, 255, 255, 0.35);
}

.cmp-chip--tap .cmp-chip__val {
    color: #064e3b;
    text-shadow: 0 1px 0 rgba(255, 255, 255, 0.25);
}

.cmp-chip--secondary {
    border: 1px solid #e2e8f0;
    background: #f8fafc;
}

.cmp-chip--secondary .cmp-chip__lbl {
    color: #64748b;
}

.cmp-chip--secondary .cmp-chip__val {
    color: #0f172a;
}

.cmp-chip__lbl {
    display: block;
    font-size: 0.6rem;
    font-weight: 700;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    color: #6b7280;
    margin-bottom: 0.08rem;
}

.cmp-chip__val {
    font-size: 1rem;
    font-weight: 800;
    color: #0a0a0a;
    font-variant-numeric: tabular-nums;
    letter-spacing: -0.02em;
}

.cmp-deposit {
    margin: 0 0 0.5rem 0;
    padding: 0.4rem 0.5rem 0.45rem;
    background: #fafafa;
    border: 1px solid #ececec;
    border-radius: 10px;
}

.cmp-deposit__head {
    display: flex;
    align-items: center;
    gap: 0.35rem;
    margin-bottom: 0.35rem;
}

.cmp-deposit__head-ic {
    font-size: 0.72rem;
    color: #0a0a0a;
    opacity: 0.85;
}

.cmp-deposit__head-txt {
    font-size: 0.6rem;
    font-weight: 800;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    color: #737373;
}

.cmp-deposit__select-label {
    display: block;
    font-size: 0.68rem;
    font-weight: 700;
    color: #525252;
    margin-bottom: 0.3rem;
    line-height: 1.3;
}

.cmp-deposit__select {
    display: block;
    width: 100%;
    max-width: 100%;
    box-sizing: border-box;
    margin: 0 0 0.4rem 0;
    padding: 0.55rem 0.65rem;
    font-size: max(16px, 0.88rem);
    font-weight: 600;
    color: #0a0a0a;
    border: 1.5px solid #d4d4d4;
    border-radius: 9px;
    background: #fff;
    cursor: pointer;
    -webkit-appearance: none;
    appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12'%3E%3Cpath fill='%2364748b' d='M6 8L1 3h10z'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 0.65rem center;
    padding-right: 2rem;
}

.cmp-deposit__select:focus {
    outline: none;
    border-color: #0a0a0a;
    box-shadow: 0 0 0 2px rgba(10, 10, 10, 0.08);
}

.cmp-deposit__detail {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.cmp-deposit__pair {
    display: grid;
    grid-template-columns: minmax(10rem, max-content) minmax(0, 1fr);
    column-gap: 1rem;
    row-gap: 0.12rem;
    align-items: baseline;
    font-size: 0.78rem;
    line-height: 1.35;
}

.cmp-deposit__k {
    font-size: 0.64rem;
    font-weight: 700;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    color: #64748b;
    white-space: nowrap;
    padding-right: 0.15rem;
}

.cmp-deposit__v {
    font-weight: 600;
    color: #171717;
    word-break: break-word;
}

.cmp-deposit__v--mono {
    font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
    font-size: 0.84rem;
    font-weight: 700;
    letter-spacing: 0.02em;
    font-variant-numeric: tabular-nums;
}

.cmp-deposit__noscript {
    margin-top: 0.35rem;
    padding-top: 0.35rem;
    border-top: 1px dashed #e5e5e5;
    font-size: 0.72rem;
    color: #57534e;
    line-height: 1.4;
}

.cmp-deposit__noscript-bank + .cmp-deposit__noscript-bank {
    margin-top: 0.35rem;
}

@media (max-width: 420px) {
    .cmp-deposit__pair {
        grid-template-columns: 1fr;
        column-gap: 0;
        row-gap: 0.12rem;
    }

    .cmp-deposit__k {
        margin-bottom: 0.02rem;
    }

    .cmp-deposit__v {
        margin-bottom: 0.35rem;
    }
}

.cmp-deposit--empty {
    display: flex;
    gap: 0.5rem;
    align-items: flex-start;
    background: #fffbeb;
    border-color: #fde68a;
}

.cmp-deposit--empty-ic {
    flex-shrink: 0;
    margin-top: 0.05rem;
    color: #b45309;
    font-size: 1rem;
}

.cmp-deposit--empty-txt {
    margin: 0;
    font-size: 0.78rem;
    font-weight: 500;
    color: #92400e;
    line-height: 1.45;
}

.cmp-alert {
    display: flex;
    align-items: flex-start;
    gap: 0.4rem;
    padding: 0.4rem 0.5rem;
    border-radius: 8px;
    font-size: 0.75rem;
    font-weight: 600;
    line-height: 1.35;
    margin-bottom: 0.45rem;
}

.cmp-alert--danger {
    background: #fef2f2;
    border: 1px solid #fecaca;
    color: #b91c1c;
}

.cmp-alert--wait {
    background: #fffbeb;
    border: 1px solid #fde68a;
    color: #92400e;
}

.cmp-form-row {
    margin-bottom: 0.45rem;
}

.cmp-form-row__tap {
    display: flex;
    flex-wrap: nowrap;
    align-items: center;
    gap: 0.5rem;
    width: 100%;
}

.cmp-input {
    padding: 0.45rem 0.6rem;
    border: 1.5px solid #d4d4d4;
    border-radius: 8px;
    font-size: max(16px, 0.86rem);
    box-sizing: border-box;
    width: 100%;
    min-width: 0;
    transition: border-color 0.15s ease, box-shadow 0.15s ease;
}

.cmp-form-row__tap .cmp-input--tap {
    flex: 0 0 50%;
    max-width: 50%;
    min-width: 0;
    margin: 0;
    padding: 0.38rem 0.6rem;
    line-height: 1.25;
}

.cmp-input:focus {
    outline: none;
    border-color: #0a0a0a;
    box-shadow: 0 0 0 2px rgba(10, 10, 10, 0.08);
}

.cmp-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.4rem;
    font-size: 0.82rem;
    font-weight: 700;
    border-radius: 8px;
    border: none;
    cursor: pointer;
    transition: background 0.15s ease, transform 0.1s ease;
}

.cmp-btn:active {
    transform: translateY(1px);
}

.cmp-form-row__tap .cmp-btn--tap {
    flex: 0 0 auto;
    width: auto;
    min-width: 0;
    margin: 0;
    margin-top: -0.14rem;
    box-sizing: border-box;
    padding: 0.38rem 0.8rem;
    font-size: max(16px, 0.86rem);
    line-height: 1;
    border: 1.5px solid #059669;
    background: #059669;
    color: #fff;
    white-space: nowrap;
}

.cmp-btn--tap:hover {
    background: #047857;
    border-color: #047857;
}

.cmp-upload {
    margin: 0;
}

.cmp-btn--upload {
    position: relative;
    width: 100%;
    box-sizing: border-box;
    padding: 0.5rem 0.75rem;
    background: linear-gradient(180deg, #171717 0%, #0a0a0a 100%);
    color: #fff;
    border: 1px solid #0a0a0a;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.2);
}

.cmp-btn--upload:hover {
    background: linear-gradient(180deg, #2d2d2d 0%, #171717 100%);
    border-color: #171717;
    filter: none;
}

.cmp-file-input {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}

.cmp-sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}

.cmp-status {
    text-align: center;
    padding: 0.45rem 0.35rem;
    font-size: 0.8rem;
    font-weight: 700;
    border-radius: 8px;
}

.cmp-status--ok {
    background: #ecfdf5;
    border: 1px solid #a7f3d0;
    color: #047857;
}

.cmp-status--ok i {
    margin-right: 0.35rem;
}

/* --------------------------------------------------------------------------
   Market users & public: phones first (customer / helper / broker + guests)
   Staff sessions use staff-desktop-only* — excluded here.
   -------------------------------------------------------------------------- */
body.market-mobile-experience {
    -webkit-text-size-adjust: 100%;
    text-size-adjust: 100%;
}

/* Tablets + phones: keep horizontal overflow from breaking zoom / sticky header alignment */
@media (max-width: 1024px) {

    html.market-mobile-root,
    body.market-mobile-experience {
        overflow-x: clip;
        max-width: 100%;
    }

    /* Broker market UI: compact sticky header whenever sidebar is off-canvas / drawer */
    body.market-mobile-experience.broker-mobile-session .navbar {
        padding-top: calc(0.5rem + env(safe-area-inset-top, 0px));
        padding-bottom: 0.5rem;
    }

    body.market-mobile-experience.broker-mobile-session .nav-brand {
        font-size: 1.2rem;
        font-weight: 600;
        letter-spacing: -0.03em;
    }

    body.market-mobile-experience.broker-mobile-session .menu-toggle {
        font-size: 1.25rem;
        padding: 0.35rem;
        min-width: 40px;
        min-height: 40px;
    }
}

@media (max-width: 768px) {
    body.market-mobile-experience {
        overflow-x: clip;
    }

    body.market-mobile-experience .navbar {
        padding-top: calc(1.2rem + env(safe-area-inset-top, 0px));
        padding-bottom: 1.2rem;
        padding-left: max(0.75rem, env(safe-area-inset-left, 0px));
        padding-right: max(0.75rem, env(safe-area-inset-right, 0px));
    }

    body.market-mobile-experience .nav-container {
        padding-left: 0;
        padding-right: 0;
    }

    body.market-mobile-experience .container {
        padding-left: max(1rem, env(safe-area-inset-left, 0px));
        padding-right: max(1rem, env(safe-area-inset-right, 0px));
    }

    /* Official notices + messages: min 44×44 tap targets (WCAG 2.5.5) */
    body.market-mobile-experience .nav-vim-bell-wrap {
        margin-right: 0.35rem;
    }

    body.market-mobile-experience .mobile-nav-drawer .mobile-drawer-icon-row .nav-vim-bell-wrap {
        margin-right: 0 !important;
    }

    body.market-mobile-experience .nav-vim-bell {
        min-width: 44px;
        min-height: 44px;
        align-items: center;
        justify-content: center;
    }

    body.market-mobile-experience .nav-item-dropdown>a[onclick*="toggleChatDropdown"] {
        min-width: 44px;
        min-height: 44px;
        display: inline-flex;
        align-items: center;
        justify-content: center;
    }

    /* iOS: avoid auto-zoom on focus when font-size < 16px */
    body.market-mobile-experience input[type="text"],
    body.market-mobile-experience input[type="email"],
    body.market-mobile-experience input[type="tel"],
    body.market-mobile-experience input[type="password"],
    body.market-mobile-experience input[type="search"],
    body.market-mobile-experience input[type="url"],
    body.market-mobile-experience input[type="number"],
    body.market-mobile-experience select,
    body.market-mobile-experience textarea {
        font-size: 16px;
    }

    body.market-mobile-experience #flash-overlay {
        left: max(12px, env(safe-area-inset-left, 0px)) !important;
        right: max(12px, env(safe-area-inset-right, 0px)) !important;
        bottom: max(16px, env(safe-area-inset-bottom, 0px)) !important;
        align-items: stretch !important;
    }

    body.market-mobile-experience #flash-overlay .flash-toast {
        min-width: 0 !important;
        width: 100%;
        max-width: 100%;
    }

    body.market-mobile-experience .nav-brand--truncate {
        flex: 1;
        min-width: 0;
        white-space: nowrap;
        overflow: hidden;
        text-overflow: ellipsis;
    }

    body.market-mobile-experience .nav-bar-row .menu-toggle {
        flex-shrink: 0;
    }

    /* Broker mobile: slimmer sticky header (same tap targets, less vertical chrome) */
    body.market-mobile-experience.broker-mobile-session .navbar {
        padding-top: calc(0.45rem + env(safe-area-inset-top, 0px));
        padding-bottom: 0.45rem;
    }

    body.market-mobile-experience.broker-mobile-session .nav-brand {
        font-size: 1.15rem;
        font-weight: 600;
        letter-spacing: -0.03em;
    }

    body.market-mobile-experience.broker-mobile-session .menu-toggle {
        font-size: 1.25rem;
        padding: 0.35rem;
        min-width: 40px;
        min-height: 40px;
    }

    .broker-mobile-drawer-section {
        margin: 0.35rem 0 1rem;
        padding-bottom: 0.85rem;
        border-bottom: 1px solid rgba(255, 255, 255, 0.14);
    }

    .broker-mobile-drawer-label {
        font-size: 0.7rem;
        font-weight: 700;
        letter-spacing: 0.07em;
        text-transform: uppercase;
        color: rgba(255, 255, 255, 0.52);
        margin-bottom: 0.4rem;
    }

    .mobile-nav-drawer .broker-mobile-drawer-link {
        display: flex !important;
        align-items: center;
        gap: 0.65rem;
        min-height: 48px;
        border-radius: 10px;
        padding: 0.45rem 0.5rem !important;
        margin: 0.12rem 0;
        border-bottom: none !important;
        font-size: 1.05rem !important;
        touch-action: pan-y;
    }

    .mobile-nav-drawer .broker-mobile-drawer-link i {
        width: 1.35rem;
        text-align: center;
        opacity: 0.92;
    }

    .mobile-nav-drawer .broker-mobile-drawer-link.is-active {
        background: rgba(255, 255, 255, 0.12);
        color: #fff !important;
        font-weight: 600;
        box-shadow: 0 2px 10px rgba(0, 0, 0, 0.22);
    }

    .mobile-nav-drawer .broker-mobile-drawer-link.is-active:hover {
        background: rgba(255, 255, 255, 0.14);
    }
}

/* --------------------------------------------------------------------------
   Staff (admin / moderator / ops): block narrow viewports — desktop tools only
   -------------------------------------------------------------------------- */
.staff-mobile-blocker {
    display: none;
}

@media (max-width: 991px) {

    html.staff-desktop-only-root,
    body.staff-desktop-only {
        overflow: hidden !important;
        height: 100%;
        max-height: 100vh;
        width: 100%;
        touch-action: none;
    }

    body.staff-desktop-only .staff-mobile-blocker {
        display: flex;
        position: fixed;
        inset: 0;
        z-index: 200000;
        align-items: center;
        justify-content: center;
        padding: 1.25rem;
        box-sizing: border-box;
        background: rgba(15, 23, 42, 0.92);
        backdrop-filter: blur(8px);
        -webkit-backdrop-filter: blur(8px);
    }

    body.staff-desktop-only .menu-toggle {
        display: none !important;
    }

    body.staff-desktop-only .nav-overlay {
        display: none !important;
        pointer-events: none !important;
    }

    body.staff-desktop-only .mobile-nav-drawer {
        visibility: hidden !important;
        pointer-events: none !important;
    }
}

/* Printing should never show the staff mobile blocker.
   Some browsers render print preview with a narrow viewport, which can accidentally
   trigger the max-width rules above. */
@media print {
    .staff-mobile-blocker {
        display: none !important;
        visibility: hidden !important;
    }
    html.staff-desktop-only-root,
    body.staff-desktop-only {
        overflow: visible !important;
        height: auto !important;
        max-height: none !important;
        touch-action: auto !important;
    }
}

.staff-mobile-blocker__card {
    max-width: 22rem;
    width: 100%;
    background: #fff;
    border-radius: 14px;
    padding: 1.5rem 1.35rem;
    box-shadow: 0 24px 48px rgba(0, 0, 0, 0.35);
    text-align: center;
}

.staff-mobile-blocker__title {
    margin: 0 0 0.65rem;
    font-size: 1.15rem;
    font-weight: 800;
    color: #0f172a;
}

.staff-mobile-blocker__text {
    margin: 0 0 1.25rem;
    font-size: 0.9rem;
    line-height: 1.45;
    color: #475569;
}

.staff-mobile-blocker__btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    box-sizing: border-box;
    min-height: 44px;
}

/* Password + confirm live validation (.pw-pair, password-pair-validation.js) */
.pw-pair__feedback {
    font-size: 0.82rem;
    line-height: 1.35;
    margin: 0.35rem 0 0;
    min-height: 1.35em;
}

.pw-pair__feedback.is-muted {
    color: #64748b;
}

.pw-pair__feedback.is-error {
    color: #b91c1c;
    font-weight: 500;
}

.pw-pair__feedback.is-ok {
    color: #15803d;
    font-weight: 500;
}

input.pw-pair-input--neutral {
    border-color: #e5e7eb !important;
    box-shadow: none;
}

input.pw-pair-input--warn {
    border-color: #ef4444 !important;
    box-shadow: 0 0 0 2px rgba(239, 68, 68, 0.2) !important;
}

input.pw-pair-input--ok {
    border-color: #22c55e !important;
    box-shadow: 0 0 0 2px rgba(34, 197, 94, 0.18) !important;
}

.pw-pair__confirm:disabled {
    opacity: 0.55;
    cursor: not-allowed;
    background-color: #f8fafc !important;
}