 :root { 
    --apc-orange: #F7941D; 
    --apc-black: #1A1A1B; 
    --apc-charcoal: #333333;
    --apc-soft-grey: #555555;
    --apc-blue: #007AFF;        /* was hardcoded everywhere — now a variable */
    --apc-blue-bg: #0056b3;     /* used for item price colour */
    --apc-green: #28a745;       /* active badge colour */
    --apc-green-bg: #e6f4ea;
    --apc-amber: #FFF9F2;
    --apc-orange-light: #FFF4E6;
    --bg: #F4F4F4;
    --white: #ffffff; 
}

body { 
    margin: 0; 
    font-family: 'Segoe UI', sans-serif; 
    background: var(--bg); 
    padding-bottom: 90px; 
}

.sidebar-open { overflow: hidden; }

/* HEADER */
.top-nav-container {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    z-index: 3000;
    background: var(--white);
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
}

header { 
    border-bottom: 5px solid var(--apc-orange); 
    padding: 10px 15px 15px 15px; 
}

.logo-main img {
    height: 62px;
    width: auto;
    display: block;
    margin: 0;
}

/* HEADER TOP ROW — logo on left, account pill on right */
.header-top {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 12px;
    gap: 10px;
}

/* === MOBILE HEADER INBOX BUTTON === */
.header-inbox-btn {
    position: relative;
    background: none;
    border: none;
    cursor: pointer;
    color: var(--apc-orange);
    color: var(--apc-charcoal);
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 6px;
    border-radius: 8px;
    flex-shrink: 0;
}
.header-inbox-btn svg { display: block; }
.header-inbox-btn.active svg { stroke: var(--apc-orange); }

/* === NAV PROFILE CIRCLE (bottom nav) === */
.nav-profile-circle {
    width: 30px; height: 30px;
    border-radius: 50%;
    background: var(--apc-orange);
    color: white;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 13px;
    font-weight: 900;
    overflow: hidden;
    flex-shrink: 0;
}
.nav-profile-circle.pro { background: var(--apc-blue); }
.nav-profile-circle.signed-out {
    background: var(--apc-orange);
    border-radius: 20px;
    width: auto;
    padding: 0 10px;
    font-size: 12px;
    font-weight: 700;
    color: white;
    letter-spacing: 0.2px;
}

/* === ACCOUNT PILL === */
.account-pill {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 8px 14px;
    border-radius: 10px;
    font-weight: 800;
    font-size: 12px;
    letter-spacing: 0.5px;
    text-transform: uppercase;
    cursor: pointer;
    border: none;
    color: white;
    white-space: nowrap;
    box-shadow: 0 2px 6px rgba(0,0,0,0.12);
    transition: transform 0.1s ease;
    font-family: inherit;
}
.account-pill:active { transform: scale(0.97); }
.sign-up-prompt {
    display: none; /* hidden on mobile — shown via desktop media query */
    font-size: 11px;
    color: #888;
    text-align: center;
    margin-top: 6px;
    white-space: nowrap;
}
.sign-up-link {
    color: var(--apc-orange);
    font-weight: 700;
    text-decoration: none;
}
.sign-up-link:hover { text-decoration: underline; }
.account-pill.signed-out {
    background: var(--apc-orange);
    padding: 11px 22px;
    font-size: 13px;
    border-radius: 8px;
}
.account-pill.signed-in {
    background: #f8f8f8;
    padding: 6px 10px;
    border-radius: 24px;
    border: none;
    justify-content: center;
    box-shadow: 0 0 0 2px #F7941D, 0 0 8px rgba(247,148,29,0.3);
}
.account-pill.signed-in.tier-pro {
    box-shadow: 0 0 0 2px #007AFF, 0 0 8px rgba(0,122,255,0.3);
}
.pill-avatar {
    width: 34px; height: 34px;
    border-radius: 50%;
    background: var(--apc-orange);
    color: white;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 14px;
    font-weight: 900;
    flex-shrink: 0;
    overflow: hidden;
    box-shadow: none;
}
.pill-avatar.pro { background: var(--apc-blue); }

