/* Ortak ERP liste / form sayfaları — mobile-first (StokListesi ile aynı dil) */

/* ——————————————————————————————————————
   ERP Sub-bar: Sayfa içi kompakt başlık şeridi
   Kullanım: <div class="erp-subbar">
               <a class="erp-subbar__back" href="..."><i class="bi bi-arrow-left"></i></a>
               <span class="erp-subbar__icon"><i class="bi bi-..."></i></span>
               <span class="erp-subbar__title">Sayfa Adı</span>
             </div>
   —————————————————————————————————————— */
.erp-subbar {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.45rem 0.1rem;
    margin-bottom: 0.55rem;
    min-height: 44px;
}

.erp-subbar__back {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 34px;
    height: 34px;
    border-radius: 10px;
    background: #fff;
    border: 1px solid rgba(15, 39, 68, 0.1);
    color: #0f2744;
    font-size: 0.95rem;
    text-decoration: none;
    flex-shrink: 0;
    box-shadow: 0 1px 2px rgba(15,39,68,0.05);
    transition: background 0.15s, border-color 0.15s;
    -webkit-tap-highlight-color: transparent;
}

.erp-subbar__back:hover,
.erp-subbar__back:active {
    background: #eff6ff;
    border-color: rgba(30,58,138,0.2);
    color: #1e3a8a;
}

.erp-subbar__icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 30px;
    height: 30px;
    border-radius: 8px;
    background: #eff6ff;
    color: #1e3a8a;
    font-size: 0.9rem;
    flex-shrink: 0;
}

.erp-subbar__title {
    font-size: 0.92rem;
    font-weight: 700;
    color: #0f2744;
    letter-spacing: -0.01em;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    flex: 1;
    min-width: 0;
    font-family: "Plus Jakarta Sans", Inter, system-ui, sans-serif;
}

.erp-subbar__sub {
    font-size: 0.65rem;
    font-weight: 500;
    color: #64748b;
    margin-left: auto;
    white-space: nowrap;
    flex-shrink: 0;
}

