/* MuhasebeJet - ortak bileşenler (dashboard tasarım dili) */
:root {
    --mj-muted: #64748b;
    --mj-line: #f1f5f9;
    --mj-giris: #4f46e5;
    --mj-cikis: #eb6834;
}

/* ---------- Sayfa başlığı ---------- */
.mj-content .breadcrumb {
    font-size: 0.78rem !important;
    margin-bottom: 6px;
}

.mj-content h2 {
    font-size: 1.5rem;
    font-weight: 650;
    letter-spacing: -0.025em;
    margin-bottom: 4px;
}

.mj-content h2 > i:first-child { display: none; }

.page-hero { display: flex; flex-wrap: wrap; align-items: flex-end; justify-content: space-between; gap: 16px; margin-bottom: 24px; }
.page-hero h2 { margin: 0 0 4px; }
.page-sub { color: var(--mj-muted); font-size: 0.875rem; }
.page-actions { display: flex; flex-wrap: wrap; gap: 8px; }

/* ---------- Kartlar ---------- */
.card-header {
    padding: 16px 20px;
}

.card-header h5, .card-header h6, .card-header .card-title {
    font-size: 0.95rem;
    font-weight: 650;
    letter-spacing: -0.01em;
    margin: 0;
}

.card-header .sub { font-size: 0.75rem; color: var(--mj-muted); font-weight: 400; margin-top: 2px; }

.card-body { padding: 20px; }

.card-footer {
    background: #fff;
    border-top: 1px solid var(--mj-line);
    padding: 12px 20px;
}

.card-footer:last-child { border-radius: 0 0 14px 14px; }

/* Düz renkli istatistik kartları -> beyaz KPI kartı */
.card.bg-primary, .card.bg-success, .card.bg-warning, .card.bg-info, .card.bg-danger, .card.bg-secondary, .card.bg-dark {
    background: #fff !important;
    color: #0f172a !important;
}

.card.bg-primary .text-white, .card.bg-success .text-white, .card.bg-warning .text-white,
.card.bg-info .text-white, .card.bg-danger .text-white, .card.bg-secondary .text-white, .card.bg-dark .text-white,
.card.text-white h1, .card.text-white h2, .card.text-white h3, .card.text-white h4, .card.text-white h5, .card.text-white h6,
.card.text-white p, .card.text-white small, .card.text-white div {
    color: inherit !important;
}

.card.text-white h3, .card.text-white .h3, .card.text-white h4 {
    font-weight: 650;
    letter-spacing: -0.025em;
    font-variant-numeric: tabular-nums;
}

.card.text-white p, .card.text-white small, .card.text-white .small { color: var(--mj-muted) !important; }

.card.bg-primary i.fa-2x, .card.bg-success i.fa-2x, .card.bg-warning i.fa-2x, .card.bg-info i.fa-2x,
.card.bg-danger i.fa-2x, .card.bg-secondary i.fa-2x, .card.bg-dark i.fa-2x,
.card.bg-primary i.fa-3x, .card.bg-success i.fa-3x, .card.bg-warning i.fa-3x, .card.bg-info i.fa-3x,
.card.bg-danger i.fa-3x, .card.bg-secondary i.fa-3x, .card.bg-dark i.fa-3x {
    font-size: 1rem;
    width: 40px;
    height: 40px;
    border-radius: 10px;
    display: inline-grid;
    place-items: center;
    background: #eef2ff;
    color: #4f46e5 !important;
    opacity: 1 !important;
}

