/* ══════════════════════════════════════════════════════════════════
   NP3 · MÜÜK + ARTIKLID — visuaali 3. etapp (14.11.2026, rühm 3)
   Müügitellimuste (.so-*) kujunduskeel viiakse teistele müügivaadetele
   ja Artiklid → Tooted saab pildiga kataloogi. Ainult välimus:
   id-d, onclick'id ja andmed on samad. Tokenid: niidupaber.css (--np-*).
   Kõik selektorid skoobitud #sales / #products sektsiooniga.
   Telefon (≤768 px): Saatelehtede/Hinnakirjade kaardikuju tuleb endiselt
   mobile-myyk.css-ist (sama DOM-järjekord); Toodete kaart tuleb siit.
   ══════════════════════════════════════════════════════════════════ */

/* ── 1. Müügitellimuste kuupäevaväljad „Alates / Kuni" kiibina ───── */
#salesOrders .so-kp {
    min-height: 36px; padding: 0 0.3rem 0 0.8rem; gap: 0.35rem;
    border: 1px solid var(--s-joon2); border-radius: 999px; background: var(--s-kaart);
    font: 500 0.82rem var(--font-body, system-ui, sans-serif); color: var(--s-hall); white-space: nowrap;
}
#salesOrders .so-kp:focus-within { border-color: var(--s-pruun); box-shadow: 0 0 0 3px rgba(176,138,79,0.18); }
#salesOrders .so-kp input.date-input,
#salesOrders .so-kp input#orderDateFrom,
#salesOrders .so-kp input#orderDateTo {
    width: 6.4em; min-width: 0; min-height: 0; margin: 0; padding: 0.3rem 0;
    border: none !important; border-radius: 0; background: transparent !important; box-shadow: none !important; outline: none !important;
    font: 500 0.85rem var(--font-body, system-ui, sans-serif); color: var(--s-tint); font-variant-numeric: tabular-nums;
}
#salesOrders .so-kp input::placeholder { color: var(--s-hall); opacity: 0.75; font-weight: 400; }
#salesOrders .so-kp .date-cal-icon { width: 1.75rem; height: 1.75rem; margin: 0; border-radius: 50%; opacity: 0.55; filter: grayscale(1); }
#salesOrders .so-kp .date-cal-icon:hover { opacity: 0.9; background: var(--s-valik); filter: none; }

/* ── 2. Ühine vaatepäis + filtririda (Saatelehed, Tagastused, Hinnakirjad) ── */
#sales .np3-pais { display: flex; align-items: flex-end; justify-content: space-between; gap: 1rem; flex-wrap: wrap; margin-bottom: 0.9rem; }
#sales .np3-pealkiri { margin: 0; font-family: var(--font-display, Georgia, serif); font-weight: 600; font-size: 1.8rem; line-height: 1.15; color: var(--np-action, #765620); }
#sales .np3-alam { margin: 0.15rem 0 0; color: var(--np-ink-3, #746759); font-size: 0.88rem; }
#sales .np3-pais .btn-primary { min-height: 40px; padding: 0.45rem 1.05rem; border-radius: 10px; font-weight: 600; }