/* card-header içindeki eski page-back + başlık kombinasyonunu düzenle */
.card-header .page-back {
    display: inline-flex;
    align-items: center;
    gap: 0.3rem;
    padding: 0.28rem 0.65rem;
    border-radius: 8px;
    background: rgba(15,39,68,0.05);
    border: 1px solid rgba(15,39,68,0.08);
    color: #475569;
    font-size: 0.72rem;
    font-weight: 600;
    text-decoration: none;
    min-height: 32px;
    transition: background 0.15s;
    -webkit-tap-highlight-color: transparent;
}
.card-header .page-back:hover { background: #eff6ff; color: #1e3a8a; border-color: rgba(30,58,138,0.18); }



.home-app,
.erp-page-cari.home-app,
.erp-page-stok.home-app {
    --home-ink: #0f2744;
    --home-muted: #5b6b7c;
    --home-surface: rgba(255, 255, 255, 0.92);
    --home-line: rgba(15, 39, 68, 0.08);
    font-family: "Plus Jakarta Sans", Inter, system-ui, sans-serif;
}

.erp-page-cari__inner,
.app-page__inner {
    max-width: 100%;
    margin: 0 auto;
    display: flex;
    flex-direction: column;
    gap: 0.35rem;
}

.erp-list-hero {
    padding: 0.2rem 0.05rem 0.1rem;
}

.erp-list-hero__back {
    display: inline-flex;
    align-items: center;
    gap: 0.3rem;
    margin-bottom: 0.45rem;
    padding: 0.28rem 0.55rem;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.85);
    border: 1px solid var(--home-line, rgba(15, 39, 68, 0.08));
    color: var(--home-muted, #5b6b7c) !important;
    text-decoration: none !important;
    font-size: 0.68rem;
    font-weight: 600;
    min-height: 36px;
    box-shadow: 0 1px 2px rgba(15, 39, 68, 0.04);
}

.erp-list-hero__back:hover {
    color: #0f2744 !important;
    border-color: rgba(30, 58, 138, 0.22);
}

.erp-list-hero__row {
    display: flex;
    align-items: center;
    gap: 0.55rem;
}

.erp-list-hero__icon {
    width: 2.25rem;
    height: 2.25rem;
    border-radius: 0.65rem;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    background: #ecfeff;
    color: #0e7490;
    font-size: 1rem;
    border: 1px solid rgba(14, 116, 144, 0.12);
    box-shadow: 0 1px 2px rgba(15, 39, 68, 0.04);
}

.erp-list-hero__icon--cari {
    background: #eff6ff;
    color: #1d4ed8;
    border-color: rgba(29, 78, 216, 0.12);
}

.erp-list-hero__icon--fatura {
    background: #f0fdf4;
    color: #15803d;
    border-color: rgba(21, 128, 61, 0.12);
}

.erp-list-hero__icon--rapor {
    background: #faf5ff;
    color: #7e22ce;
    border-color: rgba(126, 34, 206, 0.12);
}

.erp-list-hero__title {
    margin: 0;
    font-size: clamp(1.05rem, 4.2vw, 1.35rem);
    font-weight: 800;
    letter-spacing: -0.03em;
    color: var(--home-ink, #0f2744);
    line-height: 1.2;
}

.erp-list-hero__sub {
    margin: 0.15rem 0 0;
    font-size: 0.72rem;
    font-weight: 500;
    color: var(--home-muted, #5b6b7c);
    line-height: 1.35;
}

/* Kart sarmalayıcı yerine düz sayfa yüzeyi (home-app sayfalarında) */
.app-page.home-app > .card.fade-in,
.app-page.home-app > .card {
    border: 0;
    border-radius: 0;
    box-shadow: none;
    background: transparent;
    margin-bottom: 0;
}

.app-page.home-app > .card > .card-header {
    display: none;
}

.app-page.home-app > .card > .card-body {
    padding: 0;
}

.page-back {
    display: none;
}

/* Cari listesi */
.erp-page-cari .erp-card-grid {
    margin: 0;
    --bs-gutter-x: 0.45rem;
    --bs-gutter-y: 0.45rem;
}

.erp-page-cari .erp-cari-card {
    border: 1px solid var(--home-line, #e2e8f0);
    border-radius: 0.85rem;
    background: #fff;
    height: 100%;
    display: flex;
    flex-direction: column;
    box-shadow: 0 1px 1px rgba(15, 39, 68, 0.04);
}

.erp-page-cari .erp-cari-card__top {
    padding: 0.6rem 0.65rem 0.35rem;
}

.erp-page-cari .erp-cari-card__kod {
    font-size: 0.62rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    color: #64748b;
}

.erp-page-cari .erp-cari-card__unvan {
    font-weight: 600;
    font-size: 0.82rem;
    color: #0f172a;
    line-height: 1.35;
    margin: 0.2rem 0 0;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.erp-page-cari .erp-cari-card__body {
    padding: 0.2rem 0.65rem 0.4rem;
    flex: 1;
    font-size: 0.72rem;
    color: #475569;
}

.erp-page-cari .erp-cari-card__row {
    display: flex;
    justify-content: space-between;
    gap: 0.4rem;
    padding: 0.15rem 0;
    border-bottom: 1px solid #f1f5f9;
}

.erp-page-cari .erp-cari-card__row:last-child {
    border-bottom: none;
}

.erp-page-cari .erp-cari-card__lbl {
    color: #94a3b8;
    font-size: 0.65rem;
}

.erp-page-cari .erp-cari-card__foot {
    padding: 0 0.65rem 0.55rem;
}

.erp-page-cari .erp-cari-card__foot .btn {
    min-height: 40px;
    font-size: 0.68rem;
    border-radius: 0.55rem;
}

.erp-page-cari .badge-status-aktif {
    background: #dcfce7;
    color: #166534;
    font-weight: 600;
    font-size: 0.62rem;
}

.erp-page-cari .badge-status-pasif {
    background: #f1f5f9;
    color: #64748b;
    font-weight: 600;
    font-size: 0.62rem;
}

.erp-page-cari .cari-edit-panel {
    background: #fff;
    border: 1px solid var(--home-line);
    border-radius: 0.85rem;
    padding: 0.75rem 0.8rem;
    box-shadow: 0 1px 2px rgba(15, 39, 68, 0.04);
}

.erp-page-cari .cari-edit-panel h6 {
    font-size: 0.62rem;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    color: #64748b;
    margin-top: 0.85rem;
    margin-bottom: 0.4rem;
    padding-bottom: 0.3rem;
    border-bottom: 1px solid #f1f5f9;
}

.erp-page-cari .cari-edit-panel h6:first-of-type {
    margin-top: 0;
}

.erp-page-cari .erp-cari-filtre {
    border: 1px solid var(--home-line);
    border-radius: 0.75rem;
    background: #f7f8fa;
    padding: 0.55rem 0.65rem 0.65rem;
}

.erp-page-cari .erp-cari-filtre__bar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.5rem;
    flex-wrap: wrap;
    margin-bottom: 0.45rem;
    padding-bottom: 0.4rem;
    border-bottom: 1px solid #e8eaed;
}

.erp-page-cari .erp-cari-filtre__title {
    font-size: 0.62rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.07em;
    color: #3d4550;
    margin: 0;
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
}

.erp-page-cari .erp-cari-filtre__title i {
    font-size: 0.85rem;
    color: #5c6570;
}

.erp-page-cari .erp-cari-filtre .form-check-label {
    font-size: 0.75rem;
    color: #3d4550;
    font-weight: 500;
}

.erp-page-cari .erp-cari-search {
    border: 1px solid var(--home-line);
    border-radius: 0.75rem;
    background: #fff;
    padding: 0.6rem 0.65rem;
}

.erp-page-cari .erp-stok-empty,
.erp-page-cari .text-center.text-muted.py-5 {
    padding: 1.5rem 0.75rem !important;
    border-radius: 0.75rem !important;
    font-size: 0.75rem;
}