/* ACCOUNT MENU AVATAR — shared by drawer + dropdown */
.account-menu-avatar {
    width: 40px; height: 40px;
    color: white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 900;
    font-size: 16px;
    background: var(--apc-orange);
    flex-shrink: 0;
}
.account-menu-name   { font-weight: 800; font-size: 14px; }
.account-menu-status { font-size: 11px; text-transform: uppercase; letter-spacing: 0.5px; color: #aaa; margin-top: 1px; }
.account-menu-status.pro { color: var(--apc-blue); font-weight: 800; }

/* ACCOUNT MENU DRAWER — mobile */
#accountMenuDrawer { z-index: 3200; }
.amenu-section {
    background: white;
    border-bottom: 8px solid #f4f4f4;
}
.amenu-section:last-child { border-bottom: none; }
@media (min-width: 900px) { .amenu-mobile-only { display: none !important; } }
.account-menu-chevron { margin-left: auto; color: #ddd; font-size: 18px; font-weight: 400; }
.account-menu-item {
    display: flex;
    align-items: center;
    width: 100%;
    padding: 15px 20px;
    border: none;
    border-bottom: 1px solid #f4f4f4;
    background: white;
    text-align: left;
    font-size: 15px;
    font-weight: 600;
    cursor: pointer;
    color: var(--apc-charcoal);
    font-family: inherit;
    transition: background 0.12s;
}
.account-menu-item:last-child { border-bottom: none; }
.account-menu-item:hover { background: #fafafa; }
.account-menu-item:active { background: #f4f4f4; }
.account-menu-item.upgrade { color: var(--apc-blue); font-weight: 700; }
.account-menu-item.activate-search { font-weight: 700; }
.account-menu-item.activate-search.on { color: var(--apc-blue); }
.account-menu-item.logout { color: #c0392b; }

/* ACCOUNT DROPDOWN — desktop */
.acct-dropdown {
    display: none;
    position: fixed;
    right: max(0px, calc(50vw - 700px));
    top: 140px;
    width: 300px;
    background: white;
    border-radius: 14px;
    box-shadow: 0 8px 40px rgba(0,0,0,0.16), 0 2px 8px rgba(0,0,0,0.08);
    border: 1px solid #e8e8e8;
    z-index: 2001;
    overflow: hidden;
}
.acct-dropdown.active { display: block; }
.acct-dd-profile {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 18px 20px;
    background: white;
}
.acct-dd-avatar { width: 44px !important; height: 44px !important; font-size: 18px !important; }
.acct-dd-name { font-size: 15px; font-weight: 800; color: #222; }
.acct-dd-tier { font-size: 11px; font-weight: 700; text-transform: uppercase; letter-spacing: 0.5px; color: #aaa; margin-top: 2px; }
.acct-dd-tier.pro { color: var(--apc-blue); }
.acct-dd-divider { height: 1px; background: #f0f0f0; margin: 0; }
.acct-dd-group { padding: 6px 0; }
.acct-dd-item {
    display: flex;
    align-items: center;
    width: 100%;
    padding: 10px 20px;
    border: none;
    background: none;
    text-align: left;
    font-size: 14px;
    font-weight: 600;
    color: #333;
    cursor: pointer;
    font-family: inherit;
    transition: background 0.1s, color 0.1s;
}
.acct-dd-item:hover { background: #fdf6ee; color: var(--apc-orange); }
.acct-dd-chevron { margin-left: auto; color: #ddd; font-size: 16px; }
.acct-dd-item:hover .acct-dd-chevron { color: var(--apc-orange); }
.acct-dd-upgrade { color: var(--apc-blue); font-weight: 700; }
.acct-dd-upgrade:hover { background: #eef4ff; color: var(--apc-blue); }
.acct-dd-signout { color: #c0392b; }
.acct-dd-signout:hover { background: #fff5f5; color: #c0392b; }

/* DETAIL OVERLAY — icon action buttons (share + save) */
.detail-icon-btn {
    width: 44px;
    height: 44px;
    border-radius: 50%;
    border: 1.5px solid var(--apc-orange);
    background: white;
    color: var(--apc-orange);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    flex-shrink: 0;
    transition: background 0.15s, color 0.15s;
}
/* hover tint only on real pointer devices — prevents stuck highlight after tap on mobile */
@media (hover: hover) {
    .detail-icon-btn:hover { background: #fff7ef; }
}
.detail-icon-btn:active { background: #fff7ef; }
.detail-icon-btn svg { display: block; }
.detail-icon-btn.saved { background: var(--apc-orange); color: white; }
.detail-icon-btn.saved svg { fill: currentColor; }
.detail-icon-btn:focus { outline: none; background: inherit; }

/* Seller card in info col — hidden on mobile (shown in amber header instead) */
.detail-seller-col-card {
    display: none;
    align-items: center;
    gap: 12px;
    padding: 16px 15px 14px 15px;
    border-bottom: 1px solid #f0f0f0;
    cursor: pointer;
    background: #fafafa;
}

.auth-tab-bar {
    display: flex;
    gap: 8px;
    padding: 0 20px 16px;
}
.auth-error-banner {
    background: #fff1f2;
    border: 1.5px solid #f87171;
    border-radius: 8px;
    color: #991b1b;
    font-size: 13px;
    font-weight: 600;
    padding: 10px 14px;
    margin-bottom: 14px;
}
.auth-tab {
    flex: 1;
    border: 1.5px solid #ddd;
    background: white;
    color: #555;
    border-radius: 8px;
    padding: 11px 0;
    font-size: 13px;
    font-weight: 800;
    cursor: pointer;
    letter-spacing: 0.2px;
}
.auth-tab.active {
    background: var(--apc-orange);
    color: white;
    border-color: var(--apc-orange);
}

.auth-drawer-title {
    font-size: 15px;
    font-weight: 800;
    color: var(--apc-charcoal);
    letter-spacing: 0.2px;
}
.auth-join-prompt {
    text-align: center;
    font-size: 12px;
    color: #888;
    margin: 14px 0 0 0;
}

/* Sign-up choice screen */
.auth-choice-heading {
    font-size: 14px;
    font-weight: 800;
    color: #333;
    text-align: center;
    margin: 0 0 16px;
}
.auth-type-choice {
    display: flex;
    flex-direction: column;
    gap: 12px;
}
@media (min-width: 500px) {
    .auth-type-choice { flex-direction: row; }
}
.auth-type-card {
    flex: 1;
    border-radius: 14px;
    border: 2px solid #e8e8e8;
    padding: 16px 14px;
    cursor: pointer;
    display: flex;
    flex-direction: column;
    gap: 6px;
    transition: transform 0.15s, box-shadow 0.15s;
    background: white;
}
.auth-type-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(0,0,0,0.1);
}
.auth-type-personal { border-top: 4px solid var(--apc-orange); }
.auth-type-pro      { border-top: 4px solid #1d4ed8; background: #f0f5ff; }
.auth-type-pro-pill {
    display: inline-block;
    background: #1d4ed8;
    color: white;
    font-size: 9px;
    font-weight: 900;
    padding: 2px 8px;
    border-radius: 999px;
    letter-spacing: 0.6px;
    align-self: flex-start;
    margin-bottom: 2px;
}
.auth-type-title {
    font-size: 15px;
    font-weight: 900;
    color: #222;
    line-height: 1.2;
}
.auth-type-desc {
    font-size: 11px;
    color: #777;
    line-height: 1.4;
}
.auth-type-perks {
    list-style: none;
    padding: 0;
    margin: 4px 0 6px;
    display: flex;
    flex-direction: column;
    gap: 3px;
    font-size: 11px;
    color: #444;
    flex: 1;
}
.auth-type-perks li::before { content: '✓ '; color: #22c55e; font-weight: 900; }
.auth-type-tag {
    align-self: flex-start;
    font-size: 10px;
    font-weight: 800;
    border-radius: 999px;
    padding: 3px 10px;
    margin-top: auto;
}
.auth-tag-orange { background: #fff3e0; color: var(--apc-orange); }
.auth-tag-blue   { background: #dbeafe; color: #1d4ed8; }

/* Sign-up forms */
.auth-back-btn {
    background: none;
    border: none;
    color: #aaa;
    font-size: 12px;
    font-weight: 700;
    cursor: pointer;
    padding: 0;
    margin-bottom: 14px;
    display: block;
}
.auth-back-btn:hover { color: #666; }
.auth-form-heading {
    font-size: 16px;
    font-weight: 900;
    color: #222;
    margin-bottom: 16px;
    display: flex;
    align-items: center;
    gap: 8px;
}
.auth-pro-inline-badge {
    font-size: 9px;
    font-weight: 900;
    background: #1d4ed8;
    color: white;
    padding: 3px 8px;
    border-radius: 999px;
    letter-spacing: 0.5px;
    vertical-align: middle;
}
.auth-pro-perks-box {
    background: #f0f5ff;
    border: 1px solid #bfdbfe;
    border-radius: 10px;
    padding: 12px 14px;
    margin-bottom: 14px;
}
.auth-pro-perks-hdr {
    font-size: 10px;
    font-weight: 900;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    color: #1d4ed8;
    margin-bottom: 8px;
}
.auth-pro-perks-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4px 8px;
    font-size: 11px;
    color: #374151;
    font-weight: 600;
}

.seller-avatar {
    width: 44px;
    height: 44px;
    min-width: 44px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 800;
    font-size: 18px;
    color: white;
    background: var(--apc-orange);
    box-shadow: 0 6px 16px rgba(255,149,0,0.18);
    overflow: hidden;
}

.seller-card-meta {
    flex: 1;
    min-width: 0;
}

.seller-card-name,
.detail-seller-name {
    font-size: 14px;
    font-weight: 800;
    color: #222;
    line-height: 1.2;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.detail-seller-name-row {
    display: flex;
    align-items: center;
    gap: 8px;
    flex-wrap: wrap;
}

.seller-card-sub,
.detail-seller-sub {
    margin-top: 4px;
    font-size: 12px;
    color: #666;
    line-height: 1.3;
}

.seller-pro-badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 4px 10px;
    border-radius: 999px;
    font-size: 10px;
    font-weight: 900;
    letter-spacing: 0.5px;
    color: var(--apc-blue);
    background: rgba(0, 122, 255, 0.1);
}
.trade-only-badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 3px 8px;
    border-radius: 999px;
    font-size: 9px;
    font-weight: 900;
    letter-spacing: 0.8px;
    color: #b45309;
    background: rgba(180, 83, 9, 0.1);
    border: 1px solid rgba(180, 83, 9, 0.2);
}

.detail-seller-card {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 14px;
    background: #fff;
    border: 1px solid #EEE;
    border-radius: 18px;
    box-shadow: 0 5px 20px rgba(0,0,0,0.05);
    cursor: pointer;
    transition: transform 0.15s ease, box-shadow 0.15s ease, background 0.15s ease;
}

.detail-seller-card:hover {
    transform: translateY(-1px);
    box-shadow: 0 10px 24px rgba(0,0,0,0.08);
    background: #fafafa;
}

/* =====================
   SELLER STOREFRONT v2
   ===================== */

/* Back-to-listing context bar */
.storefront-back-bar {
    padding: 10px 16px;
    border-bottom: 1px solid #f0f0f0;
    background: #fafafa;
}
.storefront-back-bar button {
    background: none;
    border: none;
    color: var(--apc-orange);
    font-size: 13px;
    font-weight: 800;
    cursor: pointer;
    font-family: inherit;
    padding: 0;
}

/* Floating close button */
.sf-close-btn {
    position: absolute;
    top: 14px; right: 14px;
    z-index: 10;
    width: 34px; height: 34px;
    display: flex; align-items: center; justify-content: center;
    border-radius: 50%;
    background: rgba(80,80,80,0.65);
    backdrop-filter: blur(4px);
    -webkit-backdrop-filter: blur(4px);
    font-size: 22px;
    line-height: 1;
    cursor: pointer;
    color: #fff;
    font-weight: 400;
}
/* Stat bar spacer — pushes message + heart to the right */
.sf-bar-spacer { flex: 1; }

/* Message Seller button */
.sf-msg-btn {
    background: none; border: 1.5px solid #ccc; color: #555;
    border-radius: 20px; padding: 6px 14px;
    font-size: 12px; font-weight: 700; cursor: pointer;
    font-family: inherit; white-space: nowrap;
    margin-right: 10px;
    transition: border-color 0.15s, color 0.15s;
}
.sf-msg-btn:hover { border-color: var(--apc-orange); color: var(--apc-orange); }

/* Inline heart save button in stat bar */
.sf-heart-btn {
    display: inline-flex; align-items: center; gap: 5px;
    background: none; border: none; padding: 0; margin: 0;
    cursor: pointer; font-family: inherit;
    color: #bbb;
    transition: color 0.15s;
    line-height: 1;
}
.sf-heart-btn:hover { color: var(--apc-orange); }
.sf-heart-btn.sf-save-btn-active { color: var(--apc-orange); }
.sf-heart-icon {
    font-size: 40px; line-height: 1;
    transition: transform 0.15s;
}
.sf-heart-btn.sf-save-btn-active .sf-heart-icon { transform: scale(1.1); }
.sf-saves-count {
    font-size: 13px; font-weight: 700; color: inherit;
}

/* Hero banner */
.sf-hero {
    background: linear-gradient(135deg, var(--apc-orange) 0%, #e07a0a 100%);
    height: 120px;
    position: relative;
    flex-shrink: 0;
    transition: height 0.2s ease;
}
.sf-hero.has-banner {
    height: 160px;
}

/* Logo circle — sits half over hero, half over identity */
.sf-logo-wrap {
    position: absolute;
    bottom: -44px;
    left: 20px;
    width: 88px; height: 88px;
    border-radius: 16px;
    background: white;
    border: 3px solid white;
    box-shadow: 0 4px 20px rgba(0,0,0,0.22);
    display: flex; align-items: center; justify-content: center;
    overflow: hidden;
}
.sf-logo-img { width: 100%; height: 100%; object-fit: contain; border-radius: 13px; }
.sf-logo-initials {
    font-size: 32px; font-weight: 900;
    color: var(--apc-orange);
}

/* Identity block */
.sf-identity {
    padding: 54px 20px 14px 20px;
    display: flex; flex-direction: column; gap: 6px;
    border-bottom: 1px solid #f0f0f0;
}
.sf-name-row {
    display: flex; align-items: center; gap: 8px; flex-wrap: wrap;
}
.sf-business-name {
    font-size: 17px; font-weight: 900; color: var(--apc-charcoal);
}
.sf-abn-chip {
    font-size: 10px; font-weight: 800;
    background: #dcfce7; color: #16a34a;
    border-radius: 99px; padding: 3px 9px;
    letter-spacing: 0.3px;
}

/* Inline stat bar: Name | 15 Listings | 188 Saves | ★ 4.9 Rating */
.sf-stat-bar {
    display: flex; align-items: center; gap: 0; flex-wrap: wrap;
}
.sf-bar-name {
    font-size: 14px; font-weight: 800; color: var(--apc-charcoal);
    padding-right: 12px;
}
.sf-bar-divider {
    width: 1px; height: 14px; background: #ddd; flex-shrink: 0; margin: 0 12px;
}
.sf-bar-stat {
    font-size: 13px; color: #555; font-weight: 500; white-space: nowrap;
}
.sf-bar-num {
    font-weight: 800; color: var(--apc-charcoal);
}

.sf-location {
    font-size: 12px; color: #888;
}

/* About */
.sf-about-section {
    padding: 14px 20px;
    border-bottom: 1px solid #f0f0f0;
}
.sf-about-text {
    font-size: 13px; color: #555; line-height: 1.55;
}

/* Workshop / service storefront sections */
.sf-section {
    padding: 14px 20px;
    border-bottom: 1px solid #f0f0f0;
}
.sf-section-label {
    font-size: 10px; font-weight: 800; text-transform: uppercase;
    letter-spacing: 0.6px; color: var(--apc-orange);
    margin-bottom: 10px;
}
.sf-chips-wrap { display: flex; flex-wrap: wrap; gap: 7px; }
.sf-chip {
    background: #f4f4f4; color: #333;
    font-size: 12px; font-weight: 600;
    padding: 5px 11px; border-radius: 20px;
}
.sf-address { font-size: 13px; color: #555; }
.sf-parts-condition { font-size: 12px; color: #aaa; margin-top: 8px; font-style: italic; }

/* Search */
.sf-search-wrap {
    padding: 12px 15px 8px;
}
.sf-search-input {
    width: 100%; padding: 10px 16px;
    border-radius: 20px; border: 1.5px solid #e8e8e8;
    font-size: 13px; outline: none; background: #f9f9f9;
    box-sizing: border-box;
    font-family: inherit;
}
.sf-search-input:focus { border-color: var(--apc-orange); background: white; }

/* Settings — logo upload */
.logo-upload-preview {
    width: 64px; height: 64px; flex-shrink: 0;
    border-radius: 50%;
    background: var(--apc-orange);
    display: flex; align-items: center; justify-content: center;
    overflow: hidden;
}
.logo-upload-btn {
    display: inline-block;
    padding: 7px 14px;
    background: #f0f0f0;
    border-radius: 8px;
    font-size: 12px; font-weight: 700; color: #444;
    cursor: pointer;
    transition: background 0.15s;
}
.logo-upload-btn:hover { background: #e4e4e4; }
.logo-remove-btn {
    padding: 7px 14px;
    background: none;
    border: 1.5px solid #e0e0e0;
    border-radius: 8px;
    font-size: 12px; font-weight: 700; color: #e53935;
    cursor: pointer;
}
.banner-upload-preview {
    width: 100%; height: 80px;
    border-radius: 10px;
    background: linear-gradient(135deg, var(--apc-orange) 0%, #e07a0a 100%);
    display: flex; align-items: center; justify-content: center;
    overflow: hidden;
    position: relative;
}
/* === VEHICLE MAKES PICKER === */
.makes-picker-btn {
    width: 100%;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 11px 14px;
    border: 1.5px solid #e0e0e0;
    border-radius: 10px;
    background: #fafafa;
    cursor: pointer;
    font-family: inherit;
    text-align: left;
    gap: 8px;
}
.makes-picker-btn:active { background: #f0f0f0; }
.makes-summary { font-size: 13px; font-weight: 600; color: var(--apc-charcoal); flex: 1; }
.makes-summary-empty { color: #bbb; font-weight: 500; }
.makes-picker-chevron { font-size: 20px; color: #bbb; line-height: 1; }
.makes-all-row {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 14px 0 10px;
    font-size: 15px;
    font-weight: 800;
}
.makes-all-label { font-size: 15px; font-weight: 800; color: var(--apc-charcoal); }
.makes-all-hint { font-size: 12px; color: #aaa; padding-bottom: 10px; }
.makes-separator { height: 1px; background: #ececec; margin: 0 0 8px; }
.makes-list { display: flex; flex-direction: column; gap: 0; }
.makes-item { padding: 11px 0; border-bottom: 1px solid #f4f4f4; font-size: 14px; }
.makes-done-bar {
    position: absolute;
    bottom: 0; left: 0; right: 0;
    padding: 12px 16px;
    background: white;
    border-top: 1px solid #eee;
}

.apc-badge-trigger-btn {
    display: flex;
    align-items: center;
    gap: 10px;
    width: 100%;
    padding: 13px 16px;
    background: #fff7ee;
    border: 1.5px solid var(--apc-orange);
    border-radius: 12px;
    color: var(--apc-orange);
    font-weight: 700;
    font-size: 14px;
    cursor: pointer;
    transition: background 0.15s;
}
.apc-badge-trigger-btn:hover { background: #ffecd4; }

.ws-service-group { margin-bottom: 16px; }
.input-group-row { display: flex; gap: 10px; align-items: flex-start; }
.input-group-row .input-group { margin-bottom: 0; }
.ws-group-label {
    font-size: 10px; font-weight: 800; text-transform: uppercase;
    letter-spacing: 0.6px; color: var(--apc-orange);
    margin-bottom: 8px; padding-bottom: 4px;
    border-bottom: 1.5px solid #f0f0f0;
}
.prof-media-remove-btn {
    position: absolute; bottom: 8px; right: 8px;
    background: rgba(0,0,0,0.45); color: white; border: none;
    border-radius: 6px; padding: 4px 10px; font-size: 11px; font-weight: 700;
    cursor: pointer; font-family: inherit;
}
.settings-about-input {
    width: 100%; padding: 10px 12px;
    border-radius: 10px; border: 1.5px solid #e8e8e8;
    font-size: 13px; font-family: inherit;
    resize: vertical; outline: none;
    box-sizing: border-box; color: #333;
}
.settings-about-input:focus { border-color: var(--apc-orange); }

.menu-divider { height: 1px; background: #eee; margin: 4px 0; }

/* On/off switch inside the menu */
.switch {
    margin-left: auto;
    width: 34px; height: 20px;
    background: #ccc;
    border-radius: 999px;
    position: relative;
    transition: background 0.15s;
    flex-shrink: 0;
}
.switch::after {
    content: '';
    position: absolute;
    top: 2px; left: 2px;
    width: 16px; height: 16px;
    background: white;
    border-radius: 50%;
    transition: left 0.15s;
    box-shadow: 0 1px 2px rgba(0,0,0,0.2);
}
.switch.on { background: var(--apc-blue); }
.switch.on::after { left: 16px; }

.search-group { display: flex; border-radius: 8px; overflow: hidden; border: 1px solid #ccc; background: white; }
.filter-status-chip {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 4px 10px 6px;
    font-size: 12px;
    font-weight: 600;
    color: #666;
}
.filter-status-chip span { flex: 1; }
.filter-status-chip button {
    background: none;
    border: none;
    color: var(--apc-orange);
    font-weight: 800;
    font-size: 11px;
    cursor: pointer;
    padding: 2px 6px;
    border-radius: 4px;
    white-space: nowrap;
}
.search-group input { flex: 1; border: none; padding: 12px; font-size: 16px; outline: none; }
.btn-search-main { background: var(--apc-orange); border: none; width: 50px; font-size: 18px; color: white; cursor: pointer; }
.btn-search-filters {
    background: var(--apc-orange);
    border: none;
    padding: 0 18px;
    font-size: 12px;
    font-weight: 800;
    letter-spacing: 1px;
    cursor: pointer;
    color: white;
    font-family: inherit;
    text-transform: uppercase;
    white-space: nowrap;
}
.btn-search-filters:active { background: var(--apc-orange-dark, #d97c0c); }



/* GRID HEADING — "Recently Listed" / "Results for X" */
/* PRO DASHBOARD MOBILE BANNER */
#proDashboardBanner {
    display: flex;
    align-items: center;
    gap: 12px;
    margin: 10px 10px 4px;
    padding: 14px;
    background: #fff;
    border-radius: 14px;
    border-left: 4px solid var(--apc-orange);
    box-shadow: 0 1px 6px rgba(0,0,0,0.08);
}
.pdb-icon { font-size: 26px; flex-shrink: 0; }
.pdb-body { flex: 1; min-width: 0; }
.pdb-title { font-size: 13px; font-weight: 700; color: #1a1a1a; margin-bottom: 3px; }
.pdb-text  { font-size: 12px; color: #666; line-height: 1.4; }
.pdb-dismiss {
    flex-shrink: 0;
    background: var(--apc-orange);
    color: #fff;
    border: none;
    border-radius: 20px;
    padding: 7px 14px;
    font-size: 12px;
    font-weight: 700;
    cursor: pointer;
}
.amenu-desktop-badge {
    display: inline-block;
    background: #e8e8e8;
    color: #888;
    font-size: 10px;
    font-weight: 600;
    border-radius: 4px;
    padding: 2px 6px;
    margin-left: 6px;
    vertical-align: middle;
    letter-spacing: 0.3px;
}
@media (min-width: 900px) {
    #proDashboardBanner { display: none !important; }
    .amenu-desktop-badge { display: none; }
}

.grid-heading {
    display: flex;
    align-items: baseline;
    gap: 8px;
    padding: 10px 10px 4px;
}
.grid-heading-label {
    font-size: 13px;
    font-weight: 800;
    color: #333;
    letter-spacing: -0.1px;
}
.grid-heading-count {
    font-size: 11px;
    font-weight: 600;
    color: #aaa;
}

/* RESULTS GRID */
.results-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 5px;
    padding: 5px 0px;
    background: #E4E6EB;
    margin-top: 0;
}
#sellerPartsGrid {
    margin-top: 0 !important;
}

/* ITEM CARD */
.item-card {
    background: white;
    overflow: hidden;
    position: relative;
    border-radius: 0px;
    border: 0px solid #ddd;
    display: flex;
    flex-direction: column;
    cursor: pointer;
}

/* Pending banner — amber strip across top of listing card */
.card-pending-banner {
    position: absolute;
    top: 0; left: 0; right: 0;
    z-index: 2;
    background: #f59e0b;
    color: white;
    font-size: 10px; font-weight: 900;
    letter-spacing: 1px;
    text-align: center;
    padding: 4px 0;
    border-radius: 10px 10px 0 0;
}

/* Pending banner in detail overlay */
.detail-pending-banner {
    margin: 0 0 0 0;
    padding: 10px 15px;
    background: #fef3c7;
    border-bottom: 2px solid #f59e0b;
    font-size: 12px; font-weight: 800;
    color: #92400e;
    letter-spacing: 0.3px;
}

/* Sell form inline error banner */
.sell-error-banner {
    margin: 12px 15px 0;
    padding: 10px 14px;
    background: #fff1f2;
    border: 1.5px solid #f87171;
    border-radius: 8px;
    font-size: 13px;
    font-weight: 700;
    color: #991b1b;
}

/* Dashboard pending chip */
.dash-pending-chip {
    display: inline-block;
    margin-top: 4px;
    padding: 2px 8px;
    background: #fef3c7;
    color: #92400e;
    border: 1px solid #f59e0b;
    border-radius: 99px;
    font-size: 10px; font-weight: 800;
    letter-spacing: 0.5px;
}

/* Load More button */
.load-more-btn {
    background: white;
    border: 2px solid var(--apc-orange);
    color: var(--apc-orange);
    font-weight: 800;
    font-size: 13px;
    padding: 10px 28px;
    border-radius: 24px;
    cursor: pointer;
    letter-spacing: 0.5px;
    text-transform: uppercase;
    transition: background 0.15s, color 0.15s;
}
.load-more-btn:hover { background: var(--apc-orange); color: white; }

/* Saved indicator — orange heart top-right of saved cards, non-interactive */
.card-saved-dot {
    position: absolute;
    top: 8px;
    right: 8px;
    z-index: 1;
    color: var(--apc-orange);
    font-size: 22px;
    line-height: 1;
    pointer-events: none;
    text-shadow: 0 1px 4px rgba(0,0,0,0.18);
}

.item-img {
    width: 100%;
    aspect-ratio: 4/3;
    object-fit: contain;
    background: #ffffff;
    display: block;
    margin: 0;
}

.item-info {
    padding: 8px;
}

/* ── Skeleton loading cards ─────────────────────────────── */
@keyframes shimmer {
    0%   { background-position: -600px 0; }
    100% { background-position:  600px 0; }
}
.skeleton-card {
    background: white;
    overflow: hidden;
    display: flex;
    flex-direction: column;
}
.skeleton-line {
    background: linear-gradient(90deg, #f0f0f0 25%, #e8e8e8 50%, #f0f0f0 75%);
    background-size: 600px 100%;
    animation: shimmer 1.4s ease-in-out infinite;
    border-radius: 4px;
}
.skeleton-img  { width: 100%; aspect-ratio: 4/3; border-radius: 0; }
.skeleton-info { padding: 8px; display: flex; flex-direction: column; gap: 7px; }
.skeleton-price { height: 16px; width: 55px; }
.skeleton-title { height: 13px; width: 88%; }
.skeleton-title2 { height: 13px; width: 65%; }
.skeleton-loc   { height: 11px; width: 48%; margin-top: 2px; }

.price-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 4px;
}

.item-price { 
    font-weight: 900; 
    color: var(--apc-blue-bg);   /* was hardcoded #0056b3 */
    font-size: 15px; 
}

.fitting-pill {
    background: rgba(247, 148, 29, 0.1);
    color: var(--apc-orange);
    padding: 3px 6px;
    border-radius: 4px;
    font-size: 8px;
    font-weight: 900;
    letter-spacing: 0.5px;
    border: 1px solid rgba(247, 148, 29, 0.3);
}

.item-card-pro-btn {
    border: none;
    background: var(--apc-orange);
    color: white;
    border-radius: 999px;
    padding: 4px 10px;
    font-size: 9px;
    font-weight: 900;
    letter-spacing: 0.5px;
    cursor: default;
    white-space: nowrap;
}

.blurred-location {
    filter: blur(4px);
    opacity: 0.65;
    display: inline-block;
}

.blurred-detail {
    filter: blur(5px);
    opacity: 0.55;
    pointer-events: none;
}

/* Wrapper that holds blurred content + sign-in prompt */
.detail-locked-group {
    position: relative;
    transition: filter 0.15s ease, opacity 0.15s ease;
}
.detail-signin-overlay {
    display: none;
    position: absolute;
    inset: 0;
    align-items: center;
    justify-content: center;
    background: rgba(255,255,255,0.08);
    border-radius: 10px;
    cursor: pointer;
    z-index: 2;
}
.detail-signin-overlay span {
    background: rgba(255,255,255,0.92);
    color: #555;
    font-size: 11px;
    font-weight: 800;
    padding: 5px 12px;
    border-radius: 20px;
    letter-spacing: 0.3px;
    white-space: nowrap;
    box-shadow: 0 2px 8px rgba(0,0,0,0.12);
}
.blurred-active + .detail-signin-overlay,
.detail-locked-group.locked .detail-signin-overlay {
    display: flex;
}

.detail-signin-prompt {
    box-shadow: 0 10px 30px rgba(0,0,0,0.05);
}

.image-lightbox {
    display: none;
    position: fixed;
    inset: 0;
    z-index: 3400;
    align-items: center;
    justify-content: center;
    padding: 15px;
    background: rgba(0,0,0,0.55);
    backdrop-filter: blur(12px);
}

.image-lightbox.active {
    display: flex;
}

.image-lightbox-inner {
    position: relative;
    width: 100%;
    max-width: 980px;
    max-height: 92vh;
    border-radius: 24px;
    overflow: hidden;
    box-shadow: 0 30px 60px rgba(0,0,0,0.35);
}

.image-lightbox img {
    width: 100%;
    height: auto;
    max-height: 92vh;
    object-fit: contain;
    display: block;
    background: #111;
}

.image-lightbox-close {
    position: absolute;
    top: 14px;
    right: 14px;
    width: 42px;
    height: 42px;
    border: none;
    border-radius: 999px;
    background: rgba(0,0,0,0.45);
    color: white;
    font-size: 24px;
    font-weight: 900;
    line-height: 1;
    cursor: pointer;
    z-index: 2;
}
.lightbox-nav {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    width: 44px;
    height: 44px;
    border: none;
    border-radius: 999px;
    background: rgba(0,0,0,0.45);
    color: white;
    font-size: 28px;
    font-weight: 300;
    line-height: 1;
    cursor: pointer;
    z-index: 2;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.15s;
}
.lightbox-nav:hover { background: rgba(0,0,0,0.7); }
.lightbox-prev { left: 14px; }
.lightbox-next { right: 14px; }
.lightbox-dots {
    position: absolute;
    bottom: 18px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    gap: 8px;
    z-index: 2;
    pointer-events: auto;
}

.item-title { 
    font-size: 11px; 
    font-weight: 700; 
    color: #333;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    margin: 0 0 4px 0; 
}

.item-loc { 
    font-size: 9px; 
    color: #888; 
    font-weight: 700; 
}

/* Mobile: hide account pill zone (profile goes to bottom nav circle) */
@media (max-width: 899px) {
    #accountPillZone { display: none !important; }
}

/* BOTTOM NAV */
.bottom-nav {
    position: fixed; 
    bottom: 0; 
    left: 0; 
    width: 100%; 
    background: var(--white);
    display: flex; justify-content: space-around; align-items: center;
    height: 75px; border-top: 1px solid #ddd; z-index: 1500;
    transition: transform 0.3s ease;
}
.nav-hidden { transform: translateY(110%); }
.nav-item { display: flex; flex-direction: column; align-items: center; justify-content: center; color: var(--apc-charcoal); font-size: 15px; font-weight: 800; width: 20%; cursor: pointer; position: relative; letter-spacing: 0.2px; }
.nav-item.active { color: var(--apc-orange); }
.nav-sell {
    background: var(--apc-orange);
    color: white !important;
    border-radius: 12px;
    margin: 8px 4px;
    justify-content: center;
    font-size: 13px;
    box-shadow: 0 3px 10px rgba(247, 148, 29, 0.35);
}

/* DRAWER SYSTEM */
.drawer {
    display: none;
    position: fixed; top: 0; left: 0; right: 0; bottom: 0;
    background: var(--white); z-index: 3100; flex-direction: column;
}
/* Detail overlay always stacks on top of any other open drawer */
#detailOverlay { z-index: 3150; }

/* Chat reference card — centred floating modal */
#detailOverlay.chat-card {
    top: 50% !important;
    bottom: auto !important;
    transform: translateY(-50%);
    left: 16px !important;
    right: 16px !important;
    right: 16px !important;
    width: auto !important;
    max-height: 78vh !important;
    height: auto !important;
    border-radius: 16px !important;
    overflow: hidden !important;
    box-shadow: 0 8px 50px rgba(0,0,0,0.3) !important;
    z-index: 3300 !important;
}
#detailOverlay.chat-card .detail-sell-yours-block,
#detailOverlay.chat-card #sellYoursMobile { display: none !important; }

.carousel-arrow {
    display: none;
    position: absolute;
    top: 50%; transform: translateY(-50%);
    background: rgba(0,0,0,0.45);
    color: #fff;
    border: none;
    width: 36px; height: 36px;
    border-radius: 50%;
    font-size: 22px;
    line-height: 1;
    cursor: pointer;
    z-index: 10;
    align-items: center;
    justify-content: center;
    padding: 0;
}
.carousel-arrow-prev { left: 8px; }
.carousel-arrow-next { right: 8px; }
#detailOverlay.chat-card .carousel-arrow { display: flex; }
#detailOverlay.chat-card #imageCarousel { scrollbar-width: none; -ms-overflow-style: none; }
#detailOverlay.chat-card #imageCarousel::-webkit-scrollbar { display: none; }
/* On desktop, chat-card: centred 520px modal, single-column layout */
@media (min-width: 900px) {
    #detailOverlay.chat-card {
        left: 50% !important;
        right: auto !important;
        transform: translate(-50%, -50%);
        width: 520px !important;
        border-left: none !important;
        border-right: none !important;
    }
    #detailOverlay.chat-card #detailScrollArea {
        display: flex !important;
        grid-template-columns: unset !important;
        height: 100% !important;
        overflow-y: auto !important;
    }
    #detailOverlay.chat-card .desktop-detail-images { display: none !important; }
    #detailOverlay.chat-card .mobile-carousel { display: block !important; }
}

/* Inbox and chat sit above the detail overlay so Message Seller works from a listing */
#inboxDrawer, #chatDrawer, #messageDetailDrawer { z-index: 3200; }
/* Filter drawer sits below the header on all screen sizes */
#filterDrawer { z-index: 2000; }
.drawer.active {
    display: flex !important;
}
.drawer-header { padding: 15px 18px; min-height: 60px; border-bottom: 5px solid var(--apc-orange); display: flex; justify-content: space-between; align-items: center; font-weight: 900; background: white; box-sizing: border-box; flex-shrink: 0; }

/* Uniform drawer header button — outlined orange pill */
.dh-btn {
    background: none;
    border: 1.5px solid var(--apc-orange);
    color: var(--apc-orange);
    border-radius: 999px;
    padding: 6px 16px;
    font-size: 12px;
    font-weight: 800;
    cursor: pointer;
    font-family: inherit;
    white-space: nowrap;
    transition: background 0.15s, color 0.15s;
}
.dh-btn:hover { background: var(--apc-orange); color: white; }

/* Uniform drawer header close × */
.dh-close {
    font-size: 34px;
    line-height: 1;
    font-weight: 300;
    color: #888;
    cursor: pointer;
    padding: 4px;
    flex-shrink: 0;
}

/* Floating close button — desktop detail overlay only, hidden on mobile */
.detail-float-close {
    display: none;
    position: absolute;
    top: 14px;
    right: 16px;
    z-index: 10;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    border: none;
    background: rgba(255,255,255,0.92);
    box-shadow: 0 2px 8px rgba(0,0,0,0.15);
    font-size: 22px;
    font-weight: 300;
    color: #555;
    cursor: pointer;
    align-items: center;
    justify-content: center;
    line-height: 1;
}
.detail-float-close:hover { background: #fff; color: #111; }

.back-btn {
    font-size: 18px;
    cursor: pointer;
    color: var(--apc-orange);
    font-weight: 800;
    padding: 5px 10px;
    border-radius: 8px;
    transition: background 0.15s;
}
.back-btn:hover { background: rgba(255, 138, 51, 0.1); }
.drawer-content { padding: 15px; flex: 1; overflow-y: auto; background: white; padding-bottom: 100px; }

.detail-workshop-section {
    padding: 15px 0 0 0;
}
.workshop-sponsored-badge {
    font-size: 10px;
    color: #FF9800;
    font-weight: 900;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}
.workshop-card {
    background: #fff;
    border: 1px solid #eee;
    border-radius: 12px;
    padding: 12px 14px;
    box-shadow: 0 2px 6px rgba(0,0,0,0.04);
}
.workshop-card-header {
    display: flex;
    justify-content: space-between;
    align-items: baseline;
    gap: 8px;
    margin-bottom: 4px;
}
.workshop-card-name {
    font-size: 13px;
    font-weight: 800;
    color: #222;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}
.workshop-card-distance {
    font-size: 11px;
    color: #888;
    white-space: nowrap;
    flex-shrink: 0;
}
.workshop-card-specialty {
    font-size: 12px;
    color: #555;
    margin-bottom: 0;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}
.workshop-card-meta {
    font-size: 10px;
    color: #999;
    margin-bottom: 0;
}
.workshop-card-footer {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-top: 8px;
    border-top: 1px solid #f4f4f4;
    padding-top: 8px;
}
.workshop-rating {
    color: var(--apc-orange);
    font-weight: 800;
    font-size: 11px;
}
.workshop-card-button {
    padding: 4px 12px;
    border: 1.5px solid var(--apc-blue);
    background: transparent;
    color: var(--apc-blue);
    border-radius: 999px;
    font-size: 10px;
    font-weight: 800;
    cursor: pointer;
    transition: background 0.15s, color 0.15s;
    white-space: nowrap;
    font-family: inherit;
}
.workshop-card-button:hover {
    background: var(--apc-blue);
    color: white;
}
.workshop-sponsor-grid {
    display: grid;
    gap: 8px;
}

/* WORKSHOP EMPTY STATE */
.workshop-empty-state {
    text-align: center;
    padding: 48px 20px 40px;
    color: #aaa;
}
.workshop-empty-icon { font-size: 36px; margin-bottom: 12px; }
.workshop-empty-title { font-size: 15px; font-weight: 800; color: #666; margin-bottom: 6px; }
.workshop-empty-sub { font-size: 13px; margin-bottom: 18px; }
.workshop-empty-cta {
    background: var(--apc-orange);
    color: #fff;
    border: none;
    border-radius: 999px;
    padding: 8px 20px;
    font-size: 13px;
    font-weight: 800;
    cursor: pointer;
    font-family: inherit;
}

/* WORKSHOP DETAIL DRAWER */
.wsd-hero {
    background: linear-gradient(135deg, #2e2820 0%, #1c1812 100%);
    padding: 20px 20px 16px;
    color: white;
}
.wsd-name { font-size: 18px; font-weight: 900; margin-bottom: 4px; }
.wsd-loc  { font-size: 12px; opacity: 0.85; margin-bottom: 8px; }
.wsd-meta-row { display: flex; align-items: center; gap: 12px; font-size: 12px; }
.wsd-rating { font-weight: 800; }
.wsd-distance { opacity: 0.85; }
.wsd-section { padding: 14px 20px; border-bottom: 1px solid #f0f0f0; }
.wsd-section h4 { font-size: 10px; text-transform: uppercase; color: #aaa; font-weight: 800; letter-spacing: 0.5px; margin: 0 0 8px; }
.wsd-specialty { font-size: 14px; color: #333; line-height: 1.5; }
.wsd-chips { display: flex; flex-wrap: wrap; gap: 6px; }
.wsd-chip {
    background: #f0f0f0;
    color: #444;
    font-size: 11px;
    font-weight: 700;
    padding: 4px 10px;
    border-radius: 999px;
}
.wsd-contact-btn {
    margin: 20px;
    width: calc(100% - 40px);
    padding: 14px;
    background: var(--apc-orange);
    color: white;
    border: none;
    border-radius: 12px;
    font-size: 14px;
    font-weight: 900;
    cursor: pointer;
    font-family: inherit;
    box-sizing: border-box;
}

/* GARAGE — vehicle cards */
.garage-list {
    display: flex;
    flex-direction: column;
    gap: 8px;
    padding-bottom: 4px;
}
.garage-row {
    background: white;
    border-radius: 12px;
    padding: 14px 16px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    cursor: pointer;
    border-left: 4px solid transparent;
    box-shadow: 0 1px 4px rgba(0,0,0,0.07);
    transition: border-color 0.15s, box-shadow 0.15s;
}
.garage-row:active { opacity: 0.85; }
.garage-row-selected {
    border-left-color: var(--apc-orange);
    box-shadow: 0 2px 10px rgba(247,148,29,0.12);
}
.garage-row-info { flex: 1; min-width: 0; }
.garage-row-name { font-weight: 800; font-size: 14px; color: var(--apc-charcoal); line-height: 1.3; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.garage-row-meta { font-size: 12px; color: #999; margin-top: 2px; }
.garage-row-actions { display: flex; align-items: center; gap: 8px; flex-shrink: 0; }
.garage-row-edit {
    background: none;
    border: 1.5px solid #e0e0e0;
    border-radius: 20px;
    padding: 5px 13px;
    font-size: 12px;
    font-weight: 700;
    color: #777;
    cursor: pointer;
    font-family: inherit;
    transition: border-color 0.15s, color 0.15s;
}
.garage-row-edit:hover { border-color: var(--apc-orange); color: var(--apc-orange); }
.garage-row-delete {
    background: none;
    border: none;
    font-size: 22px;
    line-height: 1;
    cursor: pointer;
    color: #ddd;
    padding: 0 2px;
    font-family: inherit;
    transition: color 0.15s;
}
.garage-row-delete:hover { color: #ff3b30; }

#garageDrawer .drawer-content { padding-top: 20px; }
.garage-divider {
    border: none;
    border-top: 1px solid #e4e4e4;
    margin: 14px 0;
}

.garage-empty {
    text-align: center;
    padding: 40px 20px;
    color: #888;
}
.garage-empty .ico { font-size: 56px; margin-bottom: 8px; }
.garage-empty .title { font-weight: 800; font-size: 16px; color: var(--apc-charcoal); margin-bottom: 4px; }
.garage-empty .sub { font-size: 13px; line-height: 1.4; max-width: 260px; margin: 0 auto; }

.segmented-control {
    display: flex;
    background: #e8e8e8;
    border-radius: 8px;
    padding: 3px;
    margin-bottom: 12px;
}
.segmented-control .seg {
    flex: 1;
    text-align: center;
    padding: 8px 4px;
    font-size: 11px;
    font-weight: 800;
    border-radius: 6px;
    cursor: pointer;
    color: #888;
    user-select: none;
    transition: background 0.15s, color 0.15s;
}
.segmented-control .seg.active {
    background: white;
    color: var(--apc-orange);
    box-shadow: 0 1px 3px rgba(0,0,0,0.1);
}

.veh-empty {
    background: white;
    border-radius: 12px;
    padding: 30px 20px;
    text-align: center;
    color: #888;
    font-size: 13px;
    line-height: 1.5;
}
.veh-empty .ico { font-size: 38px; margin-bottom: 10px; }
.veh-empty .text { white-space: pre-line; max-width: 260px; margin: 0 auto; }
.veh-empty-cta {
    margin-top: 18px;
    border: none;
    background: var(--apc-orange);
    color: white;
    border-radius: 10px;
    padding: 12px 18px;
    font-weight: 800;
    cursor: pointer;
}
.veh-empty-cta:hover { background: #ff8b33; }

/* WANTED RESULTS — compact row layout for Pro seller search mode */
.wanted-results-wrap {
    grid-column: 1/-1;
    display: flex;
    flex-direction: column;
    gap: 6px;
}
.wanted-results-hdr {
    font-size: 11px;
    font-weight: 900;
    text-transform: uppercase;
    letter-spacing: 0.6px;
    color: #999;
    margin-bottom: 4px;
    padding: 0 2px;
}
.wanted-row {
    display: flex;
    align-items: center;
    gap: 12px;
    background: white;
    border: 1px solid #eee;
    border-radius: 10px;
    padding: 10px 14px;
    transition: border-color 0.15s;
}
.wanted-row:hover { border-color: var(--apc-orange); }
.wanted-row-avatar {
    width: 34px; height: 34px;
    border-radius: 50%;
    background: var(--apc-orange-light);
    color: var(--apc-orange);
    display: flex; align-items: center; justify-content: center;
    font-size: 12px; font-weight: 900;
    flex-shrink: 0;
}
.wanted-row-name {
    font-size: 14px; font-weight: 700; color: #222;
    min-width: 0;
    word-break: break-word;
}
.wanted-row-chips {
    display: flex; gap: 6px; align-items: center; flex-shrink: 0; flex-wrap: wrap;
}
.wanted-chip {
    font-size: 11px; color: #666;
    background: #f4f4f4;
    padding: 3px 9px; border-radius: 99px; white-space: nowrap;
}
.wanted-chip-budget  { background: var(--apc-orange-light); color: var(--apc-orange); font-weight: 700; }
.wanted-chip-time    { color: #bbb; background: none; padding-left: 0; }
.wanted-chip-pro     { background: #dbeafe; color: #1d4ed8; font-weight: 800; }
.wanted-chip-personal{ background: #f3f4f6; color: #6b7280; font-weight: 700; }
.wanted-avatar-pro   { background: #dbeafe; color: #1d4ed8; }
.wanted-row-body     { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 5px; }
.wanted-have-btn {
    flex-shrink: 0;
    padding: 7px 14px;
    background: white;
    color: var(--apc-orange);
    border: 2px solid var(--apc-orange);
    border-radius: 8px;
    font-size: 11px; font-weight: 900; cursor: pointer;
    letter-spacing: 0.3px; white-space: nowrap;
    transition: background 0.15s, color 0.15s;
}
.wanted-have-btn:hover { background: var(--apc-orange); color: white; }

/* SEARCH DEMAND WIDGET */
#dashDemandCard { overflow-y: auto; }
.demand-subtitle {
    font-size: 12px; color: #888;
    margin: 0 0 14px 0; line-height: 1.4;
}
.demand-bars { display: flex; flex-direction: column; gap: 7px; }
.demand-bar-row {
    display: flex; align-items: center; gap: 8px;
}
.demand-bar-label {
    width: 160px; flex-shrink: 0;
    font-size: 12px; color: #444;
    white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.demand-bar-track {
    flex: 1; height: 10px;
    background: #f0f0f0; border-radius: 99px; overflow: hidden;
}
.demand-bar-fill {
    height: 100%; border-radius: 99px;
    background: var(--apc-blue);
    transition: width 0.3s;
}
.demand-bar-fill.demand-bar-gap { background: var(--apc-orange); }
.demand-bar-count {
    width: 22px; flex-shrink: 0;
    font-size: 11px; font-weight: 700; color: #888;
    text-align: right;
}
.demand-insight {
    margin-top: 14px; padding: 10px 12px;
    background: var(--apc-orange-light); border-radius: 8px;
    font-size: 12px; color: var(--apc-charcoal); line-height: 1.5;
    display: flex; align-items: flex-start; gap: 8px;
}
.demand-insight-ico { font-size: 16px; flex-shrink: 0; }

/* WANTED LIST — cards for personal wanted drawer */
/* WANTED LIST DRAWER */
.wl-vehicle-hdr {
    font-size: 11px;
    font-weight: 900;
    text-transform: uppercase;
    letter-spacing: 0.6px;
    color: #888;
    padding: 4px 2px 8px;
    margin-top: 8px;
}
.wl-vehicle-hdr:first-child { margin-top: 0; }

.wanted-garage-chip {
    background: #f4f4f4;
    border: 1.5px solid #e0e0e0;
    border-radius: 20px;
    padding: 5px 12px;
    font-size: 12px;
    font-weight: 700;
    color: #555;
    cursor: pointer;
    font-family: inherit;
    transition: border-color 0.15s, background 0.15s, color 0.15s;
}
.wanted-garage-chip:hover  { border-color: var(--apc-orange); color: var(--apc-orange); }
.wanted-garage-chip.active { background: var(--apc-orange); border-color: var(--apc-orange); color: white; }

/* GARAGE INLINE WANTED LIST — classic row cards */
.wanted-list { display: flex; flex-direction: column; gap: 8px; }
.wanted-card {
    display: flex;
    align-items: center;
    background: white;
    border-radius: 10px;
    border: 1.5px solid #eee;
    padding: 10px 12px;
    gap: 10px;
}
.wanted-info { flex: 1; min-width: 0; }
.wanted-name { font-size: 13px; font-weight: 700; color: #222; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.wanted-meta { font-size: 11px; color: #aaa; margin-top: 2px; }
.wanted-actions { display: flex; gap: 6px; flex-shrink: 0; }
.wanted-delete {
    background: none;
    border: 1px solid #ddd;
    border-radius: 50%;
    width: 28px;
    height: 28px;
    font-size: 16px;
    color: #bbb;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    line-height: 1;
    flex-shrink: 0;
}
.wanted-delete:hover { border-color: #FF3B30; color: #FF3B30; }

/* WANTED LIST — row modifiers */
.wl-wanted-row {
    background: white;
    border: 1.5px solid #e8e8e8;
    border-radius: 10px;
    padding: 8px 12px !important;
    margin-bottom: 6px;
    border-bottom: 1.5px solid #e8e8e8 !important;
}
.wl-row-match { border-color: var(--apc-orange) !important; cursor: pointer; }
.wl-row-watching { cursor: default; opacity: 0.7; }

/* WANTED LIST — redesigned cards */
.wl-section-hdr {
    font-size: 10px;
    font-weight: 900;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    color: #bbb;
    padding: 16px 2px 8px;
}
.wl-section-hdr:first-child { padding-top: 4px; }
.wl-section-hdr-match { color: var(--apc-orange); }

.wl-card {
    background: white;
    border-radius: 12px;
    padding: 14px 12px;
    margin-bottom: 8px;
    display: flex;
    align-items: center;
    gap: 10px;
    border-left: 3px solid transparent;
    transition: background 0.12s;
}
.wl-card-match {
    cursor: pointer;
    border-left-color: var(--apc-orange);
}
.wl-card-match:active { background: #fff8f4; }
.wl-card-watching { opacity: 0.65; }

.wl-card-name {
    font-weight: 800;
    font-size: 14px;
    color: var(--apc-charcoal);
    margin-bottom: 3px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}
.wl-card-meta {
    font-size: 11px;
    color: #aaa;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}
/* 2-col grid for wanted + saved sections */
.wl-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 8px;
    margin-bottom: 4px;
}
.wl-grid .wl-card {
    flex-direction: column;
    align-items: flex-start;
    position: relative;
    padding: 12px 10px;
}
.wl-grid .wl-delete-btn {
    position: absolute;
    top: 6px;
    right: 6px;
    padding: 0;
}
.wl-grid .wl-card-right {
    margin-left: 0;
    margin-top: 8px;
}

.wl-card-right {
    display: flex;
    align-items: center;
    gap: 2px;
    flex-shrink: 0;
    margin-left: auto;
}
.wl-match-count {
    font-weight: 900;
    font-size: 13px;
    color: var(--apc-orange);
    white-space: nowrap;
}
.wl-chevron {
    font-size: 20px;
    color: var(--apc-orange);
    line-height: 1;
}
.wl-watching-label {
    font-size: 11px;
    color: #ccc;
    font-weight: 700;
    letter-spacing: 0.04em;
}
.wl-delete-btn {
    background: none;
    border: none;
    font-size: 20px;
    line-height: 1;
    cursor: pointer;
    color: #ddd;
    flex-shrink: 0;
    padding: 2px 0 2px 6px;
    font-family: inherit;
}
.wl-delete-btn:hover { color: #ff3b30; }
.wanted-contact-btn {
    flex-shrink: 0;
    background: var(--apc-orange);
    color: white;
    border: none;
    border-radius: 8px;
    padding: 7px 12px;
    font-size: 11px;
    font-weight: 900;
    cursor: pointer;
    white-space: nowrap;
}
.wanted-contact-btn:hover { background: #e07b00; }

/* RECENTLY VIEWED DRAWER */
.rv-drawer-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 14px 16px 10px 16px;
    border-bottom: 1px solid #f0f0f0;
}
.rv-drawer-count {
    font-size: 13px;
    font-weight: 800;
    color: #888;
}
.rv-drawer-clear {
    font-size: 13px;
    font-weight: 700;
    color: var(--apc-orange);
    cursor: pointer;
}
.rv-drawer-row {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 16px;
    border-bottom: 1px solid #f4f4f4;
    cursor: pointer;
}
.rv-drawer-row:active { background: #fafafa; }
.rv-drawer-img {
    width: 64px;
    height: 52px;
    object-fit: cover;
    border-radius: 8px;
    flex-shrink: 0;
    background: #f0f0f0;
}
.rv-drawer-info {
    flex: 1;
    min-width: 0;
}
.rv-drawer-title {
    font-size: 13px;
    font-weight: 700;
    color: #222;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    line-height: 1.35;
}
.rv-drawer-meta {
    font-size: 11px;
    color: #aaa;
    margin-top: 3px;
}
.rv-drawer-price {
    font-size: 14px;
    font-weight: 900;
    color: var(--apc-orange);
    flex-shrink: 0;
}
.sp-unsave-btn {
    background: none;
    border: 1.5px solid #ddd;
    border-radius: 50%;
    width: 28px;
    height: 28px;
    font-size: 18px;
    color: #aaa;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    line-height: 1;
    transition: border-color 0.15s, color 0.15s;
}
.sp-unsave-btn:hover { border-color: #FF3B30; color: #FF3B30; }
.sp-unsave-btn:active { transform: scale(0.85); }

.sp-tabs { display: flex; gap: 14px; }
.sp-tab {
    background: #e8e8e8;
    border: none;
    border-radius: 8px;
    padding: 5px 16px;
    font-size: 11px;
    white-space: nowrap;
    font-weight: 900;
    letter-spacing: 0.3px;
    color: #555;
    cursor: pointer;
    transition: opacity 0.15s;
}
.sp-tab:hover { opacity: 0.8; }
.sp-tab-active { background: var(--apc-orange) !important; color: white !important; }
.sp-tab-count {
    display: inline-block;
    background: rgba(0,0,0,0.1);
    border-radius: 99px;
    font-size: 10px;
    font-weight: 900;
    padding: 1px 6px;
    margin-left: 3px;
}
.sp-tab-active .sp-tab-count { background: rgba(255,255,255,0.25); }
.sp-tab-count-ended { background: rgba(231,76,60,0.15); color: #e74c3c; }
.sp-tab-active .sp-tab-count-ended { background: rgba(255,255,255,0.25); color: white; }

/* SAVED STORES */
.saved-store-card {
    display: flex; align-items: center; gap: 12px;
    background: white; border-radius: 12px;
    padding: 12px 14px; margin-bottom: 8px;
    box-shadow: 0 1px 4px rgba(0,0,0,0.07);
}
.saved-store-avatar {
    width: 44px; height: 44px; border-radius: 10px;
    background: var(--apc-orange); color: white;
    font-size: 18px; font-weight: 900;
    display: flex; align-items: center; justify-content: center;
    flex-shrink: 0;
}
.saved-store-info { flex: 1; min-width: 0; }
.saved-store-name { font-size: 14px; font-weight: 800; color: #1a1a1a; }
.saved-store-meta { font-size: 12px; color: #888; margin-top: 2px; }
.saved-store-pro { color: var(--apc-blue); font-weight: 800; }
.saved-store-count { font-size: 11px; color: #aaa; margin-top: 3px; }
.saved-store-actions { display: flex; flex-direction: column; gap: 6px; flex-shrink: 0; }
.saved-store-visit-btn {
    background: var(--apc-blue); color: white; border: none;
    border-radius: 8px; padding: 6px 12px;
    font-size: 12px; font-weight: 700; cursor: pointer; font-family: inherit;
}
.saved-store-unsave-btn {
    background: none; border: 1.5px solid #ddd; color: #aaa;
    border-radius: 8px; padding: 4px 10px;
    font-size: 14px; font-weight: 700; cursor: pointer; font-family: inherit;
}
.saved-store-unsave-btn:hover { border-color: #FF3B30; color: #FF3B30; }

/* STALE SAVED PARTS */
.stale-section-hdr {
    font-size: 11px;
    font-weight: 900;
    text-transform: uppercase;
    letter-spacing: 0.6px;
    color: #bbb;
    padding: 12px 16px 6px;
}
.stale-row {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    padding: 10px 16px 12px;
    border-bottom: 1px solid #f4f4f4;
}
.stale-img-wrap { position: relative; flex-shrink: 0; }
.stale-img { opacity: 0.4; filter: grayscale(60%); }
.stale-badge {
    position: absolute;
    top: 4px;
    left: 4px;
    background: #e74c3c;
    color: white;
    font-size: 9px;
    font-weight: 900;
    letter-spacing: 0.5px;
    padding: 2px 5px;
    border-radius: 4px;
}
.stale-title { font-size: 13px; font-weight: 700; color: #aaa; margin-bottom: 2px; }
.stale-meta { font-size: 11px; color: #ccc; margin-bottom: 8px; }
.stale-actions { display: flex; gap: 6px; flex-wrap: wrap; }
.stale-action-btn {
    font-size: 11px;
    font-weight: 900;
    letter-spacing: 0.3px;
    padding: 5px 10px;
    border-radius: 6px;
    border: none;
    cursor: pointer;
    transition: opacity 0.15s;
}
.stale-action-btn:hover { opacity: 0.85; }
.stale-similar-btn { background: var(--apc-blue); color: white; }
.stale-wanted-btn { background: var(--apc-orange); color: white; }
.stale-dismiss-btn {
    font-size: 11px;
    font-weight: 700;
    color: #bbb;
    background: none;
    border: 1px solid #e8e8e8;
    padding: 5px 10px;
    border-radius: 6px;
    cursor: pointer;
    transition: color 0.15s, border-color 0.15s;
}
.stale-dismiss-btn:hover { color: #888; border-color: #ccc; }

/* SETTINGS */
.settings-section-label {
    font-size: 11px;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.6px;
    color: #999;
    padding: 18px 16px 6px 16px;
}
.settings-section {
    background: white;
    border-radius: 14px;
    margin: 0 12px 4px 12px;
    overflow: hidden;
}
.settings-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 14px 16px;
    border-bottom: 1px solid #f2f2f2;
    gap: 12px;
}
.settings-row:last-child { border-bottom: none; }
.settings-row-tappable { cursor: pointer; }
.settings-row-tappable:active { background: #f9f9f9; }
.settings-row-label {
    font-size: 14px;
    color: #222;
    font-weight: 500;
    flex: 1;
}
.settings-row-sub {
    font-size: 11px;
    color: #aaa;
    margin-top: 2px;
}
.settings-row-value {
    font-size: 13px;
    color: #aaa;
    font-weight: 500;
}
.settings-chevron {
    font-size: 20px;
    color: #ccc;
    line-height: 1;
}
.settings-inline-input {
    flex: 1;
    border: none;
    outline: none;
    font-size: 14px;
    color: #555;
    text-align: right;
    background: transparent;
    min-width: 0;
}
.location-picker-wrap {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 6px;
    flex: 1;
    min-width: 0;
}
.loc-postcode-input {
    width: 72px;
    flex: none;
    text-align: right;
    border: none;
    outline: none;
    font-size: 14px;
    color: #555;
    background: transparent;
    font-family: inherit;
}
.loc-suburb-select {
    flex: 1;
    max-width: 200px;
    border: 1px solid #e5e5e5;
    border-radius: 8px;
    padding: 4px 8px;
    font-size: 13px;
    color: #333;
    background: #fafafa;
    outline: none;
    font-family: inherit;
    cursor: pointer;
}
.location-chip {
    display: flex;
    align-items: center;
    gap: 6px;
    background: #f0f7ff;
    border: 1px solid #bdd8f5;
    border-radius: 20px;
    padding: 3px 6px 3px 10px;
    font-size: 13px;
    color: #1a6fb8;
    font-weight: 600;
    white-space: nowrap;
    max-width: 200px;
    overflow: hidden;
}
.location-chip-text {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}
.location-chip-clear {
    background: none;
    border: none;
    font-size: 16px;
    line-height: 1;
    color: #aaa;
    cursor: pointer;
    padding: 0;
    flex-shrink: 0;
}
.location-chip-clear:hover { color: #FF3B30; }
.settings-save-btn {
    background: var(--apc-orange);
    color: white;
    border: none;
    border-radius: 8px;
    padding: 8px 18px;
    font-size: 13px;
    font-weight: 800;
    cursor: pointer;
    letter-spacing: 0.3px;
}
.settings-save-btn:active { opacity: 0.8; }
.settings-profile-pic-wrap {
    width: 48px; height: 48px; border-radius: 50%;
    background: var(--apc-orange);
    display: flex; align-items: center; justify-content: center;
    overflow: hidden; cursor: pointer; flex-shrink: 0;
    border: 2px solid #eee;
}
.settings-pic-remove-btn {
    font-size: 11px; font-weight: 700; color: #e74c3c;
    background: none; border: none; cursor: pointer; padding: 0;
}
.settings-save-btn-pro {
    background: #2563eb;
}
/* Pro settings section — blue-tinted, only visible for Pro users */
.settings-pro-label {
    color: #2563eb !important;
    letter-spacing: 1px;
}
.settings-pro-section {
    background: #eef4ff !important;
    border-left: 3px solid #2563eb;
    margin-bottom: 8px !important;
}
.settings-pro-section-hdr {
    font-size: 10px;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    color: #2563eb;
    padding: 10px 16px 4px;
    border-bottom: 1px solid #dbeafe;
}

/* iOS-style toggle */
.settings-toggle {
    position: relative;
    display: inline-block;
    width: 44px;
    height: 26px;
    flex-shrink: 0;
}
.settings-toggle input { display: none; }
.settings-toggle-track {
    position: absolute;
    inset: 0;
    border-radius: 999px;
    background: #ddd;
    transition: background 0.2s;
    cursor: pointer;
}
.settings-toggle-track::after {
    content: '';
    position: absolute;
    top: 3px;
    left: 3px;
    width: 20px;
    height: 20px;
    border-radius: 50%;
    background: white;
    box-shadow: 0 1px 4px rgba(0,0,0,0.25);
    transition: transform 0.2s;
}
.settings-toggle input:checked + .settings-toggle-track { background: var(--apc-orange); }
.settings-toggle input:checked + .settings-toggle-track::after { transform: translateX(18px); }

/* Search radius segmented control in filters */
.radius-seg-control {
    display: flex;
    border-radius: 10px;
    overflow: hidden;
    border: 1px solid #ddd;
    background: #f4f4f4;
}
.radius-seg {
    flex: 1;
    text-align: center;
    padding: 8px 2px;
    font-size: 11px;
    font-weight: 700;
    color: #666;
    cursor: pointer;
    border-right: 1px solid #ddd;
    transition: background 0.15s, color 0.15s;
    line-height: 1.3;
}
.radius-seg:last-child { border-right: none; }
.radius-seg.active {
    background: var(--apc-orange);
    color: white;
}
.radius-seg-disabled .radius-seg {
    opacity: 0.35;
    pointer-events: none;
    cursor: default;
}
.radius-seg-disabled .radius-seg.active {
    background: #ccc;
    color: #fff;
}
#filterDrawer .drawer-header { display: none; }

.filter-clear-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 6px 4px 0;
}
.filter-clear-btn {
    background: none;
    border: none;
    font-size: 11px;
    font-weight: 900;
    letter-spacing: 0.5px;
    color: #aaa;
    cursor: pointer;
    padding: 4px 8px;
    border-radius: 6px;
    transition: color 0.15s, background 0.15s;
}
.filter-clear-btn:hover { color: var(--apc-orange); background: var(--apc-orange-light); }

.filter-radius-hint {
    font-size: 11px;
    color: #aaa;
    margin-top: 6px;
    font-style: italic;
}
.filter-input-disabled {
    opacity: 0.4;
    pointer-events: none;
}

/* PROFILE */
.profile-hero {
    background: linear-gradient(135deg, #2e2820 0%, #1c1812 100%);
    padding: 32px 20px 28px 20px;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 10px;
}
.profile-avatar {
    width: 72px;
    height: 72px;
    border-radius: 50%;
    background: rgba(255,255,255,0.25);
    color: white;
    font-size: 30px;
    font-weight: 900;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 3px solid rgba(255,255,255,0.5);
}
.profile-hero-name-row {
    display: flex;
    align-items: center;
    gap: 8px;
}
.profile-name {
    font-size: 20px;
    font-weight: 900;
    color: white;
}
.profile-tier-badge {
    font-size: 10px;
    font-weight: 900;
    padding: 3px 8px;
    border-radius: 999px;
    letter-spacing: 0.5px;
}
.profile-tier-badge.pro      { background: white; color: #007AFF; }
.profile-tier-badge.standard { background: rgba(255,255,255,0.3); color: white; border: 1px solid rgba(255,255,255,0.6); }
.profile-location {
    font-size: 13px;
    color: rgba(255,255,255,0.85);
    font-weight: 600;
}
.profile-stats-row {
    display: flex;
    align-items: center;
    background: white;
    padding: 18px 0;
    border-bottom: 1px solid #f0f0f0;
}
.profile-stat {
    flex: 1;
    text-align: center;
}
.profile-stat-value {
    font-size: 22px;
    font-weight: 900;
    color: var(--apc-charcoal);
}
.profile-stat-label {
    font-size: 11px;
    color: #888;
    margin-top: 2px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}
.profile-stat-divider {
    width: 1px;
    height: 36px;
    background: #eee;
}
.profile-meta-row {
    display: flex;
    flex-direction: column;
    gap: 10px;
    padding: 16px 20px;
    background: white;
    border-bottom: 1px solid #f0f0f0;
}
.profile-meta-item {
    display: flex;
    align-items: center;
    gap: 8px;
}
.profile-meta-icon { font-size: 15px; }
.profile-meta-text { font-size: 13px; color: #555; font-weight: 600; }
.profile-section {
    padding: 16px 20px;
    background: white;
    margin-top: 8px;
}
.profile-section-title {
    font-size: 12px;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    color: #aaa;
    margin-bottom: 10px;
}
.profile-about-text {
    font-size: 14px;
    color: #444;
    line-height: 1.5;
}
.profile-action-btn {
    width: 100%;
    padding: 14px;
    border-radius: 12px;
    font-size: 13px;
    font-weight: 900;
    cursor: pointer;
    border: none;
    margin-bottom: 10px;
}
.profile-action-btn.primary   { background: var(--apc-orange); color: white; }
.profile-action-btn.secondary { background: #f4f4f4; color: #333; }
.profile-action-btn:last-child { margin-bottom: 0; }

/* Settings Pro upgrade nudge */
.sun-promo-card {
    background: linear-gradient(160deg, #fff7ed 0%, #ffedd5 60%, #fde8c8 100%);
    border: 1.5px solid #fed7aa;
    border-radius: 14px;
    padding: 18px 16px 20px;
}
.sun-badge {
    display: inline-block;
    background: var(--apc-orange);
    color: white;
    font-size: 10px;
    font-weight: 900;
    letter-spacing: 1px;
    text-transform: uppercase;
    border-radius: 999px;
    padding: 3px 10px;
    margin-bottom: 10px;
}
.sun-headline {
    font-size: 15px;
    font-weight: 900;
    color: #1a1a1a;
    margin-bottom: 12px;
    line-height: 1.3;
}
.sun-features {
    list-style: none;
    padding: 0;
    margin: 0 0 16px 0;
    display: flex;
    flex-direction: column;
    gap: 6px;
}
.sun-features li {
    font-size: 12px;
    font-weight: 600;
    color: #7c2d12;
    padding-left: 16px;
    position: relative;
}
.sun-features li::before {
    content: '✓';
    position: absolute;
    left: 0;
    color: var(--apc-orange);
    font-weight: 900;
}
.sun-promo-btn {
    width: 100%;
    background: var(--apc-orange);
    color: white;
    border: none;
    border-radius: 10px;
    padding: 12px 16px;
    font-size: 13px;
    font-weight: 800;
    cursor: pointer;
    font-family: inherit;
    letter-spacing: 0.3px;
}

/* Settings profile strip */
.spc-card {
    display: flex; align-items: center; gap: 14px;
    background: white; padding: 14px 16px;
    border-bottom: 1px solid #ebebeb;
}
.spc-avatar {
    width: 46px; height: 46px; border-radius: 50%;
    background: var(--apc-orange); color: white;
    font-size: 19px; font-weight: 900;
    display: flex; align-items: center; justify-content: center;
    flex-shrink: 0;
}
.spc-body { flex: 1; min-width: 0; }
.spc-name-row { display: flex; align-items: center; gap: 7px; margin-bottom: 4px; }
.spc-name { font-size: 15px; font-weight: 800; color: #1a1a1a; }
.spc-stats { font-size: 12px; color: #999; display: flex; align-items: center; gap: 5px; }
.spc-stats b { color: #444; font-weight: 700; }
.spc-dot { color: #ddd; }
.spc-storefront-btn {
    font-size: 12px; font-weight: 700; color: var(--apc-blue);
    background: none; border: none; cursor: pointer;
    white-space: nowrap; padding: 0; font-family: inherit; flex-shrink: 0;
}

/* INBOX — tabs and content */
.inbox-tabs {
    display: flex;
    background: white;
    border-radius: 12px;
    margin-bottom: 15px;
    overflow: hidden;
}
.inbox-tab {
    flex: 1;
    text-align: center;
    padding: 12px;
    font-weight: 700;
    font-size: 13px;
    color: #888;
    cursor: pointer;
    background: #f4f4f4;
    transition: background 0.15s, color 0.15s;
}
.inbox-tab.active {
    background: var(--apc-orange);
    color: white;
}
.inbox-tab:not(.active):hover { background: #e0e0e0; }

.inbox-item {
    background: white;
    border-radius: 12px;
    padding: 14px;
    margin-bottom: 10px;
    display: flex;
    align-items: center;
    gap: 12px;
    border: 1px solid transparent;
}
.inbox-item.unread {
    border-color: #F7941D;
    box-shadow: 0 8px 20px rgba(247, 148, 29, 0.08);
}
.inbox-item.flagged {
    border-color: #FF9800;
}
.inbox-icon { font-size: 24px; }
.inbox-text { flex: 1; min-width: 0; }
.inbox-title { font-weight: 800; font-size: 14px; color: var(--apc-charcoal); }
.inbox-meta { font-size: 11px; color: #666; margin-top: 2px; }
.inbox-actions {
    display: flex;
    align-items: center;
    gap: 8px;
}
.inbox-action-btn {
    border: none;
    background: transparent;
    padding: 6px;
    border-radius: 10px;
    cursor: pointer;
    font-size: 16px;
    color: #888;
    transition: background 0.15s, color 0.15s;
}
.inbox-action-btn:hover {
    background: rgba(0,0,0,0.05);
    color: #333;
}
.inbox-flag-btn.flagged {
    color: var(--apc-orange);
}
.inbox-delete-btn:hover {
    color: #FF3B30;
}

/* MESSAGE DETAIL DRAWER */
.message-detail-action-btn {
    border: none;
    background: #f5f5f5;
    padding: 10px 16px;
    border-radius: 8px;
    cursor: pointer;
    font-size: 14px;
    font-weight: 600;
    color: #666;
    transition: background 0.15s, color 0.15s;
}
.message-detail-action-btn:hover {
    background: #e0e0e0;
    color: #333;
}
.message-detail-action-btn.flagged {
    background: #FFF9F2;
    color: var(--apc-orange);
}
.message-detail-action-btn.delete {
    background: #FFF5F5;
    color: #FF3B30;
}
.message-detail-action-btn.delete:hover {
    background: #FFE5E5;
}

/* SAVE / HEART button — sits on the carousel inside the detail overlay */
.detail-save-btn {
    position: absolute;
    top: 12px;
    right: 12px;
    width: 44px;
    height: 44px;
    border: none;
    background: rgba(255,255,255,0.95);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 24px;
    cursor: pointer;
    color: #888;
    box-shadow: 0 3px 10px rgba(0,0,0,0.22);
    z-index: 10;
    line-height: 1;
    padding: 0;
    font-family: inherit;
    transition: transform 0.1s, color 0.15s;
}
.detail-save-btn:active { transform: scale(0.9); }
.detail-save-btn.saved  { color: #FF3B30; }

/* Toast — single global feedback chip */
.app-toast {
    position: fixed;
    bottom: 95px;
    left: 50%;
    z-index: 9999;
    transform: translateX(-50%) translateY(8px);
    background: #333;
    color: white;
    padding: 9px 18px;
    border-radius: 999px;
    font-size: 12px;
    font-weight: 700;
    z-index: 5000;
    opacity: 0;
    transition: opacity 0.2s, transform 0.2s;
    pointer-events: none;
    white-space: nowrap;
}
.app-toast.show {
    opacity: 1;
    transform: translateX(-50%) translateY(0);
}

/* STICKY BUTTON */
.sticky-action-bar {
    position: absolute; bottom: 0; left: 0; right: 0; padding: 15px;
    background: linear-gradient(to top, rgba(255,255,255,1) 80%, rgba(255,255,255,0));
    transition: transform 0.3s ease-in-out; z-index: 100;
}
.sticky-hidden { transform: translateY(100%); }

/* FORM ELEMENTS */
.filter-section { margin-bottom: 22px; }
.filter-section h4 { font-size: 10px; text-transform: uppercase; border-bottom: 2px solid var(--apc-orange); display: inline-block; margin-bottom: 10px; }
.input-group { margin-bottom: 10px; }
.input-group label { display: block; font-size: 9px; font-weight: 900; margin-bottom: 4px; color: #888; }
.input-group input, .input-group select, .input-group textarea { 
    width: 100%; 
    padding: 12px; 
    border: 1px solid #ddd; 
    border-radius: 8px; 
    box-sizing: border-box; 
    background: white; 
    font-family: inherit; 
    font-size: 14px; 
    resize: vertical; 
}
.input-group textarea { min-height: 110px; }
.input-row-flex { display: flex; gap: 10px; }
.input-row-flex .input-group { flex: 1; }
.apc-textarea {
    width: 100%;
    padding: 12px 14px;
    border: 1.5px solid #ddd;
    border-radius: 12px;
    box-sizing: border-box;
    background: #f9f9f9;
    font-family: inherit;
    font-size: 14px;
    line-height: 1.5;
    color: #222;
    resize: vertical;
    outline: none;
    transition: border-color 0.15s;
}
.apc-textarea:focus { border-color: var(--apc-orange); background: #fff; }
.apc-textarea::placeholder { color: #aaa; }
.shared-choice-box { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.shared-choice-box .choice-item { justify-content: flex-start; }
.choice-item { display: flex; align-items: center; gap: 5px; font-size: 12px; font-weight: 700; cursor: pointer; }
.choice-item input[type="checkbox"] { accent-color: var(--apc-orange); width: 17px; height: 17px; cursor: pointer; flex-shrink: 0; }

/* Workshop filter — collapsible panel */
.ws-filter-toggle-row { margin-bottom: 10px; }
.ws-filter-toggle-btn {
    display: flex;
    align-items: center;
    gap: 8px;
    width: 100%;
    padding: 10px 14px;
    background: #f7f7f7;
    border: 1px solid var(--apc-orange);
    border-radius: 10px;
    font-size: 12px;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    color: #333;
    cursor: pointer;
    transition: background 0.15s;
}
.ws-filter-toggle-btn:hover { background: #fff6ec; }
.ws-filter-badge {
    background: var(--apc-orange);
    color: white;
    font-size: 10px;
    font-weight: 900;
    border-radius: 10px;
    padding: 1px 7px;
    line-height: 1.6;
}
.ws-filter-chevron { margin-left: auto; font-size: 11px; color: #888; }
.ws-filter-panel {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.35s ease;
    margin-bottom: 0;
}
.ws-filter-panel.open {
    max-height: 1200px;
    margin-bottom: 16px;
}
.ws-filter-actions {
    display: flex;
    gap: 14px;
    padding: 10px 0 4px;
}
.ws-filter-action-btn {
    font-size: 11px;
    font-weight: 800;
    color: var(--apc-orange);
    cursor: pointer;
    text-decoration: underline;
    text-underline-offset: 2px;
}

/* Workshop browse — compact search + distance bar */
.ws-search-bar {
    display: flex;
    flex-direction: column;
    gap: 8px;
    margin-bottom: 16px;
}
.ws-search-input { flex: 1; }
.ws-radius-control { width: 100%; }

/* Workshop service filter grid */
#workshopServiceGrid {
    display: flex;
    flex-direction: column;
    gap: 14px;
    padding: 14px 0 10px;
}
.ws-filter-group {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 6px 16px;
}
.ws-filter-group-label {
    grid-column: 1 / -1;
    font-size: 10px;
    font-weight: 900;
    text-transform: uppercase;
    letter-spacing: 0.6px;
    color: var(--apc-orange);
    padding-bottom: 2px;
    border-bottom: 1px solid #f0f0f0;
    margin-bottom: 2px;
}

/* Approved repairer filter */
.workshop-approved-section {
    margin-top: 4px;
    padding: 10px 12px;
    background: #eef4ff;
    border: 1px solid #c5d9f7;
    border-radius: 10px;
}
.workshop-approved-label {
    display: flex;
    align-items: center;
    gap: 8px;
    cursor: pointer;
    font-size: 13px;
    font-weight: 700;
    color: var(--apc-charcoal);
}
.approved-club-badge {
    background: #005eb8;
    color: white;
    font-size: 9px;
    font-weight: 900;
    padding: 2px 7px;
    border-radius: 4px;
    letter-spacing: 0.5px;
    text-transform: uppercase;
    flex-shrink: 0;
    white-space: nowrap;
}
.workshop-approved-subtext {
    font-size: 11px;
    color: #6a82a0;
    margin-top: 5px;
    margin-left: 22px;
    line-height: 1.4;
}
.motoring-clubs-banner {
    display: block;
    width: 100%;
    height: auto;
    max-height: 50px;
    object-fit: contain;
    margin-top: 10px;
    border-radius: 6px;
    opacity: 0.88;
    mix-blend-mode: multiply;
}

/* Approved badge on workshop cards */
.card-approved-badge {
    display: inline-flex;
    align-items: center;
    gap: 3px;
    background: #005eb8;
    color: white;
    font-size: 9px;
    font-weight: 900;
    padding: 2px 7px;
    border-radius: 4px;
    letter-spacing: 0.3px;
    text-transform: uppercase;
}
/* Detail overlay — horizontal mini card strip */
.detail-footer-strip {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 10px;
}
.detail-footer-label {
    font-size: 10px;
    font-weight: 900;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    color: #888;
    margin-bottom: 8px;
    display: flex;
    align-items: center;
    justify-content: space-between;
}
.detail-mini-card {
    background: white;
    border-radius: 8px;
    border: 1px solid #eee;
    overflow: hidden;
    cursor: pointer;
    transition: box-shadow 0.15s;
    display: flex;
    flex-direction: column;
}
.detail-mini-card:hover { box-shadow: 0 2px 10px rgba(0,0,0,0.1); }
.detail-mini-img {
    width: 100%;
    aspect-ratio: 4/3;
    object-fit: cover;
    background: #f0f0f0;
}
.detail-mini-info {
    padding: 6px 8px 8px;
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 2px;
}
.detail-mini-title {
    font-size: 11px;
    font-weight: 700;
    color: #333;
    line-height: 1.3;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}
.detail-mini-price {
    font-size: 12px;
    font-weight: 900;
    color: var(--apc-blue);
    margin-top: auto;
}

.action-container { padding: 10px 0 20px 0; }
.btn-full-action { width: 100%; background: var(--apc-orange); color: white; padding: 20px; border: none; border-radius: 12px; font-weight: 900; cursor: pointer; font-size: 14px; }
.btn-full-action:disabled { opacity: 0.55; cursor: not-allowed; }

/* DEMAND BADGES */
.demand-icon-area { width: 100%; aspect-ratio: 4/3; background: #f9f9f9; display: flex; align-items: center; justify-content: center; font-size: 40px; border-bottom: 1px solid #eee; }
.heat-badge { position: absolute; top: 8px; right: 8px; background: #FF3B30; color: white; font-size: 8px; font-weight: 900; padding: 2px 6px; border-radius: 4px; z-index: 10; }

/* IMAGE CAROUSEL — fixed scroll-snap property names */
#imageCarousel { 
    display: flex; 
    overflow-x: auto; 
    scroll-snap-type: x mandatory;          /* fixed: was snap-type */
    -webkit-overflow-scrolling: touch;
    scroll-behavior: smooth;
}
#imageCarousel img {
    scroll-snap-align: start;
    flex-shrink: 0;
    width: 100%;
    aspect-ratio: 1/1;
    object-fit: contain;
    background: #f4f4f4;
}

/* CAROUSEL DOT INDICATORS */
.carousel-dots {
    position: absolute;
    bottom: 12px;
    left: 50%;
    transform: translateX(-50%);
    display: none;                    /* shown by JS only when there's > 1 image */
    gap: 8px;
    pointer-events: auto;
    z-index: 5;
}
.carousel-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: rgba(255,255,255,0.6);
    box-shadow: 0 1px 3px rgba(0,0,0,0.5);
    transition: background 0.2s ease, transform 0.2s ease;
    cursor: pointer;
    flex-shrink: 0;
}
.carousel-dot.active {
    background: white;
    transform: scale(1.3);
}

/* CAROUSEL: mobile vs desktop */
.mobile-carousel { display: none; }
.desktop-thumbs-container { display: block; }

@media (max-width: 600px) {
    .mobile-carousel { display: block; }
    .desktop-thumbs-container { display: none; }
    #imageCarousel::-webkit-scrollbar { display: none; }
    #imageCarousel { -ms-overflow-style: none; scrollbar-width: none; }
    .image-lightbox { background: #000; backdrop-filter: none; -webkit-backdrop-filter: none; }
}

/* MY PARTS LIST */
.my-part-row {
    background: white;
    border: 1px solid #eee;
    border-radius: 12px;
    padding: 10px 12px;
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 8px;
}
.my-part-thumb {
    width: 50px;
    height: 50px;
    border-radius: 8px;
    object-fit: cover;
    flex-shrink: 0;
}
.my-part-info {
    flex: 1;
    min-width: 0;
}
.my-part-title {
    font-weight: 800;
    font-size: 13px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}
.my-part-sub {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-top: 4px;
}
.my-part-price {
    font-size: 13px;
    font-weight: 900;
    color: var(--apc-blue);
}
.my-part-badge {
    font-size: 9px;
    font-weight: 900;
    color: var(--apc-green);
    background: var(--apc-green-bg);
    padding: 2px 6px;
    border-radius: 4px;
    flex-shrink: 0;
}
.my-part-badge.pending { color: #b86e00; background: #fff3cd; }
.my-part-badge.sold    { color: #888;    background: #f0f0f0; }
.my-part-row.sold { opacity: 0.6; }
.my-part-row.sold .my-part-thumb  { filter: grayscale(0.6); }
.my-part-row.sold .my-part-price  { color: #888; }
.my-part-manage-btn {
    border: none;
    background: var(--apc-blue);
    color: #fff;
    padding: 8px 14px;
    border-radius: 8px;
    font-weight: 900;
    font-size: 10px;
    cursor: pointer;
    flex-shrink: 0;
    letter-spacing: 0.3px;
}
.my-part-delete-btn {
    background: none;
    border: 1.5px solid #ddd;
    border-radius: 50%;
    width: 28px;
    height: 28px;
    font-size: 18px;
    color: #aaa;
    cursor: pointer;
    flex-shrink: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    line-height: 1;
    transition: border-color 0.15s, color 0.15s;
}
.my-part-delete-btn:hover { border-color: #FF3B30; color: #FF3B30; }
.my-part-delete-btn:active { transform: scale(0.85); }

/* MANAGE LISTING — status pills + rate buyer (edit mode only) */
.manage-section {
    margin-top: 4px;
}
.manage-status-pills {
    display: flex;
    gap: 8px;
    margin-top: 8px;
}
.status-pill {
    flex: 1;
    padding: 9px 6px;
    border-radius: 8px;
    font-weight: 800;
    font-size: 11px;
    border: 2px solid #e0e0e0;
    background: #f5f5f5;
    color: #aaa;
    cursor: pointer;
    transition: all 0.15s;
}
.status-pill.pill-selected-active  { color: #155c24; background: #e6f4ea; border-color: #28a745; }
.status-pill.pill-selected-pending { color: #b86e00; background: #fff3cd; border-color: #e6950a; }
.status-pill.pill-selected-sold    { color: #444;    background: #ececec; border-color: #888; }
.rate-buyer-section {
    margin-top: 16px;
    padding-top: 16px;
    border-top: 1px solid #eee;
}
.rate-buyer-section h4 { margin-bottom: 8px; }
.rate-stars-row {
    display: flex;
    gap: 6px;
}
.rate-star {
    font-size: 30px;
    cursor: pointer;
    color: #ddd;
    transition: color 0.1s;
    line-height: 1;
    user-select: none;
}
.rate-star.filled { color: #f5a623; }
.buyer-picker {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-top: 6px;
}
.buyer-chip {
    padding: 7px 14px;
    border-radius: 20px;
    border: 2px solid #ddd;
    background: #f5f5f5;
    font-weight: 700;
    font-size: 12px;
    color: #444;
    cursor: pointer;
    transition: all 0.15s;
}
.buyer-chip.selected {
    border-color: var(--apc-blue);
    background: #e8f0fe;
    color: var(--apc-blue);
}
.buyer-chip-input {
    width: 100%;
    margin-top: 8px;
    padding: 8px 10px;
    border: 1px solid #ddd;
    border-radius: 8px;
    font-size: 13px;
}

/* CHAT BUBBLE — replaces inline style from JS, safe textContent insertion */
.chat-bubble-sent {
    align-self: flex-end;
    background: #DCF8C6;
    padding: 10px 15px;
    border-radius: 15px 15px 0 15px;
    max-width: 80%;
    font-size: 14px;
    margin-bottom: 10px;
    box-shadow: 0 1px 2px rgba(0,0,0,0.1);
    word-break: break-word;             /* prevents long words breaking the layout */
}

.chat-bubble-image {
    width: 100%;
    display: block;
    border-radius: 14px;
    object-fit: cover;
    max-height: 360px;
}

.chat-attach-btn {
    width: 38px;
    height: 38px;
    border-radius: 50%;
    border: 1.5px solid var(--apc-orange);
    background: white;
    color: var(--apc-orange);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    flex-shrink: 0;
    transition: background 0.15s, color 0.15s;
}

.chat-attach-btn:hover {
    background: var(--apc-orange);
    color: white;
}

.chat-attach-btn svg {
    display: block;
}

/* ============================================================
   DESKTOP SIDEBAR (base styles — display:none on mobile)
   ============================================================ */
.desktop-sidebar {
    display: none;
    flex-direction: column;
    position: fixed;
    top: 0; left: 0;
    width: 220px;
    height: 100vh;
    background: white;
    border-right: 1px solid #eee;
    box-shadow: 2px 0 12px rgba(0,0,0,0.06);
    z-index: 1200;
    overflow-y: auto;
}
.dsb-brand {
    padding: 14px 18px;
    border-bottom: 5px solid var(--apc-orange);
    flex-shrink: 0;
}
.dsb-brand img { height: 46px; width: auto; display: block; }
.dsb-nav { flex: 1; padding: 8px 0; }
.dsb-item {
    display: flex;
    align-items: center;
    padding: 14px 20px;
    font-size: 14px;
    font-weight: 800;
    color: var(--apc-charcoal);
    cursor: pointer;
    letter-spacing: 0.3px;
    transition: background 0.1s, color 0.1s;
    position: relative;
}
.dsb-item:hover { background: #f7f7f7; }
.dsb-item.active { color: var(--apc-orange); background: #fff6ec; }
.dsb-item.active::before {
    content: '';
    position: absolute;
    left: 0; top: 0; bottom: 0;
    width: 4px;
    background: var(--apc-orange);
    border-radius: 0 3px 3px 0;
}
.dsb-inbox-badge {
    background: #FF3B30;
    color: white;
    font-size: 9px;
    font-weight: 800;
    border-radius: 999px;
    padding: 1px 5px;
    min-width: 16px;
    text-align: center;
    margin-left: auto;
}
.dsb-sell-wrap { padding: 16px; border-top: 1px solid #eee; flex-shrink: 0; }
.dsb-sell {
    background: var(--apc-orange);
    color: white;
    text-align: center;
    padding: 14px;
    border-radius: 12px;
    font-size: 13px;
    font-weight: 900;
    cursor: pointer;
    letter-spacing: 0.5px;
    box-shadow: 0 3px 10px rgba(247,148,29,0.35);
    transition: background 0.15s;
}
.dsb-sell:hover { background: #e07b00; }

/* DRAWER BACKDROP — desktop only */
#drawerBackdrop {
    display: none;
    position: fixed;
    top: 0; left: 0; right: 0; bottom: 0;
    background: rgba(0,0,0,0.45);
    z-index: 1998;
}

/* ============================================================
   DESKTOP UTILITY BAR + RIGHT PANEL (base — hidden on mobile)
   ============================================================ */
.desktop-top-bar {
    display: none;
    position: fixed;
    top: 0; left: 0; right: 0;
    height: 36px;
    background: #fdfdfd;
    border-bottom: 1px solid #eee;
    padding: 0 20px;
    align-items: center;
    justify-content: space-between;
    font-size: 11px;
    font-weight: 600;
    z-index: 3100;
    box-sizing: border-box;
}
.dtb-left, .dtb-right { display: flex; align-items: center; gap: 4px; }
.dtb-link {
    padding: 0 12px;
    height: 36px;
    display: flex;
    align-items: center;
    gap: 5px;
    color: #555;
    cursor: pointer;
    text-transform: uppercase;
    letter-spacing: 0.4px;
    transition: color 0.1s, background 0.1s;
    text-decoration: none;
}
.dtb-link:hover { color: var(--apc-orange); background: var(--apc-orange-light, #fff4e6); }
.dtb-active { color: var(--apc-orange) !important; }
.dtb-sell { color: var(--apc-orange) !important; font-weight: 900; }
.dtb-badge {
    background: #FF3B30;
    color: white;
    font-size: 9px;
    font-weight: 800;
    border-radius: 999px;
    padding: 1px 5px;
    min-width: 14px;
    text-align: center;
}

.desktop-right-panel {
    display: none;
    position: fixed;
    right: 0;
    width: 220px;
    overflow-y: auto;
    padding: 10px 10px 20px;
    box-sizing: border-box;
    background: #f4f4f4;
}

/* Sidebar cards — base */
.drp-card {
    background: white;
    border-radius: 14px;
    box-shadow: 0 2px 12px rgba(0,0,0,0.07);
    margin-bottom: 12px;
    overflow: hidden;
}

/* Sponsored / Featured / Partner tag */
.drp-sponsored-tag {
    display: inline-block;
    font-size: 9px;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.6px;
    color: white;
    background: var(--apc-orange);
    padding: 4px 10px;
    border-radius: 14px 0 8px 0;
}
.drp-sponsored-tag--subtle {
    color: #aaa;
    background: #f0f0f0;
    border-radius: 6px;
    padding: 3px 7px;
}

/* Featured Supplier card */
.drp-supplier-card { padding-bottom: 14px; }
.drp-supplier-logo {
    margin: 10px 12px 8px;
    width: 44px;
    height: 44px;
    border-radius: 10px;
    background: linear-gradient(135deg, var(--apc-orange), #e05000);
    display: flex;
    align-items: center;
    justify-content: center;
}
.drp-supplier-logo-placeholder {
    font-size: 12px;
    font-weight: 900;
    color: white;
    letter-spacing: 0.5px;
}
.drp-supplier-name {
    font-size: 13px;
    font-weight: 800;
    color: #222;
    padding: 0 12px 3px;
    line-height: 1.2;
}
.drp-supplier-tagline {
    font-size: 10px;
    color: #888;
    padding: 0 12px 10px;
    line-height: 1.4;
}
.drp-supplier-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 4px;
    padding: 0 12px 10px;
}
.drp-tag {
    font-size: 9px;
    font-weight: 700;
    color: var(--apc-orange);
    background: #fff3e8;
    border: 1px solid #ffd5a8;
    border-radius: 20px;
    padding: 2px 8px;
}
.drp-supplier-btn {
    display: block;
    width: calc(100% - 24px);
    margin: 0 12px;
    padding: 8px 0;
    background: var(--apc-orange);
    color: white;
    border: none;
    border-radius: 8px;
    font-size: 11px;
    font-weight: 800;
    cursor: pointer;
    letter-spacing: 0.3px;
}

/* Individual sponsored part card */
.drp-sp-card {
    cursor: pointer;
    overflow: hidden;
    padding: 0;
    transition: box-shadow 0.15s, transform 0.15s;
}
.drp-sp-card:hover {
    box-shadow: 0 4px 18px rgba(0,0,0,0.13);
    transform: translateY(-1px);
}
.drp-sp-img-wrap {
    position: relative;
    overflow: hidden;
    border-radius: 14px 14px 0 0;
}
.drp-sp-img {
    width: 100%;
    height: 120px;
    object-fit: cover;
    display: block;
    background: #eee;
}
.drp-sp-img-wrap .drp-sponsored-tag {
    position: absolute;
    top: 0;
    left: 0;
}
.drp-sp-info { padding: 8px 10px 12px; }
.drp-sp-price { font-size: 15px; font-weight: 900; color: var(--apc-blue-bg); margin-bottom: 3px; }
.drp-sp-title {
    font-size: 11px; font-weight: 700; color: #222; line-height: 1.3;
    display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden;
    margin-bottom: 3px;
}
.drp-sp-seller { font-size: 9px; color: #aaa; }

/* Partner / affiliate card */
.drp-partner-card { padding: 10px 12px 14px; }
.drp-partner-logo { font-size: 24px; margin-bottom: 6px; }
.drp-partner-name { font-size: 12px; font-weight: 800; color: #222; margin-bottom: 4px; }
.drp-partner-desc { font-size: 10px; color: #888; line-height: 1.4; margin-bottom: 10px; }
.drp-partner-btn {
    display: block;
    width: 100%;
    padding: 7px 0;
    background: #f0f0f0;
    color: #444;
    border: none;
    border-radius: 8px;
    font-size: 11px;
    font-weight: 800;
    cursor: pointer;
}

/* DETAIL OVERLAY — desktop image column (hidden on mobile) */
.desktop-detail-images { display: none; }
.detail-info-col { display: block; }
.detail-sell-yours-block { display: none; }

/* ============================================================
   DESKTOP LAYOUT — 900px+
   ============================================================ */
@media (min-width: 900px) {
    /* Show utility bar, right panel. Hide nav sidebar and bottom nav */
    .desktop-top-bar { display: flex; }
    .desktop-right-panel { display: block; }
    .desktop-sidebar { display: none !important; }
    .bottom-nav { display: none !important; }

    /* Constrain page to 1400px centred — sides show html background */
    html { background: #e0e0e0; scrollbar-gutter: stable; }
    body {
        padding-bottom: 0;
        padding-left: 240px;
        padding-right: 220px;
        max-width: 1400px;
        margin-left: auto;
        margin-right: auto;
        box-sizing: border-box;
    }

    /* Top utility bar: constrained to 1400px zone */
    .desktop-top-bar {
        left: max(0px, calc(50vw - 700px));
        right: max(0px, calc(50vw - 700px));
    }

    /* Header: constrained to 1400px zone */
    .top-nav-container {
        top: 36px;
        left: max(0px, calc(50vw - 700px));
        right: max(0px, calc(50vw - 700px));
        width: auto;
    }

    /* Single-row header — three zones matching the sidebar layout:
       [240px logo zone] [flex:1 search = grid width] [220px pill zone] */
    header {
        display: flex;
        align-items: center;
        padding: 8px 0;
        gap: 0;
    }
    .header-top { display: contents; }
    .logo-main  { order: 1; flex-shrink: 0; width: 240px; display: flex; align-items: center; padding: 0 8px; }
    .logo-main img { width: 100%; height: auto; max-height: 64px; object-fit: contain; }
    .search-col { order: 2; flex: 1; display: flex; flex-direction: column; gap: 6px; max-width: none; padding: 0; }
    .search-col .search-group { margin: 0; }
    #proSearchToggle { margin-top: 0; }

    .header-inbox-btn { display: none !important; }
    #accountPillZone { order: 3; flex-shrink: 0; width: 220px; display: flex; flex-direction: column; justify-content: center; align-items: center; padding: 0 8px; }
    #accountPill    { width: auto; }
    .sign-up-prompt { display: block; }
    .account-pill.signed-out {
        font-size: 13px;
        padding: 11px 24px;
        border-radius: 8px;
    }
    /* Desktop signed-in: just the avatar circle, no pill box */
    .account-pill.signed-in {
        background: transparent;
        border: none;
        box-shadow: none;
        border-radius: 50%;
        padding: 4px;
        justify-content: center;
        gap: 0;
        transition: opacity 0.15s;
    }
    .account-pill.signed-in.tier-pro { box-shadow: none; }
    .pill-avatar { width: 36px; height: 36px; font-size: 14px; }
    .account-pill.signed-in:hover .pill-avatar { transform: scale(1.08); transition: transform 0.15s; }

    /* Right panel: below top bar + header */
    .desktop-right-panel { top: 140px; bottom: 0; } /* fallback — overridden by updateHeaderOffset() */

    /* Filter drawer: always visible as left sidebar on desktop */
    #filterDrawer {
        display: flex !important;
        position: fixed;
        left: max(0px, calc(50vw - 700px));
        top: 140px; /* fallback — overridden by updateHeaderOffset() after images load */
        bottom: 0;
        height: auto;
        width: 240px;
        z-index: 600;
        border-right: 1px solid #eee;
        box-shadow: 2px 0 10px rgba(0,0,0,0.04);
        overflow-y: auto;
        box-sizing: border-box;
    }
    #filterDrawer .drawer-header { display: none; }
    .filter-drawer-close { display: none; }
    .btn-search-filters { display: none; }

    /* 5-column grid */
    .results-grid {
        grid-template-columns: repeat(5, 1fr);
        gap: 10px;
        padding: 8px 14px;
    }
    .grid-heading { padding: 12px 14px 4px; }
    .grid-heading-label { font-size: 14px; }

    /* Desktop card sizing + subtle hover — click card to open detail */
    .item-card {
        height: 240px;
        border-radius: 10px;
        border: 1px solid #eee;
        box-shadow: 0 2px 8px rgba(0,0,0,0.06);
        cursor: pointer;
        transition: transform 0.2s, border-color 0.2s, box-shadow 0.2s;
    }
    .item-card:hover { transform: translateY(-3px); border-color: var(--apc-orange); box-shadow: 0 6px 18px rgba(247,148,29,0.15); }
    .item-img { aspect-ratio: unset; height: 100%; }
    .item-info {
        position: absolute;
        bottom: 0; left: 0; right: 0;
        background: rgba(255,255,255,0.94);
        backdrop-filter: blur(6px);
        padding: 10px 12px;
    }

    /* Right panel: constrained to 1400px zone */
    .desktop-right-panel { right: max(0px, calc(50vw - 700px)); }

    /* Drawers become right-side panels */
    .drawer { left: auto; right: max(0px, calc(50vw - 700px)); width: 500px; }
    .drawer.active { box-shadow: -4px 0 40px rgba(0,0,0,0.18); }
    #accountMenuDrawer { width: 360px; }
    #filterDrawer { right: auto; width: 240px; box-shadow: none; }
    /* Inbox: float off the bottom edge so the reply bar isn't flush against the screen */
    #inboxDrawer { bottom: 18px; border-radius: 0 0 14px 14px; }

    /* Sell overlay: full card-drawer, two-column form layout */
    #sellOverlay {
        left: calc(max(0px, 50vw - 700px) + 240px) !important;
        right: calc(max(0px, 50vw - 700px) + 220px) !important;
        width: auto !important;
        height: auto !important;
    }
    #sellOverlay .drawer-header,
    #settingsDrawer .drawer-header,
    #workshopDrawer .drawer-header {
        border-bottom: 3px solid var(--apc-orange);
        border-radius: 0;
        flex-shrink: 0;
    }
    #sellOverlay .drawer-content {
        overflow: hidden;
        display: flex;
        flex-direction: column;
        flex: 1;
        min-height: 0;
    }
    .sell-form-grid {
        display: grid;
        grid-template-columns: 1fr 1fr;
        flex: 1;
        overflow: hidden;
    }
    .sell-left-col {
        overflow-y: auto;
        padding: 20px;
        border-right: 1px solid #f0f0f0;
    }
    .sell-right-col {
        overflow-y: auto;
        padding: 20px;
    }

    /* Settings: two-column layout on desktop */
    #settingsDrawer .drawer-content {
        display: grid;
        grid-template-columns: 1fr 1fr;
        align-items: start;
        overflow-y: auto;
        padding: 20px;
        gap: 0 24px;
    }
    #settingsDrawer .settings-col-left,
    #settingsDrawer .settings-col-right { min-width: 0; }
    #settingsProfileCard { grid-column: 1 / -1; margin: -20px -20px 20px -20px; }

    /* Detail overlay: fills center column between sidebars */
    #detailOverlay {
        left: calc(max(0px, 50vw - 700px) + 240px) !important;
        right: calc(max(0px, 50vw - 700px) + 220px) !important;
        width: auto !important;
        height: auto !important;
        top: 36px; /* overridden by updateHeaderOffset() — aligns with top of search bar */
        bottom: 0;
        box-shadow: none !important;
        border-left: 1px solid #e8e8e8;
        border-right: 1px solid #e8e8e8;
    }
    /* Two-column layout: images left, info right — footer strip pinned below */
    #detailScrollArea {
        display: grid !important;
        grid-template-columns: 55% 45%;
        grid-template-rows: 1fr auto;
        height: 100% !important;
        overflow: hidden !important;
        padding-bottom: 0 !important;
        position: unset !important;
    }
    .desktop-detail-images {
        display: flex !important;
        flex-direction: column;
        overflow-y: auto;
        min-height: 0;
        padding: 24px;
        background: #f7f7f7;
        border-right: 1px solid #eee;
    }
    .mobile-carousel { display: none !important; }
    .detail-info-col { overflow-y: auto; min-height: 0; padding-bottom: 24px; }
    #sellYoursMobile { display: none !important; }
    .detail-sell-yours-block {
        display: flex !important;
        flex-direction: column;
        align-items: center;
        gap: 10px;
        margin-top: auto;
        padding: 16px;
        background: #fff7eb;
        border: 1.5px dashed var(--apc-orange);
        border-radius: 10px;
        cursor: pointer;
        transition: background 0.15s;
    }
    .detail-sell-yours-block:hover { background: #fff0d6; }
    .detail-sell-yours-label {
        font-size: 12px;
        font-weight: 700;
        color: #7a4b0d;
    }
    .detail-sell-yours-btn {
        background: var(--apc-orange);
        color: white;
        border: none;
        border-radius: 8px;
        padding: 8px 20px;
        font-size: 12px;
        font-weight: 900;
        cursor: pointer;
        text-transform: uppercase;
        letter-spacing: 0.5px;
        pointer-events: none;
    }
    #dynamicDetailFooter {
        grid-column: 1 / -1;
        border-top: 1px solid #e8e8e8;
        background: #fafafa;
        padding: 12px 16px 14px;
        overflow: hidden;
    }
    #dynamicDetailFooter .detail-footer-strip {
        display: flex;
        align-items: stretch;
        gap: 10px;
        flex-wrap: nowrap;
        overflow: hidden;
    }
    #dynamicDetailFooter .detail-mini-card {
        flex: 0 0 calc(20% - 8px);
    }
    .desktop-main-img {
        width: 100%;
        aspect-ratio: 1/1;
        object-fit: contain;
        border-radius: 12px;
        cursor: zoom-in;
        background: #f4f4f4;
        display: block;
    }
    .desktop-thumbnails {
        display: flex;
        gap: 8px;
        margin-top: 12px;
        flex-wrap: wrap;
    }
    .desktop-thumb {
        width: calc(25% - 6px);
        aspect-ratio: 1;
        object-fit: cover;
        border-radius: 8px;
        cursor: pointer;
        border: 2px solid transparent;
        transition: border-color 0.15s;
        background: #ddd;
    }
    .desktop-thumb:hover { border-color: rgba(247,148,29,0.5); }
    .desktop-thumb.active { border-color: var(--apc-orange); }

    /* Show backdrop when a non-filter drawer is open */
    #drawerBackdrop.active { display: block; }

    /* Apply button redundant on desktop — live filters handle it */
    #filterDrawer .action-container { display: none; }

    /* Detail overlay: seller card moves into info col on desktop */
    .detail-seller-col-card { display: flex !important; }
    #detailSellerSection { display: none !important; }
    /* With seller section hidden, push × to the right — !important overrides inline style */
    #detailOverlay .drawer-header { display: none !important; }
    #detailScrollArea { height: 100% !important; }
    .detail-float-close { display: flex; right: 29px; }

    /* Storefront: same centre-panel positioning as detail overlay */
    #storefrontDrawer {
        left: calc(max(0px, 50vw - 700px) + 240px) !important;
        right: calc(max(0px, 50vw - 700px) + 220px) !important;
        width: auto !important;
        height: auto !important;
        /* top is set dynamically by updateHeaderOffset() */
        bottom: 16px !important;
        border-radius: 16px !important;
        box-shadow: 0 4px 32px rgba(0,0,0,0.15) !important;
        border: none !important;
        overflow: hidden;
    }
    #sellerPartsGrid {
        grid-template-columns: repeat(5, 1fr) !important;
        margin-top: 0 !important;
        gap: 4px !important;
    }
    #sellerPartsGrid .item-card-title { font-size: 10px !important; line-height: 1.3 !important; -webkit-line-clamp: 2 !important; }
    #sellerPartsGrid .item-card-price { font-size: 11px !important; }
    #sellerPartsGrid .item-card-location,
    #sellerPartsGrid .save-btn { display: none !important; }

    /* Floating card drawers — centred, auto height, not full screen */
    #authDrawer {
        left: 50% !important;
        right: auto !important;
        transform: translateX(-50%);
        height: auto !important;
        max-height: calc(100vh - 100px);
        overflow-y: auto;
        top: 36px; /* overridden by updateHeaderOffset() */
        bottom: auto !important;
        border-radius: 16px !important;
        box-shadow: 0 8px 40px rgba(0,0,0,0.18) !important;
        z-index: 2100;
    }
    #authDrawer { width: 420px !important; }

    /* Add Wanted — floating card, centred both axes */
    #addWantedDrawer,
    #addVehicleDrawer {
        left: 50% !important;
        right: auto !important;
        width: 480px !important;
        transform: translate(-50%, -50%) !important;
        top: 50% !important;
        height: auto !important;
        max-height: calc(100vh - 100px);
        overflow-y: auto;
        bottom: auto !important;
        border-radius: 16px !important;
        box-shadow: 0 8px 40px rgba(0,0,0,0.22) !important;
        z-index: 3250;
    }

    /* All full-screen drawers: centre column between sidebars */
    #detailOverlay,
    #garageDrawer,
    #wantedListDrawer,
    #savedPartsDrawer,
    #profileDrawer,
    #myPartsDrawer,
    #workshopDrawer,
    #vehicleMakesDrawer,
    #recentlyViewedDrawer,
    #messageDetailDrawer,
    #chatDrawer,
    #inboxDrawer,
    #settingsDrawer {
        left: calc(max(0px, 50vw - 700px) + 240px) !important;
        right: calc(max(0px, 50vw - 700px) + 220px) !important;
        width: auto !important;
        height: auto !important;
        /* top is set dynamically by updateHeaderOffset() */
        bottom: 0;
        box-shadow: none !important;
        border-left: 1px solid #e8e8e8;
        border-right: 1px solid #e8e8e8;
    }

    /* Detail overlay always sits above other open drawers (e.g. garage) */
    #detailOverlay { z-index: 2050; }

    /* Card-style drawers: rounded corners + shadow, stay as full-column drawers */
    /* top is set dynamically by updateHeaderOffset() — no hardcoded value here */
    #detailOverlay,
    #garageDrawer,
    #myPartsDrawer,
    #wantedListDrawer,
    #savedPartsDrawer,
    #inboxDrawer,
    #settingsDrawer,
    #workshopDrawer,
    #vehicleMakesDrawer,
    #sellOverlay {
        bottom: 16px !important;
        border-radius: 16px !important;
        box-shadow: 0 4px 32px rgba(0,0,0,0.15) !important;
        border: none !important;
        overflow: hidden;
    }

    /* Workshop search + distance — single row on desktop */
    .ws-search-bar { flex-direction: row; align-items: center; gap: 10px; margin-bottom: 14px; }
    .ws-radius-control { width: auto; flex-shrink: 0; }
    .ws-radius-control .radius-seg { padding: 7px 9px; font-size: 10px; }

    /* Workshop service filters — 3 columns on desktop for better space use */
    .ws-filter-group { grid-template-columns: 1fr 1fr 1fr; }

    /* Live filters on desktop — Apply button not needed */
    #filterDrawer .action-container { display: none; }


    /* Dashboard: constrained to 1400px zone */
    #dashboardView {
        left: max(0px, calc(50vw - 700px)) !important;
        right: max(0px, calc(50vw - 700px)) !important;
    }
}

/* ============================================================
   PRO DASHBOARD
   ============================================================ */
.dtb-dashboard { color: var(--apc-orange) !important; font-weight: 800 !important; }

.dash-inner {
    max-width: 1400px;
    margin: 0 auto;
    padding: 28px 32px 48px;
    box-sizing: border-box;
}

/* Page header */
.dash-page-hdr {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 26px;
}
.dash-page-hdr-left {
    display: flex;
    align-items: center;
    gap: 20px;
}
.dash-back-btn {
    background: white;
    border: 1.5px solid #e0e0e0;
    border-radius: 9px;
    padding: 9px 16px;
    font-size: 13px;
    font-weight: 700;
    color: #555;
    cursor: pointer;
    transition: border-color 0.15s, color 0.15s;
    white-space: nowrap;
}
.dash-back-btn:hover { border-color: var(--apc-orange); color: var(--apc-orange); }
.dash-page-title {
    font-size: 24px;
    font-weight: 900;
    color: #1a1a1a;
    line-height: 1.1;
}
.dash-page-sub {
    font-size: 12px;
    color: #888;
    margin-top: 3px;
    font-weight: 500;
}
.dash-pro-pill {
    background: var(--apc-blue);
    color: white;
    font-size: 11px;
    font-weight: 800;
    letter-spacing: 0.6px;
    padding: 6px 14px;
    border-radius: 999px;
}

/* Stat cards */
.dash-stats-row {
    display: grid;
    grid-template-columns: repeat(5, 1fr);
    gap: 14px;
    margin-bottom: 18px;
}
.dash-stat-card {
    background: white;
    border-radius: 14px;
    padding: 22px 20px 18px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.05);
    border-top: 3px solid #eee;
}
.dash-stat-primary { border-top-color: var(--apc-orange); }
.dash-stat-green   { border-top-color: #34c759; }
.dash-stat-ico {
    font-size: 22px;
    margin-bottom: 12px;
    line-height: 1;
}
.dash-heart-ico { color: var(--apc-orange); }
.dash-stat-val {
    font-size: 34px;
    font-weight: 900;
    color: #1a1a1a;
    line-height: 1;
    margin-bottom: 6px;
    letter-spacing: -1px;
}
.dash-stat-lbl {
    font-size: 10px;
    font-weight: 700;
    color: #999;
    text-transform: uppercase;
    letter-spacing: 0.4px;
}

/* Mid row: charts + activity */
.dash-mid-row {
    display: grid;
    grid-template-columns: 1.6fr 1fr 0.7fr;
    gap: 14px;
    margin-bottom: 18px;
}
.dash-chart-main, .dash-chart-cat, .dash-activity-col { min-height: 260px; }

/* Generic card */
.dash-card {
    background: white;
    border-radius: 14px;
    padding: 20px 22px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.05);
}
.dash-card-hdr {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 16px;
}
.dash-card-title {
    font-size: 12px;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.6px;
    color: #444;
}
.dash-card-meta {
    font-size: 11px;
    color: #bbb;
    font-weight: 600;
}
.dash-chart-wrap {
    position: relative;
    height: 190px;
}

/* Tabs */
.dash-tabs { display: flex; gap: 6px; }
.dash-tab {
    background: #f0f0f0;
    border: none;
    border-radius: 8px;
    padding: 6px 14px;
    font-size: 12px;
    font-weight: 700;
    color: #666;
    cursor: pointer;
    transition: background 0.15s, color 0.15s;
    display: flex;
    align-items: center;
    gap: 6px;
}
.dash-tab.active { background: var(--apc-orange); color: white; }
.dash-tab-badge {
    background: rgba(0,0,0,0.12);
    border-radius: 999px;
    padding: 1px 7px;
    font-size: 10px;
    font-weight: 800;
}
.dash-tab.active .dash-tab-badge { background: rgba(255,255,255,0.3); }

/* Activity feed */
.dash-activity-list {
    display: flex;
    flex-direction: column;
    overflow-y: auto;
    max-height: 210px;
}
.dash-activity-item {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    padding: 10px 0;
    border-bottom: 1px solid #f5f5f5;
}
.dash-activity-item:last-child { border-bottom: none; }
.dash-act-ico {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 14px;
    flex-shrink: 0;
}
.dash-act-text {
    flex: 1;
    font-size: 12px;
    line-height: 1.4;
    color: #333;
}
.dash-act-time {
    font-size: 10px;
    color: #bbb;
    font-weight: 600;
    margin-top: 2px;
    display: block;
}

/* Listings search row */
.dash-search-row {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 14px 0 10px;
    border-top: 1px solid #f0f0f0;
}
.dash-search-input {
    flex: 1;
    padding: 9px 14px;
    border: 1.5px solid #e8e8e8;
    border-radius: 9px;
    font-size: 13px;
    font-family: inherit;
    outline: none;
    transition: border-color 0.15s;
    background: #fafafa;
}
.dash-search-input:focus { border-color: var(--apc-orange); background: white; }
.dash-search-select {
    padding: 9px 12px;
    border: 1.5px solid #e8e8e8;
    border-radius: 9px;
    font-size: 13px;
    font-family: inherit;
    background: #fafafa;
    color: #555;
    outline: none;
    cursor: pointer;
    transition: border-color 0.15s;
}
.dash-search-select:focus { border-color: var(--apc-orange); }
.dash-results-count {
    font-size: 11px;
    color: #bbb;
    font-weight: 600;
    white-space: nowrap;
}

/* Listings table */
.dash-listings-body { overflow-x: auto; }
.dash-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 13px;
}
.dash-table th {
    text-align: left;
    font-size: 10px;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    color: #bbb;
    padding: 10px 14px 8px;
    border-bottom: 1.5px solid #f0f0f0;
}
.dash-table td {
    padding: 13px 14px;
    border-bottom: 1px solid #f8f8f8;
    vertical-align: middle;
}
.dash-table tr:last-child td { border-bottom: none; }
.dash-table tbody tr:hover td { background: #fffaf5; }
.dash-thumb {
    width: 46px;
    height: 46px;
    object-fit: cover;
    border-radius: 8px;
    display: block;
}
.dash-part-name { font-weight: 700; color: #1a1a1a; }
.dash-part-sub  { font-size: 11px; color: #999; margin-top: 3px; }
.dash-td-price  { font-weight: 800; color: var(--apc-orange); white-space: nowrap; }
.dash-td-saves  { color: #999; font-weight: 600; white-space: nowrap; }
.dash-td-date   { color: #bbb; font-size: 12px; white-space: nowrap; }
.dash-action-btn {
    border: 1.5px solid #e0e0e0;
    background: white;
    border-radius: 7px;
    padding: 5px 12px;
    font-size: 11px;
    font-weight: 700;
    cursor: pointer;
    color: #555;
    transition: border-color 0.15s, color 0.15s;
    margin-right: 5px;
    white-space: nowrap;
}
.dash-action-btn:hover { border-color: var(--apc-orange); color: var(--apc-orange); }
.dash-action-btn.dash-btn-danger:hover { border-color: #FF3B30; color: #FF3B30; }
.dash-action-btn.dash-btn-primary { background: var(--apc-orange); border-color: var(--apc-orange); color: white; }
.dash-action-btn.dash-btn-primary:hover { background: #e5850f; border-color: #e5850f; }
.dash-action-btn.dash-btn-warning { border-color: #f59e0b; color: #f59e0b; }
.dash-action-btn.dash-btn-warning:hover { background: #f59e0b; color: white; border-color: #f59e0b; }
.dash-empty-state {
    text-align: center;
    padding: 40px 20px;
    color: #ccc;
    font-weight: 700;
    font-size: 14px;
}
.dash-offered-price { font-size: 20px; font-weight: 900; color: var(--apc-orange); display: block; }
.dash-listed-price  { font-size: 13px; font-weight: 600; color: #aaa; display: block; margin-top: 4px; }
.dash-offer-note    { font-size: 12px; color: #888; font-style: italic; margin-top: 4px; }
.dash-counter-row   { display: flex; gap: 8px; align-items: center; margin-top: 8px; }
.dash-counter-input {
    width: 110px; padding: 6px 10px; border: 1.5px solid var(--apc-orange);
    border-radius: 7px; font-size: 13px; font-weight: 700; outline: none;
}

/* Sell form — Open to Offers toggle row */
.sell-toggle-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 14px 16px;
    background: #fafafa;
    border-radius: 10px;
    margin-bottom: 12px;
    border: 1.5px solid #eee;
}
.sell-toggle-label { font-size: 14px; font-weight: 700; color: #222; }
.sell-toggle-sub   { font-size: 11px; color: #aaa; margin-top: 3px; }
.sell-switch-wrap  { cursor: pointer; }

/* Make an Offer button — on detail page */
.offer-make-btn {
    width: 100%;
    padding: 14px;
    background: white;
    border: 2px solid var(--apc-orange);
    border-radius: 8px;
    color: var(--apc-orange);
    font-size: 14px;
    font-weight: 800;
    letter-spacing: 0.5px;
    cursor: pointer;
    transition: background 0.15s, color 0.15s;
}
.offer-make-btn:hover { background: var(--apc-orange); color: white; }
@media (hover: none) {
    .offer-make-btn:active { background: var(--apc-orange); color: white; }
}

/* Offer bottom sheet */
.offer-sheet {
    position: fixed;
    bottom: 0;
    left: 0; right: 0;
    background: white;
    border-radius: 20px 20px 0 0;
    z-index: 3300;
    transform: translateY(100%);
    transition: transform 0.32s cubic-bezier(0.4, 0, 0.2, 1);
    padding-bottom: env(safe-area-inset-bottom, 16px);
    box-shadow: 0 -4px 30px rgba(0,0,0,0.15);
}
.offer-sheet.active { transform: translateY(0); }
.offer-sheet-handle {
    width: 40px; height: 4px;
    background: #ddd; border-radius: 999px;
    margin: 12px auto 0;
}
.offer-sheet-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 16px 20px 8px;
}
.offer-sheet-title  { font-size: 17px; font-weight: 900; }
.offer-sheet-close  {
    background: none; border: none; font-size: 28px;
    color: #aaa; cursor: pointer; line-height: 1; padding: 0;
}
.offer-sheet-part-info {
    padding: 10px 20px 14px;
    background: #fff9f2;
    margin: 0 16px 4px;
    border-radius: 10px;
    font-size: 13px;
}
.offer-sheet-part-title { font-weight: 700; color: #222; margin-bottom: 3px; }
.offer-sheet-listed-price { font-size: 12px; color: #888; }
.offer-sheet-listed-price strong { color: var(--apc-orange); }
.offer-sheet-body { padding: 10px 20px 20px; }

@media (min-width: 900px) {
    .offer-sheet {
        left: 50%; right: auto;
        width: 520px;
        transform: translateX(-50%) translateY(100%);
        border-radius: 20px 20px 0 0;
    }
    .offer-sheet.active { transform: translateX(-50%) translateY(0); }
}

/* Sell form — no spinners on number inputs where arrows are useless */
#sellQuantity { width: 25%; }
#sellQuantity, #sellPrice, #sellPostcode, #sellYear { -moz-appearance: textfield; }
#sellQuantity::-webkit-outer-spin-button,
#sellQuantity::-webkit-inner-spin-button,
#sellPrice::-webkit-outer-spin-button,
#sellPrice::-webkit-inner-spin-button,
#sellPostcode::-webkit-outer-spin-button,
#sellPostcode::-webkit-inner-spin-button,
#sellYear::-webkit-outer-spin-button,
#sellYear::-webkit-inner-spin-button {
    -webkit-appearance: none;
    margin: 0;
}

/* ===== SELL FORM — WAREHOUSE BIN SECTION ===== */
.sell-warehouse-hdr {
    font-size: 10px;
    font-weight: 900;
    text-transform: uppercase;
    color: var(--apc-orange);
    letter-spacing: 0.5px;
    margin: 18px 0 10px;
}

/* ===== WELCOME MODAL ===== */
#welcomeModal { flex-direction: column; }

.welcome-tile {
    background: #f9f8f6;
    border: 1.5px solid #edeae6;
    border-radius: 14px;
    padding: 14px 14px 12px;
    display: flex;
    flex-direction: column;
    gap: 5px;
    transition: border-color 0.15s, box-shadow 0.15s;
}
.welcome-tile:hover {
    border-color: rgba(200,130,60,0.35);
    box-shadow: 0 2px 10px rgba(200,130,60,0.08);
}
.welcome-tile-pro {
    border-color: rgba(200,130,60,0.3);
    background: linear-gradient(135deg, #fdf9f4 0%, #faf5ec 100%);
}
.welcome-tile-icon { font-size: 26px; line-height: 1; margin-bottom: 2px; }
.welcome-tile-title { font-size: 13px; font-weight: 900; color: #1a1a1a; letter-spacing: -0.1px; }
.welcome-tile-title-pro { color: #b8721a; }
.welcome-tile-desc { font-size: 12px; color: #777; line-height: 1.5; }

.welcome-cta-btn {
    width: 100%;
    padding: 15px;
    background: var(--apc-orange);
    color: white;
    border: none;
    border-radius: 14px;
    font-weight: 900;
    font-size: 15px;
    letter-spacing: 0.3px;
    cursor: pointer;
    box-shadow: 0 4px 16px rgba(247,148,29,0.3);
    transition: opacity 0.15s;
}
.welcome-cta-btn:hover { opacity: 0.88; }

/* ===== UPGRADE TO PRO MODAL ===== */
.upgrade-plan-card {
    border: 2px solid #e8e8e8;
    border-radius: 12px;
    padding: 14px 12px 12px;
    cursor: pointer;
    transition: border-color 0.15s, box-shadow 0.15s;
    text-align: center;
}
.upgrade-plan-card:hover { border-color: var(--apc-orange); }
.upgrade-plan-active {
    border-color: var(--apc-orange) !important;
    box-shadow: 0 0 0 3px rgba(247,148,29,0.15);
}

/* ===== QR LABEL MODAL ===== */
.label-modal {
    position: fixed;
    inset: 0;
    z-index: 4000;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
}
.label-modal-inner {
    background: white;
    border-radius: 16px;
    width: 100%;
    max-width: 360px;
    padding: 24px 20px 20px;
    box-shadow: 0 8px 40px rgba(0,0,0,0.3);
}
.label-modal-hdr {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 16px;
}
.label-modal-title { font-size: 17px; font-weight: 900; }
.label-modal-close {
    background: none; border: none; font-size: 28px;
    color: #aaa; cursor: pointer; line-height: 1; padding: 0;
}
.label-print-area {
    border: 2px dashed #ddd;
    border-radius: 12px;
    padding: 20px 16px;
    text-align: center;
    background: white;
}
.label-brand-line { margin-bottom: 10px; }
.label-logo { height: 26px; object-fit: contain; }
.label-qr { display: flex; justify-content: center; margin: 8px 0; }
.label-qr img, .label-qr canvas { border-radius: 6px; }
.label-part-name {
    font-size: 12px; font-weight: 700; color: #222;
    margin-top: 10px; line-height: 1.3; max-width: 220px;
    margin-left: auto; margin-right: auto;
}
.label-bin-ref {
    font-size: 20px; font-weight: 900;
    color: var(--apc-orange); margin: 6px 0 4px;
    letter-spacing: 1px;
}
.label-price { font-size: 13px; color: #666; font-weight: 600; }
.label-apc-id { font-size: 10px; color: #aaa; font-weight: 500; letter-spacing: 0.5px; margin-top: 6px; }

/* ── INBOX MESSAGE CENTRE ─────────────────────── */
#inboxDrawer .drawer-content.inbox-drawer-content {
    padding: 0; overflow: hidden; display: flex; flex-direction: column;
}
.inbox-tab-bar { display: flex; border-bottom: 1px solid #f0f0f0; background: white; flex-shrink: 0; }
.itab {
    flex: 1; padding: 12px 16px; background: none; border: none; border-bottom: 2px solid transparent;
    font-size: 13px; font-weight: 700; color: #888; cursor: pointer; font-family: inherit;
    display: flex; align-items: center; justify-content: center; gap: 6px;
}
.itab.active { color: var(--apc-orange); border-bottom-color: var(--apc-orange); }
.itab-badge { background: var(--apc-orange); color: white; font-size: 10px; font-weight: 800; border-radius: 10px; padding: 1px 6px; }

.inbox-two-panel { display: flex; flex: 1; overflow: hidden; }

/* ── Trash panel ── */
.inbox-trash-empty { display: flex; flex-direction: column; align-items: center; justify-content: center; padding: 60px 20px; color: #aaa; font-size: 14px; font-weight: 600; }
.inbox-trash-toolbar { display: flex; align-items: center; justify-content: space-between; padding: 12px 16px; border-bottom: 1px solid #f0f0f0; }
.inbox-trash-empty-btn { background: none; border: 1.5px solid #e03b3b; color: #e03b3b; font-size: 12px; font-weight: 700; border-radius: 8px; padding: 5px 12px; cursor: pointer; font-family: inherit; }
.inbox-trash-empty-btn:hover { background: #ffeaea; }
.inbox-trash-item { display: flex; align-items: center; gap: 12px; padding: 14px 16px; border-bottom: 1px solid #f5f5f5; }
.inbox-trash-item-info { flex: 1; min-width: 0; }
.inbox-trash-name { font-size: 14px; font-weight: 700; color: #222; }
.inbox-trash-part { font-size: 12px; color: #888; margin-top: 2px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.inbox-trash-meta { font-size: 11px; color: #bbb; margin-top: 3px; }
.inbox-trash-actions { display: flex; flex-direction: row; gap: 8px; flex-shrink: 0; align-items: center; }
.inbox-trash-restore-btn { background: var(--apc-blue); color: white; border: none; border-radius: 999px; padding: 7px 14px; font-size: 12px; font-weight: 700; cursor: pointer; font-family: inherit; white-space: nowrap; }
.inbox-trash-del-btn { background: none; border: 1.5px solid #e03b3b; color: #e03b3b; border-radius: 999px; padding: 6px 14px; font-size: 12px; font-weight: 700; cursor: pointer; font-family: inherit; white-space: nowrap; }
.inbox-trash-del-btn:hover { background: #ffeaea; }

.inbox-conv-col {
    width: 270px; flex-shrink: 0; border-right: 1px solid #eee;
    display: flex; flex-direction: column; background: white;
}
.inbox-conv-search { padding: 10px 12px; border-bottom: 1px solid #f0f0f0; flex-shrink: 0; }
.inbox-conv-search input {
    width: 100%; box-sizing: border-box; padding: 7px 12px; border: 1px solid #e4e4e4; border-radius: 10px;
    font-size: 13px; background: #f7f7f7; outline: none; font-family: inherit;
}
.inbox-conv-search input:focus { border-color: var(--apc-orange); background: white; }
.inbox-conv-list { flex: 1; overflow-y: auto; }

.inbox-conv-item {
    position: relative;
    padding: 13px 52px 13px 14px; cursor: pointer; border-bottom: 1px solid #f5f5f5;
    transition: background 0.12s; border-left: 3px solid transparent;
}
.inbox-conv-item:hover { background: #fafafa; }
.inbox-conv-item.active { background: #fff8f0; border-left-color: var(--apc-orange); }
.inbox-conv-item.flagged { background: #fff8f8; border-left-color: #FF3B30; }
.inbox-conv-item.flagged:hover { background: #fff0f0; }
.inbox-conv-item.unread .inbox-conv-preview { font-weight: 700; color: #333; }
.inbox-conv-item.unread .inbox-conv-name { font-weight: 900; }
.inbox-conv-del-btn {
    position: absolute; top: 50%; right: 14px; transform: translateY(-50%);
    background: none; border: none; color: #ccc; font-size: 22px;
    cursor: pointer; padding: 6px; line-height: 1;
    transition: color 0.12s;
}
.inbox-conv-del-btn:hover { color: #FF3B30; }
.inbox-conv-name-row { display: flex; align-items: center; gap: 6px; }
.inbox-conv-name { font-size: 15px; font-weight: 700; color: #222; }
.inbox-conv-flag-btn {
    background: none; border: none; padding: 4px; cursor: pointer;
    font-size: 16px; color: #ccc; line-height: 1; flex-shrink: 0;
    transition: color 0.12s;
}
.inbox-conv-flag-btn:hover { color: #bbb; }
.inbox-conv-flag-btn.flagged { color: #FF3B30; }
.inbox-conv-flag-btn.flagged:hover { color: #FF3B30; }
.inbox-conv-time { font-size: 12px; color: #bbb; flex-shrink: 0; margin-left: auto; padding-right: 4px; }
.inbox-unread-dot { width: 9px; height: 9px; border-radius: 50%; background: var(--apc-orange); flex-shrink: 0; }
.inbox-conv-part { font-size: 13px; color: var(--apc-orange); font-weight: 700; margin-top: 2px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.inbox-conv-preview { font-size: 13px; color: #999; margin-top: 3px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }

.inbox-thread-col { flex: 1; display: flex; flex-direction: column; background: #f9f9f9; min-width: 0; overflow: hidden; position: relative; }

/* ── ITEM PREVIEW PANEL ──────────────────────── */
.inbox-item-preview {
    position: absolute; inset: 0; z-index: 20;
    background: white;
    display: flex; flex-direction: column;
    transform: translateX(100%);
    transition: transform 0.28s ease;
    overflow: hidden;
}
.inbox-item-preview.open { transform: translateX(0); }

.iip-header {
    display: flex; align-items: center; justify-content: space-between;
    padding: 12px 16px; border-bottom: 1px solid #eee;
    background: white; flex-shrink: 0;
}
.iip-header-label { font-size: 14px; font-weight: 900; color: #333; }
.iip-back-btn {
    background: none; border: none; cursor: pointer;
    color: var(--apc-blue); font-size: 13px; font-weight: 700;
    font-family: inherit; padding: 0; white-space: nowrap;
}

.iip-body { flex: 1; overflow-y: auto; padding: 16px; display: flex; flex-direction: column; gap: 16px; }

.iip-photos { display: flex; flex-direction: column; gap: 8px; }
.iip-main-photo { width: 100%; aspect-ratio: 4/3; object-fit: cover; border-radius: 12px; background: #f0f0f0; cursor: zoom-in; }
.iip-thumbs { display: flex; gap: 6px; }
.iip-thumb { width: 52px; height: 52px; border-radius: 8px; object-fit: cover; cursor: pointer; border: 2px solid transparent; opacity: 0.7; transition: opacity 0.15s, border-color 0.15s; }
.iip-thumb.active { border-color: var(--apc-orange); opacity: 1; }

.iip-price-row { display: flex; align-items: baseline; gap: 10px; }
.iip-price { font-size: 28px; font-weight: 900; color: var(--apc-blue); }
.iip-condition { font-size: 12px; font-weight: 700; color: #888; background: #f4f4f4; padding: 3px 9px; border-radius: 6px; }

.iip-title { font-size: 16px; font-weight: 800; color: #222; line-height: 1.35; }

.iip-delivery { display: flex; flex-wrap: wrap; gap: 8px; }
.iip-delivery-badge {
    display: flex; align-items: center; gap: 5px;
    font-size: 12px; font-weight: 700; color: #555;
    background: #f5f5f5; border-radius: 8px; padding: 6px 10px;
}

.iip-section-label { font-size: 11px; font-weight: 800; color: #aaa; text-transform: uppercase; letter-spacing: 0.5px; margin-bottom: -8px; }
.iip-fitment { font-size: 13px; color: #444; font-weight: 600; }
.iip-description { font-size: 13px; line-height: 1.6; color: #444; }
.iip-apc-id { font-size: 11px; color: #ccc; font-weight: 600; letter-spacing: 0.3px; padding-top: 4px; border-top: 1px solid #f0f0f0; }
.inbox-thread-empty { flex: 1; display: flex; flex-direction: column; align-items: center; justify-content: center; color: #ccc; font-size: 14px; font-weight: 700; }

.inbox-thread-hdr {
    padding: 11px 14px; border-bottom: 1px solid #eee;
    display: flex; align-items: center; gap: 10px; background: white; flex-shrink: 0;
}
.inbox-thread-thumb { width: 46px; height: 46px; border-radius: 9px; object-fit: cover; border: 1px solid #eee; flex-shrink: 0; }
.inbox-thread-meta { flex: 1; min-width: 0; }
.inbox-thread-with { font-size: 11px; font-weight: 700; color: #888; }
.inbox-thread-title { font-size: 13px; font-weight: 800; color: #222; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.inbox-thread-price { font-size: 15px; font-weight: 900; color: var(--apc-blue); }
.inbox-view-btn { background: var(--apc-blue); color: white; border: none; border-radius: 7px; padding: 6px 12px; font-size: 12px; font-weight: 800; cursor: pointer; flex-shrink: 0; font-family: inherit; }
.inbox-view-btn:hover { background: #0062cc; }
.inbox-pending-btn { background: white; color: #92400e; border: 2px solid #f59e0b; border-radius: 7px; padding: 6px 12px; font-size: 12px; font-weight: 800; cursor: pointer; flex-shrink: 0; font-family: inherit; transition: background 0.15s, color 0.15s; }
.inbox-pending-btn:hover { background: #fef3c7; }
.inbox-pending-btn.inbox-pending-active { background: #f59e0b; color: white; border-color: #f59e0b; }

.inbox-msg-list { flex: 1; overflow-y: auto; padding: 14px; display: flex; flex-direction: column; gap: 10px; }
.inbox-date-divider { text-align: center; font-size: 11px; font-weight: 700; color: #c0c0c0; margin: 4px 0 2px; }
.inbox-msg-row { display: flex; align-items: flex-end; gap: 6px; }
.inbox-msg-row.sent { flex-direction: row-reverse; }
.inbox-msg-avatar { width: 24px; height: 24px; border-radius: 50%; background: #ddd; color: #888; font-size: 10px; font-weight: 900; display: flex; align-items: center; justify-content: center; flex-shrink: 0; }
.inbox-msg-row.sent .inbox-msg-avatar { background: var(--apc-orange); color: white; }
.inbox-msg-col { display: flex; flex-direction: column; max-width: 68%; }
.inbox-msg-row.sent .inbox-msg-col { align-items: flex-end; }
.inbox-msg-bubble { padding: 9px 12px; border-radius: 16px; font-size: 14px; line-height: 1.45; word-break: break-word; }
.inbox-msg-row.received .inbox-msg-bubble { background: white; color: #222; border: 1px solid #eee; border-bottom-left-radius: 4px; }
.inbox-msg-row.sent .inbox-msg-bubble { background: var(--apc-orange); color: white; border-bottom-right-radius: 4px; }
.inbox-msg-bubble img { max-width: 180px; max-height: 180px; border-radius: 9px; display: block; }
.inbox-msg-time { font-size: 10px; color: #bbb; margin-top: 0; max-height: 0; overflow: hidden; opacity: 0; transition: max-height 0.2s ease, opacity 0.2s ease, margin-top 0.2s ease; }
#inboxMsgList.times-visible .inbox-msg-time { max-height: 20px; opacity: 1; margin-top: 3px; }
.inbox-msg-del { opacity: 0; background: none; border: none; font-size: 16px; color: #ccc; cursor: pointer; padding: 0 2px; align-self: center; transition: opacity 0.15s, color 0.15s; flex-shrink: 0; }
.inbox-msg-del:hover { color: #FF3B30; }
.inbox-msg-row:hover .inbox-msg-del { opacity: 1; }
.inbox-msg-row.del-visible .inbox-msg-del { opacity: 1; }

.inbox-reply-bar { padding: 10px 12px; border-top: 1px solid #eee; display: flex; align-items: flex-end; gap: 8px; background: white; flex-shrink: 0; }

/* OFFER CARD — inside inbox thread */
.inbox-msg-col.offer-col { max-width: 96%; width: 320px; }
.offer-bubble {
    padding: 0 !important;
    background: white !important;
    color: #222 !important;
    border: 1.5px solid #e0e0e0 !important;
    border-radius: 14px !important;
    overflow: hidden;
}
.offer-card { font-size: 13px; }
.offer-card-header {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 11px 12px 9px;
    border-bottom: 1px solid #f0f0f0;
    background: #fafafa;
}
.offer-card-img {
    width: 44px; height: 44px;
    border-radius: 7px;
    object-fit: cover;
    flex-shrink: 0;
    border: 1px solid #eee;
}
.offer-card-part-title {
    font-weight: 800;
    font-size: 12px;
    color: #222;
    line-height: 1.3;
}
.offer-card-listed { font-size: 11px; color: #aaa; margin-top: 2px; }
.offer-card-body { padding: 10px 12px; }
.offer-card-amount {
    font-size: 22px;
    font-weight: 900;
    color: var(--apc-blue);
    line-height: 1;
}
.offer-card-amount span {
    font-size: 11px;
    font-weight: 700;
    color: #aaa;
    margin-left: 4px;
    vertical-align: middle;
}
.offer-card-note {
    font-size: 12px;
    color: #666;
    font-style: italic;
    margin-top: 6px;
}
.offer-card-actions {
    display: flex;
    gap: 6px;
    margin-top: 10px;
}
.offer-action-btn {
    flex: 1;
    padding: 8px 4px;
    border: none;
    border-radius: 8px;
    font-weight: 900;
    font-size: 10px;
    cursor: pointer;
    letter-spacing: 0.3px;
    color: #fff;
}
.offer-accept  { background: #28a745; }
.offer-decline { background: #888; }
.offer-counter { background: var(--apc-orange); }
.offer-card-status {
    margin-top: 10px;
    padding: 6px 10px;
    border-radius: 7px;
    font-size: 11px;
    font-weight: 800;
    text-align: center;
}
.offer-card-status.accepted  { background: #e6f4ea; color: #155c24; }
.offer-card-status.declined  { background: #f5f5f5; color: #888; }
.offer-card-status.countered { background: #fff3cd; color: #b86e00; }
.offer-card-awaiting {
    margin-top: 8px;
    font-size: 11px;
    color: #aaa;
    font-style: italic;
}
.offer-counter-form {
    display: flex;
    gap: 6px;
    margin-top: 8px;
    align-items: center;
}
.offer-counter-input {
    flex: 1;
    padding: 7px 10px;
    border: 1.5px solid #ddd;
    border-radius: 8px;
    font-size: 13px;
    font-weight: 700;
}
.inbox-photo-btn { width: 36px; height: 36px; border-radius: 50%; background: #f0f0f0; border: none; cursor: pointer; display: flex; align-items: center; justify-content: center; flex-shrink: 0; color: #888; }
.inbox-photo-btn:hover { background: #e4e4e4; }
.inbox-reply-input { flex: 1; border: 1.5px solid #e4e4e4; border-radius: 18px; padding: 8px 14px; font-size: 14px; resize: none; outline: none; font-family: inherit; min-height: 36px; max-height: 100px; overflow-y: auto; line-height: 1.4; background: #f8f8f8; }
.inbox-reply-input:focus { border-color: var(--apc-orange); background: white; }
.inbox-send-btn { width: 36px; height: 36px; border-radius: 50%; background: var(--apc-blue); border: none; cursor: pointer; display: flex; align-items: center; justify-content: center; flex-shrink: 0; }

@media (max-width: 899px) {
    .inbox-conv-col { width: 100%; position: absolute; inset: 0; transition: transform 0.28s ease; z-index: 1; }
    .inbox-conv-col.slide-away { transform: translateX(-100%); }
    .inbox-thread-col { position: absolute; inset: 0; transform: translateX(100%); transition: transform 0.28s ease; z-index: 2; }
    .inbox-thread-col.slide-in { transform: translateX(0); }
    .inbox-two-panel { position: relative; overflow: hidden; }
}

/* Dashboard — label button */
.dash-btn-label { background: #fff3e0; color: var(--apc-orange); border-color: var(--apc-orange); }
.dash-btn-label:hover { background: var(--apc-orange); color: white; }

/* Sell label print area — hidden on screen */
#sellLabelPrintArea { display: none; }
#sellLabelPrintArea .sell-label { border: 2px solid #222; border-radius: 6px; padding: 10px 12px; font-family: Arial, sans-serif; }
#sellLabelPrintArea .sell-header { display: flex; align-items: center; justify-content: space-between; border-bottom: 2px solid #222; padding-bottom: 8px; margin-bottom: 8px; }
#sellLabelPrintArea .sell-brand { font-size: 18px; font-weight: 900; color: #f7941d; letter-spacing: -0.5px; }
#sellLabelPrintArea .sell-date { font-size: 10px; color: #aaa; text-align: right; }
#sellLabelPrintArea .sell-body { display: flex; gap: 12px; align-items: flex-start; }
#sellLabelPrintArea .sell-left { flex: 1; min-width: 0; }
#sellLabelPrintArea .sell-right { flex-shrink: 0; display: flex; flex-direction: column; align-items: center; gap: 4px; }
#sellLabelPrintArea .sell-title { font-size: 13px; font-weight: 800; margin-bottom: 7px; line-height: 1.3; }
#sellLabelPrintArea table { width: 100%; border-collapse: collapse; font-size: 11px; }
#sellLabelPrintArea td { padding: 2px 6px 2px 0; vertical-align: top; }
#sellLabelPrintArea td:first-child { color: #555; width: 65px; white-space: nowrap; }
#sellLabelPrintArea .sell-price-row { margin-top: 7px; border-top: 2px solid #222; padding-top: 7px; display: flex; align-items: baseline; gap: 6px; }
#sellLabelPrintArea .sell-price { font-size: 20px; font-weight: 900; }
#sellLabelPrintArea .sell-price-label { font-size: 11px; color: #555; }
#sellLabelPrintArea .sell-qr-id { font-size: 9px; color: #555; text-align: center; margin-top: 2px; word-break: break-all; max-width: 90px; }

/* Print — QR label modal (default) */
@media print {
    body:not(.printing-sell-label) * { visibility: hidden; }
    body:not(.printing-sell-label) #labelPrintArea,
    body:not(.printing-sell-label) #labelPrintArea * { visibility: visible; }
    body:not(.printing-sell-label) #labelPrintArea {
        position: fixed;
        top: 50%; left: 50%;
        transform: translate(-50%, -50%);
        border: 1px solid #ccc;
        border-radius: 8px;
        padding: 30px;
    }
    body:not(.printing-sell-label) .label-bin-ref { font-size: 26px; }

    /* Print — sell label (A6 landscape, one copy) */
    body.printing-sell-label > * { display: none !important; }
    body.printing-sell-label #sellLabelPrintArea { display: block !important; }
    @page { size: A6 landscape; margin: 8mm; }
}

/* HELP & SUPPORT DRAWER */
.help-drawer-content {
    padding: 20px 16px 40px;
    background: #f4f4f4;
}
.help-section-title {
    font-size: 11px;
    font-weight: 800;
    color: #999;
    text-transform: uppercase;
    letter-spacing: 0.6px;
    margin-bottom: 10px;
}
.help-faq-list {
    background: #fff;
    border-radius: 14px;
    overflow: hidden;
    box-shadow: 0 1px 4px rgba(0,0,0,0.07);
}
.help-faq-item { border-bottom: 1px solid #f0f0f0; }
.help-faq-item:last-child { border-bottom: none; }
.help-faq-q {
    width: 100%;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    background: none;
    border: none;
    padding: 14px 16px;
    font-size: 14px;
    font-weight: 600;
    color: #1a1a1a;
    text-align: left;
    cursor: pointer;
}
.help-faq-chevron {
    flex-shrink: 0;
    font-size: 18px;
    color: #bbb;
    transition: transform 0.2s;
    display: inline-block;
}
.help-faq-q.open .help-faq-chevron { transform: rotate(90deg); }
.help-faq-a {
    display: none;
    padding: 0 16px 14px;
    font-size: 13px;
    color: #555;
    line-height: 1.55;
}
.help-faq-a.open { display: block; }
.help-contact-form {
    background: #fff;
    border-radius: 14px;
    padding: 16px;
    box-shadow: 0 1px 4px rgba(0,0,0,0.07);
}
.help-contact-form textarea {
    width: 100%;
    border: 1px solid #e0e0e0;
    border-radius: 10px;
    padding: 10px 12px;
    font-size: 14px;
    font-family: inherit;
    resize: none;
    box-sizing: border-box;
    outline: none;
    color: #1a1a1a;
}
.help-contact-form textarea:focus { border-color: var(--apc-orange); }