/* Sol kenarlıklı renkli kartlar -> sade */
.card.border-start.border-4 { border-left-width: 1px !important; border-color: #e6e8f0 !important; }

/* ---------- Tablolar ---------- */
.table {
    border-color: var(--mj-line);
    margin-bottom: 0;
}

.table > :not(caption) > * > * { padding: 0.7rem 0.75rem; }
.table > tbody > tr > td { vertical-align: middle; color: #334155; }
.table > tbody > tr > td strong, .table > tbody > tr > td b { color: #0f172a; font-weight: 600; }
.table > thead > tr > th { border-bottom: 1px solid #e6e8f0; white-space: nowrap; }
.table thead.table-light, .table thead.table-light th, .table thead.table-dark th, .table thead.table-primary th {
    background-color: #f8fafc !important;
    color: #64748b !important;
    border-color: #e6e8f0;
}
.table > tbody > tr:last-child > td { border-bottom: 0; }
.table-striped > tbody > tr:nth-of-type(odd) > * { background-color: #fbfcfe; }

.card > .table-responsive > .table > :not(caption) > * > *:first-child,
.card-body.p-0 > .table-responsive > .table > :not(caption) > * > *:first-child,
.card > .table > :not(caption) > * > *:first-child,
.card-body.p-0 > .table > :not(caption) > * > *:first-child { padding-left: 20px; }

.card > .table-responsive > .table > :not(caption) > * > *:last-child,
.card-body.p-0 > .table-responsive > .table > :not(caption) > * > *:last-child,
.card > .table > :not(caption) > * > *:last-child,
.card-body.p-0 > .table > :not(caption) > * > *:last-child { padding-right: 20px; }

.table .btn-group-sm > .btn, .table .btn-sm { padding: 0.25rem 0.5rem; }

tfoot td, tfoot th { background: #f8fafc; font-weight: 600; color: #0f172a; }

/* ---------- Formlar ---------- */
.input-group-text { background: #f8fafc; border-color: #dbe0ea; color: var(--mj-muted); }
.form-control::placeholder { color: #94a3b8; }
.form-text, .form-control + small.text-muted { font-size: 0.75rem; }

/* ---------- Modal ---------- */
.modal-content { border: 1px solid #e6e8f0; border-radius: 16px; box-shadow: 0 24px 60px -12px rgba(15, 23, 42, 0.3); }
.modal-header { padding: 18px 20px; border-bottom: 1px solid var(--mj-line); }
.modal-header[class*="bg-"] { background: #fff !important; color: #0f172a !important; }
.modal-header[class*="bg-"] .modal-title, .modal-header.text-white .modal-title { color: #0f172a !important; }
.modal-header[class*="bg-"] .btn-close-white { filter: none; }
.modal-title { font-size: 1rem; font-weight: 650; }
.modal-body { padding: 20px; }
.modal-footer { padding: 14px 20px; border-top: 1px solid var(--mj-line); }

/* ---------- Sekmeler ---------- */
.nav-tabs { border-bottom: 1px solid #e6e8f0; gap: 4px; }
.nav-tabs .nav-link { border: 0; border-bottom: 2px solid transparent; border-radius: 0; padding: 10px 14px; font-weight: 500; font-size: 0.875rem; }
.nav-tabs .nav-link:hover { border-bottom-color: #cbd5e1; }
.nav-tabs .nav-link.active { border-bottom-color: #4f46e5; background: transparent; }

/* ---------- KPI kartları ---------- */
.kpi { height: 100%; padding: 20px; display: flex; flex-direction: column; gap: 6px; }
.kpi-label { display: flex; align-items: center; gap: 8px; font-size: .8rem; font-weight: 500; color: var(--mj-muted); }
.kpi-icon { width: 30px; height: 30px; border-radius: 8px; display: grid; place-items: center; background: #eef2ff; color: #4f46e5; font-size: .8rem; }
.kpi-value { font-size: 1.6rem; font-weight: 650; letter-spacing: -.025em; color: #0f172a; font-variant-numeric: tabular-nums; line-height: 1.2; }
.kpi-value small { font-size: .9rem; font-weight: 500; color: var(--mj-muted); margin-left: 2px; }
.kpi-foot { margin-top: auto; padding-top: 8px; font-size: .78rem; color: var(--mj-muted); }
.kpi-foot a { color: #4f46e5; text-decoration: none; font-weight: 500; }
.kpi-foot a:hover { text-decoration: underline; }

.delta { display: inline-flex; align-items: center; gap: 4px; padding: 2px 8px; border-radius: 999px; font-size: .72rem; font-weight: 600; }
.delta.up { background: #f0fdf4; color: #15803d; }
.delta.down { background: #fef2f2; color: #b91c1c; }
.delta.flat { background: #f1f5f9; color: #475569; }

.split { display: flex; height: 6px; gap: 2px; border-radius: 999px; overflow: hidden; background: #f1f5f9; margin: 6px 0 2px; }
.split span { display: block; height: 100%; }
.split-legend { display: flex; justify-content: space-between; gap: 8px; font-size: .75rem; color: var(--mj-muted); }
.split-legend b { color: #334155; font-weight: 600; font-variant-numeric: tabular-nums; }
.dot { display: inline-block; width: 8px; height: 8px; border-radius: 2px; margin-right: 6px; vertical-align: 0; }

/* ---------- Kart başlığı (başlık + alt yazı + aksiyon) ---------- */
.dash-card .card-header { display: flex; align-items: center; justify-content: space-between; gap: 12px; }

/* ---------- Liste satırları ---------- */
.list-row { display: flex; align-items: center; gap: 12px; padding: 12px 20px; border-bottom: 1px solid var(--mj-line); color: inherit; text-decoration: none; transition: background-color .15s; }
.list-row:last-child { border-bottom: 0; }
a.list-row:hover { background: #f8fafc; color: inherit; }
.list-avatar { width: 36px; height: 36px; border-radius: 10px; background: #f1f5f9; color: #475569; display: grid; place-items: center; font-size: .8rem; font-weight: 700; flex-shrink: 0; text-transform: uppercase; }
.list-main { min-width: 0; flex: 1; }
.list-title { font-size: .85rem; font-weight: 600; color: #0f172a; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.list-meta { font-size: .75rem; color: var(--mj-muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.list-end { text-align: right; flex-shrink: 0; }
.list-amount { font-size: .875rem; font-weight: 650; color: #0f172a; font-variant-numeric: tabular-nums; }
.overdue { color: #b91c1c; font-weight: 600; }

.mini-stat { display: flex; align-items: center; justify-content: space-between; padding: 14px 20px; border-bottom: 1px solid var(--mj-line); }
.mini-stat:last-child { border-bottom: 0; }
.mini-stat .lbl { font-size: .83rem; color: #334155; display: flex; align-items: center; gap: 10px; }
.mini-stat .lbl i { width: 16px; text-align: center; color: #94a3b8; }
.mini-stat .val { font-size: 1rem; font-weight: 650; color: #0f172a; font-variant-numeric: tabular-nums; }

/* ---------- Boş durum ---------- */
.empty { padding: 40px 20px; text-align: center; color: var(--mj-muted); font-size: .85rem; }
/* Boş durumun kendi ikonu (düğme içindeki ikonları etkilemez) */
.empty > i { display: grid; place-items: center; width: 52px; height: 52px; margin: 0 auto 12px; border-radius: 16px;
             background: #f1f5f9; color: #94a3b8; font-size: 1.2rem; }
.empty > .mt-3 { margin-top: 16px !important; }

/* Boş durum eylem düğmesi: "İlk hareketi ekle", "İlk faturayı oluştur" ... */
.empty .btn-primary {
    display: inline-flex; align-items: center; gap: 8px;
    padding: 7px 16px 7px 8px; border-radius: 999px;
    background: #eef2ff; border: 1px solid #c7d2fe; color: #4338ca;
    font-size: .83rem; font-weight: 600; box-shadow: none;
    transition: background-color .15s, border-color .15s, color .15s, transform .15s;
}
.empty .btn-primary > i {
    display: grid; place-items: center; width: 24px; height: 24px; margin: 0 !important; border-radius: 50%;
    background: #4f46e5; color: #fff; font-size: .7rem;
}
.empty .btn-primary:hover, .empty .btn-primary:focus-visible {
    background: #4f46e5; border-color: #4f46e5; color: #fff; transform: translateY(-1px);
}
.empty .btn-primary:hover > i, .empty .btn-primary:focus-visible > i { background: #fff; color: #4f46e5; }
.empty .btn-secondary { border-radius: 999px; padding: 6px 14px; font-size: .8rem; }

/* Mevcut sayfalardaki büyük boş durum ikonları */
.text-center > i.fa-3x.text-muted, .text-center > i.fa-4x.text-muted, .text-center > i.fa-2x.text-muted {
    font-size: 1.6rem;
    color: #cbd5e1 !important;
}

/* KPI'ye dönüşen istatistik kartlarında etiket soluk, değer koyu */
.card.text-white h6, .card.text-white .h6 { color: var(--mj-muted) !important; font-size: .8rem; font-weight: 500; margin-bottom: 4px !important; }

/* Menülerdeki süs ikonları */
.dropdown-item > i:first-child { width: 18px; text-align: center; color: #94a3b8 !important; }

/* ---------- Liste sayfaları ---------- */
.dash-card > .card-header { flex-wrap: wrap; }

.toolbar { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; margin: 0; }
.toolbar .form-select, .toolbar .form-control { width: auto; min-width: 128px; font-size: .83rem; padding-top: .38rem; padding-bottom: .38rem; }
.toolbar .form-select { max-width: 180px; }

.search-box { position: relative; }
.search-box > i { position: absolute; left: 11px; top: 50%; transform: translateY(-50%); color: #94a3b8; font-size: .8rem; pointer-events: none; }
.search-box > .form-control { padding-left: 32px; min-width: 220px; }

.cell-entity { display: flex; align-items: center; gap: 12px; min-width: 0; }
.cell-entity .list-avatar { width: 34px; height: 34px; font-size: .75rem; }
.cell-entity .list-title { max-width: 320px; }
.cell-entity a.list-title { text-decoration: none; }
.cell-entity a.list-title:hover { color: #4f46e5; }

.num { text-align: right; font-variant-numeric: tabular-nums; white-space: nowrap; }
.num-strong { font-weight: 650; color: #0f172a; }
.num-sub { display: block; font-size: .72rem; color: var(--mj-muted); font-weight: 500; }
.amt-b { color: #b91c1c; }
.amt-a { color: #15803d; }

.row-actions { display: inline-flex; gap: 4px; justify-content: flex-end; }
.row-actions .btn {
    padding: 0;
    width: 30px; height: 30px; display: inline-grid; place-items: center;
    border-radius: 8px; border: 1px solid transparent; background: transparent; color: #64748b; box-shadow: none;
}
.row-actions .btn:hover { background: #f1f5f9; color: #0f172a; border-color: #e2e8f0; }
.row-actions .btn.danger:hover { background: #fef2f2; color: #b91c1c; border-color: #fee2e2; }
.row-actions .btn.primary:hover { background: #eef2ff; color: #4338ca; border-color: #e0e7ff; }

.pager { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 12px; font-size: .8rem; color: var(--mj-muted); }
.pager .pagination { margin: 0; }

.filter-chip { display: inline-flex; align-items: center; gap: 6px; padding: 2px 4px 2px 10px; border-radius: 999px; background: #eef2ff; color: #4338ca; font-size: .75rem; font-weight: 500; }
.filter-chip a { color: inherit; width: 18px; height: 18px; display: inline-grid; place-items: center; border-radius: 50%; text-decoration: none; }
.filter-chip a:hover { background: #e0e7ff; }

@media (max-width: 767.98px) {
    .search-box > .form-control { min-width: 0; width: 100%; }
    .toolbar, .toolbar .search-box { width: 100%; }
}

/* ---------- Hesap kartları (kasa / banka listeleri) ---------- */
.acc-card { height: 100%; display: flex; flex-direction: column; }
.acc-head { display: flex; align-items: center; gap: 12px; padding: 18px 20px 0; }
.acc-head .list-main { min-width: 0; }
.acc-balance { padding: 14px 20px 4px; }
.acc-balance .kpi-value.neg { color: #b91c1c; }
.acc-flow { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; padding: 12px 20px 16px; font-size: .78rem; color: var(--mj-muted); }
.acc-flow b { display: block; font-size: .9rem; color: #0f172a; font-weight: 600; font-variant-numeric: tabular-nums; }
.acc-note { padding: 0 20px 14px; font-size: .78rem; color: var(--mj-muted); }
.acc-ids { margin: 0 20px 16px; padding: 10px 12px; border-radius: 10px; background: #f8fafc; border: 1px solid #eef0f5; font-size: .75rem; color: var(--mj-muted); display: grid; gap: 4px; }
.acc-ids code { color: #334155; background: none; font-size: .78rem; letter-spacing: .02em; word-break: break-all; }
.acc-card .card-footer { margin-top: auto; display: flex; justify-content: space-between; align-items: center; }

/* Eksik alan içeren sekme */
.nav-link.tab-has-error::after { content: ''; display: inline-block; width: 6px; height: 6px; margin-left: 6px; border-radius: 50%; background: #dc2626; vertical-align: middle; }

/* ---------- Fatura formu ---------- */
.inv-form { padding-bottom: 88px; }
.inv-form .form-label { font-size: .78rem; font-weight: 500; color: #475569; margin-bottom: 6px; display: flex; align-items: center; gap: 6px; }
.inv-form .form-label .req { color: #94a3b8; }
.inv-form .form-control, .inv-form .form-select { min-height: 38px; font-size: .875rem; }
.inv-form .form-control:focus, .inv-form .form-select:focus { border-color: #a5b4fc; box-shadow: 0 0 0 3px rgba(79, 70, 229, .12); }
.inv-form .form-control[readonly] { background: #f8fafc; color: #64748b; }
.inv-form .dash-card > .card-header { padding: 12px 18px; }
.inv-form .dash-card > .card-body { padding: 16px 18px; }
.inv-form .dash-card .card-header h6 { font-size: .9rem; font-weight: 600; display: flex; align-items: center; }
.inv-step { width: 22px; height: 22px; border-radius: 7px; background: #eef2ff; color: #4f46e5; font-size: .72rem; font-weight: 700; display: inline-grid; place-items: center; margin-right: 10px; }
.inv-muted { color: var(--mj-muted); font-weight: 400; }
.inv-hint { font-size: .7rem; font-weight: 500; color: #4f46e5; background: #eef2ff; border-radius: 6px; padding: 1px 7px; }

/* Cari özeti */
.inv-cari { display: flex; flex-wrap: wrap; align-items: center; gap: 4px 12px; margin-top: 6px; font-size: .75rem; color: #475569; }
.inv-tag { font-size: .7rem; font-weight: 600; padding: 2px 8px; border-radius: 6px; background: #f1f5f9; color: #475569; }
.inv-tag.is-accent { background: #eef2ff; color: #4f46e5; }

/* Vade çipleri */
.inv-label-row { display: flex; align-items: center; justify-content: space-between; gap: 8px; margin-bottom: 6px; }
.inv-label-row .form-label { margin-bottom: 0; }
.inv-chips { display: flex; flex-wrap: wrap; gap: 4px; }
.inv-chip { border: 1px solid #e2e8f0; background: #fff; color: #475569; border-radius: 999px; padding: 0 8px; font-size: .7rem; font-weight: 500; line-height: 1.6; transition: all .15s; }
.inv-chip:hover { border-color: #c7d2fe; color: #4f46e5; }
.inv-chip.active { background: #eef2ff; border-color: #c7d2fe; color: #4f46e5; }

/* Parçalı seçim */
.inv-seg { display: flex; padding: 3px; gap: 3px; background: #f1f5f9; border-radius: 10px; }
.inv-seg label { flex: 1; text-align: center; padding: 5px 8px; white-space: nowrap; border-radius: 8px; font-size: .8rem; font-weight: 500; color: #64748b; cursor: pointer; margin: 0; transition: all .15s; user-select: none; }
.inv-seg label:hover { color: #0f172a; }
.inv-seg .btn-check:checked + label { background: #fff; color: #0f172a; box-shadow: 0 1px 2px rgba(15, 23, 42, .08), 0 0 0 1px #e2e8f0; }
.inv-seg .btn-check:focus-visible + label { outline: 2px solid #a5b4fc; outline-offset: 1px; }

/* Kalem girişi */
.inv-entry { padding: 16px 20px; background: #f8fafc; border-bottom: 1px solid #eef2f6; }
.inv-entry .alert { font-size: .82rem; }
.inv-stock { font-size: .68rem; font-weight: 600; color: #4f46e5; background: #eef2ff; border-radius: 5px; padding: 0 6px; }
.inv-table thead th { background: #fff; font-size: .72rem; font-weight: 600; text-transform: uppercase; letter-spacing: .04em; color: #64748b; border-bottom: 1px solid #e2e8f0; }
.inv-table td.empty { text-align: center; padding: 40px 16px; color: var(--mj-muted); }
.inv-table td.empty i { font-size: 1.6rem; color: #cbd5e1; display: block; margin-bottom: 8px; }
.inv-table td.empty small { color: #94a3b8; }

/* Özet */
.inv-sum-row { display: flex; justify-content: space-between; gap: 12px; padding: 5px 0; font-size: .85rem; color: #475569; }
.inv-sum-total { display: flex; justify-content: space-between; align-items: baseline; gap: 12px; margin-top: 8px; padding-top: 12px; border-top: 1px solid #e2e8f0; font-weight: 600; color: #0f172a; }
.inv-sum-total .num { font-size: 1.35rem; font-weight: 650; letter-spacing: -.02em; }
.inv-form .num { font-variant-numeric: tabular-nums; }

/* Sabit alt çubuk */
.inv-bar { position: fixed; left: var(--mj-sb-width, 0px); right: 0; bottom: 0; z-index: 1020; display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 12px; padding: 12px 24px calc(12px + env(safe-area-inset-bottom, 0px)); background: rgba(255, 255, 255, .92); backdrop-filter: blur(8px); border-top: 1px solid #e2e8f0; }
.mj-collapsed .inv-bar { left: var(--mj-sb-rail, 0px); }
@media (max-width: 991.98px) { .inv-bar, .mj-collapsed .inv-bar { left: 0; padding-left: 16px; padding-right: 16px; } }
.inv-bar-info { display: flex; align-items: baseline; gap: 14px; font-size: .82rem; }
.inv-bar-total { font-size: 1.15rem; font-weight: 650; color: #0f172a; }

/* Select2: genel görünüm mj-ui.css'te */
.inv-form .select2-container { width: 100% !important; }
.inv-form .select2-container--default .select2-selection--single { min-height: 38px; }

/* ---------- Fatura özeti ---------- */
.fd-badges { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; margin-top: 6px; }
.fd .dash-card .card-header h6 { font-size: .9rem; font-weight: 600; }
.fd-name { font-size: .95rem; font-weight: 600; color: #0f172a; margin-bottom: 10px; }
.fd-dl { display: grid; grid-template-columns: max-content 1fr; gap: 7px 16px; margin: 0; font-size: .83rem; }
.fd-dl dt { font-weight: 500; color: var(--mj-muted); }
.fd-dl dd { margin: 0; color: #0f172a; min-width: 0; overflow-wrap: anywhere; }
.fd-uuid { font-size: .72rem; color: #475569; }
.fd-tag { display: inline-block; margin-top: 4px; font-size: .7rem; font-weight: 600; color: #4f46e5; background: #eef2ff; border-radius: 6px; padding: 1px 7px; }
.fd-table thead th { font-size: .72rem; font-weight: 600; text-transform: uppercase; letter-spacing: .04em; color: #64748b; }
.fd-table td { vertical-align: top; font-size: .85rem; }
.fd-table .num { font-variant-numeric: tabular-nums; white-space: nowrap; }
.fd-totals { margin-left: auto; max-width: 360px; padding: 14px 20px 18px; font-size: .85rem; color: #475569; }
.fd-totals > div { display: flex; justify-content: space-between; gap: 16px; padding: 4px 0; }
.fd-totals .num { font-variant-numeric: tabular-nums; color: #0f172a; }
.fd-totals .fd-grand { border-top: 1px solid #e2e8f0; margin-top: 4px; padding-top: 10px; font-weight: 600; color: #0f172a; }
.fd-totals .fd-grand .num { font-size: 1.1rem; font-weight: 650; }

/* Tarih aralığı (liste filtreleri) */
.date-range { display: flex; align-items: center; gap: 6px; }
.date-range > span { color: #94a3b8; font-size: .8rem; }
.toolbar .date-range .form-control { min-width: 0; width: 132px; }
@media (max-width: 767.98px) { .date-range { width: 100%; } .toolbar .date-range .form-control { flex: 1; width: auto; } }
.inv-select-row { display: flex; gap: 4px; }
.inv-form .inv-select-row .select2-container { flex: 1; width: auto !important; min-width: 0; }
.fd-dl-row { grid-template-columns: max-content 1fr max-content 1fr; }
@media (max-width: 767.98px) { .fd-dl-row { grid-template-columns: max-content 1fr; } }

/* ---------- Teklif şablon/paket ---------- */
.ts-card { overflow: hidden; }
.ts-card .ts-swatch { height: 96px; border-radius: 0; border-width: 0 0 1px; }
.ts-title { font-size: .95rem; font-weight: 600; color: #0f172a; }
.ts-desc { font-size: .8rem; color: var(--mj-muted); margin-bottom: 10px; }
.ts-meta { display: flex; flex-wrap: wrap; gap: 6px 14px; font-size: .75rem; color: #475569; }
.ts-meta i { color: #94a3b8; margin-right: 5px; }
.ts-dot { display: inline-block; width: 9px; height: 9px; border-radius: 50%; margin-right: 6px; vertical-align: 0; }
.ts-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; background: #fff; }

/* Tema küçük önizlemesi */
.ts-swatch { --ts-renk: #4f46e5; position: relative; display: block; height: 84px; background: #fff; border: 1px solid #e2e8f0; border-radius: 10px; overflow: hidden; }
.ts-swatch > span { position: absolute; display: block; }
.ts-swatch-band { left: 10%; right: 10%; top: 12%; height: 18%; border-radius: 4px; }
.ts-swatch-line { left: 10%; width: 46%; top: 40%; height: 6%; border-radius: 3px; background: #e2e8f0; }
.ts-swatch-line.short { top: 52%; width: 30%; }
.ts-swatch-table { left: 10%; right: 10%; top: 66%; height: 22%; border-top: 2px solid #cbd5e1; background: repeating-linear-gradient(#fff 0 6px, #f1f5f9 6px 7px); }
.ts-swatch-modern .ts-swatch-band { background: var(--ts-renk); }
.ts-swatch-modern .ts-swatch-table { border-top-color: #e2e8f0; background-color: #f8fafc; }
.ts-swatch-klasik .ts-swatch-band { background: transparent; border-bottom: 2px solid var(--ts-renk); border-radius: 0; }
.ts-swatch-klasik .ts-swatch-table { border: 1px solid #cbd5e1; border-top: 2px solid var(--ts-renk); }
.ts-swatch-minimal .ts-swatch-band { background: transparent; left: 60%; height: 12%; border-bottom: 1px solid #0f172a; border-radius: 0; }
.ts-swatch-minimal .ts-swatch-table { border-top: 1px solid #0f172a; background: repeating-linear-gradient(#fff 0 6px, #f8fafc 6px 7px); }

/* Tema seçimi */
.ts-tema-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 10px; }
.ts-tema { display: flex; flex-direction: column; gap: 6px; padding: 6px; border: 1px solid #e2e8f0; border-radius: 12px; cursor: pointer; transition: border-color .15s, box-shadow .15s; margin: 0; }
.ts-tema:hover { border-color: #c7d2fe; }
.ts-tema.active { border-color: #4f46e5; box-shadow: 0 0 0 3px rgba(79, 70, 229, .12); }
.ts-tema-ad { font-size: .8rem; font-weight: 600; text-align: center; color: #334155; }
.ts-tema:has(input:focus-visible) { outline: 2px solid #a5b4fc; outline-offset: 2px; }
@media (max-width: 575.98px) { .ts-tema-grid { grid-template-columns: 1fr; } }

/* Renk seçimi */
.ts-renkler { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; }
.ts-renk { width: 28px; height: 28px; border-radius: 50%; border: 2px solid #fff; box-shadow: 0 0 0 1px #e2e8f0; padding: 0; cursor: pointer; }
.ts-renk.active { box-shadow: 0 0 0 2px #0f172a; }
.ts-renk-ozel { display: inline-flex; align-items: center; gap: 6px; margin: 0 0 0 4px; padding: 2px 10px 2px 4px; border: 1px solid #e2e8f0; border-radius: 999px; font-size: .75rem; color: #475569; cursor: pointer; font-family: ui-monospace, monospace; }
.ts-renk-ozel input[type="color"] { width: 24px; height: 24px; border: 0; padding: 0; background: none; cursor: pointer; }

/* Şablon formu canlı özet */
.ts-onizleme { --ts-renk: #4f46e5; position: sticky; top: calc(76px + env(safe-area-inset-top, 0px)); }
.ts-oz { border: 1px solid #e2e8f0; border-radius: 10px; padding: 14px; font-size: .75rem; color: #334155; background: #fff; }
.ts-oz-head { display: flex; justify-content: space-between; align-items: center; margin-bottom: 10px; font-weight: 600; }
.ts-oz-head strong { letter-spacing: .06em; }
.ts-oz-modern .ts-oz-head { background: var(--ts-renk); color: #fff; margin: -14px -14px 12px; padding: 12px 14px; border-radius: 10px 10px 0 0; }
.ts-oz-klasik { font-family: Georgia, 'Times New Roman', serif; }
.ts-oz-klasik .ts-oz-head { border-bottom: 2px solid var(--ts-renk); padding-bottom: 8px; }
.ts-oz-klasik .ts-oz-head strong { color: var(--ts-renk); }
.ts-oz-minimal .ts-oz-head strong { font-weight: 300; font-size: 1rem; letter-spacing: 0; }
.ts-oz-giris { white-space: pre-line; margin-bottom: 10px; }
.ts-oz-giris.bos { color: #94a3b8; font-style: italic; }
.ts-oz-tablo > div { display: flex; justify-content: space-between; padding: 5px 0; border-bottom: 1px solid #f1f5f9; }
.ts-oz-tablo > div:first-child { font-size: .65rem; text-transform: uppercase; letter-spacing: .05em; color: #64748b; border-bottom-color: #e2e8f0; }
.ts-oz-toplam { display: flex; justify-content: space-between; padding-top: 8px; font-weight: 600; }
.ts-oz-toplam strong { color: var(--ts-renk); }
.ts-oz-sartlar { margin-top: 10px; display: grid; gap: 6px; }
.ts-oz-sartlar > div { display: grid; gap: 1px; }
.ts-oz-sartlar b { font-size: .62rem; text-transform: uppercase; letter-spacing: .06em; color: var(--ts-renk); }
.ts-oz-sartlar span { white-space: pre-line; color: #475569; }
.ts-oz-bilgi { display: flex; gap: 14px; margin-top: 12px; font-size: .75rem; color: #475569; }
.ts-oz-bilgi i { color: #94a3b8; margin-right: 5px; }

/* Paket formu */
.tp-table td { vertical-align: top; }
.tp-table .tp-ack { font-size: .78rem; color: #64748b; }
.tp-table .tp-stok { display: inline-block; margin-top: 4px; font-size: .68rem; font-weight: 600; color: #4f46e5; background: #eef2ff; border-radius: 5px; padding: 0 6px; }
.tp-table .tp-tutar { padding-top: 14px; }
.tp-table tr.tp-opsiyonel td { background: #fafafa; }
.tp-table tr.tp-opsiyonel .tp-tutar { color: #94a3b8; }

/* ---------- Teklif formu ---------- */
.tk-form .tk-temalar { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; }
.tk-form .tk-tema { display: flex; flex-direction: column; align-items: center; gap: 6px; padding: 8px 6px 6px; border: 1px solid #e2e8f0; border-radius: 10px; font-size: .78rem; font-weight: 500; color: #475569; cursor: pointer; transition: all .15s; margin: 0; }
.tk-form .tk-tema:hover { border-color: #c7d2fe; }
.tk-form .btn-check:checked + .tk-tema { border-color: #4f46e5; box-shadow: 0 0 0 3px rgba(79, 70, 229, .12); color: #0f172a; }
.tk-form .btn-check:focus-visible + .tk-tema { outline: 2px solid #a5b4fc; outline-offset: 1px; }
.tk-tema-onizleme { display: block; width: 100%; height: 44px; border-radius: 6px; background: #f8fafc; padding: 5px; position: relative; overflow: hidden; }
.tk-tema-onizleme i { display: block; height: 9px; border-radius: 3px; background: #cbd5e1; margin-bottom: 5px; }
.tk-tema-onizleme b { display: block; height: 3px; border-radius: 2px; background: #e2e8f0; margin-bottom: 3px; }
.tk-tema-modern .tk-tema-onizleme i { background: #4f46e5; height: 12px; }
.tk-tema-klasik .tk-tema-onizleme i { background: transparent; border-bottom: 2px solid #334155; border-radius: 0; width: 60%; margin-left: auto; }
.tk-tema-klasik .tk-tema-onizleme b { background: #cbd5e1; }
.tk-tema-minimal .tk-tema-onizleme { background: #fff; border: 1px solid #f1f5f9; }
.tk-tema-minimal .tk-tema-onizleme i { background: #0f172a; height: 4px; width: 35%; }
.tk-renkler { display: flex; gap: 5px; }
.tk-renk { width: 18px; height: 18px; border-radius: 50%; border: 2px solid #fff; box-shadow: 0 0 0 1px #e2e8f0; padding: 0; }
.tk-renk.active { box-shadow: 0 0 0 2px #0f172a; }
.tk-form .form-control-color { height: 34px; padding: 3px; }
.tk-kalemler td { vertical-align: top; padding-top: 10px; padding-bottom: 10px; }
.tk-kalemler .form-control-sm, .tk-kalemler .form-select-sm { min-height: 32px; font-size: .82rem; }
.tk-kalemler .tk-aciklama { resize: vertical; min-height: 30px; color: #475569; }
.tk-kalemler tr.tk-opsiyonel td { background: #fafaff; }
.tk-kalemler tr.tk-opsiyonel .js-satir-tutar { color: #94a3b8; font-weight: 500; }
.tk-kalemler .btn-link { color: #64748b; }
.tk-kalemler .btn-link:hover { color: #4f46e5; }
.tk-iskonto-tipi { max-width: 92px; }

/* Teklif listesi: görüntülenme */
.tk-gorunum { font-size: .78rem; color: #475569; white-space: nowrap; }
.tk-gorunum.yok { color: #94a3b8; }

/* ---------- Teklif detay ---------- */
.td-kagit { background: #fff; border: 1px solid #e2e8f0; border-radius: 12px; padding: 32px; overflow-x: auto; box-shadow: 0 1px 2px rgba(15, 23, 42, .04); }
.td-kagit .tb { min-width: 640px; }
.td-pre { white-space: pre-line; }
@media (max-width: 575.98px) { .td-kagit { padding: 16px; } }

/* ---------- Teklif logo seçici ---------- */
.tk-logo-kutu { display: flex; align-items: center; gap: 12px; min-height: 64px; padding: 10px 12px; border: 1px dashed #cbd5e1; border-radius: 10px; background: #f8fafc; flex-wrap: wrap; }
.tk-logo-kutu img { max-height: 48px; max-width: 160px; object-fit: contain; background: #fff; border-radius: 6px; padding: 4px; }
.tk-logo-bos { flex: 1; min-width: 140px; font-size: .78rem; color: var(--mj-muted); }
.tk-logo-eylem { display: flex; align-items: center; gap: 10px; margin-left: auto; }
.tk-logo .inv-seg label { font-size: .76rem; padding: 5px 6px; }

/* İki satırlı düğme: ana etiket + minik açıklama */
.btn.btn-alt-yazi { display: inline-flex; flex-direction: column; align-items: center; justify-content: center; line-height: 1.15; padding-top: .3rem; padding-bottom: .3rem; }
.btn.btn-alt-yazi small { font-size: .62rem; font-weight: 400; opacity: .75; letter-spacing: .01em; }

/* ---------- Pazaryeri ---------- */
.pz-platform { display: inline-grid; place-items: center; min-width: 30px; height: 30px; padding: 0 6px; border-radius: 8px; background: #f1f5f9; color: #334155; font-size: .68rem; font-weight: 700; letter-spacing: .02em; flex-shrink: 0; }
.pz-platform-trendyol { background: #fff7ed; color: #c2410c; }
.pz-platform-hepsiburada { background: #fff7ed; color: #ea580c; }
.pz-platform-n11 { background: #f5f3ff; color: #6d28d9; }
.pz-platform-secim { display: flex; flex-wrap: wrap; gap: 10px; justify-content: center; }
.pz-platform-kart { display: inline-flex; align-items: center; gap: 10px; padding: 12px 16px; border: 1px solid #e2e8f0; border-radius: 12px; color: #0f172a; text-decoration: none; font-weight: 600; background: #fff; transition: all .15s; }
.pz-platform-kart:hover { border-color: #c7d2fe; box-shadow: 0 0 0 3px rgba(79, 70, 229, .08); color: #0f172a; }
.pz-hesap.pz-pasif { opacity: .7; }
.pz-dl { display: grid; grid-template-columns: max-content 1fr; gap: 6px 14px; margin: 0; font-size: .83rem; }
.pz-dl dt { font-weight: 500; color: var(--mj-muted); }
.pz-dl dd { margin: 0; }
.pz-ozellikler { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 14px; }
.pz-ozellik { font-size: .72rem; padding: 2px 8px; border-radius: 999px; background: #f1f5f9; color: #94a3b8; }
.pz-ozellik i { margin-right: 4px; font-size: .65rem; }
.pz-ozellik.acik { background: #eef2ff; color: #4f46e5; }
.pz-secenekler { display: grid; gap: 10px; }
.pz-secenekler .form-check-label { display: flex; flex-direction: column; font-size: .84rem; }
.pz-secenekler .form-check-label span { font-size: .75rem; color: var(--mj-muted); }
.pz-toplu { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 10px 20px; background: #eef2ff; border-bottom: 1px solid #e0e7ff; font-size: .85rem; color: #312e81; }
.pz-adres { white-space: pre-line; font-size: .85rem; }
.pz-eslesmemis { display: inline-block; margin-top: 4px; font-size: .72rem; font-weight: 600; color: #b45309; background: #fffbeb; border-radius: 6px; padding: 1px 7px; text-decoration: none; }
.pz-ham { max-height: 420px; overflow: auto; padding: 16px 20px; font-size: .75rem; background: #0f172a; color: #e2e8f0; border-radius: 0 0 12px 12px; white-space: pre-wrap; word-break: break-word; }
.pz-urun-tablo td { vertical-align: middle; }
.pz-mesaj { max-width: 520px; overflow-wrap: anywhere; }

/* ---------- Önkoşul rehberi (ör. önce banka hesabı, sonra hareket) ---------- */
.onkosul { max-width: 460px; margin: 0 auto; padding: 36px 20px 8px; text-align: center; }
.onkosul .empty { padding: 0 0 12px; }
.onkosul-ikon { display: grid; place-items: center; width: 52px; height: 52px; margin: 0 auto 12px; border-radius: 16px; background: #eef2ff; color: #4f46e5; font-size: 1.15rem; }
.onkosul-baslik { font-size: .98rem; font-weight: 600; color: #0f172a; }
.onkosul-aciklama { margin-top: 4px; font-size: .84rem; color: var(--mj-muted); }
.onkosul-adimlar { list-style: none; padding: 0; margin: 18px 0 4px; text-align: left; display: grid; gap: 8px; }
.onkosul-adimlar li { display: flex; align-items: center; gap: 12px; padding: 10px 12px; border: 1px solid #e2e8f0; border-radius: 12px; background: #fff; }
.onkosul-no { flex-shrink: 0; display: grid; place-items: center; width: 26px; height: 26px; border-radius: 50%; background: #f1f5f9; color: #64748b; font-size: .75rem; font-weight: 700; }
.onkosul-metin { display: flex; flex-direction: column; line-height: 1.3; }
.onkosul-metin strong { font-size: .84rem; font-weight: 600; color: #0f172a; }
.onkosul-metin small { font-size: .75rem; color: var(--mj-muted); }
.onkosul-adimlar li.siradaki { border-color: #c7d2fe; background: #f8f9ff; box-shadow: 0 0 0 3px rgba(79, 70, 229, .08); }
.onkosul-adimlar li.siradaki .onkosul-no { background: #4f46e5; color: #fff; }
.onkosul-adimlar li.tamam .onkosul-no { background: #dcfce7; color: #15803d; }
.onkosul-adimlar li.bekliyor { opacity: .65; }
.onkosul-serit { display: flex; align-items: center; gap: 10px; margin-bottom: 16px; padding: 10px 14px; border: 1px solid #c7d2fe; border-radius: 12px; background: #f8f9ff; font-size: .84rem; color: #3730a3; }
.onkosul-serit-no { flex-shrink: 0; padding: 2px 8px; border-radius: 999px; background: #4f46e5; color: #fff; font-size: .72rem; font-weight: 700; }

/* ---------- Giriş / kayıt (oturumsuz) ---------- */
.mj-auth-sayfa .site-footer { display: none; }
.mj-auth-sayfa .main-content > .container-fluid { margin: 0 !important; padding: 0 !important; }
.mj-auth { min-height: 100vh; display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); background: #fff; }
.mj-auth-marka {
    position: relative; overflow: hidden; display: flex; flex-direction: column; justify-content: space-between; gap: 32px;
    padding: 48px 56px; background: #f5f6ff; border-right: 1px solid #eceefb;
}
.mj-auth-marka::before {
    content: ""; position: absolute; inset: 0; pointer-events: none; opacity: .55;
    background-image: radial-gradient(#c7d2fe 1px, transparent 1px); background-size: 22px 22px;
    -webkit-mask-image: linear-gradient(180deg, transparent, #000 35%, #000 70%, transparent);
            mask-image: linear-gradient(180deg, transparent, #000 35%, #000 70%, transparent);
}
.mj-auth-marka > * { position: relative; }
.mj-auth-logo { display: inline-flex; align-items: center; gap: 10px; font-size: 1.1rem; font-weight: 700; color: #0f172a; letter-spacing: -.02em; text-decoration: none; }
.mj-auth-logo:hover { color: #0f172a; }
.mj-auth-logo img { display: block; height: 44px; width: auto; }
.mj-auth-mobil-logo img { height: 36px; }
.mj-auth-logo .ikon { width: 36px; height: 36px; border-radius: 10px; display: grid; place-items: center; color: #fff; background: #4f46e5; box-shadow: 0 6px 16px -6px rgba(79, 70, 229, .6); }
.mj-auth-logo b { color: #4f46e5; font-weight: 700; }
.mj-auth-slogan h2 { font-size: 2rem; line-height: 1.2; letter-spacing: -.03em; margin: 0 0 12px; color: #0f172a; max-width: 460px; }
.mj-auth-slogan p { color: #475569; font-size: .95rem; max-width: 440px; margin: 0; }
.mj-auth-ozellikler { list-style: none; padding: 0; margin: 28px 0 0; display: grid; gap: 14px; }
.mj-auth-ozellikler li { display: flex; gap: 12px; align-items: flex-start; font-size: .875rem; color: #334155; }
.mj-auth-ozellikler i { width: 30px; height: 30px; flex-shrink: 0; border-radius: 8px; display: grid; place-items: center; background: #fff; color: #4f46e5; border: 1px solid #e0e7ff; font-size: .8rem; }
.mj-auth-ozellikler strong { display: block; color: #0f172a; font-weight: 600; }
.mj-auth-alt { font-size: .75rem; color: #94a3b8; }
.mj-auth-form { display: flex; flex-direction: column; justify-content: center; align-items: center; padding: 48px 24px; }
.mj-auth-kutu { width: 100%; max-width: 400px; }
.mj-auth-kutu.genis { max-width: 520px; }
.mj-auth-kutu h1 { font-size: 1.6rem; letter-spacing: -.03em; margin: 0 0 6px; }
.mj-auth-kutu .alt-baslik { color: #64748b; font-size: .9rem; margin-bottom: 28px; }
.mj-auth-kutu .form-label { font-size: .8rem; }
.mj-auth-kutu .form-control { min-height: 42px; }
.mj-alan { position: relative; }
.mj-alan > i { position: absolute; left: 13px; top: 50%; transform: translateY(-50%); color: #94a3b8; font-size: .85rem; pointer-events: none; }
.mj-alan > .form-control { padding-left: 38px; }
.mj-alan > .form-control.sifre { padding-right: 42px; }
.mj-alan > .goster { position: absolute; right: 6px; top: 50%; transform: translateY(-50%); width: 32px; height: 32px; border: 0; background: transparent; color: #94a3b8; border-radius: 6px; }
.mj-alan > .goster:hover { color: #475569; background: #f1f5f9; }
.mj-auth-kutu .hata { margin-top: 6px; font-size: .78rem; color: #b91c1c; display: flex; gap: 6px; align-items: center; }
.mj-auth-kutu .btn-blok { width: 100%; min-height: 44px; font-size: .9rem; }
.mj-auth-kutu .bolum { display: flex; align-items: center; gap: 10px; margin: 22px 0 14px; font-size: .7rem; font-weight: 600; text-transform: uppercase; letter-spacing: .06em; color: #94a3b8; }
.mj-auth-kutu .bolum::after { content: ""; flex: 1; height: 1px; background: #eef0f5; }
.mj-auth-gecis { margin-top: 24px; text-align: center; font-size: .85rem; color: #64748b; }
.mj-auth-mobil-logo { display: none; margin-bottom: 28px; }
@media (max-width: 991.98px) {
    .mj-auth { grid-template-columns: 1fr; }
    .mj-auth-marka { display: none; }
    .mj-auth-mobil-logo { display: inline-flex; }
    .mj-auth-form { justify-content: flex-start; padding-top: 40px; }
}

/* Fatura formu: stokta olmayan (serbest) kalem */
.inv-serbest { display: flex; align-items: center; gap: 8px; font-size: .72rem; line-height: 1; white-space: nowrap; }
.inv-serbest[hidden] { display: none; }
.inv-label-row .inv-serbest .inv-tag { padding: 1px 6px; font-size: .65rem; }
.inv-serbest .form-check-input { width: .95em; height: .95em; margin-top: 0; }
.inv-serbest .form-check { min-height: 0; padding-left: 1.4em; display: flex; align-items: center; }
.inv-serbest .form-check .form-check-input { margin-left: -1.4em; }
.inv-serbest .form-check-label { font-size: .72rem; color: #475569; margin-left: 2px; cursor: pointer; }
.inv-serbest-secenek { display: flex; align-items: baseline; gap: 6px; }
.inv-serbest-secenek i { font-size: .7rem; color: #4f46e5; }
.inv-serbest-secenek small { color: #64748b; font-size: .72rem; }
.select2-results__option--highlighted .inv-serbest-secenek small, .select2-results__option--highlighted .inv-serbest-secenek i { color: inherit; }
td .inv-tag { margin-top: 3px; display: inline-block; font-size: .65rem; padding: 1px 6px; }

/* Bildirimler: sayfada sabit alt çubuk (.inv-bar) varsa onun üstünde dursun */
#flash-messages-container { bottom: var(--mj-alt-bosluk, 20px) !important; transition: bottom .2s ease; }
