/* Iekšējais veikals — pārdevēja tālruņa skats (bez Bootstrap). Tumšais ir bāze, gaišais — pārrakstījums. */

:root {
    --shop-bg: #020617;
    --shop-surface: #0b1120;
    --shop-surface-2: #111827;
    --shop-border: rgba(148, 163, 184, 0.25);
    --shop-text: #d9dde4;
    --shop-muted: #9ca3af;
    --shop-primary: #22c55e;
    --shop-primary-ink: #04130a;
    --shop-primary-soft: rgba(34, 197, 94, 0.14);
    --shop-danger: #ef4444;
    --shop-danger-soft: rgba(239, 68, 68, 0.14);
    --shop-warning: #f59e0b;
    --shop-key-bg: #111827;
    --shop-key-active: #1f2937;
    --shop-radius: 16px;
    --shop-tabbar-h: 64px;
    color-scheme: dark;
}

[data-theme="light"] {
    --shop-bg: #f1f5f9;
    --shop-surface: #ffffff;
    --shop-surface-2: #f8fafc;
    --shop-border: rgba(15, 23, 42, 0.12);
    --shop-text: #0f172a;
    --shop-muted: #64748b;
    --shop-primary: #16a34a;
    --shop-primary-ink: #ffffff;
    --shop-primary-soft: rgba(22, 163, 74, 0.12);
    --shop-danger-soft: rgba(239, 68, 68, 0.1);
    --shop-key-bg: #ffffff;
    --shop-key-active: #e2e8f0;
    color-scheme: light;
}

*,
*::before,
*::after {
    box-sizing: border-box;
}

html {
    -webkit-text-size-adjust: 100%;
}

body.shop-body {
    margin: 0;
    min-height: 100vh;
    min-height: 100dvh;
    background: var(--shop-bg);
    color: var(--shop-text);
    font-family: "Inter", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
    font-size: 16px;
    line-height: 1.4;
    -webkit-tap-highlight-color: transparent;
}

.shop-app {
    min-height: 100vh;
    min-height: 100dvh;
    display: flex;
    flex-direction: column;
    padding-top: env(safe-area-inset-top);
}

/* Augšējā josla */
.shop-topbar {
    position: sticky;
    top: 0;
    z-index: 10;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    min-height: 56px;
    padding: 8px max(16px, env(safe-area-inset-right)) 8px max(16px, env(safe-area-inset-left));
    background: var(--shop-surface);
    border-bottom: 1px solid var(--shop-border);
}

.shop-topbar-title {
    margin: 0;
    font-size: 18px;
    font-weight: 700;
}

.shop-topbar-user {
    color: var(--shop-muted);
    font-size: 14px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.shop-main {
    flex: 1;
    width: 100%;
    max-width: 720px;
    margin: 0 auto;
    padding: 16px max(16px, env(safe-area-inset-right)) calc(var(--shop-tabbar-h) + 24px + env(safe-area-inset-bottom)) max(16px, env(safe-area-inset-left));
}

.shop-main--centered {
    display: flex;
    flex-direction: column;
    justify-content: center;
    padding-bottom: calc(24px + env(safe-area-inset-bottom));
}

/* Pogas: vismaz 48px pieskārienam, galvenās — 56px */
.shop-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    min-height: 48px;
    padding: 0 20px;
    border: 1px solid var(--shop-border);
    border-radius: 12px;
    background: var(--shop-surface-2);
    color: var(--shop-text);
    font: inherit;
    font-weight: 600;
    text-decoration: none;
    cursor: pointer;
    touch-action: manipulation;
}

.shop-btn:active {
    transform: scale(0.98);
}

.shop-btn--primary {
    min-height: 56px;
    border-color: transparent;
    background: var(--shop-primary);
    color: var(--shop-primary-ink);
    font-size: 17px;
}

.shop-btn--block {
    display: flex;
    width: 100%;
}

.shop-btn--ghost {
    background: transparent;
    border-color: transparent;
    color: var(--shop-muted);
    font-weight: 500;
}

.shop-btn--small {
    min-height: 40px;
    padding: 0 14px;
    font-size: 14px;
}

