/* Stile ramo terminalino Opticon H-35 (mobile, dita, alto contrasto) */
.term-shell {
    max-width: 480px;
    margin: 0 auto;
    padding: 1rem;
    font-family: "Segoe UI", Roboto, sans-serif;
}

.term-title {
    font-size: 1.2rem;
    text-align: center;
    margin: .5rem 0 1rem;
}

.term-scan label,
.term-card label {
    display: block;
    font-size: .85rem;
    font-weight: 600;
    margin: .6rem 0 .25rem;
    color: #333;
}

.term-input {
    width: 100%;
    box-sizing: border-box;
    padding: .7rem;
    font-size: 1.1rem;
    border: 2px solid #b7becb;
    border-radius: 6px;
}

/* Riga campo scansione + pulsante Cerca affiancati */
.term-scan-row {
    display: flex;
    gap: .5rem;
    align-items: stretch;
}
.term-scan-row .term-input { flex: 1 1 auto; }
.term-btn-cerca {
    width: auto;
    margin-top: 0;
    padding: .7rem 1.1rem;
    white-space: nowrap;
}

.term-card {
    margin-top: 1rem;
    padding: 1rem;
    border: 1px solid #dfe3ec;
    border-radius: 8px;
    background: #fafbfd;
}

.term-id {
    font-size: 1.1rem;
    font-weight: 700;
    color: #2b3a55;
    margin-bottom: .5rem;
}

/* Campi in sola lettura (Colore/Titolo/Giacenza) come etichette compatte */
.term-field {
    display: flex;
    justify-content: space-between;
    align-items: baseline;
    gap: .75rem;
    padding: .35rem 0;
    border-bottom: 1px solid #edf0f5;
}
.term-lbl {
    font-size: .8rem;
    font-weight: 600;
    color: #6b7280;
    flex: 0 0 auto;
}
.term-val {
    font-size: 1.05rem;
    color: #1f2430;
    text-align: right;
    word-break: break-word;
}
.term-giacenza {
    font-weight: 700;
    color: #2b3a55;
    white-space: nowrap;
}

/* Riga tasti variazione: Sottrai (-) e Aggiungi (+) affiancati */
.term-var-row {
    display: flex;
    gap: .5rem;
}
.term-var-row .term-btn { flex: 1 1 0; margin-top: .4rem; }
.term-btn-sub { background: #a1122a; color: #fff; }
.term-btn-add { background: #2b6a3f; color: #fff; }

.term-btn {
    width: 100%;
    margin-top: .6rem;
    padding: .8rem;
    font-size: 1.05rem;
    border: 0;
    border-radius: 6px;
    background: #e2e6ee;
    color: #1f2430;
    cursor: pointer;
}
.term-btn-primary { background: #2b6a3f; color: #fff; }
.term-btn-ghost { background: transparent; color: #2b3a55; text-decoration: underline; }
.term-btn:disabled { opacity: .6; }

.term-msg {
    margin: .75rem 0;
    padding: .6rem .8rem;
    border-radius: 6px;
    font-weight: 600;
}
.term-msg-ok { background: #e4f4e8; color: #1d6b34; }
.term-msg-err { background: #fbe4e6; color: #a1122a; }
