/* ══════════════════════════════════════════════
   B2B Global Theme — CSS Variables
   Bu dosya GLOBAL oldugu icin :root calısır.
   Scoped .razor.css dosyalarinda var() ile kullanilir.
   ══════════════════════════════════════════════ */

:root {
    /* ── Renkler — profesyonel arduvaz (koyu shell + açık içerik) ── */
    --b2b-header: #3c4e5b;
    --b2b-header-hover: rgba(255, 255, 255, 0.10);
    --b2b-accent: #0078d4;
    --b2b-accent-light: #e8f4fd;
    --b2b-accent-hover: #005a9e;

    /* Sidebar (koyu) + kendi metin renkleri (paylaşımlı --b2b-text koyu zeminde görünmez) */
    --b2b-sidebar: #3c4e5b;
    --b2b-sidebar-hover: rgba(255, 255, 255, 0.08);
    --b2b-sidebar-border: #2f3e49;
    --b2b-sidebar-active-bg: rgba(34, 211, 238, 0.16);
    --b2b-sidebar-accent: #22d3ee;
    --b2b-sidebar-text: #d6dfe4;
    --b2b-sidebar-text-secondary: #b8c6ce;
    --b2b-sidebar-text-muted: #8398a4;
    --b2b-sidebar-pin: #eab308;

    --b2b-content-bg: #eef2f4;
    --b2b-danger: #dc2626;
    --b2b-success: #16a34a;

    /* ── Metin ── */
    --b2b-text: #1e293b;
    --b2b-text-secondary: #64748b;
    --b2b-text-muted: #94a3b8;

    /* ── Font ── */
    --b2b-font: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;

    /* ── Layout ── */
    --b2b-navbar-h: 54px;
    --b2b-sidebar-w: 260px;
}

/* ── Global font ── */
body {
    font-family: var(--b2b-font);
}

/* ── Content background ── */
.app-content {
    background-color: var(--b2b-content-bg);
}

/* ── DxPopup mobil taşma düzeltmesi ── */
.dxbl-modal-body {
    max-width: 100% !important;
    word-break: break-word;
    padding-top: 0 !important;
}

/* b2b-popup-body — sticky header için overflow ayarı */
.dxbl-modal-body.b2b-popup-body {
    overflow-y: auto !important;
    overflow-x: hidden !important;
    max-height: 85vh !important;
    padding: 0 !important;
    scrollbar-width: none !important;
}

.dxbl-modal-body.b2b-popup-body::-webkit-scrollbar {
    display: none !important;
}

.dxbl-modal-content {
    max-width: 96vw !important;
    max-height: 92vh !important;
    overflow: visible;
    gap: 0 !important;
}

.dxbl-modal-content > * {
    margin-bottom: 0 !important;
}


/* ── Tüm popup'ları ekran merkezinde aç ── */
.dxbl-modal {
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
}

.dxbl-modal-dialog {
    margin: auto !important;
}