.shop-link {
    color: var(--shop-muted);
    font-size: 15px;
}

/* Kartes un paziņojumi */
.shop-card {
    padding: 20px;
    border: 1px solid var(--shop-border);
    border-radius: var(--shop-radius);
    background: var(--shop-surface);
}

.shop-card + .shop-card {
    margin-top: 12px;
}

.shop-heading {
    margin: 0 0 6px;
    font-size: 22px;
    font-weight: 700;
    text-align: center;
}

.shop-subtext {
    margin: 0 0 20px;
    color: var(--shop-muted);
    text-align: center;
}

.shop-alert {
    margin: 0 0 16px;
    padding: 12px 14px;
    border-radius: 12px;
    background: var(--shop-danger-soft);
    color: var(--shop-danger);
    font-weight: 500;
    text-align: center;
}

.shop-alert--info {
    background: var(--shop-primary-soft);
    color: var(--shop-text);
}

/* PIN: punkti un cipartastatūra */
.shop-pin-dots {
    display: flex;
    justify-content: center;
    gap: 16px;
    margin: 8px 0 24px;
}

.shop-pin-dot {
    width: 16px;
    height: 16px;
    border: 2px solid var(--shop-muted);
    border-radius: 50%;
    transition: background-color 0.1s ease, border-color 0.1s ease;
}

.shop-pin-dot.is-filled {
    background: var(--shop-primary);
    border-color: var(--shop-primary);
}

.shop-pin-dots.is-error .shop-pin-dot {
    border-color: var(--shop-danger);
}

.shop-keypad {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 12px;
    max-width: 320px;
    margin: 0 auto;
}

.shop-key {
    min-height: 64px;
    border: 1px solid var(--shop-border);
    border-radius: 16px;
    background: var(--shop-key-bg);
    color: var(--shop-text);
    font: inherit;
    font-size: 26px;
    font-weight: 600;
    cursor: pointer;
    touch-action: manipulation;
    user-select: none;
}

.shop-key:active {
    background: var(--shop-key-active);
}

.shop-key--muted {
    border-color: transparent;
    background: transparent;
    color: var(--shop-muted);
    font-size: 16px;
}

.shop-key[disabled] {
    visibility: hidden;
}

/* Pārdevēju izvēle PIN ekrānā */
.shop-seller-list {
    display: grid;
    gap: 12px;
    margin: 0;
    padding: 0;
    list-style: none;
}

.shop-seller-btn {
    display: flex;
    align-items: center;
    gap: 14px;
    width: 100%;
    min-height: 72px;
    padding: 12px 16px;
    border: 1px solid var(--shop-border);
    border-radius: var(--shop-radius);
    background: var(--shop-surface);
    color: var(--shop-text);
    font: inherit;
    font-size: 19px;
    font-weight: 600;
    text-align: left;
    text-decoration: none;
    cursor: pointer;
    touch-action: manipulation;
}

.shop-seller-btn:active {
    background: var(--shop-surface-2);
}

.shop-avatar {
    display: inline-flex;
    flex: 0 0 auto;
    align-items: center;
    justify-content: center;
    width: 44px;
    height: 44px;
    border-radius: 50%;
    background: var(--shop-primary-soft);
    color: var(--shop-primary);
    font-size: 17px;
    font-weight: 700;
}

.shop-footer-links {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 6px;
    margin-top: 24px;
}

/* Apakšējā cilņu josla */
.shop-tabbar {
    position: fixed;
    right: 0;
    bottom: 0;
    left: 0;
    z-index: 20;
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    height: calc(var(--shop-tabbar-h) + env(safe-area-inset-bottom));
    padding-bottom: env(safe-area-inset-bottom);
    background: var(--shop-surface);
    border-top: 1px solid var(--shop-border);
}

.shop-tab {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 3px;
    min-width: 0;
    padding: 0 4px;
    border: 0;
    background: transparent;
    color: var(--shop-muted);
    font: inherit;
    font-size: 12px;
    font-weight: 600;
    /* Garš nosaukums («Jauns komplekts») ar lielu sistēmas fontu pārnesas — rindas centrā zem ikonas. */
    line-height: 1.15;
    text-align: center;
    text-decoration: none;
    touch-action: manipulation;
}

