/* ============================================================
   UNIT SELECTOR + COMPARISON UPDATES
   Append to bottom of scanner.css
   ============================================================ */

/* ── Unit selector ───────────────────────────────── */
.unit-selector-wrap {
    display: flex;
    align-items: center;
    gap: 0.7rem;
    padding: 0.7rem 0 0.9rem;
    border-bottom: 1px solid rgba(255,255,255,0.05);
    margin-bottom: 0.9rem;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
}

.unit-selector-wrap::-webkit-scrollbar { display: none; }

.unit-selector-label {
    font-size: 0.78rem;
    color: var(--text-dim);
    white-space: nowrap;
    letter-spacing: 0.06em;
    flex-shrink: 0;
}

.unit-selector-pills {
    display: flex;
    gap: 0.5rem;
    flex-shrink: 0;
}

.unit-pill {
    display: flex;
    flex-direction: column;
    align-items: center;
    background: var(--dark-card);
    border: 1px solid rgba(255,255,255,0.08);
    border-radius: 100px;
    padding: 0.3rem 0.9rem;
    cursor: pointer;
    transition: all 0.18s;
    white-space: nowrap;
    gap: 0;
}

.unit-pill:hover {
    border-color: rgba(201,122,58,0.35);
}

.unit-pill-active {
    background: rgba(155,79,26,0.2);
    border-color: var(--amber);
    color: var(--amber);
}

.unit-pill-name {
    font-size: 0.6rem;
    color: var(--text-dim);
    letter-spacing: 0.04em;
    margin-top: 0.05rem;
}

.unit-pill-active .unit-pill-name {
    color: rgba(201,122,58,0.7);
}

/* ── Unit cost display updates ───────────────────── */
.product-unit-cost {
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    gap: 0.1rem;
}

.product-unit-cost-best {
    color: var(--amber);
}

.unit-cost-label {
    font-size: 0.7rem;
    color: var(--text-dim);
    letter-spacing: 0.04em;
}

.product-unit-cost-best .unit-cost-label {
    color: rgba(201,122,58,0.6);
}

.product-unit-cost-na {
    font-size: 0.78rem;
    color: var(--text-dim);
    font-style: italic;
}

/* ── Compare summary updates ─────────────────────── */
.compare-summary-savings {
    font-size: 0.8rem;
    color: #6BAF7A;
    margin-top: 0.4rem;
}

/* ── Zoom prevention on keypad keys ─────────────── */
.keypad-key,
.keypad-done,
.keypad-cancel {
    touch-action: manipulation;
}
