/* TOYA Portal — Masaüstü ERP Paritesi Tasarım Sistemi
   Kaynak: gelistirme/11_entegrasyonlar/portal_tasarim_ornegi/ornek.css
   Bootstrap 5.3 + Tabulator 6.2 üzerine tam uyumlu kurallar. */

:root {
  --t-primary: #2563eb;
  --t-primary-600: #1d4ed8;
  --t-primary-50: #eff6ff;
  --t-primary-100: #dbeafe;

  --t-ink: #0f172a;
  --t-text: #1e293b;
  --t-muted: #64748b;
  --t-faint: #94a3b8;
  --t-line: #e2e8f0;
  --t-line-soft: #eef2f7;
  --t-bg: #f4f6fa;
  --t-surface: #ffffff;
  --t-surface-2: #f8fafc;

  --t-green: #15803d;  --t-green-bg: #dcfce7;
  --t-red: #b91c1c;    --t-red-bg: #fee2e2;
  --t-amber: #b45309;  --t-amber-bg: #fef3c7;
  --t-violet: #6d28d9; --t-violet-bg: #ede9fe;
  --t-sky: #0369a1;    --t-sky-bg: #e0f2fe;

  --t-top-h: 52px;

  --t-radius: 10px;
  --t-radius-sm: 7px;
  --t-shadow: 0 1px 2px rgba(15, 23, 42, .05), 0 1px 3px rgba(15, 23, 42, .06);
  --t-shadow-lg: 0 10px 30px rgba(15, 23, 42, .14);
  --t-font: "Segoe UI Variable Text", "Segoe UI", system-ui, -apple-system, Roboto, "Helvetica Neue", Arial, sans-serif;

  /* Bootstrap 5.3 Değişkenleri */
  --bs-primary: var(--t-primary);
  --bs-primary-rgb: 37, 99, 235;
  --bs-body-bg: var(--t-bg);
  --bs-body-color: var(--t-text);
  --bs-body-font-family: var(--t-font);
  --bs-body-font-size: .8125rem;          /* 13px: masaüstü uygulama yoğunluğu */
  --bs-border-color: var(--t-line);
  --bs-border-radius: var(--t-radius-sm);
  --bs-link-color-rgb: 37, 99, 235;

  /* Geriye dönük uyumluluk takma adları */
  --toya-primary: var(--t-primary);
  --toya-primary-hover: var(--t-primary-600);
  --toya-primary-subtle: var(--t-primary-50);
  --toya-primary-border: var(--t-primary-100);
  --toya-bg: var(--t-bg);
  --toya-surface: var(--t-surface);
  --toya-border: var(--t-line);
  --toya-text: var(--t-text);
  --toya-muted: var(--t-muted);
  --toya-success: var(--t-green);
  --toya-success-bg: var(--t-green-bg);
  --toya-danger: var(--t-red);
  --toya-danger-bg: var(--t-red-bg);
  --toya-warning: var(--t-amber);
  --toya-warning-bg: var(--t-amber-bg);
  --toya-sidebar-width: 240px;
}

.toya-layout { display: flex; }

html, body { height: 100%; }
body { font-size: 13px; -webkit-font-smoothing: antialiased; overflow-x: hidden; }
.num { font-variant-numeric: tabular-nums; }

/* ───────────── Kabuk: masaüstü TOYA ERP ile aynı yapı ─────────────
   üst çubuk (lacivert) → modül çubuğu (koyu mavi, gruplar) → içerik */