.shop-tab svg {
    flex: none;
    width: 24px;
    height: 24px;
}

/* Nosaukumam vienmēr divu rindu augstums: ikonas paliek vienā līnijā arī tad, ja kāds nosaukums pārnesas. */
.shop-tab span {
    min-height: 2.3em;
}

.shop-tab.is-active {
    color: var(--shop-primary);
}

.shop-empty {
    padding: 48px 16px;
    text-align: center;
}

.shop-empty-icon {
    width: 64px;
    height: 64px;
    margin: 0 auto 16px;
    color: var(--shop-muted);
}

.shop-empty h2 {
    margin: 0 0 8px;
    font-size: 20px;
}

.shop-empty p {
    margin: 0;
    color: var(--shop-muted);
}

@media (min-width: 600px) {
    .shop-main--centered {
        max-width: 420px;
    }
}

/* ======================================================================
   4. posms: dēlis, komplekts, samaksa, Mana diena
   ====================================================================== */
:root {
    --shop-accent: #38bdf8;
    --shop-accent-ink: #04121c;
    --shop-warning-soft: rgba(245, 158, 11, 0.16);
    --shop-bottom-h: 76px;
}

[data-theme="light"] {
    --shop-accent: #0284c7;
    --shop-accent-ink: #ffffff;
    --shop-warning-soft: rgba(245, 158, 11, 0.14);
}

[hidden] {
    display: none !important;
}

.shop-muted { color: var(--shop-muted); }
.shop-center { text-align: center; }
.shop-mt { margin-top: 16px; }
.shop-mt-sm { margin-top: 8px; }
.shop-loading { padding: 48px 0; color: var(--shop-muted); text-align: center; }

.shop-offline {
    position: sticky;
    top: 0;
    z-index: 30;
    padding: 10px 16px;
    background: var(--shop-danger);
    color: #fff;
    font-weight: 700;
    text-align: center;
}