#sales .np3-filtrid { gap: 0.5rem !important; }
#sales .np3-filtrid .np3-otsing {
    flex: 1 1 260px; min-width: 220px; max-width: 420px; min-height: 38px;
    padding: 0.4rem 0.8rem 0.4rem 2.2rem; border: 1px solid var(--np-line-strong, #9c8872); border-radius: 10px;
    background: var(--np-surface, #fff) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%235c4033' stroke-width='2' stroke-linecap='round'%3E%3Ccircle cx='10.5' cy='10.5' r='6.5'/%3E%3Cpath d='M15.5 15.5 21 21'/%3E%3C/svg%3E") no-repeat 0.7rem 50% / 17px 17px;
    font-size: 0.9rem;
}
#sales .np3-filtrid .np3-valik { min-height: 36px; padding: 0.3rem 0.6rem; border: 1px solid var(--np-line-strong, #9c8872); border-radius: 8px; background-color: var(--np-surface, #fff); font-size: 0.85rem; }
#sales .np3-filtrid .np3-kp {
    min-height: 36px; padding: 0 0.3rem 0 0.8rem; border: 1px solid var(--np-line-strong, #9c8872); border-radius: 999px;
    background: var(--np-surface, #fff); color: var(--np-ink-3, #746759); font-size: 0.82rem; white-space: nowrap;
}
#sales .np3-filtrid .np3-kp:focus-within { border-color: var(--np-action, #765620); box-shadow: 0 0 0 3px rgba(176,138,79,0.18); }
#sales .np3-filtrid .np3-kp input {
    width: 6.4em; min-width: 0; min-height: 0; margin: 0; padding: 0.3rem 0;
    border: none !important; background: transparent !important; box-shadow: none !important; outline: none !important;
    font-size: 0.85rem; color: var(--np-ink, #2a2420); font-variant-numeric: tabular-nums;
}
#sales .np3-filtrid .np3-kp .date-cal-icon { width: 1.75rem; height: 1.75rem; margin: 0; border-radius: 50%; opacity: 0.55; filter: grayscale(1); }
#sales .np3-filtrid .np3-kp .date-cal-icon:hover { opacity: 0.9; filter: none; }

/* Väike ikoon-nupp (PDF, printer, kustuta, kopeeri) — vaikne, ei konkureeri põhitegevusega */
#sales .np3-ikoon { min-width: 30px; padding-left: 0.4rem !important; padding-right: 0.4rem !important; line-height: 1; }
#sales .np3-disp .btn-danger.np3-ikoon { color: var(--np-danger, #a33025); }

/* ── 3. Saatelehed / Tagastused / Hinnakirjad: tellimuste tabeli keel ── */
/* Alus kõigis laiustes (= endised inline-stiilid; telefonikaart ehitab sellele mobile-myyk.css) */
#sales .np3-disp { border: 1px solid var(--np-line, #e6dccf); border-radius: 10px; margin-bottom: 0.4rem; background: var(--np-surface, #fff); overflow: hidden; }
#sales .np3-disp-rida { display: flex; align-items: center; gap: 0.6rem; padding: 0.55rem 0.8rem; cursor: pointer; user-select: none; }
#sales .np3-disp-rida > .np3-nool { width: 1em; font-size: 0.8rem; color: var(--np-ink-3, #746759); }
#sales .np3-disp-rida > .np3-nr { min-width: 110px; font-weight: 600; color: var(--np-action, #765620); font-variant-numeric: tabular-nums; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
#sales .np3-disp-rida > .np3-tell { font-size: 0.82rem; color: var(--np-ink-2, #5e534a); font-variant-numeric: tabular-nums; white-space: nowrap; }
#sales .np3-disp-rida > .np3-klient { flex: 1; min-width: 0; font-size: 0.88rem; font-weight: 500; color: var(--np-ink, #2a2420); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
#sales .np3-disp-rida > .np3-kp,
#sales .np3-disp-rida > .np3-valuuta { font-size: 0.82rem; color: var(--np-ink-2, #5e534a); white-space: nowrap; font-variant-numeric: tabular-nums; }
#sales .np3-disp-rida > .np3-kogus { min-width: 50px; font-size: 0.82rem; color: var(--np-ink-2, #5e534a); white-space: nowrap; text-align: right; font-variant-numeric: tabular-nums; }
#sales .np3-disp-rida > .np3-kogus strong { color: var(--np-ink, #2a2420); }
#sales .np3-disp-rida > .np3-summa { min-width: 70px; text-align: right; white-space: nowrap; font-family: var(--font-display, Georgia, serif); font-weight: 600; font-variant-numeric: tabular-nums; }
#sales .np3-disp-rida > .np3-tegevused { display: flex; gap: 0.3rem; flex-wrap: nowrap; justify-content: flex-end; }
#sales .np3-disp-rida > .np3-olekud { display: inline-flex; gap: 0.3rem; flex-wrap: wrap; }
#sales .np3-tuhi { color: var(--np-ink-3, #746759); font-weight: 400; }
#sales .np3-puudu { color: var(--np-danger, #a33025); font-weight: 600; }
#sales .np3-mono { font-family: ui-monospace, "IBM Plex Mono", Menlo, monospace; font-size: 0.8rem; color: var(--np-ink-2, #5e534a); }
#sales .np3-disp-rida:hover { background: var(--np-surface-2, #faf6ef); }
#sales .np3-disp.lahti > .np3-disp-rida { background: var(--np-action-soft, #fbf3e6); }

/* Olekupill: üks kuju, värv = tähendus (sama palett mis müügitellimustel) */
#sales .np3-olek {
    display: inline-block; padding: 0.15rem 0.6rem; border-radius: 999px; border: 1px solid #e2d8cd;
    background: #f1ece6; color: #5e534a; font-size: 0.74rem; font-weight: 600; line-height: 1.35; white-space: nowrap;
}
#sales .np3-olek-confirmed, #sales .np3-olek-processed { background: #eef4f8; color: #2a5f8a; border-color: #cfe0ec; }
#sales .np3-olek-sent, #sales .np3-olek-announced, #sales .np3-olek-ootab { background: #fbf0e1; color: #8a5300; border-color: #efd9b5; }
#sales .np3-olek-delivered, #sales .np3-olek-received { background: #eef3e8; color: #3a5230; border-color: #d3e0c5; }
#sales .np3-olek-cancelled { background: #f8e9e7; color: #8f2a20; border-color: #ebc9c4; }
#sales .np3-olek-silt { background: transparent; color: #5e534a; border-color: #d8c7b8; }
/* Hinnakirjal tähendab „kinnitatud" kehtivat → roheline; aegunud → hall */
#salesPriceLists .np3-olek-confirmed { background: #eef3e8; color: #3a5230; border-color: #d3e0c5; }
#salesPriceLists .np3-olek-expired { background: #f1ece6; color: #746759; border-color: #e2d8cd; text-decoration: line-through; text-decoration-thickness: 1px; }

/* Avatud detail */
#sales .np3-disp-detail { border-top: 1px solid var(--np-line, #e6dccf); padding: 0.75rem 0.95rem 0.9rem; background: var(--np-surface-2, #faf6ef); }
#sales .np3-disp-meta { display: flex; gap: 0.4rem 1.2rem; flex-wrap: wrap; margin-bottom: 0.55rem; font-size: 0.82rem; color: var(--np-ink-2, #5e534a); }
#sales .np3-disp-meta strong { color: var(--np-ink, #2a2420); font-weight: 600; }
#sales .np3-disp-markus { margin-top: 0.5rem; font-size: 0.82rem; color: var(--np-ink-2, #5e534a); }
#sales table.np3-read { width: 100%; border-collapse: collapse; font-size: 0.84rem; background: var(--np-surface, #fff); border: 1px solid var(--np-line, #e6dccf); border-radius: 8px; overflow: hidden; }
#sales table.np3-read th { text-align: left; font-size: 0.7rem; letter-spacing: 0.06em; text-transform: uppercase; font-weight: 600; padding: 0.4rem 0.6rem; }
#sales table.np3-read td { padding: 0.4rem 0.6rem; }
#sales table.np3-read .num { text-align: right; font-variant-numeric: tabular-nums; white-space: nowrap; }

/* Mustandite hulgikinnituse riba */
#sales .np3-disp-riba {
    display: flex; justify-content: space-between; align-items: center; flex-wrap: wrap; gap: 0.5rem;
    margin-bottom: 0.7rem; padding: 0.55rem 0.9rem; border: 1px solid #efd9b5; border-radius: 10px;
    background: #fbf0e1; color: #6b4300; font-size: 0.88rem;
}