.t-app { display: flex; flex-direction: column; min-height: 100vh; }
.t-top {
  height: var(--t-top-h); background: #0b1220; color: #e2e8f0; display: flex; align-items: center; gap: 10px; padding: 0 14px;
  position: sticky; top: 0; z-index: 1030;
}
.t-logo { width: 34px; height: 34px; border-radius: 8px; background: #fff url("../ikon/logo.png") center/cover no-repeat; flex: 0 0 34px; }
.t-brand { color: #fff; font-weight: 800; font-size: 16px; letter-spacing: .01em; white-space: nowrap; text-decoration: none; margin-right: 6px; }
.t-brand small { font-weight: 600; color: #7dd3fc; font-size: 11px; margin-left: 6px; letter-spacing: .06em; }
.t-search {
  margin-left: auto; display: flex; align-items: center; gap: 8px; height: 34px; width: 300px; max-width: 30vw; padding: 0 10px; border-radius: 8px;
  background: #111c33; border: 1px solid #2b4fa8; color: #7c8aa0;
}
.t-search input { border: 0; outline: 0; background: transparent; flex: 1; min-width: 0; font-size: 12.5px; color: #fff; }
.t-search input::placeholder { color: #7c8aa0; }
.t-pill {
  height: 32px; display: inline-flex; align-items: center; gap: 7px; padding: 0 11px; border-radius: 8px; background: #16213a; border: 1px solid #263553;
  color: #e2e8f0; font-weight: 650; white-space: nowrap; font-size: 12.5px;
}
.t-pill i { color: #93c5fd; }
.t-pill.ok { background: #065f46; border-color: #047857; color: #d1fae5; }
.t-pill.ok i { color: #6ee7b7; }
.t-pill.warn { background: #92400e; border-color: #b45309; color: #fef3c7; }
.t-pill.warn i { color: #fcd34d; }
button.t-pill:hover { background: #1d2b4a; }
.t-round { width: 34px; height: 34px; border-radius: 50%; background: #16213a; border: 1px solid #263553; color: #fbbf24; display: grid; place-items: center; position: relative; flex: 0 0 34px; }
.t-round .t-pip { position: absolute; top: -3px; right: -3px; min-width: 16px; height: 16px; border-radius: 9px; background: #ef4444; color: #fff; font-size: 9.5px; font-weight: 800; display: grid; place-items: center; padding: 0 4px; border: 2px solid #0b1220; }
.t-burger { display: none; width: 34px; height: 34px; border-radius: 8px; background: #16213a; border: 1px solid #263553; color: #fff; font-size: 18px; }

/* modül çubuğu: masaüstündeki alt grup çubuğunun karşılığı */
.t-mods { background: #14275e; border-bottom: 1px solid #0b1a44; display: flex; align-items: center; gap: 8px; padding: 6px 14px; position: sticky; top: var(--t-top-h); z-index: 1025; overflow-x: auto; scrollbar-width: none; }
.t-mods::-webkit-scrollbar { display: none; }
.t-mod { position: static; }
.t-mod > button, .t-mod > a {
  height: 32px; display: inline-flex; align-items: center; gap: 8px; padding: 0 14px; border-radius: 8px; background: #1e3a8a; border: 1px solid #3151b5;
  color: #fff; font-weight: 800; font-size: 12px; letter-spacing: .04em; white-space: nowrap; text-decoration: none;
}
.t-mod > button img, .t-mod > a img { width: 20px; height: 20px; object-fit: contain; }
.t-mod > button:hover, .t-mod > a:hover, .t-mod > button.show { background: #2563eb; border-color: #60a5fa; }
.t-mod.active > button, .t-mod.active > a { background: #2563eb; border-color: #93c5fd; box-shadow: 0 0 0 2px rgba(147, 197, 253, .25); }
.t-mod .dropdown-menu { min-width: 220px; }
.t-mod .dropdown-item img { width: 22px; height: 22px; object-fit: contain; }
.t-mod .dropdown-item.active { background: var(--t-primary-50); color: var(--t-primary-600); font-weight: 700; }
.t-mod .dropdown-item.soon { color: var(--t-faint); pointer-events: none; }
.t-mod .dropdown-item.soon img { filter: grayscale(1); opacity: .5; }
.t-mods .t-state { margin-left: auto; display: inline-flex; align-items: center; gap: 8px; color: #a7f3d0; font-weight: 700; font-size: 12px; white-space: nowrap; padding-left: 12px; }
.t-dot { width: 8px; height: 8px; border-radius: 50%; background: #22c55e; box-shadow: 0 0 0 3px rgba(34, 197, 94, .2); flex: 0 0 8px; }

/* sekme şeridi (masaüstündeki "Ana Panel" sekmesi gibi: nerede olduğunu gösterir) */
.t-tabs { background: #fff; border-bottom: 1px solid var(--t-line); display: flex; align-items: flex-end; gap: 2px; padding: 0 14px; height: 36px; }
.t-tabs a { display: inline-flex; align-items: center; gap: 7px; height: 36px; padding: 0 14px; color: var(--t-muted); font-weight: 650; text-decoration: none; border-bottom: 2px solid transparent; white-space: nowrap; }
.t-tabs a img { width: 18px; height: 18px; object-fit: contain; }
.t-tabs a.active { color: var(--t-primary); border-bottom-color: var(--t-primary); }
.t-tabs a:hover { color: var(--t-ink); }

.t-main { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.t-content { padding: 14px 16px 24px; flex: 1; min-width: 0; }

/* ───────────── Ana panel: Favoriler + Ana Menüler ───────────── */
.t-home { display: grid; grid-template-columns: 280px minmax(0, 1fr); gap: 14px; align-items: start; }
.t-panel { background: #fff; border: 1px solid var(--t-line); border-radius: 12px; box-shadow: var(--t-shadow); padding: 14px; }
.t-panel-title { display: flex; align-items: center; gap: 8px; font-size: 14px; font-weight: 750; color: var(--t-ink); margin: 0 0 10px; }
.t-panel-title i { color: #f97316; }
.t-panel-title .t-n { margin-left: auto; font-size: 11px; font-weight: 700; color: var(--t-primary); background: var(--t-primary-50); border: 1px solid var(--t-primary-100); border-radius: 20px; padding: 1px 10px; }
.t-fav { display: grid; gap: 6px; }
.t-fav a { display: flex; align-items: center; gap: 10px; padding: 9px 12px; border: 1px solid var(--t-line); border-radius: 9px; background: #fff; color: var(--t-ink); font-weight: 600; text-decoration: none; }
.t-fav a img { width: 26px; height: 26px; object-fit: contain; }
.t-fav a:hover { border-color: #93c5fd; background: var(--t-primary-50); }
.t-quick { display: grid; gap: 8px; margin-top: 12px; }
.t-quick a { display: flex; align-items: center; gap: 9px; padding: 9px 12px; border-radius: 9px; background: var(--t-primary); color: #fff; font-weight: 700; text-decoration: none; box-shadow: 0 1px 2px rgba(37, 99, 235, .35); }
.t-quick a:hover { background: var(--t-primary-600); }
.t-menu { display: grid; grid-template-columns: repeat(auto-fill, minmax(124px, 1fr)); gap: 6px 10px; }
.t-menu a { display: flex; flex-direction: column; align-items: center; gap: 6px; padding: 12px 6px 10px; border-radius: 12px; text-decoration: none; color: var(--t-ink); font-weight: 700; font-size: 12px; text-align: center; border: 1px solid transparent; transition: transform .12s ease, background .12s ease; }
.t-menu a img { width: 76px; height: 76px; object-fit: contain; filter: drop-shadow(0 4px 6px rgba(15, 23, 42, .14)); transition: transform .12s ease; }
.t-menu a:hover { background: var(--t-primary-50); border-color: var(--t-primary-100); }
.t-menu a:hover img { transform: translateY(-3px) scale(1.05); }
.t-menu a.soon { color: var(--t-faint); pointer-events: none; }
.t-menu a.soon img { filter: grayscale(1); opacity: .35; }
.t-menu a small { font-weight: 600; color: var(--t-muted); font-size: 10.5px; margin-top: -4px; }
.t-strip { background: #1e3a8a; color: #fff; border-radius: 9px; padding: 7px 12px; font-weight: 800; font-size: 11.5px; letter-spacing: .05em; display: flex; align-items: center; gap: 8px; margin: 14px 0 10px; }
.t-strip i { color: #fbbf24; }

/* ───────────── Liste ekranı: sol işlemler · grid · sağ süzgeçler (masaüstündeki üç panel) ───────────── */
.t-three { display: grid; grid-template-columns: 216px minmax(0, 1fr) 232px; gap: 10px; align-items: start; }
.t-three > *, .t-home > *, .t-cols > * { min-width: 0; }
body.t-no-left .t-three { grid-template-columns: minmax(0, 1fr) 232px; }
body.t-no-right .t-three { grid-template-columns: 216px minmax(0, 1fr); }
body.t-no-left.t-no-right .t-three { grid-template-columns: minmax(0, 1fr); }
body.t-no-left .t-left, body.t-no-right .t-right-pane { display: none; }
.t-pane { display: grid; gap: 8px; position: sticky; top: calc(var(--t-top-h) + 46px + 36px + 10px); }
.t-sec-box { background: #fff; border: 1px solid var(--t-line); border-radius: 10px; overflow: hidden; box-shadow: var(--t-shadow); }
.t-sec-box > summary { list-style: none; cursor: pointer; background: #e0e7ff; color: #1e3a8a; font-weight: 800; font-size: 11px; letter-spacing: .05em; padding: 8px 10px; display: flex; align-items: center; gap: 6px; }
.t-sec-box > summary::-webkit-details-marker { display: none; }
.t-sec-box > summary::before { content: "▸"; font-size: 10px; }
.t-sec-box[open] > summary::before { content: "▾"; }
.t-sec-body { padding: 8px; display: grid; gap: 6px; }
.t-act { display: flex; align-items: center; gap: 9px; width: 100%; text-align: left; padding: 7px 10px; border-radius: 8px; border: 1px solid #cbd5e1; border-bottom-width: 2px; background: #fff; color: var(--t-ink); font-weight: 650; font-size: 12.5px; text-decoration: none; cursor: pointer; }
.t-act i { font-size: 14px; color: var(--t-primary); width: 16px; text-align: center; }
.t-act:hover { background: var(--t-surface-2); border-color: #94a3b8; }
.t-act kbd { margin-left: auto; background: transparent; color: var(--t-faint); font-size: 10.5px; font-family: inherit; padding: 0; }
.t-act.danger { background: #fee2e2; border-color: #fca5a5; color: #991b1b; }
.t-act.danger i { color: #dc2626; }
.t-act.warn { background: #fef9c3; border-color: #fde047; color: #854d0e; }
.t-act.warn i { color: #ca8a04; }
.t-act:disabled, .t-act.off { opacity: .5; pointer-events: none; }
.t-field label { display: block; font-size: 11px; font-weight: 700; color: var(--t-muted); margin-bottom: 3px; }
.t-sum-row { display: flex; justify-content: space-between; gap: 8px; padding: 3px 2px; }
.t-sum-row span { color: var(--t-muted); }
.t-sum-row b { color: var(--t-ink); font-variant-numeric: tabular-nums; }
.t-edge { width: 18px; height: 44px; border-radius: 6px; border: 1px solid #93c5fd; background: var(--t-primary); color: #fff; font-size: 10px; display: grid; place-items: center; padding: 0; }

/* ───────────── Sayfa başlığı ───────────── */
.t-page-head { display: flex; align-items: flex-end; gap: 12px; flex-wrap: wrap; margin-bottom: 14px; }
.t-page-head h1 { font-size: 20px; font-weight: 720; letter-spacing: -.02em; color: var(--t-ink); margin: 0; }
.t-page-head p { margin: 2px 0 0; color: var(--t-muted); }
.t-page-head .t-actions { margin-left: auto; display: flex; gap: 8px; flex-wrap: wrap; }

.btn { --bs-btn-font-size: 12.5px; --bs-btn-font-weight: 600; --bs-btn-padding-y: .36rem; --bs-btn-padding-x: .75rem; border-radius: 8px; display: inline-flex; align-items: center; gap: 6px; }
.btn-primary { --bs-btn-bg: var(--t-primary); --bs-btn-border-color: var(--t-primary); --bs-btn-hover-bg: var(--t-primary-600); --bs-btn-hover-border-color: var(--t-primary-600); box-shadow: 0 1px 2px rgba(37, 99, 235, .3); }
.btn-light { --bs-btn-bg: #fff; --bs-btn-border-color: var(--t-line); --bs-btn-hover-bg: var(--t-surface-2); --bs-btn-hover-border-color: #cbd5e1; --bs-btn-color: var(--t-text); box-shadow: var(--t-shadow); }
.form-control, .form-select { font-size: 12.5px; border-radius: 8px; border-color: var(--t-line); min-height: 32px; padding-top: .3rem; padding-bottom: .3rem; }
.form-control:focus, .form-select:focus { border-color: #93c5fd; box-shadow: 0 0 0 3px rgba(59, 130, 246, .15); }
.dropdown-menu { font-size: 12.5px; border-color: var(--t-line); border-radius: 10px; box-shadow: var(--t-shadow-lg); padding: 6px; }
.dropdown-item { border-radius: 6px; padding: 6px 10px; display: flex; align-items: center; gap: 8px; }

/* ───────────── Kartlar ve özet kutuları ───────────── */
.t-card { background: var(--t-surface); border: 1px solid var(--t-line); border-radius: var(--t-radius); box-shadow: var(--t-shadow); }
.t-card-head { display: flex; align-items: center; gap: 8px; padding: 12px 14px; border-bottom: 1px solid var(--t-line-soft); }
.t-card-head h2 { font-size: 13px; font-weight: 700; color: var(--t-ink); margin: 0; }
.t-card-head .t-link { margin-left: auto; font-weight: 600; text-decoration: none; font-size: 12px; }
.t-card-body { padding: 14px; }

.t-kpis { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 12px; margin-bottom: 14px; }
.t-kpi { background: var(--t-surface); border: 1px solid var(--t-line); border-radius: var(--t-radius); box-shadow: var(--t-shadow); padding: 12px 14px; display: flex; gap: 12px; align-items: center; text-align: left; min-width: 0; }
button.t-kpi { cursor: pointer; transition: border-color .12s, box-shadow .12s; border: 1px solid var(--t-line); }
button.t-kpi:hover { border-color: #bfdbfe; }
button.t-kpi.on { border-color: var(--t-primary); box-shadow: 0 0 0 3px rgba(59, 130, 246, .14); }
.t-kpi-ico { width: 38px; height: 38px; border-radius: 10px; display: grid; place-items: center; font-size: 18px; flex: 0 0 38px; background: var(--t-primary-50); color: var(--t-primary); }
.t-kpi-ico.green { background: var(--t-green-bg); color: var(--t-green); }
.t-kpi-ico.red { background: var(--t-red-bg); color: var(--t-red); }
.t-kpi-ico.amber { background: var(--t-amber-bg); color: var(--t-amber); }
.t-kpi-ico.violet { background: var(--t-violet-bg); color: var(--t-violet); }
.t-kpi-lbl { font-size: 11.5px; color: var(--t-muted); font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.t-kpi-val { font-size: 20px; font-weight: 740; letter-spacing: -.02em; color: var(--t-ink); line-height: 1.2; font-variant-numeric: tabular-nums; white-space: nowrap; }
.t-kpi-val small { font-size: 12px; font-weight: 600; color: var(--t-muted); }
.t-kpi-sub { font-size: 11px; color: var(--t-muted); white-space: nowrap; }
.t-up { color: var(--t-green); font-weight: 700; }
.t-down { color: var(--t-red); font-weight: 700; }

/* rozetler */
.t-badge { display: inline-flex; align-items: center; gap: 5px; font-size: 11px; font-weight: 650; padding: 2px 8px; border-radius: 20px; white-space: nowrap; background: #f1f5f9; color: #475569; }
.t-badge::before { content: ""; width: 6px; height: 6px; border-radius: 50%; background: currentColor; opacity: .85; }
.t-badge.green { background: var(--t-green-bg); color: var(--t-green); }
.t-badge.red { background: var(--t-red-bg); color: var(--t-red); }
.t-badge.amber { background: var(--t-amber-bg); color: var(--t-amber); }
.t-badge.blue { background: var(--t-primary-100); color: var(--t-primary-600); }
.t-badge.violet { background: var(--t-violet-bg); color: var(--t-violet); }
.t-badge.plain::before { display: none; }

/* ───────────── Araç çubuğu ───────────── */
.t-toolbar { display: flex; align-items: center; gap: 8px; padding: 10px 12px; border-bottom: 1px solid var(--t-line-soft); flex-wrap: wrap; }
.t-find { position: relative; flex: 1 1 240px; max-width: 340px; }
.t-find i { position: absolute; left: 10px; top: 50%; transform: translateY(-50%); color: var(--t-faint); }
.t-find input { padding-left: 30px; }
.t-seg { display: inline-flex; background: #eef2f7; border-radius: 8px; padding: 2px; }
.t-seg button { border: 0; background: transparent; font-size: 12px; font-weight: 600; color: var(--t-muted); padding: 4px 10px; border-radius: 6px; white-space: nowrap; }
.t-seg button.on { background: #fff; color: var(--t-ink); box-shadow: var(--t-shadow); }
.t-seg button b { font-weight: 700; color: var(--t-faint); margin-left: 4px; font-size: 11px; }
.t-seg button.on b { color: var(--t-primary); }
.t-toolbar .t-right { margin-left: auto; display: flex; gap: 6px; align-items: center; flex-wrap: wrap; }
.t-tool { height: 32px; display: inline-flex; align-items: center; gap: 6px; padding: 0 10px; border-radius: 8px; border: 1px solid var(--t-line); background: #fff; color: var(--t-text); font-weight: 650; font-size: 12px; white-space: nowrap; cursor: pointer; }
.t-tool:hover { background: var(--t-surface-2); border-color: #cbd5e1; }
.t-tool.on { background: var(--t-primary-50); border-color: #93c5fd; color: var(--t-primary-600); }
.t-chip { display: inline-flex; align-items: center; gap: 6px; background: var(--t-primary-50); color: var(--t-primary-600); border: 1px solid var(--t-primary-100); border-radius: 20px; padding: 2px 4px 2px 10px; font-size: 11.5px; font-weight: 600; }
.t-chip button { border: 0; background: transparent; color: inherit; width: 18px; height: 18px; border-radius: 50%; display: grid; place-items: center; padding: 0; }
.t-chip button:hover { background: var(--t-primary-100); }

/* ───────────── Tabulator (grid) ───────────── */
.t-grid.tabulator { border: 0; background: transparent; font-size: 12.5px; margin: 0; border-radius: 0; }
.t-gridbox { border: 1px solid var(--t-line); border-radius: 10px; overflow: hidden; background: #fff; box-shadow: var(--t-shadow); }
.t-grid .tabulator-header { background: var(--t-primary); border-bottom: 0; border-top: 0; color: #fff; font-weight: 800; }
.t-grid .tabulator-header .tabulator-col { background: var(--t-primary); border-right: 1px solid rgba(255, 255, 255, .28); }
.t-grid .tabulator-header .tabulator-col .tabulator-col-content { padding: 9px 10px; }
.t-grid .tabulator-header .tabulator-col .tabulator-col-title { font-size: 11.5px; letter-spacing: .03em; text-transform: uppercase; color: #fff; text-align: center; padding-right: 14px !important; }
.t-grid .tabulator-header .tabulator-col.tabulator-sortable.tabulator-col-sorter-element:hover { background: var(--t-primary-600); }
.t-grid .tabulator-header .tabulator-col .tabulator-col-sorter .tabulator-arrow { border-bottom-color: rgba(255, 255, 255, .45) !important; border-top-color: rgba(255, 255, 255, .45) !important; }
.t-grid .tabulator-header .tabulator-col[aria-sort="none"] .tabulator-col-sorter { display: none; }
.t-grid .tabulator-header .tabulator-col[aria-sort="none"] .tabulator-col-title { padding-right: 0 !important; }
.t-grid .tabulator-header .tabulator-col[aria-sort="ascending"] .tabulator-arrow { border-bottom-color: #fff !important; }
.t-grid .tabulator-header .tabulator-col[aria-sort="descending"] .tabulator-arrow { border-top-color: #fff !important; }
.t-grid .tabulator-header .tabulator-col .tabulator-header-filter { margin-top: 6px; }
.t-grid .tabulator-header .tabulator-col .tabulator-header-filter input,
.t-grid .tabulator-header .tabulator-col .tabulator-header-filter select { height: 26px; border: 1px solid var(--t-line); border-radius: 6px; padding: 2px 7px !important; font-size: 12px; background: #fff; font-weight: 500; }
.t-grid .tabulator-header .tabulator-col .tabulator-header-filter input:focus { outline: 0; border-color: #93c5fd; box-shadow: 0 0 0 3px rgba(59, 130, 246, .15); }
.t-grid:not(.t-filters) .tabulator-header-filter { display: none; }
.t-grid .tabulator-tableholder { background: #fff; }
.t-grid .tabulator-row { border-bottom: 1px solid var(--t-line); background: #fff; min-height: 34px; color: var(--t-text); }
.t-grid .tabulator-row.tabulator-row-even { background: #f8fafc; }
.t-grid .tabulator-row.tabulator-selectable:hover { background: #f5f8ff; cursor: pointer; }
.t-grid .tabulator-row.tabulator-selected, .t-grid .tabulator-row.tabulator-selected:hover { background: #3b82f6; color: #fff; }
.t-grid .tabulator-row.tabulator-selected .t-code, .t-grid .tabulator-row.tabulator-selected .t-strong, .t-grid .tabulator-row.tabulator-selected .t-two b, .t-grid .tabulator-row.tabulator-selected .t-two small, .t-grid .tabulator-row.tabulator-selected .t-zero { color: #fff; }
.t-grid .tabulator-row .tabulator-cell { padding: 7px 10px; border-right: 1px solid var(--t-line-soft); }
.t-grid.t-dense .tabulator-row { min-height: 29px; }
.t-grid.t-dense .tabulator-row .tabulator-cell { padding: 5px 10px; }
.t-grid .tabulator-row .tabulator-frozen, .t-grid .tabulator-header .tabulator-frozen { border-right: 1px solid var(--t-line) !important; }
.t-grid .tabulator-footer { background: var(--t-surface-2); border-top: 1px solid var(--t-line); padding: 6px 10px; font-weight: 500; color: var(--t-muted); font-size: 12px; }
.t-grid .tabulator-footer .tabulator-calcs-holder { background: #fff !important; border-top: 0; border-bottom: 1px solid var(--t-line); margin: -6px -10px 6px; width: calc(100% + 20px); }
.t-grid .tabulator-footer .tabulator-calcs-holder .tabulator-row { background: #f8fafc !important; font-weight: 700; color: var(--t-ink); border: 0; }
.t-grid .tabulator-footer .tabulator-paginator { font-size: 12px; }
.t-grid .tabulator-footer .tabulator-page { border: 1px solid var(--t-line); background: #fff; border-radius: 6px; margin: 0 2px; padding: 3px 9px; color: var(--t-text); font-weight: 600; }
.t-grid .tabulator-footer .tabulator-page.active { background: var(--t-primary); border-color: var(--t-primary); color: #fff; }
.t-grid .tabulator-footer .tabulator-page:not(.disabled):not(.active):hover { background: var(--t-surface-2); color: var(--t-ink); }
.t-grid .tabulator-footer .tabulator-page-size { border: 1px solid var(--t-line); border-radius: 6px; padding: 3px 6px; }
.t-grid .tabulator-placeholder { background: #fff; }
.t-grid .tabulator-placeholder .tabulator-placeholder-contents { color: var(--t-muted); font-size: 13px; font-weight: 500; }
.t-code { font-weight: 650; color: var(--t-ink); font-variant-numeric: tabular-nums; }
.t-two b { display: block; font-weight: 600; color: var(--t-ink); overflow: hidden; text-overflow: ellipsis; }
.t-two small { color: var(--t-muted); font-size: 11px; }
.t-neg { color: var(--t-red); font-weight: 700; }
.t-zero { color: var(--t-faint); }
.t-strong { font-weight: 700; color: var(--t-ink); }
.t-bar { display: flex; align-items: center; gap: 8px; justify-content: flex-end; }
.t-bar i { display: block; width: 44px; height: 5px; border-radius: 4px; background: #e8edf4; overflow: hidden; flex: 0 0 44px; }
.t-bar i u { display: block; height: 100%; background: #22c55e; border-radius: 4px; }
.t-bar.amber i u { background: #f59e0b; }
.t-bar.red i u { background: #ef4444; }
.t-row-btn { border: 0; background: transparent; color: var(--t-faint); width: 26px; height: 26px; border-radius: 6px; }
.t-row-btn:hover { background: #e8edf4; color: var(--t-ink); }

/* ───────────── Ayrıntı çekmecesi ───────────── */
.offcanvas.t-drawer { --bs-offcanvas-width: 460px; border-left: 1px solid var(--t-line); box-shadow: var(--t-shadow-lg); }
.t-drawer .offcanvas-header { border-bottom: 1px solid var(--t-line); padding: 14px 16px; align-items: flex-start; }
.t-drawer .offcanvas-title { font-size: 15px; font-weight: 720; color: var(--t-ink); }
.t-drawer .offcanvas-body { padding: 14px 16px; }
.t-qty { display: grid; grid-template-columns: repeat(4, 1fr); border: 1px solid var(--t-line); border-radius: var(--t-radius); overflow: hidden; margin-bottom: 14px; }
.t-qty div { padding: 10px 8px; text-align: center; border-right: 1px solid var(--t-line-soft); background: #fff; }
.t-qty div:last-child { border-right: 0; background: var(--t-primary-50); }
.t-qty span { display: block; font-size: 10px; font-weight: 700; letter-spacing: .05em; text-transform: uppercase; color: var(--t-muted); }
.t-qty b { font-size: 17px; font-weight: 740; color: var(--t-ink); font-variant-numeric: tabular-nums; }
.t-qty small { display: block; font-size: 10px; color: var(--t-faint); line-height: 1.25; margin-top: 2px; }
.t-dl { display: grid; grid-template-columns: 120px 1fr; gap: 6px 10px; margin: 0 0 14px; }
.t-dl dt { color: var(--t-muted); font-weight: 500; }
.t-dl dd { margin: 0; color: var(--t-ink); font-weight: 600; }
.t-sec { font-size: 10.5px; font-weight: 700; letter-spacing: .07em; text-transform: uppercase; color: var(--t-muted); margin: 0 0 8px; }
.t-mini-table { width: 100%; border-collapse: collapse; }
.t-mini-table th { font-size: 10.5px; text-transform: uppercase; letter-spacing: .05em; color: var(--t-muted); font-weight: 700; padding: 6px 8px; background: var(--t-surface-2); border-bottom: 1px solid var(--t-line); text-align: left; }
.t-mini-table td { padding: 7px 8px; border-bottom: 1px solid var(--t-line-soft); }
.t-mini-table .r { text-align: right; font-variant-numeric: tabular-nums; }

/* ───────────── Pano parçaları ───────────── */
.t-cols { display: grid; grid-template-columns: minmax(0, 2fr) minmax(0, 1fr); gap: 14px; }
.t-list { list-style: none; margin: 0; padding: 0; }
.t-list li { display: flex; align-items: center; gap: 10px; padding: 9px 14px; border-bottom: 1px solid var(--t-line-soft); }
.t-list li:last-child { border-bottom: 0; }
.t-list .grow { flex: 1; min-width: 0; }
.t-list .grow b { display: block; color: var(--t-ink); font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.t-list .grow small { color: var(--t-muted); font-size: 11px; }
.t-age { display: grid; gap: 10px; }
.t-age div { display: grid; grid-template-columns: 104px 1fr 92px; align-items: center; gap: 10px; }
.t-age span { color: var(--t-muted); font-weight: 600; font-size: 12px; }
.t-age i { display: block; height: 8px; border-radius: 6px; background: #eef2f7; overflow: hidden; }
.t-age i u { display: block; height: 100%; border-radius: 6px; background: #3b82f6; }
.t-age b { text-align: right; font-variant-numeric: tabular-nums; color: var(--t-ink); }
.t-spark { display: flex; align-items: flex-end; gap: 6px; height: 120px; padding-top: 6px; }
.t-spark div { flex: 1; display: flex; flex-direction: column; align-items: center; justify-content: flex-end; gap: 5px; height: 100%; }
.t-spark u { display: block; width: 100%; max-width: 34px; border-radius: 5px 5px 2px 2px; background: #bfdbfe; text-decoration: none; }
.t-spark div:last-child u { background: #2563eb; }
.t-spark small { font-size: 10.5px; color: var(--t-muted); }

/* ───────────── Dış İskelet (Giriş & view.php) ───────────── */
.toya-external-body {
  background-color: var(--t-bg);
  color: var(--t-text);
  font-family: var(--t-font);
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}
.toya-brand-mark {
  width: 38px;
  height: 38px;
  border-radius: 8px;
  background: #fff url("../ikon/logo.png") center/cover no-repeat;
  display: inline-block;
  flex-shrink: 0;
}
.err {
  background-color: var(--t-red-bg);
  color: var(--t-red);
  border: 1px solid #fecaca;
  padding: 0.75rem 1rem;
  border-radius: var(--t-radius-sm);
  margin-bottom: 1rem;
  font-weight: 500;
  font-size: 13px;
}
.okm {
  background-color: var(--t-green-bg);
  color: var(--t-green);
  border: 1px solid #bbf7d0;
  padding: 0.75rem 1rem;
  border-radius: var(--t-radius-sm);
  margin-bottom: 1rem;
  font-weight: 500;
  font-size: 13px;
}
.banner.bad { background-color: var(--t-red-bg); color: var(--t-red); border: 1px solid #fecaca; padding: 0.75rem 1rem; border-radius: var(--t-radius-sm); margin-bottom: 1rem; }
.banner.ok { background-color: var(--t-green-bg); color: var(--t-green); border: 1px solid #bbf7d0; padding: 0.75rem 1rem; border-radius: var(--t-radius-sm); margin-bottom: 1rem; }
.banner.info { background-color: var(--t-primary-50); color: var(--t-primary-600); border: 1px solid var(--t-primary-100); padding: 0.75rem 1rem; border-radius: var(--t-radius-sm); margin-bottom: 1rem; }

/* view.php ve teklif dökümü stilleri */
.firm { display: flex; flex-wrap: wrap; gap: 1rem; align-items: center; justify-content: space-between; }
.firm .id { display: flex; gap: 0.85rem; align-items: center; }
.firm img { max-height: 56px; max-width: 180px; object-fit: contain; }
.firm .name { font-weight: 700; font-size: 1.15rem; }
.meta { display: grid; grid-template-columns: repeat(auto-fit, minmax(170px, 1fr)); gap: 0.65rem; margin-top: 1rem; }
.meta div { background: var(--t-surface-2); border: 1px solid var(--t-line); border-radius: var(--t-radius-sm); padding: 0.5rem 0.75rem; }
.meta b { display: block; font-size: 0.6875rem; color: var(--t-muted); text-transform: uppercase; letter-spacing: 0.04em; }
.sums { margin-left: auto; max-width: 360px; width: 100%; margin-top: 1rem; }
.sums div { display: flex !important; justify-content: space-between !important; align-items: center !important; gap: 1.5rem !important; padding: 0.35rem 0 !important; font-size: 13px; border-bottom: 1px dashed var(--t-line); }
.sums .g { font-size: 1.15rem !important; font-weight: 800 !important; border-top: 2px solid var(--t-line) !important; border-bottom: none !important; margin-top: 0.5rem !important; padding-top: 0.5rem !important; color: var(--t-ink); }
.bar { display: flex; flex-wrap: wrap; gap: 0.5rem; margin-bottom: 1rem; }
.actions { display: flex; flex-wrap: wrap; gap: 0.5rem; }
.b-ok { background-color: var(--t-green) !important; border-color: var(--t-green) !important; color: #fff !important; }
.b-bad { background-color: var(--t-red) !important; border-color: var(--t-red) !important; color: #fff !important; }
.b-cnt { background-color: var(--t-primary) !important; border-color: var(--t-primary) !important; color: #fff !important; }
.b-sec { background-color: var(--t-surface) !important; color: var(--t-text) !important; border: 1px solid var(--t-line) !important; }
dialog { width: min(920px, 96vw); max-height: 92vh; border: 1px solid var(--t-line); border-radius: var(--t-radius); padding: 0; background: var(--t-surface); color: var(--t-text); }
dialog::backdrop { background: rgba(15, 23, 42, 0.55); }
.dlg-h { display: flex; justify-content: space-between; align-items: center; padding: 0.75rem 1rem; border-bottom: 1px solid var(--t-line); position: sticky; top: 0; background: var(--t-surface); }
.dlg-b { padding: 1rem; overflow: auto; max-height: calc(92vh - 60px); }
.kv { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 0.5rem 1rem; margin-bottom: 1rem; }
.kv span { color: var(--t-muted); font-size: 0.75rem; display: block; }
@media (max-width: 640px) { .hide-m { display: none !important; } }

/* ───────────── Yazdırma ───────────── */
@media print {
  body { background: #ffffff !important; color: #000000 !important; }
  .t-top, .t-mods, .t-tabs, .bar, .no-print, #actions, footer { display: none !important; }
  .t-main, .t-content { padding: 0 !important; background: transparent !important; }
  .t-card, .t-panel { border: 0 !important; box-shadow: none !important; padding: 0 !important; }
  .wrap { max-width: none !important; padding: 0 !important; }
  body.print-report .wrap > *:not(dialog) { display: none !important; }
  body.print-report dialog { display: block !important; position: static !important; width: auto !important; max-height: none !important; border: 0 !important; }
  body.print-report .dlg-h { display: none !important; }
  body.print-report .dlg-b { max-height: none !important; overflow: visible !important; }
}

/* ───────────── Duyarlı ───────────── */
@media (max-width: 1199.98px) {
  .t-kpis { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .t-cols { grid-template-columns: minmax(0, 1fr); }
  .t-three, body.t-no-left .t-three, body.t-no-right .t-three { grid-template-columns: minmax(0, 1fr); }
  .t-pane { position: static; grid-template-columns: repeat(2, minmax(0, 1fr)); align-items: start; }
  .t-three .t-center { order: -1; }
  .t-edge { display: none; }
}
@media (max-width: 991.98px) {
  .t-home { grid-template-columns: minmax(0, 1fr); }
  .t-search, .t-pill span, .t-brand small { display: none; }
  .t-pill { padding: 0 9px; }
  .t-burger { display: grid; place-items: center; }
  .t-mods { display: none; position: fixed; inset: var(--t-top-h) 0 0 0; z-index: 1040; flex-direction: column; align-items: stretch; overflow-y: auto; padding: 12px; }
  body.t-open .t-mods { display: flex; }
  .t-mod > button, .t-mod > a { width: 100%; height: 40px; }
  .t-mod .dropdown-menu { position: static !important; transform: none !important; display: block; margin: 4px 0 8px; box-shadow: none; }
  .t-mods .t-state { margin: 8px 0 0; padding: 0; }
  .t-content { padding: 10px 10px 20px; }
  .t-page-head h1 { font-size: 18px; }
  .t-toolbar .t-right { margin-left: 0; }
  .t-find { max-width: none; flex-basis: 100%; }
  .offcanvas.t-drawer { --bs-offcanvas-width: 100vw; }
  .t-menu { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .t-menu a img { width: 60px; height: 60px; }
}
@media (max-width: 575.98px) {
  .t-kpis { gap: 8px; }
  .t-kpi { padding: 10px; gap: 9px; }
  .t-kpi-ico { width: 32px; height: 32px; flex-basis: 32px; font-size: 15px; }
  .t-kpi-val { font-size: 16px; }
  .t-page-head .t-actions { margin-left: 0; width: 100%; }
  .t-seg { overflow-x: auto; max-width: 100%; display: flex; scrollbar-width: none; -webkit-overflow-scrolling: touch; }
  .t-seg button { flex: 0 0 auto; padding: 4px 8px; font-size: 11.5px; }
  .t-pane { grid-template-columns: minmax(0, 1fr); }
  .t-tabs { overflow-x: auto; }
  .t-center { min-width: 0; max-width: 100%; }
  .t-toolbar { padding: 8px 10px; gap: 6px; }
  .t-find { flex: 1 1 100%; max-width: 100%; }
  .tabulator .tabulator-footer { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; gap: 6px; padding: 6px 8px; }
  .tabulator .tabulator-footer .tabulator-paginator { display: flex; flex-wrap: wrap; align-items: center; gap: 2px; }
  .tabulator .tabulator-page-size { font-size: 11px; padding: 2px 4px; }
  .tabulator .tabulator-page { padding: 2px 6px; min-width: 24px; font-size: 11px; }
}