/* Popup header bar — ince teal çerçeve, drag alanı */
.b2b-popup-header {
    padding: 0 !important;
    min-height: 10px !important;
    height: 10px !important;
    background: linear-gradient(135deg, #0891b2 0%, #06b6d4 100%) !important;
    border-bottom: none !important;
    cursor: grab !important;
    margin-bottom: 0 !important;
}

.b2b-popup-header * {
    display: none !important;
}

/* ── B2B Themed Popup System (Portal kalıbı, teal tema) ── */

/* DxPopup body scrollbar gizle */
.b2b-popup-body .dxbl-scroll-viewer,
.b2b-popup-body .dxbl-popup-content {
    scrollbar-width: none !important;
}

.b2b-popup-body .dxbl-scroll-viewer::-webkit-scrollbar,
.b2b-popup-body .dxbl-popup-content::-webkit-scrollbar {
    display: none !important;
}

/* B2B popup temalı header (component içinde) — sticky */
.b2b-themed-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    padding: 12px 18px;
    background: linear-gradient(135deg, #0891b2 0%, #06b6d4 100%);
    flex-shrink: 0;
    z-index: 10;
    position: sticky;
    top: 0;
}

.b2b-themed-header .bh-left {
    display: flex;
    align-items: center;
    gap: 10px;
    min-width: 0;
}

.b2b-themed-header .bh-icon {
    width: 36px;
    height: 36px;
    border-radius: 8px;
    background: rgba(255, 255, 255, 0.15);
    display: flex;
    align-items: center;
    justify-content: center;
    color: #fff;
    flex-shrink: 0;
    font-size: 18px;
}

.b2b-themed-header .bh-title {
    font-size: 15px;
    font-weight: 700;
    color: #fff;
}

.b2b-themed-header .bh-sub {
    font-size: 11.5px;
    color: rgba(255, 255, 255, 0.7);
    font-weight: 400;
}

.b2b-themed-header .bh-badge {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    padding: 5px 12px;
    background: rgba(255, 255, 255, 0.15);
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 20px;
    font-size: 11.5px;
    font-weight: 600;
    color: rgba(255, 255, 255, 0.85);
    white-space: nowrap;
}

.b2b-themed-header .bh-close {
    width: 30px;
    height: 30px;
    border-radius: 50%;
    border: 1px solid rgba(255, 255, 255, 0.25);
    background: rgba(255, 255, 255, 0.1);
    color: rgba(255, 255, 255, 0.8);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all .15s;
    font-size: 13px;
    padding: 0;
}

.b2b-themed-header .bh-close:hover {
    background: rgba(255, 255, 255, 0.25);
    color: #fff;
}

@media (max-width: 480px) {
    .b2b-themed-header {
        padding: 10px 14px;
    }

    .b2b-themed-header .bh-sub {
        display: none;
    }
}

.dxbl-modal-header-default {
    min-height: unset !important;
    padding: 0 !important;
}

.dxbl-popup-header-button {
    padding: 4px !important;
    width: 28px !important;
    height: 28px !important;
}

@media (max-width: 1024px) {
    .dxbl-modal-dialog {
        width: 96vw !important;
        max-width: 96vw !important;
        min-width: 96vw !important;
        margin: auto !important;
    }
    /* Popup içindeki sabit genişlikleri override et */
    .dxbl-popup,
    .dxbl-popup[style] {
        width: 100% !important;
        max-width: 100% !important;
    }
    .dxbl-modal-content {
        max-width: 100% !important;
        width: 100% !important;
    }
    .dxbl-modal-body {
        padding: 4px !important;
        overflow-x: auto !important;
    }
    /* ids- kartları popup içinde taşmasın */
    .ids-container {
        max-width: 100%;
        overflow: visible;
    }
    .ids-header {
        margin: 8px !important;
        padding: 12px !important;
        gap: 8px !important;
    }
    .ids-list {
        padding: 0 8px 8px !important;
    }
    .ids-card-body {
        padding: 10px !important;
    }
    .ids-field {
        padding: 5px 8px !important;
    }
    .ids-field-label {
        font-size: 11px !important;
    }
    .ids-field-value {
        font-size: 12px !important;
    }
}

/* Küçük mobil ekranlar — ids kartları dikey düzen */
@media (max-width: 500px) {
    .ids-header {
        margin: 6px !important;
        padding: 10px !important;
        gap: 6px !important;
        flex-direction: column;
        align-items: flex-start;
    }
    .ids-header-icon {
        width: 32px !important;
        height: 32px !important;
        font-size: 16px !important;
    }
    .ids-header-title {
        font-size: 13px !important;
    }
    .ids-header-sub {
        font-size: 10px !important;
    }
    .ids-header-count {
        font-size: 10px !important;
        padding: 2px 8px !important;
    }
    .ids-list {
        padding: 0 6px 6px !important;
        gap: 6px !important;
    }
    .ids-card-body {
        padding: 8px !important;
    }
    .ids-card-top {
        flex-direction: column !important;
        gap: 4px !important;
        margin-bottom: 8px !important;
    }
    .ids-code {
        font-size: 10px !important;
    }
    .ids-name {
        font-size: 12px !important;
    }
    .ids-badge {
        font-size: 10px !important;
        padding: 2px 6px !important;
    }
    /* Alanları dikey yap — label üst, değer alt */
    .ids-field {
        flex-direction: column !important;
        align-items: flex-start !important;
        padding: 4px 8px !important;
        gap: 1px !important;
    }
    .ids-field-label {
        font-size: 9px !important;
    }
    .ids-field-value {
        font-size: 13px !important;
        text-align: left !important;
    }
    .ids-progress-wrap {
        gap: 6px !important;
    }
    .ids-progress-text {
        font-size: 10px !important;
        min-width: 24px !important;
    }
}

/* ══════════════════════════════════════════════
   InventoryDeliveryStatusPopup — Global CSS
   (Popup DOM dışında render olduğu için scoped CSS çalışmaz)
   ══════════════════════════════════════════════ */
/* ══════════════════════════════════════════════
   InventoryDeliveryStatusPopup — Responsive CSS
   ══════════════════════════════════════════════ */
.ids-container {
    font-family: 'Segoe UI', system-ui, sans-serif;
    padding: 0;
}

/* HEADER */
.ids-header {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 14px 16px;
    background: linear-gradient(135deg, #0891b2 0%, #06b6d4 100%);
    border-radius: 12px;
    margin: 14px 14px 10px;
    color: #fff;
    box-shadow: 0 4px 16px rgba(8,145,178,.2);
    flex-wrap: wrap;
}

.ids-header-icon {
    width: 40px;
    height: 40px;
    background: rgba(255,255,255,.2);
    border-radius: 9px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 18px;
    flex-shrink: 0;
}

.ids-header-title {
    font-size: 15px;
    font-weight: 700;
}

.ids-header-sub {
    font-size: 11px;
    color: rgba(255,255,255,.75);
    margin-top: 2px;
}

.ids-header-count {
    margin-left: auto;
    background: rgba(255,255,255,.2);
    padding: 3px 10px;
    border-radius: 20px;
    font-size: 11px;
    font-weight: 600;
    white-space: nowrap;
}

/* LIST */
.ids-list {
    max-height: 65vh;
    overflow-y: auto;
    padding: 0 14px 14px;
    display: flex;
    flex-direction: column;
    gap: 8px;
}

/* CARD */
.ids-card {
    background: #fff;
    border: 1px solid #e2e8f0;
    border-radius: 11px;
    overflow: visible;
    box-shadow: 0 1px 3px rgba(0,0,0,.05);
}

.ids-card-strip {
    height: 3px;
    width: 100%;
}

    .ids-card-strip.strip-success {
        background: #10b981;
    }

    .ids-card-strip.strip-warning {
        background: #f59e0b;
    }

    .ids-card-strip.strip-default {
        background: #94a3b8;
    }

    .ids-card-strip.strip-danger {
        background: #ef4444;
    }

.ids-card-body {
    padding: 12px 14px;
}

/* CARD TOP — badge alta düşsün dar ekranda */
.ids-card-top {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 8px;
    flex-wrap: wrap;
    margin-bottom: 10px;
}

.ids-card-info {
    display: flex;
    flex-direction: column;
    gap: 2px;
    min-width: 0;
    flex: 1 1 60%;
}

.ids-code {
    font-family: 'Cascadia Code','Consolas',monospace;
    font-size: 11px;
    font-weight: 600;
    color: #0e7490;
    background: #ecfeff;
    padding: 2px 7px;
    border-radius: 4px;
    display: inline-block;
    width: fit-content;
}

.ids-name {
    font-size: 13px;
    font-weight: 600;
    color: #0f172a;
    line-height: 1.3;
    word-break: break-word;
}

/* BADGE */
.ids-badge {
    display: inline-flex;
    align-items: center;
    gap: 3px;
    padding: 3px 9px;
    border-radius: 20px;
    font-size: 11px;
    font-weight: 600;
    white-space: nowrap;
    flex-shrink: 0;
    align-self: flex-start;
}

.ids-badge-success {
    background: #d1fae5;
    color: #065f46;
}

.ids-badge-warning {
    background: #fef3c7;
    color: #92400e;
}

.ids-badge-default {
    background: #f1f5f9;
    color: #475569;
}

.ids-badge-danger {
    background: #fee2e2;
    color: #991b1b;
}

/* FIELDS */
.ids-fields {
    display: flex;
    flex-direction: column;
    margin-bottom: 9px;
    border: 1px solid #e2e8f0;
    border-radius: 8px;
    overflow: visible;
}

.ids-field {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 6px 10px;
    border-bottom: 1px solid #f1f5f9;
    gap: 6px;
}

    .ids-field:last-child {
        border-bottom: none;
    }

.ids-field-label {
    font-size: 11.5px;
    font-weight: 600;
    color: #64748b;
    white-space: nowrap;
    flex-shrink: 0;
}

.ids-field-value {
    font-size: 12.5px;
    font-weight: 700;
    color: #0f172a;
    text-align: right;
    white-space: nowrap;
}

.ids-val-success {
    color: #059669 !important;
}

.ids-val-warning {
    color: #d97706 !important;
}

.ids-val-default {
    color: #64748b !important;
}

.ids-val-danger {
    color: #ef4444 !important;
}

/* PROGRESS */
.ids-progress-wrap {
    display: flex;
    align-items: center;
    gap: 8px;
}

.ids-progress-bar {
    flex: 1;
    height: 5px;
    background: #e2e8f0;
    border-radius: 3px;
    overflow: hidden;
    min-width: 0;
}

.ids-progress-fill {
    height: 100%;
    border-radius: 3px;
    transition: width .4s ease;
}

    .ids-progress-fill.fill-success {
        background: #10b981;
    }

    .ids-progress-fill.fill-warning {
        background: #f59e0b;
    }

    .ids-progress-fill.fill-default {
        background: #94a3b8;
    }

.ids-progress-text {
    font-size: 11px;
    font-weight: 700;
    color: #64748b;
    min-width: 30px;
    text-align: right;
    flex-shrink: 0;
}

/* EMPTY */
.ids-empty {
    text-align: center;
    padding: 40px 16px;
    color: #64748b;
}

.ids-empty-icon {
    font-size: 36px;
    margin-bottom: 10px;
}

.ids-empty-title {
    font-size: 14px;
    font-weight: 600;
    color: #334155;
    margin-bottom: 4px;
}

.ids-empty-sub {
    font-size: 12px;
    color: #94a3b8;
}

/* ── RESPONSIVE ── */
@media (min-width: 600px) {
    /* Tablet/PC: biraz daha geniş padding */
    .ids-header {
        padding: 16px 20px;
        margin: 16px 16px 12px;
    }

    .ids-header-title {
        font-size: 16px;
    }

    .ids-header-icon {
        width: 44px;
        height: 44px;
        font-size: 20px;
    }

    .ids-card-body {
        padding: 14px 16px;
    }

    .ids-field {
        padding: 7px 12px;
    }

    .ids-field-label {
        font-size: 12px;
    }

    .ids-field-value {
        font-size: 13px;
    }

    .ids-name {
        font-size: 13.5px;
    }

    .ids-code {
        font-size: 12px;
    }

    .ids-progress-text {
        font-size: 11px;
    }
}

@media (max-width: 360px) {
    /* Çok küçük mobil */
    .ids-header {
        gap: 8px;
        padding: 12px 10px;
        margin: 10px 10px 8px;
    }

    .ids-list {
        padding: 0 10px 10px;
        gap: 7px;
    }

    .ids-card-body {
        padding: 10px 11px;
    }

    .ids-field {
        padding: 5px 8px;
    }

    .ids-field-label {
        font-size: 10.5px;
    }

    .ids-field-value {
        font-size: 11.5px;
    }

    .ids-badge {
        font-size: 10px;
        padding: 2px 7px;
    }
}

/* ══════════════════════════════════════════════
   SupplierAssitUserPopup — Tedarikçi Listesi
   ══════════════════════════════════════════════ */
.sup-mobile-list {
    display: flex;
    flex-direction: column;
    gap: 6px;
    padding: 12px;
    max-height: 70vh;
    overflow-y: auto;
}

.sup-mobile-card {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 14px;
    background: #fff;
    border: 1px solid #e2e8f0;
    border-radius: 10px;
    cursor: pointer;
    transition: all .15s;
}

.sup-mobile-card:hover {
    border-color: #0891b2;
    background: #ecfeff;
    box-shadow: 0 2px 8px rgba(8, 145, 178, .1);
}

.sup-mobile-card:active {
    transform: scale(.98);
}

.sup-mobile-icon {
    width: 38px;
    height: 38px;
    background: #ecfeff;
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    color: #0891b2;
}

.sup-mobile-info {
    flex: 1;
    min-width: 0;
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.sup-mobile-name {
    font-size: 14px;
    font-weight: 600;
    color: #0f172a;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.sup-mobile-email {
    font-size: 12px;
    color: #64748b;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

/* ══════════════════════════════════════════════
   Teal Grid — Global Styling (SshWorkOrderList baz)
   ══════════════════════════════════════════════ */
.teal-grid .dxbl-grid {
    font-family: 'Segoe UI', system-ui, sans-serif;
    border: 1px solid #e2e8f0;
    border-radius: 0 0 10px 10px;
    overflow: hidden;
}

/* Başlık satırı — açık mint arka plan, koyu yazı */
.teal-grid .dxbl-grid-header-row th,
.teal-grid .dxbl-grid-header-row td,
.teal-grid th.dxbl-grid-header-cell,
.teal-grid .dxbl-grid-header-cell {
    background: #e0f2f1 !important;
    color: #1e293b !important;
    font-size: 12px;
    font-weight: 600 !important;
    letter-spacing: .2px;
    padding: 8px 10px;
    border-bottom: 2px solid #b2dfdb !important;
}

.teal-grid .dxbl-grid-header-cell * {
    color: #1e293b !important;
}

.teal-grid .dxbl-grid-header-cell svg {
    color: #64748b !important;
    fill: #64748b !important;
}

/* Hover — focused satır hariç */
.teal-grid .dxbl-grid-table tbody tr:not([class*="focused"]):not(.dxbl-focused):hover td {
    background: #f1f5f9 !important;
}

/* Hücre */
.teal-grid .dxbl-grid-table tbody td {
    font-size: 12.5px;
    padding: 6px 10px;
    border-bottom: 1px solid #f1f5f9;
}

/* Filtre satırı */
.teal-grid .dxbl-grid-filter-row td,
.teal-grid tr.dxbl-grid-filter-row td {
    background: #f0f5f4 !important;
    border-bottom: 1px solid #e2e8f0 !important;
}

.teal-grid .dxbl-grid-filter-row input {
    background: transparent !important;
    border: none !important;
    border-bottom: 1px solid #cbd5e1 !important;
    border-radius: 0 !important;
    font-size: 12px !important;
    color: #0f172a !important;
}

.teal-grid .dxbl-grid-filter-row input:focus {
    border-bottom-color: #0891b2 !important;
    box-shadow: none !important;
}


/* Pager */
.teal-grid .dxbl-pager {
    border-top: 1px solid #e2e8f0;
    padding: 6px;
}

/* ── FOCUSED ROW — tıklanan / FocusedRowEnabled satır ──
   DevExpress default focused row açık mavi/beyaz; teal teması için #0891b2 + beyaz yazı,
   yazıların ve badge'lerin rengini de override et — kontrast garanti. */
.teal-grid .dxbl-grid-table tbody tr[class*="focused"] > td,
.teal-grid .dxbl-grid-table tbody tr.dxbl-focused > td {
    background: #0891b2 !important;
    color: #fff !important;
    font-weight: 600 !important;
    opacity: 1 !important;
}

.teal-grid .dxbl-grid-table tbody tr[class*="focused"]:hover > td,
.teal-grid .dxbl-grid-table tbody tr.dxbl-focused:hover > td {
    background: #0e7490 !important;
    color: #fff !important;
    opacity: 1 !important;
}

/* Focused satır içindeki tüm child'lar (text, span, i, badge) beyaz */
.teal-grid .dxbl-grid-table tbody tr[class*="focused"] > td *:not(.dropdown-menu *):not(.dropdown-menu),
.teal-grid .dxbl-grid-table tbody tr.dxbl-focused > td *:not(.dropdown-menu *):not(.dropdown-menu) {
    color: #fff !important;
    opacity: 1 !important;
}

/* Focused + selected (multi-select varsa) */
.teal-grid .dxbl-grid-table tbody tr.dxbl-focused.dxbl-selected > td,
.teal-grid .dxbl-grid-table tbody tr[class*="focused"][class*="selected"] > td {
    background: #0891b2 !important;
    color: #fff !important;
    font-weight: 600 !important;
    opacity: 1 !important;
}

/* Sadece selected (focus yok) — daha açık ton */
.teal-grid .dxbl-grid-table tbody tr.dxbl-selected:not(.dxbl-focused):not([class*="focused"]) > td {
    background: #cffafe !important;
    color: #0f172a !important;
}

/* Focused satırın `> td *` beyaz yazı zorlaması rozetin kendi pastel arkaplanı
   üstünde okunmaz hale getiriyor; teal zemine yarı saydam beyaz pill ile bas. */
.teal-grid .dxbl-grid-table tbody tr.dxbl-focused > td .price-source-badge,
.teal-grid .dxbl-grid-table tbody tr[class*="focused"] > td .price-source-badge,
.teal-grid .dxbl-grid-table tbody tr.dxbl-focused > td .mp-badge,
.teal-grid .dxbl-grid-table tbody tr[class*="focused"] > td .mp-badge {
    background: rgba(255, 255, 255, 0.18) !important;
    border-color: rgba(255, 255, 255, 0.4) !important;
    color: #fff !important;
}
/* İptal sebebi notu — odaklı (teal) satırda diğer satırlarla aynı yumuşak kırmızı hap kalsın
   (beyaz zemin teal üstünde sırıtıyordu); ince beyaz kenarlık teal'den ayırır.
   .mp-status-cell ile özgüllük, "> td * beyaz yazı" kuralına (0,5,3) eşitlenip sonra geldiği için kazanır. */
.teal-grid .dxbl-grid-table tbody tr.dxbl-focused > td .mp-status-cell .mp-grid-note,
.teal-grid .dxbl-grid-table tbody tr[class*="focused"] > td .mp-status-cell .mp-grid-note {
    background: #fee2e2 !important;
    color: #991b1b !important;
    border-color: rgba(255,255,255,.75) !important;
}
.teal-grid .dxbl-grid-table tbody tr.dxbl-focused > td .mp-status-cell .mp-grid-note b,
.teal-grid .dxbl-grid-table tbody tr[class*="focused"] > td .mp-status-cell .mp-grid-note b {
    color: #7f1d1d !important;
}
/* Rozet içindeki ikon da beyaz kalsın (td * kuralıyla uyumlu) */
.teal-grid .dxbl-grid-table tbody tr.dxbl-focused > td .mp-badge .material-symbols-outlined,
.teal-grid .dxbl-grid-table tbody tr[class*="focused"] > td .mp-badge .material-symbols-outlined {
    color: #fff !important;
}

/* Servis/Tedarikçi sayı butonu (SshPartUsage `pu-count-btn`) — odaklı satırda "> td * beyaz yazı"
   kuralı açık buton zemininde okunmaz yapıyor. Metin rengiyle uğraşmak yerine butona KOYU zemin ver:
   beyaz yazı koyu teal zeminde okunur (arka plan kuralını tema değiştirmiyor). */
.teal-grid .dxbl-grid-table tbody tr.dxbl-focused > td .pu-count-btn,
.teal-grid .dxbl-grid-table tbody tr[class*="focused"] > td .pu-count-btn {
    background: #0f766e !important;
    border-color: rgba(255, 255, 255, 0.6) !important;
    color: #ffffff !important;
}

/* ── Eksik gönderim satırı (SshPartUsage `pu-row-pending`) ──
   Tema hover/base kuralları yüksek özgüllük + !important olduğundan burada aynı seviyede tanımlanır.
   Odaklı (seçili) satır hariç her eksik satır her zaman soft kırmızı; odaklı satır mavi kalır ama
   sol kırmızı bar (box-shadow) tüm eksik satırlarda görünür. */
.teal-grid .dxbl-grid-table tbody tr.pu-row-pending:not(.dxbl-focused):not([class*="focused"]):not(.dxbl-selected) > td {
    background: #f7edec !important;
}

.teal-grid .dxbl-grid-table tbody tr.pu-row-pending:not(.dxbl-focused):not([class*="focused"]):not(.dxbl-selected):hover > td {
    background: #efdad7 !important;
}

.teal-grid .dxbl-grid-table tbody tr.pu-row-pending > td:first-child {
    box-shadow: inset 4px 0 0 0 #9b2c2c !important;
}

.sup-mobile-select {
    flex-shrink: 0;
    color: #94a3b8;
    transition: color .15s;
}

.sup-mobile-card:hover .sup-mobile-select {
    color: #0891b2;
}

.sup-empty {
    text-align: center;
    padding: 40px 16px;
    color: #64748b;
    font-size: 14px;
}

/* ══════════════════════════════════════════════
   Depo Stok — Mobil Kart
   ══════════════════════════════════════════════ */
.stock-mobile-list {
    display: flex;
    flex-direction: column;
    gap: 8px;
    padding: 12px;
    max-height: 65vh;
    overflow-y: auto;
}

.stock-mobile-card {
    display: flex;
    flex-direction: column;
    gap: 4px;
    padding: 12px 14px;
    background: #fff;
    border: 1px solid #e2e8f0;
    border-radius: 10px;
}

.stock-mobile-top {
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.stock-mobile-code {
    font-family: 'Cascadia Code', 'Consolas', monospace;
    font-size: 12px;
    font-weight: 600;
    color: #0e7490;
    background: #ecfeff;
    padding: 2px 8px;
    border-radius: 5px;
}

.stock-mobile-qty {
    font-size: 15px;
    font-weight: 700;
    color: #0f172a;
}

.stock-mobile-name {
    font-size: 13px;
    color: #334155;
    font-weight: 500;
}

/* ══════════════════════════════════════════════
   Popup Teal Header — Paylaşımlı stil
   ══════════════════════════════════════════════ */
.popup-teal-header {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 14px 16px;
    background: linear-gradient(135deg, #0891b2 0%, #06b6d4 100%);
    border-radius: 12px;
    margin: 12px 12px 10px;
    color: #fff;
    box-shadow: 0 4px 16px rgba(8, 145, 178, .2);
    flex-wrap: wrap;
}

.popup-teal-icon {
    width: 40px;
    height: 40px;
    background: rgba(255, 255, 255, .2);
    border-radius: 9px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 18px;
    flex-shrink: 0;
    color: #fff;
}

.popup-teal-title {
    font-size: 15px;
    font-weight: 700;
}

.popup-teal-sub {
    font-size: 11px;
    color: rgba(255, 255, 255, .75);
    margin-top: 1px;
}

.popup-teal-count {
    margin-left: auto;
    background: rgba(255, 255, 255, .2);
    padding: 3px 10px;
    border-radius: 20px;
    font-size: 11px;
    font-weight: 600;
    white-space: nowrap;
}

@media (max-width: 480px) {
    .popup-teal-header {
        margin: 8px;
        padding: 10px 12px;
        gap: 8px;
    }
    .popup-teal-icon {
        width: 32px;
        height: 32px;
        font-size: 14px;
    }
    .popup-teal-title {
        font-size: 13px;
    }
    .popup-teal-count {
        font-size: 10px;
    }
}

/* ══════════════════════════════════════════════
   Grid Sepet Butonu — Paylaşımlı (popup + sayfa)
   ══════════════════════════════════════════════ */
.grid-cart-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 4px;
    background: #ecfeff;
    border: 1.5px solid rgba(8, 145, 178, .2);
    color: #0891b2;
    border-radius: 8px;
    padding: 5px 10px;
    cursor: pointer;
    font-size: 14px;
    font-family: 'Segoe UI', system-ui, sans-serif;
    transition: background .15s, color .15s;
}

.grid-cart-btn:hover {
    background: #0891b2;
    color: #fff;
}



/* ── NewSshWorkOrderPage edit popup styles (global çünkü DxGrid popup dialog'u component scope'u dışında render eder) ── */
.dxbl-modal-dialog:has(.nw-edit-popup) {
    min-width: 680px !important;
    max-width: 920px !important;
    width: auto !important;
}

.nw-edit-popup {
    padding: 0 !important;
}

.nw-edit-popup .dxbl-grid-edit-form-content {
    padding: 20px 24px !important;
    background: #fff;
}

.nw-edit-popup .dxbl-form-layout-item-label {
    font-size: .8rem !important;
    font-weight: 500 !important;
    color: #475569 !important;
    padding-bottom: 6px !important;
}

.nw-edit-popup .dxbl-form-layout-item {
    margin-bottom: 12px !important;
}

.nw-edit-popup .dxbl-edit-form-footer {
    border-top: 1px solid #e2e8f0;
    padding: 14px 24px !important;
    background: #fafbfc;
    display: flex;
    justify-content: flex-end;
    gap: 10px;
}

.nw-edit-popup .dxbl-btn-secondary {
    background: #fff !important;
    color: #64748b !important;
    border: 1px solid #cbd5e1 !important;
}

.nw-edit-popup .dxbl-btn-primary {
    background: linear-gradient(135deg, #0891b2 0%, #06b6d4 100%) !important;
    border: none !important;
    box-shadow: 0 2px 8px rgba(8, 145, 178, .25);
}

@media (max-width: 768px) {
    .dxbl-modal-dialog:has(.nw-edit-popup) {
        min-width: 95vw !important;
        max-width: 95vw !important;
    }
}


/* ── Edit popup — default DevExpress header gizle (bizim b2b-themed-header onu replace ediyor) ── */
.nw-edit-popup .dxbl-modal-header,
.nw-edit-popup .dxbl-popup-header,
.nw-edit-popup > div[class*="popup-header"]:first-child {
    display: none !important;
}

.nw-edit-popup .dxbl-modal-body,
.nw-edit-popup .dxbl-popup-body {
    padding: 0 !important;
}

/* nw-form-wrapper zaten padding içeriyor — form alanları için */
.nw-form-wrapper {
    padding: 20px 24px;
    background: #fff;
}

/* Seçilen malzeme özet kartı (readonly değer) */
.nw-selected-inventory {
    display: flex;
    flex-direction: column;
    gap: 8px;
    margin-bottom: 16px;
    padding: 14px 16px;
    background: linear-gradient(135deg, #ecfeff 0%, #f0fdfa 100%);
    border: 1px solid #cffafe;
    border-radius: 8px;
}

.nw-selected-row {
    display: grid;
    grid-template-columns: 140px 1fr;
    gap: 12px;
    align-items: center;
}

.nw-selected-label {
    font-size: .7rem;
    color: #64748b;
    text-transform: uppercase;
    letter-spacing: .6px;
    font-weight: 600;
}

.nw-selected-row strong {
    color: #0f172a;
    font-size: .92rem;
    font-weight: 600;
}

/* Readonly miktar/fiyat label stili — inputa benzer ama disabled değil */
.nw-readonly-value {
    display: flex;
    flex-direction: column;
    gap: 2px;
    padding: 8px 12px;
    background: #f8fafc;
    border: 1px solid #e2e8f0;
    border-radius: 6px;
    min-height: 36px;
    justify-content: center;
}

.nw-readonly-value span {
    font-size: .95rem;
    font-weight: 600;
    color: #0f172a;
    font-variant-numeric: tabular-nums;
}

.nw-readonly-value small {
    font-size: .7rem;
    color: #94a3b8;
}

/* ── Edit popup + b2b-themed-header mobil responsive ── */
@media (max-width: 768px) {
    .dxbl-modal-dialog:has(.nw-edit-popup) {
        min-width: 95vw !important;
        max-width: 95vw !important;
        width: 95vw !important;
        margin: 10px auto !important;
    }

    .nw-edit-popup .dxbl-grid-edit-form-content {
        padding: 14px 16px !important;
    }

    .nw-form-wrapper {
        padding: 14px 16px !important;
    }

    .nw-edit-popup .dxbl-edit-form-footer {
        padding: 10px 14px !important;
        flex-direction: row !important;
        justify-content: stretch !important;
    }

    .nw-edit-popup .dxbl-edit-form-footer .dxbl-btn {
        flex: 1;
    }

    /* b2b-themed-header mobilde daha kompakt */
    .b2b-themed-header {
        padding: 10px 14px !important;
    }

    .b2b-themed-header .bh-icon {
        width: 32px !important;
        height: 32px !important;
        font-size: 15px !important;
    }

    .b2b-themed-header .bh-title {
        font-size: 13.5px !important;
    }

    .b2b-themed-header .bh-sub {
        font-size: 10.5px !important;
    }

    /* nw-selected-inventory mobilde tek kolon */
    .nw-selected-row {
        grid-template-columns: 1fr !important;
        gap: 2px !important;
    }
}

/* ── Edit popup footer butonları ── */
.nw-edit-footer {
    display: flex;
    justify-content: flex-end;
    align-items: center;
    gap: 10px;
    padding: 14px 20px 4px 20px;
    margin-top: 12px;
    border-top: 1px solid #e2e8f0;
}

.nw-edit-btn {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 9px 18px;
    border-radius: 8px;
    font-weight: 600;
    font-size: .85rem;
    border: 1px solid transparent;
    cursor: pointer;
    transition: all .15s;
    font-family: inherit;
}

.nw-edit-btn-cancel {
    background: #fff;
    color: #64748b;
    border-color: #cbd5e1;
}

.nw-edit-btn-cancel:hover {
    background: #f1f5f9;
    border-color: #94a3b8;
}

.nw-edit-btn-save {
    background: linear-gradient(135deg, #0891b2 0%, #06b6d4 100%);
    color: #fff;
    border: none;
    box-shadow: 0 2px 6px rgba(8, 145, 178, .3);
}

.nw-edit-btn-save:hover {
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(8, 145, 178, .4);
}

@media (max-width: 640px) {
    .nw-edit-footer {
        padding: 12px 14px;
    }
    .nw-edit-btn {
        flex: 1;
        justify-content: center;
        padding: 10px 14px;
    }
}

/* "Satır Yönetim Kaydı" (SupplierShipmentResultPopup), "İşlenen Kayıtlar" popup'ının (z-index:1200)
   ÜSTÜNDE açılsın — İşlenen Kayıtlar açık kalır, düzenleme penceresi önde görünür. */
.ssr-ontop,
.dxbl-modal:has(.ssr-ontop),
.dxbl-popup-root:has(.ssr-ontop) {
    z-index: 1300 !important;
}

/* "Satır Yönetim Kaydı" popup başlığı sürükleme tutamağı (custom JS drag) */
.ssr-header { cursor: grab; }
.ssr-header:active { cursor: grabbing; }