/* Veerupäis on ainult laias vaates */
#sales .np3-disp-pais { display: none; }

/* Lai ekraan: üks valge tabelikaart, read joonega, veerud joondatud (nagu müügitellimused) */
@media (min-width: 1100px) {
    #sales .np3-disp-tabel { border: 1px solid var(--np-line, #e6dccf); border-radius: 14px; background: var(--np-surface, #fff); overflow: hidden; }
    #sales .np3-disp-tabel > .np3-disp { border: 0; border-bottom: 1px solid var(--np-line, #e6dccf); border-radius: 0; margin: 0; background: transparent; }
    #sales .np3-disp-tabel > .np3-disp:last-child { border-bottom: 0; }
    #sales .np3-disp-pais,
    #sales .np3-disp-tabel .np3-disp-rida {
        display: grid; align-items: center; gap: 0 0.8rem; padding: 0.6rem 1rem;
        grid-template-columns: 1rem 8.5rem 7.5rem 8rem minmax(0, 1fr) 5.5rem 5rem 15rem;   /* saatelehed */
    }
    #sales .np3-disp-pais {
        padding-top: 0.55rem; padding-bottom: 0.55rem; background: var(--np-surface-2, #faf6ef); border-bottom: 1px solid var(--np-line-strong, #9c8872);
        font-size: 0.7rem; letter-spacing: 0.07em; text-transform: uppercase; font-weight: 600; color: var(--np-ink-3, #746759);
    }
    #sales .np3-disp-pais .num { text-align: right; }
    #sales .np3-disp-tabel .np3-disp-rida > * { min-width: 0; }
    #sales .np3-disp-tabel .np3-disp-rida > .np3-olek { justify-self: start; }
    /* tagastused: olekud laiemad (EDI / ootab saabumist), lisaks summa; tellimuse veergu pole */
    #salesReturns .np3-disp-pais,
    #salesReturns .np3-disp-tabel .np3-disp-rida { grid-template-columns: 1rem 8.5rem 12rem minmax(0, 1fr) 5.5rem 5rem 6.5rem 12rem; }
}

/* Hinnakirjad kliendi kaupa (3b): klient = rühmapäis, all tema hinnakirjad.
   Rea DOM on sama (telefonikaart mobile-myyk.css-ist); klient on päises → rea kliendiveerg peidus. */