/* Vietas trūkumā sarūk lietotāja vārds, nevis ekrāna virsraksts. */
.shop-topbar-right { display: flex; flex: 0 20 auto; align-items: center; gap: 8px; min-width: 0; }
.shop-topbar-title { flex: 1 1 auto; min-width: 5em; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
@media (max-width: 359px) { .shop-topbar-user { display: none; } }

.shop-icon-btn {
    display: inline-flex;
    flex: 0 0 auto;
    align-items: center;
    justify-content: center;
    width: 48px;
    height: 48px;
    margin: -4px 0;
    border: 0;
    border-radius: 12px;
    background: transparent;
    color: var(--shop-text);
    cursor: pointer;
    touch-action: manipulation;
}
.shop-icon-btn svg { width: 24px; height: 24px; }
.emax-theme-btn { color: var(--shop-muted); }
.emax-theme-moon { display: none; }
[data-theme="light"] .emax-theme-sun { display: none; }
[data-theme="light"] .emax-theme-moon { display: block; }
.shop-icon-btn--danger { color: var(--shop-muted); }
.shop-icon-btn--danger:active { color: var(--shop-danger); }

.shop-btn[disabled] { opacity: 0.45; cursor: not-allowed; }
.shop-btn--accent { border-color: transparent; background: var(--shop-accent); color: var(--shop-accent-ink); }
.shop-btn--dashed { border-style: dashed; background: transparent; }

/* Lauki: vismaz 16px, lai iOS nepietuvina */
.shop-input {
    display: block;
    width: 100%;
    min-height: 48px;
    padding: 10px 14px;
    border: 1px solid var(--shop-border);
    border-radius: 12px;
    background: var(--shop-surface-2);
    color: var(--shop-text);
    font: inherit;
    font-size: 16px;
}
.shop-input:focus { outline: 2px solid var(--shop-accent); outline-offset: 1px; }
.shop-input--big { min-height: 56px; font-size: 22px; font-weight: 700; }
.shop-textarea { min-height: 72px; resize: vertical; }
.shop-search { margin-bottom: 14px; }
.shop-label { display: block; margin: 0 0 6px; color: var(--shop-muted); font-size: 14px; font-weight: 600; }
.shop-form .shop-btn--primary { margin-top: 20px; }
.shop-row { display: flex; gap: 10px; }
.shop-row > * { flex: 1; }
.shop-row > .shop-input { flex: 3; }
.shop-grid2 { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }

/* Dēļa plāksnītes */
.shop-tiles { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
@media (min-width: 600px) { .shop-tiles { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
@media (min-width: 900px) { .shop-tiles { grid-template-columns: repeat(4, minmax(0, 1fr)); } }
.shop-tile {
    position: relative;
    display: flex;
    flex-direction: column;
    gap: 6px;
    min-height: 128px;
    padding: 14px;
    border: 1px solid var(--shop-border);
    border-radius: var(--shop-radius);
    background: var(--shop-surface);
    color: var(--shop-text);
    text-decoration: none;
    touch-action: manipulation;
}
.shop-tile:active { background: var(--shop-surface-2); }
.shop-tile-name {
    display: -webkit-box;
    overflow: hidden;
    font-size: 18px;
    font-weight: 700;
    line-height: 1.25;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow-wrap: anywhere;
}
.shop-tile-sum { margin-top: auto; color: var(--shop-primary); font-size: 22px; font-weight: 800; }
.shop-tile-meta { color: var(--shop-muted); font-size: 13px; }
.shop-tile-dot {
    position: absolute;
    top: 10px;
    right: 10px;
    width: 12px;
    height: 12px;
    border-radius: 50%;
    background: var(--shop-warning);
    box-shadow: 0 0 0 3px var(--shop-warning-soft);
}

/* Komplekts */
.shop-kit-head { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; margin-bottom: 14px; }
.shop-kit-name {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    min-height: 48px;
    padding: 0;
    border: 0;
    background: transparent;
    color: var(--shop-text);
    font: inherit;
    font-size: 22px;
    font-weight: 800;
    text-align: left;
    cursor: pointer;
}
.shop-kit-name svg { width: 18px; height: 18px; color: var(--shop-muted); }
.shop-badge {
    display: inline-flex;
    align-items: center;
    min-height: 28px;
    padding: 2px 10px;
    border-radius: 999px;
    background: var(--shop-primary-soft);
    color: var(--shop-text);
    font-size: 14px;
    font-weight: 600;
}
.shop-badge--muted { background: var(--shop-surface-2); color: var(--shop-muted); }

.shop-line {
    padding: 12px 12px 12px 14px;
    border: 1px solid var(--shop-border);
    border-radius: var(--shop-radius);
    background: var(--shop-surface);
}
.shop-line + .shop-line { margin-top: 10px; }
.shop-line-top { display: flex; align-items: flex-start; gap: 8px; }
.shop-line-name { flex: 1; min-width: 0; padding-top: 4px; font-weight: 700; overflow-wrap: anywhere; }
.shop-line-name small, .shop-part-name small, .shop-check-name small, .shop-op-main small, .shop-result small {
    display: block;
    color: var(--shop-muted);
    font-size: 13px;
    font-weight: 500;
}
.shop-line-bottom { display: flex; align-items: center; gap: 10px; margin-top: 8px; }
.shop-stepper { display: inline-flex; align-items: center; border: 1px solid var(--shop-border); border-radius: 12px; }
.shop-stepper button {
    width: 48px;
    height: 48px;
    border: 0;
    background: transparent;
    color: var(--shop-text);
    font: inherit;
    font-size: 24px;
    font-weight: 700;
    cursor: pointer;
    touch-action: manipulation;
}
.shop-stepper button[disabled] { opacity: 0.3; cursor: not-allowed; }
.shop-stepper span { min-width: 32px; font-size: 18px; font-weight: 700; text-align: center; }
.shop-price-btn {
    min-height: 48px;
    padding: 0 10px;
    border: 1px dashed var(--shop-border);
    border-radius: 12px;
    background: transparent;
    color: var(--shop-text);
    font: inherit;
    font-weight: 600;
    white-space: nowrap;
    cursor: pointer;
}
.shop-line-sum { margin-left: auto; font-size: 17px; font-weight: 800; white-space: nowrap; }
.shop-warn {
    margin-top: 8px;
    padding: 8px 10px;
    border-radius: 10px;
    background: var(--shop-warning-soft);
    color: var(--shop-warning);
    font-size: 14px;
    font-weight: 600;
}
.shop-hint { margin-top: 6px; color: var(--shop-muted); font-size: 13px; }
.shop-info { margin-top: 10px; padding: 12px; border-radius: 12px; background: var(--shop-surface-2); }

/* Apakšējā darbību josla virs cilnēm */
.shop-bottom-bar {
    position: fixed;
    right: 0;
    bottom: calc(var(--shop-tabbar-h) + env(safe-area-inset-bottom));
    left: 0;
    z-index: 15;
    display: flex;
    align-items: center;
    gap: 12px;
    min-height: var(--shop-bottom-h);
    padding: 10px max(16px, env(safe-area-inset-right)) 10px max(16px, env(safe-area-inset-left));
    background: var(--shop-surface);
    border-top: 1px solid var(--shop-border);
    box-shadow: 0 -8px 24px rgba(0, 0, 0, 0.25);
}
.shop-bottom-bar .shop-btn--primary { flex: 1; }
.has-bottom-bar .shop-main { padding-bottom: calc(var(--shop-tabbar-h) + var(--shop-bottom-h) + 24px + env(safe-area-inset-bottom)); }
.shop-total small { display: block; color: var(--shop-muted); font-size: 13px; }
.shop-total b { font-size: 22px; white-space: nowrap; }

/* Apakšas logs */
.shop-sheet-backdrop { position: fixed; inset: 0; z-index: 40; background: rgba(2, 6, 23, 0.6); }
.shop-sheet {
    position: fixed;
    right: 0;
    bottom: 0;
    left: 0;
    z-index: 41;
    max-height: 88vh;
    max-height: 88dvh;
    overflow-y: auto;
    padding: 8px max(16px, env(safe-area-inset-right)) calc(20px + env(safe-area-inset-bottom)) max(16px, env(safe-area-inset-left));
    border-radius: 20px 20px 0 0;
    background: var(--shop-surface);
    overscroll-behavior: contain;
}
.shop-sheet--full { top: env(safe-area-inset-top); max-height: none; border-radius: 0; }
@media (min-width: 720px) {
    .shop-sheet { right: 50%; left: auto; width: 640px; transform: translateX(50%); }
    .shop-sheet--full { top: 24px; border-radius: 20px 20px 0 0; }
}
/* Jauna klienta forma: vieta zem satura, lai formu var uzritināt virs tālruņa tastatūras. */
.shop-sheet--keyboard { padding-bottom: 70vh; }
.shop-sheet-grip { width: 40px; height: 5px; margin: 0 auto 12px; border-radius: 3px; background: var(--shop-border); }
.shop-sheet-title { margin: 0 0 14px; padding-right: 48px; font-size: 20px; }
.shop-sheet-close {
    position: absolute;
    top: 8px;
    right: 8px;
    width: 48px;
    height: 48px;
    border: 0;
    background: transparent;
    color: var(--shop-muted);
    font-size: 30px;
    cursor: pointer;
}
body.has-sheet { overflow: hidden; }

.shop-pay-lines { display: grid; gap: 8px; }
.shop-check {
    display: flex;
    align-items: center;
    gap: 12px;
    min-height: 56px;
    padding: 8px 12px;
    border: 1px solid var(--shop-border);
    border-radius: 12px;
    cursor: pointer;
}
.shop-check input { flex: 0 0 auto; width: 24px; height: 24px; accent-color: var(--shop-primary); }
.shop-check-name { flex: 1; min-width: 0; overflow-wrap: anywhere; }
.shop-check-sum { font-weight: 700; white-space: nowrap; }
.shop-pay-total { display: flex; align-items: baseline; justify-content: space-between; margin: 16px 0 8px; font-size: 18px; }
.shop-pay-total b { font-size: 28px; }
.shop-pay-methods { display: grid; gap: 10px; margin-top: 12px; }
.shop-pay-btn {
    min-height: 64px;
    border: 2px solid var(--shop-border);
    border-radius: 16px;
    background: var(--shop-surface-2);
    color: var(--shop-text);
    font: inherit;
    font-size: 20px;
    font-weight: 800;
    cursor: pointer;
    touch-action: manipulation;
}
.shop-pay-btn.is-selected { border-color: var(--shop-primary); background: var(--shop-primary-soft); }
.shop-pay-btn[disabled] { opacity: 0.35; cursor: not-allowed; }
.is-offline #shopIssueBtn, .is-offline #shopPayBtn { opacity: 0.4; pointer-events: none; }

.shop-spinner {
    display: inline-block;
    width: 18px;
    height: 18px;
    border: 3px solid currentColor;
    border-right-color: transparent;
    border-radius: 50%;
    animation: shop-spin 0.7s linear infinite;
}
@keyframes shop-spin { to { transform: rotate(360deg); } }

/* Klientu un preču meklēšana */
.shop-results { display: grid; gap: 6px; margin-top: 8px; }
.shop-result, .shop-part {
    display: flex;
    align-items: center;
    gap: 10px;
    width: 100%;
    min-height: 56px;
    padding: 8px 12px;
    border: 1px solid var(--shop-border);
    border-radius: 12px;
    background: var(--shop-surface);
    color: var(--shop-text);
    font: inherit;
    text-align: left;
    cursor: pointer;
    touch-action: manipulation;
}
.shop-result { flex-direction: column; align-items: flex-start; justify-content: center; gap: 0; }
.shop-result:active, .shop-part:active { background: var(--shop-surface-2); }
.shop-part + .shop-part { margin-top: 8px; }
.shop-part[disabled] { opacity: 0.4; }
.shop-part-name { flex: 1; min-width: 0; font-weight: 700; overflow-wrap: anywhere; }
.shop-part-price { color: var(--shop-primary); font-weight: 800; white-space: nowrap; }
.shop-chip {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    min-height: 44px;
    padding: 0 6px 0 14px;
    border-radius: 999px;
    background: var(--shop-primary-soft);
    font-weight: 700;
}
.shop-chip-x { width: 36px; height: 36px; border: 0; background: transparent; color: var(--shop-text); font-size: 22px; cursor: pointer; }

/* Paziņojums apakšā */
.shop-toast {
    position: fixed;
    right: 16px;
    bottom: calc(var(--shop-tabbar-h) + 16px + env(safe-area-inset-bottom));
    left: 16px;
    z-index: 50;
    display: flex;
    align-items: center;
    gap: 12px;
    max-width: 560px;
    margin: 0 auto;
    padding: 12px 16px;
    border-radius: 14px;
    background: var(--shop-text);
    color: var(--shop-bg);
    font-weight: 600;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.35);
}
.has-bottom-bar .shop-toast { bottom: calc(var(--shop-tabbar-h) + var(--shop-bottom-h) + 12px + env(safe-area-inset-bottom)); }
.shop-toast span { flex: 1; }
.shop-toast-action {
    min-height: 40px;
    padding: 0 12px;
    border: 0;
    border-radius: 10px;
    background: var(--shop-accent);
    color: var(--shop-accent-ink);
    font: inherit;
    font-weight: 800;
    cursor: pointer;
}

/* Izsniegts */
.shop-success { padding: 32px 0; text-align: center; }
.shop-success-check {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 96px;
    height: 96px;
    margin: 0 auto 16px;
    border-radius: 50%;
    background: var(--shop-primary);
    color: var(--shop-primary-ink);
}
.shop-success-check svg { width: 56px; height: 56px; }
.shop-success h2 { margin: 0; font-size: 28px; }
.shop-success-sum { margin: 8px 0 4px; font-size: 32px; font-weight: 800; }

/* Mana diena */
.shop-day-nav { display: flex; align-items: center; gap: 8px; margin-bottom: 14px; }
.shop-date { flex: 1; min-width: 0; }
.shop-stats { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
.shop-stat { padding: 14px; border: 1px solid var(--shop-border); border-radius: var(--shop-radius); background: var(--shop-surface); }
.shop-stat small { display: block; color: var(--shop-muted); font-size: 13px; font-weight: 600; }
.shop-stat b { display: block; margin-top: 4px; font-size: 22px; }
.shop-stat span { display: block; margin-top: 4px; color: var(--shop-muted); font-size: 12px; }
.shop-stat--total { border-color: var(--shop-primary); }
.shop-cashbox { margin-top: 12px; }
.shop-cashbox small { display: block; color: var(--shop-muted); font-weight: 600; }
.shop-cashbox b { font-size: 30px; }
.shop-section-title { margin: 20px 0 10px; font-size: 17px; }
.shop-ops { border: 1px solid var(--shop-border); border-radius: var(--shop-radius); background: var(--shop-surface); }
.shop-op { display: flex; align-items: center; gap: 12px; min-height: 56px; padding: 8px 14px; }
.shop-op + .shop-op { border-top: 1px solid var(--shop-border); }
.shop-op-time { color: var(--shop-muted); font-variant-numeric: tabular-nums; }
.shop-op-main { flex: 1; min-width: 0; overflow-wrap: anywhere; }
.shop-op b { white-space: nowrap; }

/* Datuma izvēle: rāda dd.mm.gggg, pieskāriens atver pārlūka kalendāru (caurspīdīgs lauks virsū). */
.shop-date { position: relative; flex: 1; min-width: 0; overflow: hidden; }
.shop-date-native { position: absolute; inset: 0; width: 100%; height: 100%; opacity: 0; cursor: pointer; }
#shopPayDetail { margin-top: 16px; }

/* 5. posms: čeka QR un pieskarama kartes operācija */
.shop-qr {
    width: min(280px, 80vw);
    margin: 8px auto 12px;
    padding: 14px;
    border-radius: 16px;
    background: #ffffff;
}
.shop-qr svg { display: block; width: 100%; height: auto; }
.shop-op--tap { cursor: pointer; }
.shop-op--tap:active { background: var(--shop-surface-2); }
.shop-op--tap .shop-op-main small::after { content: ' ›'; color: var(--shop-accent); }

/* «Mana diena»: noslēgtas pārdošanas preces */
.shop-sale-meta { margin: -8px 0 12px; }
.shop-sale-lines { border: 1px solid var(--shop-border); border-radius: 12px; }
.shop-sale-line { display: flex; align-items: center; gap: 12px; min-height: 52px; padding: 8px 12px; }
.shop-sale-line + .shop-sale-line { border-top: 1px solid var(--shop-border); }
.shop-sale-name { flex: 1; min-width: 0; overflow-wrap: anywhere; }
.shop-sale-name small { display: block; color: var(--shop-muted); font-size: 13px; }
.shop-sale-line b { white-space: nowrap; }
.shop-sale-discount { min-height: 40px; color: var(--shop-muted); }

/* ======================================================================
   eMax: adminam/menedžerim — cilne «Vairāk» un sadaļu pārslēdzējs (Remonti · Veikals),
   to pašu izmanto arī remontu sadaļa (repairs-m.js).
   ====================================================================== */
.shop-tabbar--4 { grid-template-columns: repeat(4, 1fr); }

.shop-section-switch {
    display: grid;
    grid-auto-columns: 1fr;
    grid-auto-flow: column;
    gap: 4px;
    margin-top: 8px;
    padding: 4px;
    border: 1px solid var(--shop-border);
    border-radius: 12px;
    background: var(--shop-surface-2);
}
.shop-section-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 44px;
    border-radius: 9px;
    color: var(--shop-muted);
    font-weight: 700;
    text-decoration: none;
    touch-action: manipulation;
}
.shop-section-btn.is-active {
    background: var(--shop-primary);
    color: var(--shop-primary-ink);
}