#priceListsList .np3-pl-grupp { margin-bottom: 1rem; }
#priceListsList .np3-pl-grupp-pais { display: flex; align-items: baseline; justify-content: space-between; gap: 0.4rem 1rem; flex-wrap: wrap; padding: 0 0.2rem 0.4rem; }
#priceListsList .np3-pl-grupp-nimi { margin: 0; font-family: var(--font-display, Georgia, serif); font-size: 1.12rem; font-weight: 600; line-height: 1.3; color: var(--np-ink, #2a2420); overflow-wrap: anywhere; }
#priceListsList .np3-pl-grupp-kokku { font-size: 0.8rem; color: var(--np-ink-3, #746759); font-variant-numeric: tabular-nums; white-space: nowrap; }
#priceListsList .np3-pl-grupp .np3-disp-rida > .np3-klient { display: none; }
#salesPriceLists .np3-pl-loendur { margin-left: auto; font-size: 0.82rem; color: var(--np-ink-3, #746759); font-variant-numeric: tabular-nums; white-space: nowrap; }
#salesPriceLists .np3-pl-tyhi { padding: 1.6rem 0.5rem; text-align: center; color: var(--np-ink-3, #746759); border: 1px dashed var(--np-line, #e6dccf); border-radius: 14px; }

/* Kattuvate kampaaniahindade hoiatus — kokkupandav, vaikimisi kinni */
#salesPriceLists .np3-pl-kattuvus { margin-bottom: 0.8rem; border: 1px solid #ebc9c4; border-left: 4px solid var(--np-danger, #a33025); border-radius: 10px; background: var(--np-danger-soft, #fbeae6); font-size: 0.85rem; color: var(--np-ink, #2a2420); }
#salesPriceLists .np3-pl-kattuvus > summary { cursor: pointer; padding: 0.55rem 0.9rem; list-style-position: inside; }
#salesPriceLists .np3-pl-kattuvus > summary strong { color: var(--np-danger-ink, #8f2a20); }
#salesPriceLists .np3-pl-kattuvus-alam { color: var(--np-ink-2, #5e534a); }
#salesPriceLists .np3-pl-kattuvus > ul { margin: 0; padding: 0.1rem 1rem 0.7rem 2.1rem; }
#salesPriceLists .np3-pl-kattuvus > ul > li { margin: 0.15rem 0; }

/* Lai ekraan: üks valge tabelikaart, klient = õhuke vahepäis, read joondatud veergudega (kampaania-silt võib puududa) */
@media (min-width: 1100px) {
    #priceListsList:has(> .np3-pl-grupp) { border: 1px solid var(--np-line, #e6dccf); border-radius: 14px; background: var(--np-surface, #fff); overflow: hidden; }
    #priceListsList .np3-pl-grupp { margin: 0; border-bottom: 1px solid var(--np-line-strong, #9c8872); }
    #priceListsList .np3-pl-grupp:last-child { border-bottom: 0; }
    #priceListsList .np3-pl-grupp-pais { padding: 0.5rem 1rem 0.45rem; background: var(--np-surface-2, #faf6ef); border-bottom: 1px solid var(--np-line, #e6dccf); }
    #priceListsList .np3-pl-grupp-nimi { font-size: 1.02rem; }
    #priceListsList .np3-pl-grupp > .np3-pl { border: 0; border-bottom: 1px solid var(--np-line, #e6dccf); border-radius: 0; margin: 0; background: transparent; }
    #priceListsList .np3-pl-grupp > .np3-pl:last-child { border-bottom: 0; }
    #priceListsList .np3-pl > .np3-disp-rida {
        display: grid; align-items: center; gap: 0 0.8rem; padding: 0.6rem 1rem;
        grid-template-columns: 1rem minmax(0, 1fr) 6.5rem 6.5rem 9.5rem 5.5rem 2.6rem 11rem;
    }
    #priceListsList .np3-pl > .np3-disp-rida > * { grid-row: 1; min-width: 0; }
    #priceListsList .np3-pl .np3-nool { grid-column: 1; }
    #priceListsList .np3-pl .np3-pl-nimi { grid-column: 2; }
    #priceListsList .np3-pl .np3-disp-rida > .np3-olek:not(.np3-pl-kmp) { grid-column: 3; justify-self: start; }
    #priceListsList .np3-pl .np3-pl-kmp { grid-column: 4; justify-self: start; }
    #priceListsList .np3-pl .np3-kp { grid-column: 5; }
    #priceListsList .np3-pl .np3-kogus { grid-column: 6; }
    #priceListsList .np3-pl .np3-valuuta { grid-column: 7; }
    #priceListsList .np3-pl .np3-tegevused { grid-column: 8; }
}
/* Telefon: rühmapäis kaartide kohal, kaardid ise tulevad mobile-myyk.css-ist */
@media (max-width: 768px) {
    #priceListsList .np3-pl-grupp-pais { padding: 0.3rem 0.2rem 0.5rem; }
    #priceListsList .np3-pl-grupp-kokku { white-space: normal; }
    #salesPriceLists .np3-pl-loendur { margin-left: 0; }
}
#priceListsList .np3-pl-nimi { color: var(--np-ink, #2a2420); font-weight: 600; }
#sales #priceListsList .np3-pl { padding: 0; }
@media (min-width: 1100px) { #priceListsList .np3-pl .np3-pl-nimi { white-space: normal; overflow-wrap: anywhere; line-height: 1.3; } }
#priceListsList .np3-pl .np3-klient { font-weight: 400; color: var(--np-ink-2, #5e534a); }

/* ── 4. Artiklid → Tooted: kataloog pildiga ─────────────────────────── */
#prodProducts .np3-vaatelyliti { display: inline-flex; border: 1px solid var(--np-line-strong, #9c8872); border-radius: 999px; overflow: hidden; background: var(--np-surface, #fff); }
#prodProducts .np3-vaatelyliti button {
    min-height: 34px; padding: 0.25rem 0.85rem; border: 0; background: transparent; cursor: pointer;
    font: 500 0.82rem var(--font-body, system-ui, sans-serif); color: var(--np-ink-2, #5e534a);
}
#prodProducts .np3-vaatelyliti button + button { border-left: 1px solid var(--np-line, #e6dccf); }
#prodProducts .np3-vaatelyliti button.on { background: var(--np-action, #765620); color: #fff; }
#prodProducts .np3-vaatelyliti button:focus-visible { outline: 2px solid var(--np-action, #765620); outline-offset: 2px; }
#prodProducts .np3-tk-filtrid #prodSearch { min-height: 38px; border-radius: 10px; padding: 0.4rem 0.8rem; }
#prodProducts .np3-tk-filtrid select { min-height: 36px; border-radius: 8px; padding: 0.3rem 0.6rem; }

#prodProducts .np3-tk-tyhi { padding: 1.6rem 0.5rem; text-align: center; color: var(--np-ink-3, #746759); }

/* pilt + kohatäide (rahulik lehemotiiv, mitte „?") */
#prodProducts .np3-tk-pilt {
    flex: none; display: block; width: 48px; height: 48px; object-fit: contain; border-radius: 10px;
    border: 1px solid var(--np-line, #e6dccf); background: var(--np-surface-2, #faf6ef);
}
#prodProducts .np3-tk-kohatäide { display: flex; align-items: center; justify-content: center; }
#prodProducts .np3-tk-kohatäide svg { width: 46%; height: 46%; fill: none; stroke: #a9b597; stroke-width: 1.6; stroke-linecap: round; stroke-linejoin: round; }

#prodProducts .np3-tk-wrap { overflow-x: auto; }
#prodProducts table.np3-tk-tabel { width: 100%; border-collapse: collapse; font-size: 0.88rem; }
#prodProducts table.np3-tk-tabel th { text-align: left; font-size: 0.7rem; letter-spacing: 0.07em; text-transform: uppercase; font-weight: 600; white-space: nowrap; }
#prodProducts table.np3-tk-tabel th.num { text-align: right; }
#prodProducts table.np3-tk-tabel td { padding: 0.5rem 0.75rem; vertical-align: middle; border-bottom: 1px solid var(--np-line, #e6dccf); }
#prodProducts .np3-tk-rida { cursor: pointer; }
#prodProducts .np3-tk-rida:hover { background: var(--np-surface-2, #faf6ef); }
#prodProducts .np3-tk-rida.arhiivis, #prodProducts .np3-tk-kaart.arhiivis { opacity: 0.55; }
#prodProducts .np3-tk-toode-sisu { display: flex; align-items: center; gap: 0.8rem; min-width: 0; }
#prodProducts .np3-tk-tekst { display: flex; flex-direction: column; min-width: 0; }
#prodProducts .np3-tk-nimi { font-weight: 600; color: var(--np-ink, #2a2420); line-height: 1.3; }
#prodProducts .np3-tk-kood { margin-top: 0.1rem; font-size: 0.76rem; color: var(--np-ink-3, #746759); font-variant-numeric: tabular-nums; }
#prodProducts .np3-tk-mark {
    display: inline-block; margin-left: 0.3rem; padding: 0 0.4rem; border: 1px solid var(--np-line-strong, #9c8872); border-radius: 4px;
    font-size: 0.66rem; letter-spacing: 0.05em; text-transform: uppercase; color: var(--np-ink-2, #5e534a); vertical-align: 1px;
}
#prodProducts .np3-tk-perekond {
    display: inline-block; padding: 0.1rem 0.55rem; border-radius: 999px; border: 1px solid var(--np-line, #e6dccf);
    background: var(--np-surface-2, #faf6ef); color: var(--np-ink-2, #5e534a); font-size: 0.75rem; white-space: nowrap;
}
#prodProducts .np3-tk-retsept { font-size: 0.8rem; color: var(--np-ink-2, #5e534a); max-width: 260px; }
#prodProducts td.np3-tk-saadaval { text-align: right; white-space: nowrap; }
#prodProducts .np3-tk-arv { display: block; font-weight: 600; font-variant-numeric: tabular-nums; color: var(--np-ink, #2a2420); }
#prodProducts .np3-tk-arv.np3-tk-null { color: #b0694c; }
#prodProducts .np3-tk-alam { display: block; font-size: 0.72rem; color: var(--np-ink-3, #746759); font-variant-numeric: tabular-nums; }
#prodProducts .np3-tk-tuhi { color: var(--np-ink-3, #746759); }
#prodProducts .np3-tk-olekulahter { white-space: nowrap; }
#prodProducts .np3-tk-olek {
    display: inline-block; padding: 0.15rem 0.6rem; border-radius: 999px; border: 1px solid #e2d8cd;
    background: #f1ece6; color: #5e534a; font-size: 0.74rem; font-weight: 600; white-space: nowrap;
}
#prodProducts .np3-tk-olek-approved { background: #eef3e8; color: #3a5230; border-color: #d3e0c5; }
#prodProducts .np3-tk-olek-development { background: #fbf0e1; color: #8a5300; border-color: #efd9b5; }
#prodProducts .np3-tk-olek-revision { background: #eef4f8; color: #2a5f8a; border-color: #cfe0ec; }

/* Ruudustik — suur pilt, sama info */
#prodProducts .np3-tk-ruudud { display: grid; grid-template-columns: repeat(auto-fill, minmax(190px, 1fr)); gap: 0.9rem; }
#prodProducts .np3-tk-kaart {
    display: flex; flex-direction: column; border: 1px solid var(--np-line, #e6dccf); border-radius: 14px;
    background: var(--np-surface, #fff); overflow: hidden; cursor: pointer; transition: border-color .12s;
}
#prodProducts .np3-tk-kaart:hover { border-color: var(--np-line-strong, #9c8872); }
#prodProducts .np3-tk-kaart:focus-visible { outline: 2px solid var(--np-action, #765620); outline-offset: 2px; }
#prodProducts .np3-tk-kaart-pilt { aspect-ratio: 1 / 1; padding: 0.8rem; background: var(--np-surface-2, #faf6ef); border-bottom: 1px solid var(--np-line, #e6dccf); }
#prodProducts .np3-tk-kaart-pilt .np3-tk-pilt { width: 100%; height: 100%; border: 0; background: transparent; border-radius: 6px; }
#prodProducts .np3-tk-kaart-sisu { display: flex; flex-direction: column; gap: 0.25rem; padding: 0.7rem 0.8rem 0.8rem; flex: 1; }
#prodProducts .np3-tk-kaart .np3-tk-nimi { display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
#prodProducts .np3-tk-kaart-jalus { display: flex; align-items: flex-end; justify-content: space-between; gap: 0.5rem; margin-top: auto; padding-top: 0.35rem; }
#prodProducts .np3-tk-kaart .np3-tk-perekond { align-self: flex-start; }

/* Telefon: rida = kaart, pilt vasakul (tabel on märgitud data-m-tabel → kest ei kaardista seda ise) */
@media (max-width: 768px) {
    #prodProducts .np3-tk-wrap { overflow: visible; }
    #prodProducts table.np3-tk-tabel, #prodProducts table.np3-tk-tabel tbody { display: block; width: 100%; }
    #prodProducts table.np3-tk-tabel thead { display: none; }
    #prodProducts tr.np3-tk-rida {
        display: grid; grid-template-columns: minmax(0, 1fr) auto; grid-template-areas: "toode olek" "pere saadaval" "retsept retsept";
        gap: 0.4rem 0.6rem; padding: 0.75rem 0.8rem; margin-bottom: 0.6rem;
        border: 1px solid var(--np-line, #e6dccf); border-radius: 14px; background: var(--np-surface, #fff);
    }
    #prodProducts tr.np3-tk-rida > td { display: block; padding: 0; border: 0; min-width: 0; }
    #prodProducts td.np3-tk-toode { grid-area: toode; }
    #prodProducts td.np3-tk-olekulahter { grid-area: olek; justify-self: end; align-self: start; }
    #prodProducts td.np3-tk-pere { grid-area: pere; align-self: center; padding-left: calc(48px + 0.8rem); }
    #prodProducts td.np3-tk-saadaval { grid-area: saadaval; }
    #prodProducts td.np3-tk-retsept { grid-area: retsept; max-width: none; padding-top: 0.35rem; border-top: 1px solid var(--np-line, #e6dccf); }
    #prodProducts td.np3-tk-retsept:has(> .np3-tk-tuhi:only-child) { display: none; }
    #prodProducts .np3-tk-nimi { font-family: var(--font-display, Georgia, serif); font-size: 1.02rem; white-space: normal; overflow-wrap: anywhere; }
    #prodProducts td.np3-tk-toode { overflow: hidden; }
    #prodProducts .np3-tk-kood { white-space: normal; overflow-wrap: anywhere; }
    #prodProducts .np3-tk-ruudud { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 0.6rem; }
    #prodProducts .np3-vaatelyliti button { min-height: 40px; }
}

/* ── Müügi kate (Jimmy 15.11.2026 #453) — static/js/myygikate.js ─────────── */
#salesKate { --mk-kaup: #b9a58a; --mk-trans: #c0651f; --mk-makse: #8a6fb0; --mk-kate: #5f8a4a; }
#salesKate .mk-pais { display: flex; justify-content: space-between; align-items: flex-end; gap: 1rem; flex-wrap: wrap; margin-bottom: 0.9rem; }
#salesKate .mk-h { margin: 0; font-family: Georgia, serif; font-weight: 600; }
#salesKate .mk-h3 { margin: 0 0 0.6rem; font-size: 1rem; }
#salesKate .mk-vaikne, .mk-tellimus .mk-vaikne { color: var(--np-ink-3, #8a7a66); font-size: 0.82rem; }
#salesKate .mk-valikud { display: flex; gap: 0.6rem; align-items: center; }
#salesKate .mk-valikud input[type=month] { padding: 0.35rem 0.5rem; border: 1px solid var(--np-line, #e4dacb); border-radius: 8px; }
#salesKate .mk-btn-teine { background: var(--np-surface, #fffdf8); color: var(--np-ink, #3b2f22); border: 1px solid var(--np-line-strong, #d4c6b2); }
#salesKate .mk-mt { margin-top: 0.6rem; }
#salesKate .mk-plaadid { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 0.7rem; margin-bottom: 0.9rem; }
#salesKate .mk-plaat { background: var(--np-surface, #fffdf8); border: 1px solid var(--np-line, #e4dacb); border-radius: 12px; padding: 0.7rem 0.9rem; font-size: 0.8rem; color: var(--np-ink-2, #5c4a36); }
#salesKate .mk-plaat-hinnang { background: var(--np-warn-soft, #fbf0d9); }
#salesKate .mk-nr { font-size: 1.35rem; font-weight: 700; color: var(--np-ink, #3b2f22); font-variant-numeric: tabular-nums; }
#salesKate .mk-halb { color: var(--np-danger-ink, #a8322a) !important; font-weight: 700; }
#salesKate .mk-keskmine { color: var(--np-warn-ink, #8a5300) !important; }
#salesKate .mk-hoiatus { background: var(--np-warn-soft, #fbf0d9); color: var(--np-warn-ink, #8a5300); border-radius: 8px; padding: 0.4rem 0.7rem; font-size: 0.85rem; }
#salesKate .mk-viga { color: var(--np-danger-ink, #a8322a); }
#salesKate .mk-tabel { width: 100%; border-collapse: collapse; font-size: 0.86rem; }
#salesKate .mk-tabel th { font-size: 0.7rem; letter-spacing: .04em; text-transform: uppercase; color: var(--np-ink-3, #8a7a66); text-align: left; padding: 0.4rem 0.5rem; border-bottom: 1px solid var(--np-line, #e4dacb); white-space: nowrap; }
#salesKate .mk-tabel td { padding: 0.45rem 0.5rem; border-bottom: 1px solid var(--np-line, #efe6d8); vertical-align: middle; }
#salesKate .mk-tabel .num { text-align: right; white-space: nowrap; font-variant-numeric: tabular-nums; }
#salesKate .mk-klikk { cursor: pointer; }
#salesKate .mk-klikk:hover, #salesKate .mk-valitud { background: var(--np-action-soft, #f6eedd); }
#salesKate .mk-nr-tekst { font-family: ui-monospace, monospace; font-size: 0.82rem; }
.mk-riba { display: flex; height: 12px; border-radius: 4px; overflow: hidden; background: var(--np-surface-2, #f3ece0); }
.mk-riba i, .mk-leg i { display: block; height: 100%; }
.mk-kaup { background: var(--mk-kaup, #b9a58a); }
.mk-trans { background-color: var(--mk-trans, #c0651f); }
.mk-makse { background: var(--mk-makse, #8a6fb0); }
.mk-kate { background: var(--mk-kate, #5f8a4a); }
.mk-hinnang { background-image: repeating-linear-gradient(135deg, rgba(255,255,255,.55) 0 3px, transparent 3px 6px); }
#salesKate .mk-leg { display: flex; flex-wrap: wrap; gap: 0.4rem 1rem; font-size: 0.78rem; color: var(--np-ink-3, #8a7a66); margin-top: 0.6rem; }
#salesKate .mk-leg i { display: inline-block; width: 12px; height: 12px; border-radius: 3px; vertical-align: -2px; margin-right: 4px; }
.mk-pill { font-size: 0.7rem; border-radius: 999px; padding: 0 0.45rem; background: var(--np-surface-2, #f3ece0); color: var(--np-ink-2, #5c4a36); white-space: nowrap; }
.mk-pill-h { background: var(--np-warn-soft, #fbf0d9); color: var(--np-warn-ink, #8a5300); }
.mk-pill-t { background: var(--np-moss-soft, #e9f0e2); color: var(--np-moss-ink, #3a5230); }
.mk-tellimus { margin-top: 0.8rem; max-width: 380px; border: 1px solid var(--np-line, #e4dacb); border-radius: 10px; padding: 0.6rem 0.8rem; background: var(--np-surface, #fffdf8); }
.mk-tellimus h4 { margin: 0 0 0.3rem; font-size: 0.9rem; }
.mk-tellimus .mk-k { display: flex; justify-content: space-between; gap: 1rem; font-size: 0.84rem; padding: 0.1rem 0; }
.mk-tellimus .mk-kokku { border-top: 1px solid var(--np-line, #e4dacb); margin: 0.3rem 0 0.5rem; padding-top: 0.3rem; font-weight: 700; }
.mk-tellimus .num { font-variant-numeric: tabular-nums; white-space: nowrap; }
.mk-tellimus .mk-halb { color: var(--np-danger-ink, #a8322a); }
@media (max-width: 900px) { #salesKate .mk-plaadid { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 600px) {
    #salesKate .mk-tabel thead { display: none; }
    #salesKate .mk-tabel tr { display: block; border: 1px solid var(--np-line, #e4dacb); border-radius: 10px; margin-bottom: 0.5rem; padding: 0.3rem 0.5rem; }
    #salesKate .mk-tabel td { display: flex; justify-content: space-between; gap: 0.6rem; border: 0; padding: 0.2rem 0; }
    #salesKate .mk-tabel td::before { content: attr(data-silt); color: var(--np-ink-3, #8a7a66); font-size: 0.78rem; }
    #salesKate .mk-tabel .mk-riba { width: 55% !important; }
}
.mk-riba-tyhi { background: repeating-linear-gradient(135deg, var(--np-line, #e4dacb) 0 3px, transparent 3px 6px); }
#salesKate .mk-lyliti { display: inline-flex; gap: 2px; padding: 3px; margin: 0.2rem 0 0.8rem; background: var(--np-surface-2, #f3ece0); border-radius: 999px; }
#salesKate .mk-lyl { border: 0; background: transparent; padding: 0.35rem 1rem; border-radius: 999px; font: inherit; font-size: 0.88rem; cursor: pointer; color: var(--np-ink-2, #5c4a36); }
#salesKate .mk-lyl.on { background: var(--np-surface, #fffdf8); color: var(--np-ink, #3b2f22); font-weight: 600; box-shadow: var(--np-shadow-1, 0 1px 2px rgba(0,0,0,.08)); }
#salesKate .mk-plaadid-6 { grid-template-columns: repeat(6, minmax(0, 1fr)); }
#salesKate .mk-detail h4 { margin: 0.6rem 0 0.4rem; font-size: 0.9rem; }
#salesKate .mk-detail-veerud { display: grid; grid-template-columns: 1fr 1fr; gap: 1.2rem; }
@media (max-width: 900px) { #salesKate .mk-plaadid-6 { grid-template-columns: repeat(2, minmax(0, 1fr)); } #salesKate .mk-detail-veerud { grid-template-columns: 1fr; } }
#salesKate .mk-kamp-pais { display: flex; justify-content: space-between; gap: 1rem; align-items: flex-start; flex-wrap: wrap; margin-bottom: 0.6rem; }
#salesKate .mk-kamp-otsus { text-align: right; border-radius: 10px; padding: 0.4rem 0.8rem; font-size: 0.8rem; }
#salesKate .mk-kamp-otsus.mk-ok { background: var(--np-moss-soft, #e9f0e2); color: var(--np-moss-ink, #3a5230); }
#salesKate .mk-kamp-otsus.mk-halb { background: var(--np-danger-soft, #fbeae6); }
#salesKate .mk-kamp-veerud { display: grid; grid-template-columns: 1fr 1fr; gap: 1.5rem; }
#salesKate .mk-kamp .mk-k { display: flex; justify-content: space-between; gap: 1rem; font-size: 0.86rem; padding: 0.12rem 0; }
#salesKate .mk-kamp .mk-kokku { border-top: 1px solid var(--np-line, #e4dacb); margin-top: 0.3rem; padding-top: 0.3rem; font-weight: 700; }
#salesKate .mk-kamp .num { font-variant-numeric: tabular-nums; white-space: nowrap; }
@media (max-width: 900px) { #salesKate .mk-kamp-veerud { grid-template-columns: 1fr; } }
