@charset "UTF-8";
/* =====================================================================
   PerdeFlow — TASARIM SİSTEMİ v3
   =====================================================================
   TEMEL: assets/css/ornek.css (Demsoft Mobil v5 tasarım sistemi).
   Bu dosya onu OLDUĞU GİBİ içerir, üstüne iki şey ekler:

     A) YAZI TİPLERİ YERELDEN
        Örnek dosya yazı tiplerini Google Fonts'tan çekiyordu. Atölyede
        internet olmayabilir ve uygulama Cordova ile paketlenecek; CDN
        kesilirse ekran çıplak kalır. Bu yüzden Plus Jakarta Sans ve
        JetBrains Mono assets/fonts/ içinden yükleniyor.

     B) UYUM KATMANI (en altta)
        Projede 25'ten fazla sayfa, kendi sınıf dağarcığıyla yazılmıştı
        (.panel, .inp, .pill, .kpi-val ...). O sayfaların HTML'ini tek tek
        değiştirmek yerine, bu sınıflar örnek tasarımın görünümüne
        bağlandı. Sonuç: tüm eski ekranlar yeni tasarımı anında aldı,
        yeni ekranlar doğrudan örnek dağarcığıyla (.card, .btn-light,
        .badge ...) yazılıyor.

   YENİ EKRAN YAZARKEN: örnek dosyanın sınıflarını kullanın
   (.card, .card-h, .btn-primary, .badge b-ok, .tbl, .field, .modal).
   Eski sınıflar yalnızca geriye dönük uyum içindir.

   KOYU TEMA: <html data-theme="dark"> ile açılır; kullanıcı menüsünden
   seçilir ve localStorage'da saklanır (assets/js/core/auth.js).
   ===================================================================== */

/* ---------------------------------------------------------------------
   YAZI TİPLERİ — yerelden, değişken ağırlıklı (200–800 tek dosyada)
   Türkçe kapsamı iki alt kümeden gelir:
     latin     → ı ç ö ü â  (U+0131 dahil)
     latin-ext → ğ Ğ ş Ş İ
   --------------------------------------------------------------------- */
@font-face {
  font-family: 'Plus Jakarta Sans';
  font-style: normal;
  font-display: swap;
  font-weight: 200 800;
  src: url('../fonts/jakarta-latin-ext.woff2') format('woff2-variations');
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7,
                 U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF,
                 U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB,
                 U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
@font-face {
  font-family: 'Plus Jakarta Sans';
  font-style: normal;
  font-display: swap;
  font-weight: 200 800;
  src: url('../fonts/jakarta-latin.woff2') format('woff2-variations');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6,
                 U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F,
                 U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215,
                 U+FEFF, U+FFFD;
}
@font-face {
  font-family: 'JetBrains Mono';
  font-style: normal;
  font-display: swap;
  font-weight: 100 800;
  src: url('../fonts/mono-latin-ext.woff2') format('woff2-variations');
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7,
                 U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF,
                 U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB,
                 U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
@font-face {
  font-family: 'JetBrains Mono';
  font-style: normal;
  font-display: swap;
  font-weight: 100 800;
  src: url('../fonts/mono-latin.woff2') format('woff2-variations');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6,
                 U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F,
                 U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215,
                 U+FEFF, U+FFFD;
}


/* =====================================================================
   TEMEL TASARIM — assets/css/ornek.css'ten olduğu gibi alındı
   Renkleri değiştirmek için yalnızca :root içindeki değişkenleri
   değiştirin; tüm ekranlar ona göre döner.
   ===================================================================== */

/* ---------------- 1. TEMA DEĞİŞKENLERİ ---------------- */
:root {
  --bg: #f1f4fa;
  --surface: #ffffff;
  --surface-2: #f7f9fc;
  --surface-3: #eaeef6;
  --line: #e0e6f0;
  --line-strong: #c9d3e2;
  --text: #0e1630;
  --text-2: #36425c;
  --muted: #66728a;

  /* Ana marka rengi (butonlar, seçili menü, vurgu) */
  --brand: #2f5bea;
  --brand-600: #2449c8;
  --brand-700: #1b399f;
  --brand-50: #edf2ff;
  --brand-100: #d9e3ff;
  --brand-grad: linear-gradient(135deg, #3b6cff 0%, #2f5bea 45%, #6a3df0 100%);

  /* Sol menü (koyu lacivert) */
  --nav: #0d1530;
  --nav-2: #18234a;
  --nav-text: #c3cbe3;

  /* Durum renkleri */
  --ok: #0f9d58;      --ok-bg: #defbea;     --ok-line: #8fe3b4;
  --warn: #b26a00;    --warn-bg: #fff3d6;   --warn-line: #ffd27a;
  --danger: #d0352b;  --danger-bg: #ffe6e3; --danger-line: #ffaaa2;
  --info: #0b7fc7;    --info-bg: #dff1ff;   --info-line: #98d2fa;
  --violet: #7a3ff2;  --violet-bg: #efe7ff; --violet-line: #c9b1ff;
  --pink: #e0457b;    --pink-bg: #ffe6ef;
  --teal: #0b9e95;    --teal-bg: #d9f7f4;

  --radius: 16px;
  --radius-sm: 12px;
  --radius-lg: 22px;
  --tap: 52px;               /* parmak dostu minimum yükseklik */
  --shadow-sm: 0 1px 2px rgba(14, 22, 48, .05), 0 1px 3px rgba(14, 22, 48, .07);
  --shadow: 0 8px 24px rgba(14, 22, 48, .08), 0 2px 6px rgba(14, 22, 48, .05);
  --shadow-lg: 0 24px 60px rgba(14, 22, 48, .24);
  --font: "Plus Jakarta Sans", "Segoe UI", system-ui, -apple-system, Roboto, sans-serif;
  --mono: "JetBrains Mono", ui-monospace, Consolas, monospace;
  --top-h: 66px;
  --bottom-h: 72px;
  --rail-w: 252px;
  color-scheme: light;
}

/* Koyu tema — kullanıcı menüsünden açılır (localStorage: dm5_tema) */
[data-theme="dark"] {
  --bg: #0a0f1f;
  --surface: #121a31;
  --surface-2: #17203b;
  --surface-3: #1d2847;
  --line: #26325a;
  --line-strong: #34426f;
  --text: #e8edfb;
  --text-2: #c2cbe4;
  --muted: #8d99bb;
  --brand-50: #1a2650;
  --brand-100: #253a7a;
  --nav: #070b18;
  --nav-2: #141d3a;
  --ok-bg: #0e3324; --warn-bg: #3a2a07; --danger-bg: #3d1513; --info-bg: #0c2a42; --violet-bg: #29184f;
  --pink-bg: #3d1424; --teal-bg: #083633;
  --shadow-sm: 0 1px 2px rgba(0,0,0,.4);
  --shadow: 0 8px 24px rgba(0,0,0,.35);
  color-scheme: dark;
}

/* ---------------- 2. TEMEL ---------------- */
* { box-sizing: border-box; margin: 0; padding: 0; }
html { -webkit-text-size-adjust: 100%; }
body {
  font-family: var(--font); font-size: 15.5px; line-height: 1.45;
  color: var(--text); background: var(--bg);
  -webkit-font-smoothing: antialiased; -webkit-tap-highlight-color: transparent;
  min-height: 100vh;
}
button, input, select, textarea { font-family: inherit; font-size: inherit; color: inherit; }
button { cursor: pointer; background: none; border: 0; }
a { color: var(--brand); }
img, svg { display: block; }
.hidden { display: none !important; }
.ic { width: 21px; height: 21px; flex: none; }
.ic-sm { width: 17px; height: 17px; }
.ic-lg { width: 28px; height: 28px; }
.ic-xl { width: 40px; height: 40px; }
.muted { color: var(--muted); }
.small { font-size: 13.5px; }
.tiny { font-size: 12px; }
.bold { font-weight: 800; }
.mono { font-family: var(--mono); letter-spacing: .02em; }
.num { font-variant-numeric: tabular-nums; }
.t-ok { color: var(--ok) !important; } .t-danger { color: var(--danger) !important; } .t-warn { color: var(--warn) !important; }
.row { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; }
.grow { flex: 1; min-width: 0; }
.stack { display: flex; flex-direction: column; gap: 16px; }
hr { border: 0; border-top: 1px solid var(--line); margin: 14px 0; }
.ellipsis { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }

/* ---------------- 3. BUTONLAR ---------------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 9px;
  min-height: var(--tap); padding: 0 20px; border-radius: var(--radius-sm);
  font-weight: 700; font-size: 15.5px; border: 1px solid transparent;
  transition: background .15s, box-shadow .15s, transform .06s, border-color .15s;
  white-space: nowrap; text-decoration: none; user-select: none;
}
.btn:active { transform: translateY(1px) scale(.99); }
.btn:disabled { opacity: .5; pointer-events: none; }
.btn-primary { background: var(--brand-grad); color: #fff; box-shadow: 0 8px 18px rgba(47, 91, 234, .28); }
.btn-primary:hover { filter: brightness(1.06); }
.btn-ok { background: var(--ok); color: #fff; }
.btn-danger { background: var(--danger); color: #fff; }
.btn-light { background: var(--surface); color: var(--text); border-color: var(--line-strong); }
.btn-light:hover { background: var(--surface-2); }
.btn-soft { background: var(--brand-50); color: var(--brand-700); border-color: var(--brand-100); }
[data-theme="dark"] .btn-soft { color: #b9c9ff; }
.btn-soft:hover { background: var(--brand-100); }
.btn-ghost { color: var(--text-2); }
.btn-ghost:hover { background: var(--surface-3); }
.btn-sm { min-height: 42px; padding: 0 14px; font-size: 14.5px; border-radius: 10px; }
.btn-lg { min-height: 60px; font-size: 17px; padding: 0 26px; border-radius: 14px; }
.btn-block { width: 100%; }
.btn-icon { width: var(--tap); padding: 0; }
.btn-icon.btn-sm { width: 42px; }

/* Yuvarlak iletişim butonları (Ara / SMS / WhatsApp / E-posta / Konum) */
.qa { display: flex; gap: 10px; flex-wrap: wrap; }
.qa a, .qa button {
  flex: 1 1 70px; display: flex; flex-direction: column; align-items: center; gap: 6px;
  padding: 12px 6px; border-radius: 16px; text-decoration: none; color: var(--text-2);
  background: var(--surface); border: 1px solid var(--line); font-size: 12.5px; font-weight: 700;
  transition: transform .08s, border-color .15s;
}
.qa a:hover, .qa button:hover { border-color: var(--brand-100); transform: translateY(-1px); }
.qa .ci { width: 44px; height: 44px; border-radius: 14px; display: grid; place-items: center; color: #fff; }
.ci.c-call { background: #0f9d58; } .ci.c-sms { background: #0b7fc7; } .ci.c-wa { background: #25a244; }
.ci.c-mail { background: #e0457b; } .ci.c-map { background: #b26a00; } .ci.c-share { background: #7a3ff2; }
.ci.c-qr { background: #0d1530; } .ci.c-pdf { background: #d0352b; } .ci.c-cal { background: #0b9e95; }

/* ---------------- 4. FORM ---------------- */
.field { display: flex; flex-direction: column; gap: 6px; margin-bottom: 14px; position: relative; }
.field > label { font-size: 13.5px; font-weight: 700; color: var(--text-2); display: flex; align-items: center; gap: 6px; }
.field > label .req { color: var(--danger); }
.field .help { font-size: 12.5px; color: var(--muted); }
.field .err-msg { font-size: 12.5px; color: var(--danger); font-weight: 700; display: none; }
.field.invalid .err-msg { display: block; }
.field.invalid input, .field.invalid select, .field.invalid textarea { border-color: var(--danger) !important; }
.field.valid input { border-color: var(--ok) !important; }
/* !!! SEÇİCİ ÖZGÜLLÜĞÜ — BİR KEZ HATAYA SEBEP OLDU, DİKKAT !!!
   Burada eskiden şöyle yazıyordu:
       .field input:not([type=checkbox]):not([type=radio]):not([type=range])
   Üç :not() seçiciyi o kadar ağırlaştırıyordu ki (0,4,1), aşağıdaki
       .search .inp   { padding-left: 46px }   (0,2,0)
       .with-unit .inp{ padding-right: 44px }  (0,2,0)
   kuralları EZİLİYOR; arama büyüteci yazının üstüne biniyor, birim
   rozeti (₺ / cm / %) sayının üstünde duruyordu.
   Çözüm: taban kural sade tutuldu, kutucuk/radyo/kaydırıcı hemen
   altında ayrıca sıfırlandı. YENİ KURAL EKLERKEN ÖZGÜLLÜĞÜ BÜYÜTMEYİN. */
.input, .field input, .field select, .field textarea {
  width: 100%; min-height: var(--tap); padding: 0 15px; border-radius: var(--radius-sm);
  border: 1.5px solid var(--line-strong); background: var(--surface); color: var(--text);
  font-size: 16px; outline: none; transition: border-color .15s, box-shadow .15s;
}
/* Kutucuk, radyo ve kaydırıcı metin alanı gibi davranmaz */
.field input[type=checkbox], .field input[type=radio] {
  width: auto; min-height: 0; padding: 0; border: 0;
  border-radius: 0; background: none;
}
.field input[type=range] {
  min-height: 0; padding: 0; border: 0; background: none;
}
.field textarea { padding: 12px 15px; min-height: 92px; resize: vertical; }
.input:focus, .field input:focus, .field select:focus, .field textarea:focus {
  border-color: var(--brand); box-shadow: 0 0 0 4px rgba(47, 91, 234, .15);
}
::placeholder { color: #93a0b8; }
select, .field select {
  -webkit-appearance: none; appearance: none; cursor: pointer; font-weight: 600; padding-right: 44px !important;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='20' height='20' viewBox='0 0 24 24' fill='none' stroke='%232f5bea' stroke-width='2.5' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m6 9 6 6 6-6'/%3E%3C/svg%3E");
  background-repeat: no-repeat; background-position: right 13px center;
}
.input-icon { position: relative; }
.input-icon > .ic { position: absolute; left: 15px; top: 50%; transform: translateY(-50%); color: var(--muted); pointer-events: none; }
.input-icon input { padding-left: 46px !important; }
.input-act { position: relative; }
.input-act input { padding-right: 56px !important; }
.input-act > button { position: absolute; right: 5px; top: 50%; transform: translateY(-50%); width: 44px; height: 44px; border-radius: 10px; display: grid; place-items: center; color: var(--brand); }
.input-act > button:hover { background: var(--brand-50); }
.grid-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 0 14px; }
.grid-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 0 14px; }
.span-2 { grid-column: span 2; }
@media (max-width: 640px) { .grid-2, .grid-3 { grid-template-columns: 1fr; } .span-2 { grid-column: auto; } }

/* Seçim düğmeleri (select yerine dokunmatik) */
.seg { display: flex; flex-wrap: wrap; gap: 8px; }
.seg button {
  flex: 1 1 auto; min-height: 46px; padding: 0 14px; border-radius: var(--radius-sm);
  border: 1.5px solid var(--line-strong); background: var(--surface); color: var(--text-2); font-weight: 700;
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
}
.seg button.on { background: var(--brand); border-color: var(--brand); color: #fff; box-shadow: 0 4px 12px rgba(47, 91, 234, .25); }

/* Anahtar (switch) */
.switch { display: flex; align-items: center; gap: 12px; min-height: var(--tap); padding: 0 14px; border: 1.5px solid var(--line-strong); border-radius: var(--radius-sm); background: var(--surface); cursor: pointer; font-weight: 700; user-select: none; }
.switch input { display: none; }
.switch i { width: 46px; height: 28px; border-radius: 14px; background: var(--line-strong); position: relative; flex: none; transition: background .15s; margin-left: auto; }
.switch i::after { content: ""; position: absolute; top: 3px; left: 3px; width: 22px; height: 22px; border-radius: 50%; background: #fff; box-shadow: var(--shadow-sm); transition: transform .15s; }
.switch input:checked + span + i { background: var(--ok); }
.switch input:checked + span + i::after { transform: translateX(18px); }

/* Çip filtreler (liste üstü) */
.chips { display: flex; gap: 8px; overflow-x: auto; padding-bottom: 4px; scrollbar-width: none; }
.chips::-webkit-scrollbar { display: none; }
.chip {
  flex: none; display: inline-flex; align-items: center; gap: 7px; height: 40px; padding: 0 15px;
  border-radius: 20px; border: 1.5px solid var(--line-strong); background: var(--surface);
  color: var(--text-2); font-weight: 700; font-size: 14px;
}
.chip .n { min-width: 22px; height: 22px; padding: 0 6px; border-radius: 11px; display: grid; place-items: center; font-size: 11.5px; background: var(--surface-3); }
.chip.on { background: var(--nav); border-color: var(--nav); color: #fff; }
.chip.on .n { background: rgba(255, 255, 255, .18); }
[data-theme="dark"] .chip.on { background: var(--brand); border-color: var(--brand); }

/* ---------------- 5. UYGULAMA İSKELETİ ---------------- */
.shell { min-height: 100vh; padding-left: var(--rail-w); padding-bottom: calc(var(--bottom-h) + env(safe-area-inset-bottom)); }
@media (min-width: 761px) { .shell { padding-bottom: 0; } }

/* Sol menü */
.rail {
  position: fixed; inset: 0 auto 0 0; width: var(--rail-w); z-index: 30;
  background: var(--nav); color: var(--nav-text); display: flex; flex-direction: column;
  padding: 14px 12px 16px; overflow-y: auto; scrollbar-width: thin;
}
.rail-brand { display: flex; align-items: center; gap: 12px; padding: 6px 8px 14px; color: #fff; text-decoration: none; }
.logo { width: 44px; height: 44px; border-radius: 14px; flex: none; display: grid; place-items: center; color: #fff; background: var(--brand-grad); box-shadow: 0 8px 20px rgba(59, 108, 255, .4); font-weight: 800; font-size: 19px; }
.rail-brand b { display: block; font-size: 18px; letter-spacing: -.01em; }
.rail-brand small { display: block; font-size: 11.5px; color: #8796c4; font-weight: 600; }
.rail-co { margin: 0 4px 10px; padding: 10px 12px; border-radius: 14px; background: var(--nav-2); display: flex; gap: 10px; align-items: center; color: #fff; text-align: left; width: calc(100% - 8px); }
.rail-co small { display: block; color: #8796c4; font-size: 11.5px; font-weight: 600; }
.rail-co b { display: block; font-size: 13.5px; }
.rail-group { font-size: 10.5px; font-weight: 800; letter-spacing: .1em; text-transform: uppercase; color: #6876a6; padding: 14px 12px 6px; }
.rail a { display: flex; align-items: center; gap: 13px; min-height: 46px; padding: 0 13px; border-radius: 12px; color: var(--nav-text); text-decoration: none; font-weight: 600; font-size: 14.5px; position: relative; }
.rail a:hover { background: var(--nav-2); color: #fff; }
.rail a.on { background: #fff; color: var(--nav); font-weight: 800; }
.rail a.on .ic { color: var(--brand); }
.rail a.lock { opacity: .45; }
.rail a .cnt { margin-left: auto; min-width: 24px; height: 22px; padding: 0 7px; border-radius: 11px; display: grid; place-items: center; font-size: 11.5px; font-weight: 800; background: #ff5d7a; color: #fff; }
.rail a .soon { margin-left: auto; font-size: 10px; font-weight: 800; letter-spacing: .05em; color: #6876a6; }

/* Üst bar */
.topbar {
  position: sticky; top: 0; z-index: 20; height: var(--top-h);
  display: flex; align-items: center; gap: 10px; padding: 0 20px;
  background: color-mix(in srgb, var(--surface) 92%, transparent);
  backdrop-filter: saturate(1.4) blur(12px); -webkit-backdrop-filter: saturate(1.4) blur(12px);
  border-bottom: 1px solid var(--line);
}
.topbar .title { display: flex; align-items: center; gap: 12px; min-width: 0; flex: 1; }
.topbar .title .pic { width: 42px; height: 42px; border-radius: 12px; display: grid; place-items: center; background: var(--brand-50); color: var(--brand); flex: none; }
.topbar h1 { font-size: 19px; font-weight: 800; letter-spacing: -.015em; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.topbar .sub { font-size: 12.5px; color: var(--muted); font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.searchbox {
  display: flex; align-items: center; gap: 10px; height: 44px; padding: 0 14px; min-width: 260px;
  border-radius: 12px; background: var(--surface-3); color: var(--muted); font-weight: 600; font-size: 14px;
}
.searchbox kbd { margin-left: auto; font-family: var(--mono); font-size: 11px; padding: 2px 6px; border-radius: 6px; background: var(--surface); border: 1px solid var(--line); }
.tbtn { position: relative; width: 46px; height: 46px; border-radius: 13px; display: grid; place-items: center; color: var(--text-2); }
.tbtn:hover { background: var(--surface-3); }
.tbtn .dot { position: absolute; top: 5px; right: 5px; min-width: 18px; height: 18px; padding: 0 4px; border-radius: 9px; background: #ff5d7a; color: #fff; font-size: 10.5px; font-weight: 800; display: grid; place-items: center; border: 2px solid var(--surface); }
.userchip { display: flex; align-items: center; gap: 9px; padding: 4px 12px 4px 4px; border-radius: 30px; border: 1px solid var(--line); background: var(--surface); margin-left: 4px; }
.userchip b { font-size: 13.5px; display: block; line-height: 1.1; }
.userchip small { font-size: 11.5px; color: var(--muted); display: block; }
.avatar { width: 40px; height: 40px; border-radius: 50%; flex: none; display: grid; place-items: center; font-weight: 800; font-size: 15px; background: var(--brand-100); color: var(--brand-700); }
.avatar.sq { border-radius: 14px; }
.menu-btn { display: none; }
.content { padding: 22px 24px 34px; max-width: 1560px; margin: 0 auto; }
.app-foot { display: flex; justify-content: space-between; gap: 12px; max-width: 1560px; margin: 0 auto; padding: 4px 24px 18px; color: var(--muted); font-size: 12px; font-weight: 600; }

/* Alt menü (yalnız mobil) */
.bottom-nav {
  position: fixed; left: 0; right: 0; bottom: 0; z-index: 40; display: none;
  height: calc(var(--bottom-h) + env(safe-area-inset-bottom)); padding-bottom: env(safe-area-inset-bottom);
  background: var(--surface); border-top: 1px solid var(--line); box-shadow: 0 -6px 20px rgba(14, 22, 48, .06);
}
.bottom-nav a, .bottom-nav button { flex: 1; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 3px; color: var(--muted); text-decoration: none; font-size: 11.5px; font-weight: 700; position: relative; }
.bottom-nav a .ic, .bottom-nav button .ic { width: 24px; height: 24px; }
.bottom-nav a.on { color: var(--brand); }
.bottom-nav a.on::before { content: ""; position: absolute; top: 0; left: 30%; right: 30%; height: 3px; background: var(--brand); border-radius: 0 0 3px 3px; }
.bottom-nav .fab { width: 62px; height: 62px; margin-top: -24px; border-radius: 20px; background: var(--brand-grad); color: #fff; display: grid; place-items: center; box-shadow: 0 10px 24px rgba(47, 91, 234, .45); border: 4px solid var(--surface); }
.bottom-nav .fab .ic { width: 30px; height: 30px; }
.scrim { position: fixed; inset: 0; background: rgba(8, 12, 30, .5); z-index: 25; }

/* Tablet: menü daralır, sadece ikon */
@media (max-width: 1180px) and (min-width: 761px) {
  :root { --rail-w: 92px; }
  .rail { padding: 12px 8px; }
  .rail-brand { justify-content: center; padding: 4px 0 12px; }
  .rail-brand > div:not(.logo), .rail-group, .rail-co > div, .rail a .soon { display: none; }
  .rail-co { justify-content: center; padding: 8px; }
  .rail a { flex-direction: column; justify-content: center; gap: 3px; min-height: 62px; padding: 6px 4px; font-size: 11px; text-align: center; line-height: 1.15; }
  .rail a .cnt { position: absolute; top: 4px; right: 8px; margin: 0; min-width: 18px; height: 18px; font-size: 10px; padding: 0 4px; }
  .searchbox { min-width: 0; } .searchbox span, .searchbox kbd { display: none; }
}
/* Telefon: menü çekmece olur, alt bar görünür */
@media (max-width: 760px) {
  :root { --rail-w: 0px; --top-h: 60px; }
  .rail { width: 286px; transform: translateX(-105%); transition: transform .22s ease; box-shadow: var(--shadow-lg); }
  .rail.open { transform: none; }
  .menu-btn { display: grid; }
  .bottom-nav { display: flex; }
  .topbar { padding: 0 8px; gap: 4px; }
  .topbar .title .pic, .searchbox, .userchip > div, .hide-sm { display: none !important; }
  .userchip { padding: 3px; border: 0; }
  .topbar h1 { font-size: 17.5px; }
  .content { padding: 14px 12px 24px; }
  .app-foot { padding: 4px 12px 14px; }
}

/* ---------------- 6. KART & KPI ---------------- */
.card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius-lg); box-shadow: var(--shadow-sm); padding: 20px; }
.card-h { display: flex; align-items: center; gap: 10px; margin-bottom: 14px; flex-wrap: wrap; }
.card-h h2, .card-h h3 { font-size: 16.5px; font-weight: 800; letter-spacing: -.01em; display: flex; align-items: center; gap: 9px; }
.card-h h2 .ic, .card-h h3 .ic { color: var(--brand); }
.card-h .sub { font-size: 12.5px; color: var(--muted); font-weight: 600; }
.card-h .right { margin-left: auto; display: flex; gap: 6px; align-items: center; flex-wrap: wrap; }
.page-head { display: flex; align-items: flex-end; gap: 14px; flex-wrap: wrap; margin-bottom: 18px; }
.page-head h2 { font-size: 26px; letter-spacing: -.025em; }
.page-head p { color: var(--muted); font-weight: 600; }
.page-head .right { margin-left: auto; display: flex; gap: 8px; flex-wrap: wrap; }

/* KPI kutuları (renkli, mini grafikli) */
.kpis { display: grid; grid-template-columns: repeat(auto-fit, minmax(190px, 1fr)); gap: 14px; margin-bottom: 18px; }
.kpi {
  position: relative; overflow: hidden; border-radius: var(--radius-lg); padding: 16px 18px 12px; color: #fff;
  min-height: 136px; display: flex; flex-direction: column; text-decoration: none; box-shadow: var(--shadow);
}
.kpi::after { content: ""; position: absolute; right: -40px; top: -40px; width: 140px; height: 140px; border-radius: 50%; background: rgba(255, 255, 255, .1); }
.kpi .top { display: flex; align-items: center; gap: 10px; font-weight: 700; font-size: 13.5px; opacity: .95; }
.kpi .top .ki { width: 34px; height: 34px; border-radius: 10px; background: rgba(255, 255, 255, .2); display: grid; place-items: center; }
.kpi .top .ki .ic { width: 18px; height: 18px; }
.kpi .v { font-size: clamp(21px, 2vw, 27px); font-weight: 800; letter-spacing: -.02em; margin-top: 10px; font-variant-numeric: tabular-nums; white-space: nowrap; }
.kpi .d { font-size: 12.5px; font-weight: 700; display: flex; align-items: center; gap: 5px; opacity: .95; }
.kpi .d .ic { width: 15px; height: 15px; }
.kpi .spark { margin-top: auto; height: 34px; margin-left: -4px; margin-right: -4px; }
.kpi.k1 { background: linear-gradient(135deg, #3b6cff, #6a3df0); }
.kpi.k2 { background: linear-gradient(135deg, #10b981, #0b8f74); }
.kpi.k3 { background: linear-gradient(135deg, #ff8a3d, #e5533b); }
.kpi.k4 { background: linear-gradient(135deg, #0ea5e9, #2563eb); }
.kpi.k5 { background: linear-gradient(135deg, #ec4899, #9333ea); }

/* Sade istatistik kutusu */
.stats { display: grid; grid-template-columns: repeat(auto-fill, minmax(180px, 1fr)); gap: 12px; }
.stat { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 14px 16px; display: flex; gap: 12px; align-items: center; }
.stat .si { width: 44px; height: 44px; border-radius: 13px; display: grid; place-items: center; flex: none; background: var(--brand-50); color: var(--brand); }
.stat .v { font-size: 19px; font-weight: 800; letter-spacing: -.02em; font-variant-numeric: tabular-nums; white-space: nowrap; }
.stat .l { font-size: 12.5px; color: var(--muted); font-weight: 700; }
.stat.ok .si { background: var(--ok-bg); color: var(--ok); } .stat.ok .v { color: var(--ok); }
.stat.danger .si { background: var(--danger-bg); color: var(--danger); } .stat.danger .v { color: var(--danger); }
.stat.warn .si { background: var(--warn-bg); color: var(--warn); }
.stat.violet .si { background: var(--violet-bg); color: var(--violet); }
.stat.info .si { background: var(--info-bg); color: var(--info); }

/* Modül bilgi kartları (info-grafik) */
.mods { display: grid; grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); gap: 12px; }
.mod {
  display: flex; flex-direction: column; gap: 10px; padding: 14px; border-radius: var(--radius);
  background: var(--surface); border: 1px solid var(--line); text-decoration: none; color: inherit;
  transition: transform .1s, border-color .15s, box-shadow .15s; position: relative;
}
.mod:hover { transform: translateY(-2px); border-color: var(--brand-100); box-shadow: var(--shadow); }
.mod .mh { display: flex; align-items: center; gap: 10px; }
.mod .mi { width: 42px; height: 42px; border-radius: 13px; display: grid; place-items: center; color: #fff; flex: none; }
.mod .mt { font-weight: 800; font-size: 15px; }
.mod .ms { font-size: 12px; color: var(--muted); font-weight: 600; }
.mod .mv { font-size: 20px; font-weight: 800; letter-spacing: -.02em; font-variant-numeric: tabular-nums; }
.mod .bar { height: 7px; border-radius: 4px; background: var(--surface-3); overflow: hidden; }
.mod .bar i { display: block; height: 100%; border-radius: 4px; }
.mod .mf { display: flex; justify-content: space-between; font-size: 11.5px; font-weight: 700; color: var(--muted); }
.mod.lock { opacity: .55; }
.mod.lock::after { content: "Yetki yok"; position: absolute; top: 10px; right: 10px; font-size: 10.5px; font-weight: 800; padding: 3px 7px; border-radius: 8px; background: var(--surface-3); color: var(--muted); }

/* Rozetler */
.badge { display: inline-flex; align-items: center; gap: 5px; height: 26px; padding: 0 10px; border-radius: 13px; font-size: 12px; font-weight: 800; white-space: nowrap; background: var(--surface-3); color: var(--text-2); border: 1px solid var(--line); }
.badge .ic { width: 14px; height: 14px; }
.b-ok { background: var(--ok-bg); color: var(--ok); border-color: var(--ok-line); }
.b-warn { background: var(--warn-bg); color: var(--warn); border-color: var(--warn-line); }
.b-danger { background: var(--danger-bg); color: var(--danger); border-color: var(--danger-line); }
.b-info { background: var(--info-bg); color: var(--info); border-color: var(--info-line); }
.b-violet { background: var(--violet-bg); color: var(--violet); border-color: var(--violet-line); }
.b-brand { background: var(--brand-50); color: var(--brand-700); border-color: var(--brand-100); }
[data-theme="dark"] .badge { border-color: transparent; }

/* Sekmeler */
.tabs { display: flex; gap: 4px; padding: 4px; background: var(--surface-3); border-radius: 14px; margin-bottom: 16px; overflow-x: auto; scrollbar-width: none; }
.tabs::-webkit-scrollbar { display: none; }
.tabs a { flex: 1 0 auto; min-height: 44px; padding: 0 16px; border-radius: 10px; font-weight: 700; color: var(--text-2); display: inline-flex; align-items: center; justify-content: center; gap: 8px; font-size: 14.5px; text-decoration: none; }
.tabs a.on { background: var(--surface); color: var(--brand-700); box-shadow: var(--shadow-sm); }
.tabs button { flex: 1 0 auto; min-height: 44px; padding: 0 16px; border-radius: 10px; font-weight: 700; color: var(--text-2); display: inline-flex; align-items: center; justify-content: center; gap: 8px; font-size: 14.5px; }
.tabs button.on { background: var(--surface); color: var(--brand-700); box-shadow: var(--shadow-sm); }
[data-theme="dark"] .tabs button.on { color: #b9c9ff; }

/* ---------------- 7. LİSTE & TABLO ---------------- */
.toolbar { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; margin-bottom: 12px; }
.toolbar .search { flex: 1 1 280px; }
.cards { display: grid; grid-template-columns: repeat(auto-fill, minmax(320px, 1fr)); gap: 12px; }
.ccard {
  background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 14px;
  display: flex; flex-direction: column; gap: 12px; cursor: pointer; transition: border-color .15s, box-shadow .15s, transform .08s;
}
.ccard:hover { border-color: var(--brand-100); box-shadow: var(--shadow); }
.ccard:active { transform: scale(.995); }
.ccard .hd { display: flex; gap: 12px; align-items: center; }
.ccard .nm { font-weight: 800; font-size: 15.5px; line-height: 1.25; }
.ccard .sb { font-size: 12.5px; color: var(--muted); font-weight: 600; display: flex; gap: 6px; flex-wrap: wrap; align-items: center; }
.ccard .bal { text-align: right; flex: none; }
.ccard .bal b { display: block; font-size: 16.5px; font-variant-numeric: tabular-nums; }
.ccard .bal small { font-size: 11px; font-weight: 800; letter-spacing: .04em; text-transform: uppercase; }
.ccard .ft { display: flex; gap: 6px; border-top: 1px dashed var(--line); padding-top: 10px; }
.ccard .ft a, .ccard .ft button { flex: 1; height: 38px; border-radius: 10px; display: grid; place-items: center; color: var(--text-2); background: var(--surface-2); }
.ccard .ft a:hover, .ccard .ft button:hover { background: var(--brand-50); color: var(--brand); }
.ccard .ft .ic { width: 18px; height: 18px; }

.table-wrap { overflow-x: auto; border: 1px solid var(--line); border-radius: var(--radius); background: var(--surface); }
table.tbl { width: 100%; border-collapse: collapse; min-width: 640px; }
.tbl th { text-align: left; font-size: 11.5px; text-transform: uppercase; letter-spacing: .06em; color: var(--muted); font-weight: 800; padding: 11px 14px; background: var(--surface-2); border-bottom: 1px solid var(--line); white-space: nowrap; position: sticky; top: 0; }
.tbl th.sort { cursor: pointer; user-select: none; }
.tbl td { padding: 11px 14px; border-bottom: 1px solid var(--line); vertical-align: middle; font-size: 14.5px; }
.tbl tr:last-child td { border-bottom: 0; }
.tbl tbody tr.click { cursor: pointer; }
.tbl tbody tr.click:hover td { background: var(--brand-50); }
.tbl .r { text-align: right; font-variant-numeric: tabular-nums; white-space: nowrap; }
.tbl tfoot td { font-weight: 800; background: var(--surface-2); }
.empty { padding: 40px 16px; text-align: center; color: var(--muted); }
.empty .ic { width: 46px; height: 46px; margin: 0 auto 10px; color: var(--line-strong); }

/* Yükleniyor iskeleti */
.sk { background: linear-gradient(90deg, var(--surface-3) 25%, var(--surface-2) 50%, var(--surface-3) 75%); background-size: 200% 100%; animation: sk 1.2s infinite; border-radius: 10px; }
@keyframes sk { to { background-position: -200% 0; } }

/* ---------------- 8. DASHBOARD WIDGETLARI (sürükle-bırak) ---------------- */
.widgets { display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); gap: 16px; }
.w { grid-column: span 6; min-width: 0; }
.w.w-4 { grid-column: span 4; } .w.w-8 { grid-column: span 8; } .w.w-12 { grid-column: span 12; }
@media (max-width: 1180px) { .w, .w.w-4, .w.w-8 { grid-column: span 6; } .w.w-12 { grid-column: span 12; } }
@media (max-width: 860px) { .w, .w.w-4, .w.w-8, .w.w-12 { grid-column: span 12; } }
.w > .card { height: 100%; }
.w .grip { cursor: grab; color: var(--muted); width: 32px; height: 32px; border-radius: 9px; display: grid; place-items: center; touch-action: none; }
.w .grip:hover { background: var(--surface-3); }
.w.dragging { opacity: .4; }
.w.drop-before > .card { box-shadow: -4px 0 0 var(--brand), var(--shadow); }
.w.drop-after > .card { box-shadow: 4px 0 0 var(--brand), var(--shadow); }
body.edit-mode .w > .card { outline: 2px dashed var(--brand-100); outline-offset: 3px; }
.w-ghost { position: fixed; pointer-events: none; z-index: 300; opacity: .9; transform: rotate(1.5deg); box-shadow: var(--shadow-lg); border-radius: var(--radius-lg); }

/* Liste satırı (yaklaşan vadeler, son işlemler) */
.lrow { display: flex; align-items: center; gap: 12px; padding: 10px 2px; border-bottom: 1px dashed var(--line); }
.lrow:last-child { border-bottom: 0; }
.lrow .li-ic { width: 38px; height: 38px; border-radius: 11px; display: grid; place-items: center; flex: none; }
.lrow .t { font-weight: 700; font-size: 14.5px; }
.lrow .s { font-size: 12px; color: var(--muted); font-weight: 600; }
.lrow .a { margin-left: auto; text-align: right; font-weight: 800; font-variant-numeric: tabular-nums; white-space: nowrap; }

/* Yatay çubuk (en çok borçlu cariler) */
.hbars { display: flex; flex-direction: column; gap: 10px; }
.hbar .tp { display: flex; justify-content: space-between; gap: 10px; font-size: 13.5px; font-weight: 700; margin-bottom: 5px; }
.hbar .tp span:last-child { font-variant-numeric: tabular-nums; }
.hbar .tr { height: 10px; border-radius: 5px; background: var(--surface-3); overflow: hidden; }
.hbar .tr i { display: block; height: 100%; border-radius: 5px; background: var(--brand-grad); }

/* ---------------- 9. TAKVİM ---------------- */
.cal-h { display: flex; align-items: center; gap: 6px; margin-bottom: 10px; }
.cal-h b { flex: 1; text-align: center; font-size: 15px; }
.cal { display: grid; grid-template-columns: repeat(7, 1fr); gap: 4px; }
.cal .dn { text-align: center; font-size: 11px; font-weight: 800; color: var(--muted); padding: 4px 0; text-transform: uppercase; }
.cal .d {
  aspect-ratio: 1 / .86; border-radius: 10px; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 3px;
  font-weight: 700; font-size: 13.5px; position: relative; border: 1px solid transparent; background: var(--surface-2);
}
.cal .d.out { opacity: .35; background: transparent; }
.cal .d.today { border-color: var(--brand); color: var(--brand); }
.cal .d.sel { background: var(--brand); color: #fff; }
.cal .d .dots { display: flex; gap: 3px; height: 6px; }
.cal .d .dots i { width: 6px; height: 6px; border-radius: 50%; }
.cal .d.drop { outline: 2px dashed var(--brand); }
.ev { display: flex; gap: 10px; align-items: center; padding: 9px 10px; border-radius: 12px; background: var(--surface-2); border-left: 4px solid var(--brand); cursor: grab; }
.ev + .ev { margin-top: 6px; }
.ev .t { font-weight: 700; font-size: 13.5px; }
.ev .s { font-size: 12px; color: var(--muted); font-weight: 600; }

/* ---------------- 10. MODAL / ALT SAYFA ---------------- */
.modal-back { position: fixed; inset: 0; z-index: 100; background: rgba(8, 12, 30, .55); display: flex; align-items: center; justify-content: center; padding: 18px; animation: fade .15s ease; }
.modal { width: min(620px, 100%); max-height: calc(100vh - 36px); overflow: auto; background: var(--surface); border-radius: var(--radius-lg); box-shadow: var(--shadow-lg); animation: pop .18s ease; }
.modal.wide { width: min(960px, 100%); } .modal.narrow { width: min(440px, 100%); }
.modal-h { position: sticky; top: 0; z-index: 2; background: var(--surface); display: flex; align-items: center; gap: 12px; padding: 14px 16px; border-bottom: 1px solid var(--line); }
.modal-h h3 { font-size: 17.5px; font-weight: 800; flex: 1; min-width: 0; }
.modal-h .pic { width: 40px; height: 40px; border-radius: 12px; display: grid; place-items: center; background: var(--brand-50); color: var(--brand); }
.modal-b { padding: 16px; }
.modal-f { position: sticky; bottom: 0; background: var(--surface); border-top: 1px solid var(--line); display: flex; gap: 10px; padding: 12px 16px; flex-wrap: wrap; }
.modal-f .btn { flex: 1 1 130px; }
@media (max-width: 640px) {
  .modal-back { padding: 0; align-items: flex-end; }
  .modal { max-height: 94vh; border-radius: 22px 22px 0 0; width: 100% !important; }
  .modal::before { content: ""; display: block; width: 44px; height: 5px; border-radius: 3px; background: var(--line-strong); margin: 8px auto -4px; }
}
@keyframes fade { from { opacity: 0; } }
@keyframes pop { from { transform: translateY(14px) scale(.98); opacity: 0; } }

/* Bildirim (toast) */
.toast { position: fixed; left: 50%; transform: translateX(-50%); z-index: 200; bottom: 24px; display: flex; align-items: center; gap: 10px; padding: 13px 18px; border-radius: 14px; font-weight: 700; background: #0e1630; color: #fff; box-shadow: var(--shadow-lg); max-width: calc(100vw - 24px); animation: pop .2s ease; }
@media (max-width: 760px) { .toast { bottom: calc(var(--bottom-h) + 14px + env(safe-area-inset-bottom)); } }
.toast.ok { background: #0b6b3f; } .toast.err { background: #8e1f19; } .toast.warn { background: #b45309; }

/* Seçenek listesi (paylaş menüsü vb.) */
.opts { display: grid; grid-template-columns: repeat(auto-fill, minmax(120px, 1fr)); gap: 10px; }
.opt { display: flex; flex-direction: column; align-items: center; gap: 8px; padding: 14px 8px; border-radius: 16px; border: 1px solid var(--line); background: var(--surface-2); font-weight: 700; font-size: 13px; text-align: center; color: var(--text); text-decoration: none; }
.opt:hover { border-color: var(--brand-100); background: var(--brand-50); }
.linkbox { display: flex; gap: 8px; align-items: center; padding: 6px 6px 6px 14px; border-radius: 14px; background: var(--surface-2); border: 1px solid var(--line); }
.linkbox input { flex: 1; min-width: 0; border: 0; background: transparent; font-family: var(--mono); font-size: 13px; outline: none; color: var(--text); }
.qr-wrap { display: grid; place-items: center; padding: 14px; background: #fff; border-radius: 16px; border: 1px solid var(--line); }
.qr-wrap svg, .qr-wrap img { width: 220px; height: 220px; }

/* ---------------- 11. KOMUT PALETİ (genel arama, Ctrl+K) ---------------- */
.cmd { position: fixed; inset: 0; z-index: 150; background: rgba(8, 12, 30, .5); display: flex; justify-content: center; align-items: flex-start; padding: 10vh 14px 14px; animation: fade .12s; }
.cmd-box { width: min(640px, 100%); background: var(--surface); border-radius: 20px; box-shadow: var(--shadow-lg); overflow: hidden; animation: pop .15s; }
.cmd-in { display: flex; align-items: center; gap: 10px; padding: 6px 14px; border-bottom: 1px solid var(--line); }
.cmd-in input { flex: 1; height: 54px; border: 0; outline: none; background: transparent; font-size: 17px; color: var(--text); }
.cmd-list { max-height: 56vh; overflow: auto; padding: 8px; }
.cmd-g { font-size: 11px; font-weight: 800; letter-spacing: .08em; text-transform: uppercase; color: var(--muted); padding: 10px 10px 4px; }
.cmd-i { display: flex; align-items: center; gap: 12px; width: 100%; text-align: left; padding: 10px; border-radius: 12px; }
.cmd-i.on, .cmd-i:hover { background: var(--brand-50); }
.cmd-i .t { font-weight: 700; } .cmd-i .s { font-size: 12px; color: var(--muted); }
.cmd-i .k { margin-left: auto; font-size: 12px; font-weight: 800; color: var(--muted); }
@media (max-width: 640px) { .cmd { padding-top: 12px; } }

/* ---------------- 12. KAMERA / QR OKUYUCU ---------------- */
.scanbox { position: relative; border-radius: var(--radius); overflow: hidden; background: #070b18; aspect-ratio: 4 / 3; }
.scanbox video { width: 100%; height: 100%; object-fit: cover; }
.scanbox .frame { position: absolute; inset: 16% 22%; border-radius: 22px; box-shadow: 0 0 0 9999px rgba(0, 0, 0, .38); border: 4px solid rgba(110, 160, 255, .95); }
.scanbox .laser { position: absolute; left: 24%; right: 24%; height: 3px; background: #7aa2ff; top: 50%; animation: laser 1.8s ease-in-out infinite; box-shadow: 0 0 12px #7aa2ff; }
.scanbox .msg { position: absolute; left: 0; right: 0; bottom: 10px; text-align: center; color: #fff; font-weight: 700; text-shadow: 0 1px 4px #000; }
@keyframes laser { 0%, 100% { top: 22%; } 50% { top: 76%; } }
.dropzone { border: 2px dashed var(--line-strong); border-radius: var(--radius); padding: 22px; text-align: center; color: var(--muted); font-weight: 600; transition: border-color .15s, background .15s; cursor: pointer; }
.dropzone.over { border-color: var(--brand); background: var(--brand-50); color: var(--brand-700); }
.thumbs { display: grid; grid-template-columns: repeat(auto-fill, minmax(96px, 1fr)); gap: 10px; margin-top: 12px; }
.thumb { position: relative; aspect-ratio: 1; border-radius: 12px; overflow: hidden; background: var(--surface-3); border: 1px solid var(--line); }
.thumb img { width: 100%; height: 100%; object-fit: cover; }
.thumb .fx { position: absolute; inset: 0; display: grid; place-items: center; color: var(--muted); font-size: 11px; font-weight: 700; text-align: center; padding: 6px; }
.thumb button { position: absolute; top: 4px; right: 4px; width: 26px; height: 26px; border-radius: 8px; background: rgba(0, 0, 0, .55); color: #fff; display: grid; place-items: center; }
.thumb button .ic { width: 15px; height: 15px; }

/* ---------------- 13. GİRİŞ EKRANI ---------------- */
.login { min-height: 100vh; display: grid; grid-template-columns: 1.1fr 1fr; background: var(--bg); }
.login-art {
  position: relative; overflow: hidden; color: #fff; padding: 34px 44px; display: flex; flex-direction: column;
  background:
    radial-gradient(700px 420px at 10% 0%, rgba(106, 61, 240, .55), transparent 60%),
    radial-gradient(800px 520px at 100% 100%, rgba(59, 108, 255, .6), transparent 60%),
    linear-gradient(160deg, #0d1530, #121c44);
}
.login-art .top { display: flex; align-items: center; gap: 14px; }
.login-art .top b { font-size: 22px; letter-spacing: -.02em; }
.login-art .top small { display: block; color: #a7b4e6; font-weight: 600; }
.login-art .clock { margin-left: auto; text-align: right; font-weight: 800; font-size: 24px; font-variant-numeric: tabular-nums; }
.login-art .clock small { display: block; font-size: 12.5px; color: #a7b4e6; font-weight: 600; }
.login-art .mid { margin: auto 0; padding: 26px 0; }
.login-art h2 { font-size: clamp(30px, 3.3vw, 46px); line-height: 1.08; letter-spacing: -.03em; max-width: 15ch; }
.login-art h2 em { font-style: normal; background: linear-gradient(90deg, #8fb0ff, #d6a8ff); -webkit-background-clip: text; background-clip: text; color: transparent; }
.login-art p { color: #c1cbef; font-size: 17px; margin-top: 12px; max-width: 42ch; }
.feat { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; margin-top: 24px; max-width: 620px; }
.feat div { display: flex; gap: 10px; align-items: center; padding: 12px 14px; border-radius: 14px; background: rgba(255, 255, 255, .07); border: 1px solid rgba(255, 255, 255, .1); font-weight: 700; font-size: 14.5px; }
.feat .ic { color: #9db7ff; }
/* Uçan mini grafik kartı (görsel süs) */
.float-card { position: absolute; right: 44px; top: 120px; width: 230px; padding: 14px; border-radius: 18px; background: rgba(255, 255, 255, .1); border: 1px solid rgba(255, 255, 255, .16); backdrop-filter: blur(10px); animation: float 6s ease-in-out infinite; }
.float-card small { color: #b8c4f0; font-weight: 700; font-size: 12px; } .float-card b { display: block; font-size: 22px; margin: 2px 0 6px; }
@keyframes float { 50% { transform: translateY(-10px); } }
@media (max-width: 1250px) { .float-card { display: none; } }
.login-form { display: flex; flex-direction: column; justify-content: center; padding: 34px clamp(18px, 5vw, 70px); position: relative; }
.login-card { width: 100%; max-width: 480px; margin: 0 auto; }
.login-card .logo { width: 64px; height: 64px; border-radius: 20px; margin-bottom: 18px; font-size: 26px; }
.login-card h1 { font-size: 30px; letter-spacing: -.025em; }
.login-card .lead { color: var(--muted); font-size: 16px; margin: 4px 0 22px; }
.login-card .field input { min-height: 60px; font-size: 17px; border-radius: 15px; }
.login-card .btn-login { min-height: 62px; font-size: 18px; border-radius: 16px; width: 100%; margin-top: 4px; }
.vt-card { display: flex; align-items: center; gap: 12px; padding: 12px 14px; border-radius: 16px; background: var(--brand-50); border: 1px solid var(--brand-100); margin-bottom: 16px; }
.vt-card b { display: block; font-size: 14.5px; } .vt-card small { color: var(--muted); font-weight: 600; font-size: 12px; font-family: var(--mono); }
.login-err { display: flex; gap: 10px; align-items: center; padding: 12px 14px; border-radius: 14px; background: var(--danger-bg); color: var(--danger); font-weight: 700; margin-bottom: 14px; }
.login-foot { display: flex; justify-content: center; gap: 22px; margin-top: 26px; }
.login-foot a, .login-foot button { display: flex; flex-direction: column; align-items: center; gap: 6px; color: var(--muted); font-size: 12.5px; font-weight: 700; text-decoration: none; }
.login-foot span.i { width: 52px; height: 52px; border-radius: 16px; display: grid; place-items: center; background: var(--surface); border: 1px solid var(--line); color: var(--brand); box-shadow: var(--shadow-sm); }
.co-list { display: flex; flex-direction: column; gap: 10px; }
.co-item { display: flex; align-items: center; gap: 14px; width: 100%; text-align: left; padding: 14px; border-radius: 16px; border: 1.5px solid var(--line); background: var(--surface); transition: border-color .15s, background .15s; }
.co-item:hover { border-color: var(--brand); background: var(--brand-50); }
.co-item .t { font-weight: 800; } .co-item .s { font-size: 12.5px; color: var(--muted); font-weight: 600; }
.demo-note { margin-top: 18px; padding: 12px 14px; border-radius: 14px; background: var(--warn-bg); color: var(--warn); font-weight: 600; font-size: 13.5px; display: flex; gap: 10px; }
@media (max-width: 980px) {
  .login { grid-template-columns: 1fr; }
  .login-art { padding: 20px 18px 24px; }
  .login-art .mid { padding: 18px 0 0; }
  .login-art .mid p, .feat { display: none; }
  .login-art h2 { font-size: 25px; max-width: none; }
  .login-form { padding: 22px 16px 36px; justify-content: flex-start; }
}

/* ---------------- 14. CARİ KART (profil başlığı) ---------------- */
.hero {
  position: relative; overflow: hidden; border-radius: var(--radius-lg); padding: 20px; color: #fff; margin-bottom: 16px;
  background: radial-gradient(500px 260px at 100% 0%, rgba(160, 120, 255, .45), transparent 60%), linear-gradient(135deg, #18234a, #2f5bea);
  box-shadow: var(--shadow);
}
.hero .hd { display: flex; gap: 16px; align-items: center; flex-wrap: wrap; }
.hero .avatar { width: 64px; height: 64px; font-size: 24px; border-radius: 20px; background: rgba(255, 255, 255, .16); color: #fff; border: 1px solid rgba(255, 255, 255, .25); }
.hero h2 { font-size: 23px; letter-spacing: -.02em; line-height: 1.2; }
.hero .meta { display: flex; gap: 8px; flex-wrap: wrap; margin-top: 6px; }
.hero .meta .badge { background: rgba(255, 255, 255, .14); color: #fff; border-color: rgba(255, 255, 255, .2); }
.hero .balance { margin-left: auto; text-align: right; }
.hero .balance small { display: block; font-size: 12px; font-weight: 800; letter-spacing: .06em; text-transform: uppercase; color: #c8d4ff; }
.hero .balance b { font-size: 30px; letter-spacing: -.02em; font-variant-numeric: tabular-nums; }
.hero .risk { margin-top: 16px; display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 10px; }
.hero .risk > div { padding: 10px 12px; border-radius: 14px; background: rgba(255, 255, 255, .1); }
.hero .risk small { display: block; font-size: 11.5px; color: #c8d4ff; font-weight: 700; }
.hero .risk b { font-size: 16px; font-variant-numeric: tabular-nums; }
.gauge-track { height: 8px; border-radius: 4px; background: rgba(255, 255, 255, .2); margin-top: 6px; overflow: hidden; }
.gauge-track i { display: block; height: 100%; border-radius: 4px; background: #7ef0c1; }
.gauge-track i.w { background: #ffd27a; } .gauge-track i.d { background: #ff8a80; }
@media (max-width: 760px) {
  .hero .balance { margin-left: 0; text-align: left; width: 100%; }
  .hero .risk { grid-template-columns: 1fr 1fr; }
}
.kv { display: grid; grid-template-columns: 150px 1fr; gap: 10px 14px; font-size: 14.5px; }
.kv dt { color: var(--muted); font-weight: 700; }
.kv dd { font-weight: 700; word-break: break-word; }
.kv dd a { text-decoration: none; }
@media (max-width: 640px) { .kv { grid-template-columns: 116px 1fr; } }
.two { display: grid; grid-template-columns: minmax(0, 1.5fr) minmax(320px, 1fr); gap: 16px; align-items: start; }
@media (max-width: 1100px) { .two { grid-template-columns: 1fr; } }
.tl { list-style: none; position: relative; }
.tl li { position: relative; padding: 0 0 16px 34px; }
.tl li::before { content: ""; position: absolute; left: 11px; top: 26px; bottom: 0; width: 2px; background: var(--line); }
.tl li:last-child::before { display: none; }
.tl .dot { position: absolute; left: 0; top: 0; width: 24px; height: 24px; border-radius: 50%; display: grid; place-items: center; color: #fff; }
.tl .dot .ic { width: 13px; height: 13px; }
.tl .t { font-weight: 700; font-size: 14px; } .tl .s { font-size: 12px; color: var(--muted); font-weight: 600; }

/* Sabit alt eylem çubuğu (mobilde Kaydet vb.) */
.actionbar { position: sticky; bottom: 0; z-index: 15; display: flex; gap: 10px; padding: 12px 0; background: linear-gradient(to top, var(--bg) 70%, transparent); }
@media (max-width: 760px) { .actionbar { bottom: calc(var(--bottom-h) + env(safe-area-inset-bottom)); padding: 10px 0; } }
.actionbar .btn { flex: 1; }

/* Yüzen ekle butonu (liste ekranı) */
.fab-add { position: fixed; right: 22px; bottom: 26px; z-index: 30; width: 62px; height: 62px; border-radius: 20px; display: grid; place-items: center; color: #fff; background: var(--brand-grad); box-shadow: 0 12px 28px rgba(47, 91, 234, .45); }
.fab-add .ic { width: 28px; height: 28px; }
@media (max-width: 760px) { .fab-add { bottom: calc(var(--bottom-h) + 16px + env(safe-area-inset-bottom)); right: 16px; } }

/* ---------------- 15. SİHİRBAZ (adım adım form) ---------------- */
.wiz { display: grid; grid-template-columns: 250px minmax(0, 1fr); gap: 18px; align-items: start; }
.wiz > * { min-width: 0; }
.wiz-steps { position: sticky; top: calc(var(--top-h) + 16px); display: flex; flex-direction: column; gap: 6px; }
.wiz-steps button { display: flex; align-items: center; gap: 12px; padding: 10px 12px; border-radius: 14px; text-align: left; color: var(--text-2); font-weight: 700; }
.wiz-steps button .n { width: 34px; height: 34px; border-radius: 11px; display: grid; place-items: center; background: var(--surface-3); font-weight: 800; flex: none; }
.wiz-steps button small { display: block; font-size: 11.5px; color: var(--muted); font-weight: 600; }
.wiz-steps button.on { background: var(--surface); box-shadow: var(--shadow-sm); color: var(--text); }
.wiz-steps button.on .n { background: var(--brand-grad); color: #fff; }
.wiz-steps button.done .n { background: var(--ok); color: #fff; }
.wiz-steps button.bad .n { background: var(--danger); color: #fff; }
.wiz-prog { height: 6px; border-radius: 3px; background: var(--surface-3); overflow: hidden; margin: 4px 0 8px; }
.wiz-prog i { display: block; height: 100%; background: var(--brand-grad); transition: width .2s; }
.wiz-sec { display: none; } .wiz-sec.on { display: block; animation: fade .15s; }
@media (max-width: 900px) {
  .wiz { grid-template-columns: 1fr; }
  .wiz-steps { position: static; flex-direction: row; overflow-x: auto; gap: 6px; scrollbar-width: none; }
  .wiz-steps::-webkit-scrollbar { display: none; }
  .wiz-steps button { flex: none; padding: 8px 10px; }
  .wiz-steps button small { display: none; }
}
.preview-card { border-radius: var(--radius); border: 1px dashed var(--line-strong); padding: 14px; display: flex; gap: 12px; align-items: center; background: var(--surface-2); }

/* ---------------- 16. KÜÇÜK EKRAN İNCE AYARLARI ---------------- */
@media (max-width: 760px) {
  .kpis { grid-template-columns: 1fr 1fr; gap: 10px; }
  .kpi { min-height: 118px; padding: 12px 12px 8px; border-radius: 18px; }
  .kpi .top { font-size: 12px; } .kpi .top .ki { width: 28px; height: 28px; }
  .kpi .v { font-size: 18px !important; margin-top: 6px; }
  .card { padding: 15px; border-radius: 18px; }
  .page-head h2 { font-size: 21px; }
  .cards { grid-template-columns: 1fr; }
  .mods { grid-template-columns: 1fr 1fr; gap: 10px; }
  .stats { grid-template-columns: 1fr 1fr; }
  .stat { padding: 12px; } .stat .v { font-size: 16px; } .stat .si { width: 38px; height: 38px; }
  .stat.genis { grid-column: 1 / -1; }
  .kpi:last-child:nth-child(odd) { grid-column: 1 / -1; }
  .qa { flex-wrap: nowrap; overflow-x: auto; scrollbar-width: none; margin-left: -12px; margin-right: -12px; padding: 0 12px 2px; }
  .qa::-webkit-scrollbar { display: none; }
  .qa a, .qa button { flex: 0 0 76px; }
  .toolbar .search { flex-basis: 100%; }
  .toolbar select { flex: 1; }
  .toolbar .gorunum [data-g="tablo"] { display: none; }
}

/* ---------------- 17. YAZDIRMA ---------------- */
@media print {
  body { background: #fff !important; }
  .rail, .topbar, .bottom-nav, .toast, .modal-back, .fab-add, .actionbar, .no-print { display: none !important; }
  .shell { padding: 0 !important; } .content { padding: 0 !important; max-width: none; }
}
.qr-wrap.qr-sm svg { width: 150px; height: 150px; }

/* ---------------- 18. BÜYÜK TAKVİM (servis, çek/senet vade) ---------------- */
.takvim-buyuk { gap: 6px; }
.takvim-buyuk .d.tg { aspect-ratio: auto; min-height: 104px; align-items: stretch; justify-content: flex-start; padding: 6px; gap: 4px; text-align: left; overflow: hidden; }
.takvim-buyuk .d.tg .gn { font-size: 12.5px; font-weight: 800; color: var(--muted); }
.takvim-buyuk .d.today .gn { color: var(--brand); }
.tev { font-size: 11.5px; font-weight: 700; padding: 3px 6px; border-radius: 6px; background: var(--surface); border-left: 3px solid var(--brand); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; cursor: grab; box-shadow: var(--shadow-sm); }
.tev:hover { background: var(--brand-50); }
@media (max-width: 760px) { .takvim-buyuk .d.tg { min-height: 64px; padding: 3px; } .tev { font-size: 0; padding: 0; height: 6px; border-left-width: 6px; border-radius: 3px; } }

/* ---------------- 19. BELGE EDİTÖRÜ (fatura, sipariş, irsaliye, teklif) ---------------- */
.kalemler { display: flex; flex-direction: column; gap: 8px; }
.kalem { display: grid; grid-template-columns: 26px minmax(180px, 1fr) 124px 160px 66px 66px 78px 112px 34px; gap: 8px; align-items: center; padding: 8px; border: 1px solid var(--line); border-radius: 14px; background: var(--surface); }
.kalem.drag { opacity: .4; }
.kalem .tut { cursor: grab; color: var(--muted); display: grid; place-items: center; touch-action: none; }
.kalem input, .kalem select { min-height: 42px !important; height: 42px; padding: 0 10px !important; border-radius: 10px !important; font-size: 15px !important; width: 100%; border: 1.5px solid var(--line-strong); background: var(--surface); color: var(--text); }
.kalem .ad small { display: block; font-size: 11.5px; color: var(--muted); font-weight: 600; margin-top: 2px; }
.kalem .mk { display: flex; align-items: center; gap: 2px; }
.kalem .mk button { width: 32px; height: 42px; border-radius: 9px; background: var(--surface-3); display: grid; place-items: center; flex: none; }
.kalem .mk input { text-align: center; padding: 0 4px !important; }
.kalem .tt { text-align: right; font-weight: 800; font-variant-numeric: tabular-nums; }
.kalem .lbl { display: none; font-size: 11px; font-weight: 700; color: var(--muted); }
.kalem-bas { display: grid; grid-template-columns: 26px minmax(180px, 1fr) 124px 160px 66px 66px 78px 112px 34px; gap: 8px; padding: 0 8px; font-size: 11px; font-weight: 800; letter-spacing: .05em; text-transform: uppercase; color: var(--muted); }
@media (max-width: 900px) {
  .kalem-bas { display: none; }
  .kalem { grid-template-columns: 22px 1fr 1fr 1fr 36px; grid-template-areas: "t a a a x" "t m m f f" "t i j k k" "t s s s s"; }
  .kalem .tut { grid-area: t; align-self: start; padding-top: 10px; } .kalem .ad { grid-area: a; } .kalem .mk-w { grid-area: m; } .kalem .fy { grid-area: f; } .kalem .is { grid-area: i; } .kalem .is2 { grid-area: j; } .kalem .kd { grid-area: k; } .kalem .tt { grid-area: s; text-align: left; display: flex; gap: 10px; align-items: baseline; } .kalem .sil, .kalem .menu-b { grid-area: x; justify-self: end; align-self: start; }
  .kalem .lbl { display: block; margin-bottom: 2px; }
}
.toplam-kutu { display: flex; flex-direction: column; gap: 6px; padding: 14px 16px; border-radius: 16px; background: var(--surface-2); border: 1px solid var(--line); }
.toplam-kutu .r { display: flex; justify-content: space-between; font-weight: 600; color: var(--text-2); font-variant-numeric: tabular-nums; }
.toplam-kutu .g { font-size: 22px; font-weight: 800; color: var(--text); padding-top: 6px; border-top: 1px dashed var(--line-strong); }
.belge-alt { position: sticky; bottom: 0; z-index: 14; display: flex; gap: 10px; align-items: center; padding: 10px 14px; margin: 0 -2px; border-radius: 16px; background: var(--nav); color: #fff; box-shadow: var(--shadow-lg); }
.belge-alt .tp { margin-right: auto; } .belge-alt .tp small { display: block; color: #a7b4e6; font-size: 11.5px; font-weight: 700; } .belge-alt .tp b { font-size: 20px; font-variant-numeric: tabular-nums; }
@media (max-width: 760px) { .belge-alt { bottom: calc(var(--bottom-h) + 6px + env(safe-area-inset-bottom)); } }
.adim-bag { display: flex; gap: 6px; align-items: center; flex-wrap: wrap; }
.adim-bag a { text-decoration: none; }
.ozet-bar { display: flex; height: 12px; border-radius: 6px; overflow: hidden; background: var(--surface-3); margin-top: 8px; }
.ozet-bar i { display: block; height: 100%; }

/* ---------------- Yönetim ekranları (kullanıcı, ayarlar, profil, e-belge) ---------------- */
.two-dar { grid-template-columns: minmax(260px, 340px) minmax(0, 1fr); }
.two-dar > *, .two > * { min-width: 0; }
@media (max-width: 1100px) { .two-dar { grid-template-columns: 1fr; } }
#mx td, #mx th { padding: 8px 6px; }
#mx td:first-child { min-width: 150px; }
.param-row { display: grid; grid-template-columns: minmax(140px, 220px) 1fr auto; gap: 10px; align-items: center; padding: 8px 0; border-bottom: 1px dashed var(--line); }
.param-row:last-child { border-bottom: 0; }
@media (max-width: 640px) { .param-row { grid-template-columns: 1fr auto; } .param-row > :first-child { grid-column: 1 / -1; } }
/* Taşma koruması: ızgara çocukları içerik genişliğine göre büyümesin (telefonda yatay kayma olmasın) */
.grid-2 > *, .grid-3 > *, .mods > *, .stats > * { min-width: 0; }
.mod .ms, .mod .mt { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
@media (max-width: 480px) { .seg button { flex: 1 1 40%; min-width: 0; padding-left: 8px; padding-right: 8px; white-space: normal; text-align: center; } }

/* ---------------- Menü altı kullanıcı bölümü (sadece telefonda çekmecede) ---------------- */
.rail-user { display: none; margin-top: 14px; padding: 14px 6px 4px; border-top: 1px solid rgba(255,255,255,.08); color: #fff; }
.rail-user small { color: #8796c4; font-size: 12px; }
@media (max-width: 760px) {
  .rail-user { display: block; padding-bottom: 96px; }
  .tbtn { width: 40px; height: 40px; }
  .topbar { gap: 2px; }
  .userchip .avatar { width: 34px; height: 34px; font-size: 13px; }
}

/* ---------------- Yatay kart sırası (banka hesapları, kasalar) ---------------- */
.yatay-kap { position: relative; }
.yatay { display: flex; gap: 12px; overflow-x: auto; scroll-snap-type: x mandatory; scrollbar-width: none; padding: 2px 2px 6px; outline: none; }
.yatay::-webkit-scrollbar { display: none; }
.yatay > * { flex: 0 0 236px; scroll-snap-align: start; min-width: 0; }
.yatay > .on { outline: 2px solid var(--brand); outline-offset: -2px; }
.yatay-ok { position: absolute; top: 50%; transform: translateY(-50%); width: 38px; height: 38px; border-radius: 50%; background: var(--surface); border: 1px solid var(--line); box-shadow: var(--shadow); display: grid; place-items: center; z-index: 2; }
.yatay-ok.sol { left: -10px; } .yatay-ok.sag { right: -10px; }
.yatay-ok[hidden] { display: none; }
@media (max-width: 760px) { .yatay > * { flex-basis: 78%; } .yatay-ok { display: none; } }

/* ---------------- Taşma düzeltmeleri (liste/kart) ---------------- */
.nowrap { white-space: nowrap; }
.row.nowrap { flex-wrap: nowrap !important; }
.tbl td:last-child .row { flex-wrap: nowrap; }
.tbl td.r .btn-icon, .tbl .btn-icon.btn-sm { width: 32px; height: 32px; min-height: 32px; padding: 0; }
.cards { grid-template-columns: repeat(auto-fill, minmax(min(320px, 100%), 1fr)); }
.ccard, .ccard .hd > .grow, .ccard .hd > div:not(.avatar):not(.bal) { min-width: 0; }
.ccard .nm { overflow-wrap: anywhere; }
.ccard .bal { max-width: 46%; }
.ccard .bal b { white-space: nowrap; }
.ccard .row { flex-wrap: wrap; }
@media (max-width: 760px) {
  .ccard { padding: 12px; }
  .ccard .bal b { font-size: 15px; }
  .table-wrap { -webkit-overflow-scrolling: touch; }
}

/* Geniş takvim (servis / iş programı) */
.takvim-buyuk .d.tg { min-height: 128px; }
.takvim-buyuk .tev { white-space: normal; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; line-height: 1.3; }
.takvim-buyuk.hafta .d.tg { min-height: 380px; }
.takvim-buyuk.hafta .tev { -webkit-line-clamp: 4; font-size: 12.5px; padding: 6px 8px; }
.cal-h .seg button { min-height: 34px; padding: 0 12px; }
@media (max-width: 760px) { .takvim-buyuk.hafta { grid-template-columns: 1fr; } .takvim-buyuk.hafta .dn { display: none; } .takvim-buyuk.hafta .d.tg { min-height: 60px; } .takvim-buyuk.hafta .tev { font-size: 13px; height: auto; padding: 6px 8px; border-left-width: 3px; } }

/* Üst bar döviz kuru çipi (kurlar.html) — telefonda gizli */
.kurchip { display: flex; gap: 10px; align-items: center; padding: 6px 12px; border-radius: 30px; border: 1px solid var(--line); background: var(--surface); font-size: 12.5px; white-space: nowrap; color: var(--ink); text-decoration: none; }
.kurchip[hidden] { display: none; }
.kurchip small { color: var(--muted); font-weight: 700; margin-right: 3px; }
.kurchip b { font-family: "JetBrains Mono", monospace; font-weight: 700; }
@media (max-width: 1100px) { .kurchip { display: none !important; } }
.tbtn[hidden] { display: none; }

/* Notlar & Dokümanlar zaman akışı (notlar.html) */
.nt-liste { display: flex; flex-direction: column; gap: 8px; }
.nt-gun { font-size: 12px; font-weight: 800; color: var(--muted); text-transform: uppercase; letter-spacing: .04em; margin: 10px 2px 2px; }
.nt { display: flex; gap: 12px; align-items: flex-start; padding: 12px; border: 1px solid var(--line); border-radius: 14px; background: var(--surface); }
.nt-ic { width: 38px; height: 38px; border-radius: 11px; display: grid; place-items: center; color: #fff; flex: none; }
.nt-res { width: 56px; height: 56px; border-radius: 11px; object-fit: cover; flex: none; cursor: zoom-in; background: var(--bg); }
.nt-b { display: flex; gap: 8px; align-items: baseline; min-width: 0; }
.nt-m { font-size: 13.5px; color: var(--text-2, var(--muted)); margin-top: 3px; overflow-wrap: anywhere; max-height: 8.5em; overflow: hidden; }
.nt-e { display: flex; gap: 2px; flex: none; }
.nt-bag { text-decoration: none; display: inline-flex; align-items: center; gap: 4px; max-width: 100%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
@media (max-width: 760px) { .nt { padding: 10px; gap: 10px; } .nt-e { flex-direction: column; } }

/* ---------------- 19. BELGE FORMU EKLERİ (detay grupları, dip toplam, satır menüsü) ---------------- */
.kalem .tt small { display: block; font-size: 11px; font-weight: 700; }
.kalem-arac { flex-wrap: wrap; justify-content: flex-end; }
.bgrup { border: 1px solid var(--line); border-radius: 14px; margin-top: 10px; background: var(--surface-2); }
.bgrup > summary { cursor: pointer; padding: 12px 14px; font-weight: 800; font-size: 14px; display: flex; align-items: center; gap: 8px; color: var(--text-2); list-style: none; }
.bgrup > summary::-webkit-details-marker { display: none; }
.bgrup > summary::after { content: "+"; margin-left: auto; font-size: 18px; color: var(--muted); }
.bgrup[open] > summary::after { content: "−"; }
.bgrup > div { padding: 0 14px 6px; }
#kurAlan.kur-tl > .field:nth-child(1), #kurAlan.kur-tl > .field:nth-child(2) { opacity: .55; }
.dip { display: flex; justify-content: space-between; align-items: flex-end; gap: 16px; margin-top: 14px; flex-wrap: wrap; }
.dip-sol { display: flex; flex-direction: column; gap: 10px; }
.kar-kutu { display: flex; gap: 14px; flex-wrap: wrap; font-size: 13px; color: var(--muted); font-weight: 700; padding: 10px 12px; border-radius: 12px; background: var(--surface-2); border: 1px dashed var(--line-strong); }
.kar-kutu b { color: var(--text); }
.menu-liste { display: flex; flex-direction: column; gap: 4px; }
.menu-liste button { display: flex; align-items: center; gap: 12px; padding: 12px; border-radius: 12px; font-weight: 700; text-align: left; }
.menu-liste button:hover { background: var(--surface-3); }
.fiyat-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 8px; }
.fiyat-b { display: flex; flex-direction: column; gap: 2px; padding: 10px 12px; border-radius: 12px; border: 1px solid var(--line); background: var(--surface); text-align: left; }
.fiyat-b:hover:not([disabled]) { border-color: var(--brand); }
.fiyat-b[disabled] { opacity: .45; }
.fiyat-b small { color: var(--muted); font-weight: 700; font-size: 12px; }
.sg-belge { border: 1px solid var(--line); border-radius: 14px; padding: 10px 12px; margin-bottom: 10px; }
.t-brand { color: var(--brand); }

/* ---------------- 20. BELGE GÖRÜNÜMÜ (kâğıt belge) ---------------- */
.evrak-ust { display: flex; justify-content: space-between; align-items: center; gap: 12px; flex-wrap: wrap; }
.evrak-ust .qa { flex: 1 1 auto; }
.evrak-duzen { display: grid; grid-template-columns: minmax(0, 1fr) 300px; gap: 18px; align-items: start; }
.evrak-kap { overflow-x: auto; }
.evrak { background: #fff; color: #1b2133; max-width: 900px; margin: 0 auto; padding: 36px 40px; border-radius: 6px; box-shadow: 0 1px 2px rgba(0,0,0,.06), 0 12px 32px rgba(15,23,42,.12); font-size: 13.5px; line-height: 1.45; }
.evrak .muted, .evrak .tiny.muted { color: #6b7385; }
.ev-bas { display: flex; justify-content: space-between; gap: 20px; padding-bottom: 18px; border-bottom: 2px solid #1b2133; }
.ev-firma { display: flex; gap: 12px; align-items: flex-start; min-width: 0; }
.ev-firma b { display: block; font-size: 16px; }
.ev-firma small { display: block; color: #5b6478; font-size: 12px; }
.ev-logo { width: 48px; height: 48px; border-radius: 12px; background: #1b2133; color: #fff; display: grid; place-items: center; font-weight: 800; font-size: 18px; flex: none; }
.ev-baslik { text-align: right; flex: none; }
.ev-baslik h2 { font-size: 20px; letter-spacing: .04em; margin: 0 0 4px; }
.ev-baslik .mono { font-size: 13px; color: #5b6478; }
.ev-ust { display: grid; grid-template-columns: 1fr 260px; gap: 18px; margin: 18px 0; }
.ev-muhatap { display: flex; flex-direction: column; gap: 2px; padding: 12px 14px; border: 1px solid #d9dde6; border-radius: 8px; }
.ev-muhatap small { font-weight: 800; color: #6b7385; font-size: 11px; letter-spacing: .08em; }
.ev-muhatap b { font-size: 15px; }
.ev-muhatap span { color: #3b4357; font-size: 12.5px; }
.ev-sevk { margin-top: 4px; font-style: italic; }
.ev-bilgi { display: grid; grid-template-columns: auto 1fr; gap: 4px 12px; margin: 0; padding: 12px 14px; border: 1px solid #d9dde6; border-radius: 8px; font-size: 12.5px; align-content: start; }
.ev-bilgi dt { color: #6b7385; font-weight: 700; }
.ev-bilgi dd { margin: 0; font-weight: 700; text-align: right; }
.ev-konu { margin: -6px 0 12px; }
.ev-tablo { width: 100%; border-collapse: collapse; font-size: 12.5px; }
.ev-tablo th { background: #1b2133; color: #fff; text-align: left; padding: 8px; font-size: 11px; letter-spacing: .05em; text-transform: uppercase; }
.ev-tablo td { padding: 8px; border-bottom: 1px solid #e6e9ef; vertical-align: top; }
.ev-tablo tr:nth-child(even) td { background: #f7f8fb; }
.ev-tablo .r { text-align: right; }
.ev-alt { display: grid; grid-template-columns: 1fr 300px; gap: 18px; margin-top: 16px; align-items: start; }
.ev-notlar p { margin: 0 0 8px; }
.ev-yazi { font-style: italic; }
.ev-sart ol { margin: 4px 0 8px 18px; padding: 0; }
.ev-uzun { white-space: normal; color: #3b4357; }
.evrak .toplam-kutu { background: #f7f8fb; border-color: #d9dde6; color: #1b2133; }
.evrak .toplam-kutu .r { color: #3b4357; }
.evrak .toplam-kutu .g { color: #1b2133; border-color: #b9bfcc; }
.ev-imza { display: grid; grid-template-columns: 1fr 1fr; gap: 40px; margin-top: 40px; }
.ev-imza div { border-top: 1px solid #b9bfcc; padding-top: 6px; min-height: 48px; }
.ev-imza small { display: block; color: #6b7385; font-weight: 700; font-size: 11.5px; }
@media (max-width: 1100px) { .evrak-duzen { grid-template-columns: 1fr; } }
@media (max-width: 760px) {
  .evrak { padding: 18px 14px; border-radius: 14px; font-size: 13px; }
  .ev-bas { flex-direction: column; gap: 10px; }
  .ev-baslik { text-align: left; }
  .ev-ust, .ev-alt { grid-template-columns: 1fr; }
  .ev-tablo thead { display: none; }
  .ev-tablo, .ev-tablo tbody, .ev-tablo tr, .ev-tablo td { display: block; width: 100%; }
  .ev-tablo tr { border-bottom: 1px solid #e6e9ef; padding: 6px 0; }
  .ev-tablo td { border: 0; padding: 2px 0; background: none !important; }
  .ev-tablo td:first-child { display: none; }
  .ev-tablo td.r { text-align: left; display: inline-block; width: auto; margin-right: 12px; }
  .ev-imza { gap: 16px; }
}

/* Paylaşım sayfası onay / mutabakat kutusu */
.onay-kutu.ok { display: flex; gap: 12px; align-items: center; background: var(--ok-bg); color: var(--ok); border-color: transparent; }
.onay-kutu.ok b { color: var(--ok); }

/* ---------------- 21. HIZLI SATIŞ ---------------- */
.hs { display: grid; grid-template-columns: minmax(0, 1fr) 360px; gap: 16px; align-items: start; }
.hs-okut { display: flex; gap: 8px; margin-bottom: 12px; }
.hs-okut .input { height: 56px; font-size: 18px; }
.hs-sepet { padding: 8px; min-height: 360px; }
.hs-satirlar { display: flex; flex-direction: column; gap: 6px; }
.hs-satir { display: flex; align-items: center; gap: 10px; padding: 10px 12px; border-radius: 12px; border: 1px solid var(--line); }
.hs-satir.son { border-color: var(--brand); background: var(--brand-50); }
.hs-satir b { display: block; }
.hs-satir small { display: block; font-size: 12px; }
.hs-satir .mk { display: flex; align-items: center; gap: 2px; flex: none; }
.hs-satir .mk button { width: 34px; height: 38px; border-radius: 9px; background: var(--surface-3); display: grid; place-items: center; }
.hs-satir .mk input { width: 64px; height: 38px; text-align: center; border: 1.5px solid var(--line-strong); border-radius: 9px; background: var(--surface); color: var(--text); font-weight: 700; }
.hs-tutar { display: flex; align-items: center; gap: 2px; min-width: 150px; justify-content: flex-end; font-variant-numeric: tabular-nums; }
.hs-sag { position: sticky; top: 80px; }
.hs-toplam { padding: 16px; border-radius: 16px; background: var(--nav); color: #fff; display: flex; flex-direction: column; }
.hs-toplam small { opacity: .75; font-weight: 700; }
.hs-toplam b { font-size: 40px; font-weight: 800; letter-spacing: -.02em; font-variant-numeric: tabular-nums; }
.hs-toplam span { color: rgba(255,255,255,.7) !important; }
.hs-ustu-b { padding: 10px 14px; border-radius: 12px; background: var(--warn-bg); color: var(--warn); font-weight: 700; display: flex; justify-content: space-between; margin-bottom: 10px; font-size: 16px; }
.hs-ustu-b.ok { background: var(--ok-bg); color: var(--ok); }
.hs-odeme { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.hs-odeme .btn { min-height: 64px; font-size: 17px; font-weight: 800; color: #fff; flex-direction: column; gap: 2px; }
.hs-odeme .btn kbd { font-size: 10.5px; opacity: .8; background: rgba(255,255,255,.18); border-radius: 5px; padding: 1px 6px; font-family: inherit; }
.hs-nakit { background: #0b8a52; grid-column: 1 / -1; } .hs-kart { background: #2f5bea; } .hs-veresiye { background: #b45309; }
.hs-odeme .btn[disabled] { opacity: .4; }
@media (max-width: 980px) { .hs { grid-template-columns: 1fr; } .hs-sag { position: static; } .hs-tutar { min-width: 0; } .hs-satir { flex-wrap: wrap; } .hs-satir > .grow { flex-basis: 100%; } }

/* ---------------- 22. RAPORLAR ---------------- */
.rp { display: grid; grid-template-columns: 230px minmax(0, 1fr); gap: 16px; align-items: start; }
.rp-menu { display: flex; flex-direction: column; gap: 4px; position: sticky; top: 80px; background: var(--surface); border: 1px solid var(--line); border-radius: 16px; padding: 8px; }
.rp-menu button { display: flex; align-items: center; gap: 10px; padding: 10px 12px; border-radius: 10px; font-weight: 700; color: var(--text-2); text-align: left; font-size: 14px; }
.rp-menu button.on { background: var(--brand-50); color: var(--brand-700); }
.rp-tablo { max-height: 68vh; overflow: auto; }
.rp-tablo thead th { position: sticky; top: 0; z-index: 1; background: var(--surface-2); }
.rp-tablo tfoot td { position: sticky; bottom: 0; background: var(--surface-2); border-top: 2px solid var(--line-strong); }
.rp-tablo th.sirala { cursor: pointer; user-select: none; white-space: nowrap; }
@media (max-width: 900px) { .rp { grid-template-columns: 1fr; } .rp-menu { position: static; flex-direction: row; overflow-x: auto; scrollbar-width: none; } .rp-menu button { flex: none; } }

/* ===== 23. SMS (sms.html) ===== */
.sms-liste { max-height: 360px; overflow: auto; border: 1px solid var(--line); border-radius: 12px; }
.sms-satir { display: flex; align-items: center; gap: 10px; padding: 9px 12px; border-bottom: 1px solid var(--line); cursor: pointer; min-width: 0; }
.sms-satir:last-child { border-bottom: 0; }
.sms-satir:hover { background: var(--surface-2); }
.sms-onizleme { background: var(--surface-2); border-radius: 14px; padding: 14px; min-height: 90px; }
.sms-balon { background: #0b7fc7; color: #fff; padding: 10px 14px; border-radius: 16px 16px 16px 4px; max-width: 90%; font-size: 14px; line-height: 1.45; word-break: break-word; }
.sms-gec { display: flex; gap: 10px; padding: 8px 0; border-bottom: 1px solid var(--line); }
.sms-gec .dot { width: 9px; height: 9px; border-radius: 50%; margin-top: 6px; flex: 0 0 9px; background: var(--ok); }
.sms-gec .dot.err { background: var(--danger); }
.chk { display: flex; align-items: center; gap: 10px; font-size: 14px; cursor: pointer; }
.chk input { width: 18px; height: 18px; accent-color: var(--brand); }

/* ===== 24. Dönem devri (devir.html) ===== */
.dv-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 12px; }
.dv-kalem { display: flex; gap: 12px; align-items: flex-start; padding: 14px; border: 1px solid var(--line); border-radius: 16px; background: var(--surface); cursor: pointer; }
.dv-kalem:has(input:checked) { border-color: var(--brand); background: var(--brand-50); }
.dv-kalem input { width: 20px; height: 20px; margin-top: 2px; accent-color: var(--brand); flex: 0 0 20px; }
.dv-kalem b { display: block; }
.dv-kalem .tiny { margin-top: 3px; }
.dv-sonuc li { padding: 4px 0; }
/* Kart resmi (cari / stok ana resim) */
.avatar img { width: 100%; height: 100%; object-fit: cover; border-radius: inherit; display: block; }
.hero .avatar:has(img) { background: #fff; overflow: hidden; }
.thumb button.ana { right: auto; left: 4px; }
.thumb button.ana.on { background: #f5b301; }
/* Pasif cari: kırmızı */
.ccard.pasif { border-color: rgba(239, 68, 68, .55); background: linear-gradient(0deg, rgba(239, 68, 68, .05), rgba(239, 68, 68, .05)), var(--surface); }
.ccard.pasif .nm, tr.pasif td b { color: var(--danger) !important; }
select.sel-pasif { color: #fff; background-color: var(--danger) !important; border-color: var(--danger) !important; font-weight: 800; }
/* Gelir / giriş yeşil, gider / çıkış kırmızı (kasa, banka) */
.seg button.seg-ok { color: var(--ok); } .seg button.seg-danger { color: var(--danger); }
.seg button.seg-ok.on { background: var(--ok); color: #fff; } .seg button.seg-danger.on { background: var(--danger); color: #fff; }
.fatura-al { display: flex; gap: 10px; align-items: center; padding: 10px 12px; border: 1px dashed var(--brand); border-radius: 12px; margin-bottom: 14px; background: var(--brand-50); }
.duyuru-html img { max-width: 100%; height: auto; border-radius: 8px; }
.duyuru-html p { margin: 0 0 4px; } .duyuru-html ul, .duyuru-html ol { padding-left: 18px; margin: 4px 0; }
.duyuru-html table { border-collapse: collapse; font-size: 12px; } .duyuru-html td, .duyuru-html th { border: 1px solid var(--line); padding: 2px 6px; }

/* Şablondan yazdır penceresi (js/yazdir.js) */
.yz-liste { display: flex; flex-direction: column; gap: 6px; max-height: 60vh; overflow: auto; }
.yz-sab { display: flex; align-items: center; gap: 4px; border: 1px solid var(--line); border-radius: 12px; padding: 2px 4px 2px 2px; background: var(--surface); }
.yz-sab.son { border-color: var(--brand); }
.yz-sab:hover { border-color: var(--brand); }
.yz-bas { flex: 1; display: flex; align-items: center; gap: 10px; min-width: 0; padding: 10px; border: 0; background: none; color: inherit; text-align: left; cursor: pointer; font: inherit; }
.yz-bas .grow { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }


/* =====================================================================
   UYUM KATMANI — eski sınıf dağarcığını yeni tasarıma bağlar
   =====================================================================
   Proje 25'ten fazla sayfayla birlikte kendi sınıf adlarıyla yazılmıştı.
   Bu bölüm o adları yukarıdaki tasarımın görünümüne bağlar; sayfaların
   HTML'ine dokunmaya gerek kalmaz.

   YENİ SAYFA YAZARKEN BU BÖLÜMÜ KULLANMAYIN. Yeni ekranlar doğrudan
   örnek dağarcığıyla yazılır:
      .card / .card-h       panel yerine
      .btn-light            ikincil buton
      .badge b-ok           durum etiketi
      .field > label+input  form alanı
      .tbl + .table-wrap    tablo
      .modal-h/-b/-f        modal
   ===================================================================== */

/* ---------------------------------------------------------------------
   1. ESKİ DEĞİŞKEN ADLARI → YENİ TEMA
   Sayfaların kendi <style> blokları bu adları kullanıyor. Hepsi yeni
   tema değişkenlerine bağlandı; koyu tema da kendiliğinden çalışır.
   --------------------------------------------------------------------- */
:root {
  --ink:        var(--text);
  --ink-2:      var(--text-2);
  --slate:      var(--text-2);
  --slate-2:    var(--muted);
  --slate-3:    var(--muted);
  --line-2:     var(--line);
  --line2:      var(--line);
  --mut:        var(--muted);
  --page:       var(--bg);
  --card:       var(--surface);

  --brand-2:    #6a3df0;
  --brand-ink:  var(--brand-700);
  --brand-soft: var(--brand-50);
  --brand-line: var(--brand-100);

  /* Pirinç vurgusu artık "uyarı" rengiyle aynı aileden */
  --brass:      var(--warn);
  --brass-soft: var(--warn-bg);
  --brass-line: var(--warn-line);

  --ok-soft:    var(--ok-bg);
  --warn-soft:  var(--warn-bg);
  --err:        var(--danger);
  --err-soft:   var(--danger-bg);
  --err-line:   var(--danger-line);
  --info-soft:  var(--info-bg);
  --info-line:  var(--info-line);

  /* İş akışı kartelası — aynı renk her ekranda aynı aşama */
  --sw-wait:    var(--muted);
  --sw-supply:  var(--warn);
  --sw-prod:    var(--brand);
  --sw-ready:   var(--teal);
  --sw-install: var(--info);
  --sw-done:    var(--ok);
  --sw-late:    var(--danger);

  /* Modül renkleri */
  --m-home: #2f5bea;  --m-offer: #7a3ff2;   --m-order: #2563eb;
  --m-customer: #0b9e95; --m-product: #7a3ff2; --m-prod: #b26a00;
  --m-install: #0b9e95;  --m-stock: #0b7fc7;   --m-purchase: #e0457b;
  --m-finance: #0f9d58;  --m-invoice: #d0352b; --m-dispatch: #ff8a3d;
  --m-service: #e5533b;  --m-report: #2449c8;  --m-settings: #66728a;

  --acc: var(--brand);
  --acc-soft: var(--brand-50);

  /* Ölçü ve yarıçap takma adları */
  --s1: 4px;  --s2: 8px;  --s3: 12px; --s4: 16px;
  --s5: 20px; --s6: 24px; --s8: 32px; --s10: 40px; --s12: 48px;
  --r-sm: 10px; --r-md: var(--radius-sm); --r-lg: var(--radius);
  --r-xl: var(--radius-lg); --r-pill: 999px;
  --sh-1: var(--shadow-sm); --sh-2: var(--shadow);
  --sh-3: var(--shadow); --sh-4: var(--shadow-lg);
  --tab-h: var(--bottom-h);
  --ease: cubic-bezier(.22, .61, .36, 1);
}

/* Sayfanın vurgu rengi — <body data-mod="offer"> */
body[data-mod="home"]     { --acc: var(--m-home); }
body[data-mod="offer"]    { --acc: var(--m-offer); }
body[data-mod="order"]    { --acc: var(--m-order); }
body[data-mod="customer"] { --acc: var(--m-customer); }
body[data-mod="product"]  { --acc: var(--m-product); }
body[data-mod="prod"]     { --acc: var(--m-prod); }
body[data-mod="install"]  { --acc: var(--m-install); }
body[data-mod="stock"]    { --acc: var(--m-stock); }
body[data-mod="purchase"] { --acc: var(--m-purchase); }
body[data-mod="finance"]  { --acc: var(--m-finance); }
body[data-mod="invoice"]  { --acc: var(--m-invoice); }
body[data-mod="dispatch"] { --acc: var(--m-dispatch); }
body[data-mod="service"]  { --acc: var(--m-service); }
body[data-mod="report"]   { --acc: var(--m-report); }
body[data-mod="settings"] { --acc: var(--m-settings); }

/* ---------------------------------------------------------------------
   2. İSKELET — .app/.main/.page eski adları
   --------------------------------------------------------------------- */
.app { min-height: 100vh; }
.main {
  min-height: 100vh;
  padding-left: var(--rail-w);
  padding-bottom: calc(var(--bottom-h) + env(safe-area-inset-bottom));
}
@media (min-width: 761px) { .main { padding-bottom: 0; } }
.page { padding: 22px 24px 34px; max-width: 1560px; margin: 0 auto; }
.page-wide { max-width: none; }
@media (max-width: 760px) { .page { padding: 14px 12px 24px; } }

/* ---------------------------------------------------------------------
   2b. KABUK EKLERİ — üst bar, akordeon menü, alt sekme çubuğu
   Sayfaların HTML'i değişmedi; auth.js bu yapıyı dolduruyor.
   --------------------------------------------------------------------- */
.topbar-ttl { display: flex; flex-direction: column; justify-content: center; min-width: 0; flex: 1; }
.topbar-ttl h1 { font-size: 19px; font-weight: 800; letter-spacing: -.015em; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.topbar-ttl p { font-size: 12.5px; color: var(--muted); font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.topbar-actions { display: flex; align-items: center; gap: 6px; margin-left: auto; }
@media (max-width: 760px) { .topbar-ttl h1 { font-size: 17.5px; } }

/* Koyu temada baş harfler okunmuyordu: zemin koyu, yazı da koyuydu */
[data-theme="dark"] .avatar { background: var(--brand); color: #fff; }

/* AKORDEON MENÜ
   Gruplar kapalı açılır; bir gruptaki maddeye basılınca yalnızca o grup
   açık kalır. Başlık görünüşte örnek tasarımın .rail-group etiketi gibi
   durur, davranışta düğmedir. */
.nav-group + .nav-group { margin-top: 2px; }
.nav-head {
  display: flex; align-items: center; gap: 10px; width: 100%;
  padding: 11px 12px 7px;
  font-size: 10.5px; font-weight: 800; letter-spacing: .1em;
  text-transform: uppercase; color: #6876a6;
  border-radius: 12px;
}
.nav-head:hover { background: var(--nav-2); color: #fff; }
.nav-head > svg:first-child { width: 16px; height: 16px; flex: none; opacity: .85; }
.nav-head .chev { margin-left: auto; width: 15px; height: 15px; flex: none; transition: transform .2s ease; opacity: .7; }
.nav-group.is-open > .nav-head { color: #fff; }
.nav-group.is-open > .nav-head .chev { transform: rotate(180deg); }
.nav-head .dot { width: 7px; height: 7px; border-radius: 50%; margin-left: auto; background: #ff5d7a; flex: none; }
.nav-group.is-open .nav-head .dot { display: none; }
.nav-head .dot + .chev { margin-left: 7px; }
.nav-items { display: none; padding-bottom: 4px; }
.nav-group.is-open > .nav-items { display: block; }

/* Eski düz grup başlığı (geriye dönük uyum) */
.rail-group { padding: 14px 12px 6px; }

.rail-link {
  display: flex; align-items: center; gap: 13px;
  min-height: 46px; padding: 0 13px; border-radius: 12px;
  color: var(--nav-text); text-decoration: none;
  font-weight: 600; font-size: 14.5px; position: relative;
}
.rail-link svg { width: 21px; height: 21px; flex: none; }
.rail-link:hover { background: var(--nav-2); color: #fff; }
.rail-link.is-active { background: #fff; color: var(--nav); font-weight: 800; }
.rail-link.is-active svg { color: var(--brand); }
.rail-badge {
  margin-left: auto; min-width: 24px; height: 22px; padding: 0 7px;
  border-radius: 11px; display: grid; place-items: center;
  font-size: 11.5px; font-weight: 800; background: #ff5d7a; color: #fff;
  font-variant-numeric: tabular-nums;
}

/* Alt kullanıcı bloğu (çekmecede) */
.rail-user {
  margin-top: auto; padding-top: 12px;
  border-top: 1px solid rgba(255, 255, 255, .08);
  display: flex; align-items: center; gap: 10px;
}
.rail-avatar {
  width: 38px; height: 38px; border-radius: 12px; flex: none;
  display: grid; place-items: center; font-weight: 800; font-size: 14px;
  background: var(--brand-grad); color: #fff;
}
.rail-user-txt { min-width: 0; flex: 1; }
.rail-user-txt b { display: block; color: #fff; font-size: 13.5px; font-weight: 700; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.rail-user-txt span { display: block; color: #8796c4; font-size: 11.5px; font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.rail-user .btn-icon { color: #8796c4; width: 40px; height: 40px; border-radius: 12px; }
.rail-user .btn-icon:hover { background: var(--nav-2); color: #fff; }

/* Alt sekme çubuğu — eski .tabbar adı, örnek dosyadaki .bottom-nav ile
   aynı davranır: yalnız telefonda, ekranın altına sabit. */
.tabbar {
  position: fixed; left: 0; right: 0; bottom: 0; z-index: 40;
  display: none;
  height: calc(var(--bottom-h) + env(safe-area-inset-bottom));
  padding-bottom: env(safe-area-inset-bottom);
  background: var(--surface);
  border-top: 1px solid var(--line);
  box-shadow: 0 -6px 20px rgba(14, 22, 48, .06);
}
@media (max-width: 760px) { .tabbar { display: flex; } }

/* Hamburger yalnız telefonda; masaüstünde menü zaten açık duruyor */
@media (min-width: 761px) { .burger { display: none !important; } }
.tab {
  flex: 1; display: flex; flex-direction: column;
  align-items: center; justify-content: center; gap: 3px;
  color: var(--muted); text-decoration: none;
  font-size: 11.5px; font-weight: 700; position: relative;
}
.tab svg { width: 24px; height: 24px; }
.tab.is-active { color: var(--brand); }
.tab.is-active::before {
  content: ""; position: absolute; top: 0; left: 30%; right: 30%;
  height: 3px; background: var(--brand); border-radius: 0 0 3px 3px;
}
.tab-dot {
  position: absolute; top: 8px; left: 50%; margin-left: 8px;
  width: 8px; height: 8px; border-radius: 50%;
  background: #ff5d7a; border: 2px solid var(--surface);
}

/* Yüzen ekle düğmesi (mobil) */
.fab {
  position: fixed; z-index: 45; right: 16px;
  bottom: calc(var(--bottom-h) + env(safe-area-inset-bottom) + 14px);
  width: 58px; height: 58px; border-radius: 20px;
  background: var(--brand-grad); color: #fff;
  display: grid; place-items: center;
  box-shadow: 0 10px 24px rgba(47, 91, 234, .45);
}
.fab svg { width: 28px; height: 28px; }
@media (min-width: 761px) { .fab { display: none; } }

/* Telefon: menü çekmece olur */
@media (max-width: 760px) {
  .rail { width: 286px; transform: translateX(-105%); transition: transform .22s ease; box-shadow: var(--shadow-lg); }
  .rail.is-open, .rail.open { transform: none; }
}
@media (min-width: 761px) { .scrim { display: none !important; } }

/* ---------------------------------------------------------------------
   3. PANEL → KART
   --------------------------------------------------------------------- */
.panel {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-sm);
}
.panel-raised { box-shadow: var(--shadow); }
.panel-hd {
  display: flex; align-items: center; gap: 10px; flex-wrap: wrap;
  padding: 14px 18px;
  border-bottom: 1px solid var(--line);
}
.panel-hd h2, .panel-hd h3 {
  font-size: 16.5px; font-weight: 800; letter-spacing: -.01em;
  flex: 1; min-width: 0;
}
.panel-bd { padding: 18px; }
.panel-bd-flush { padding: 0; }
.panel-ft {
  padding: 14px 18px;
  border-top: 1px solid var(--line);
  background: var(--surface-2);
  border-radius: 0 0 var(--radius-lg) var(--radius-lg);
}
.panel .tbl-wrap, .panel .table-wrap { border: 0; border-radius: 0; }

/* Süzgeç çubuğu */
.toolbar {
  display: flex; align-items: center; gap: 10px; flex-wrap: wrap;
  padding: 14px 16px; margin-bottom: 14px;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow-sm);
}
.toolbar .search { flex: 1 1 260px; min-width: 0; }

/* ---------------------------------------------------------------------
   4. IZGARA VE AKIŞ (örnek dosyada yok, projeye özgü)
   --------------------------------------------------------------------- */
.grid { display: grid; gap: 14px; }
.grid.g4 { gap: 16px; } .grid.g5 { gap: 20px; }
.c2, .c3, .c4, .c6 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
@media (min-width: 720px) {
  .c3, .c6 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .c4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }
}
@media (min-width: 1200px) { .c6 { grid-template-columns: repeat(6, minmax(0, 1fr)); } }
.split { display: grid; gap: 16px; grid-template-columns: minmax(0, 1fr); }
@media (min-width: 1200px) {
  .split { grid-template-columns: minmax(0, 2fr) minmax(0, 1fr); }
  .split-even { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); }
}
.span2 { grid-column: span 2; }
.row-top { align-items: flex-start; } .row-end { align-items: flex-end; }
.wrap { flex-wrap: wrap; } .spread { justify-content: space-between; }
.push { margin-left: auto; } .shrink0 { flex-shrink: 0; }
.stack-sm { display: flex; flex-direction: column; gap: 8px; }
.mt0 { margin-top: 0 !important; } .mt3 { margin-top: 12px; }
.mb3 { margin-bottom: 12px; } .mb4 { margin-bottom: 16px; }
.g2 { gap: 8px; } .center { text-align: center; } .right { text-align: right; }
.hide { display: none !important; }
.trunc { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }

/* Tipografi takma adları */
.t-xs { font-size: 12px; } .t-sm { font-size: 13.5px; } .t-md { font-size: 15px; }
.t-lg { font-size: 17px; } .t-xl { font-size: 21px; }
.t-2xl { font-size: 26px; letter-spacing: -.02em; }
.t-3xl { font-size: 32px; letter-spacing: -.025em; }
.w5 { font-weight: 500; } .w6 { font-weight: 700; } .w7 { font-weight: 800; }
.muted2 { color: var(--muted); } .ink { color: var(--text); }
.ok-t { color: var(--ok); } .err-t { color: var(--danger); }
.warn-t { color: var(--warn); } .brand-t { color: var(--acc); }

/* Ekran genişliğine göre gizleme (tablo sütunları) */
.hide-sm { display: none; }
@media (min-width: 640px) { .hide-sm { display: inline; } }
.hide-md { display: none; }
@media (min-width: 900px) { .hide-md { display: table-cell; } }
.hide-lg { display: none; }
@media (min-width: 1200px) { .hide-lg { display: table-cell; } }
.hide-md-inline { display: block; }
@media (min-width: 900px) { .hide-md-inline { display: none; } }

/* ---------------------------------------------------------------------
   5. KPI — örnek tasarımın renkli kutusu
   Eski işaretleme: <a class="kpi" data-tone="ok">
     <span class="kpi-lbl">..</span><span class="kpi-val">..</span>
     <span class="kpi-sub">..</span></a>
   --------------------------------------------------------------------- */
.kpi {
  position: relative; overflow: hidden;
  display: flex; flex-direction: column; justify-content: center;
  min-height: 118px; padding: 16px 18px;
  border-radius: var(--radius-lg);
  color: #fff; text-decoration: none;
  background: linear-gradient(135deg, #3b6cff, #6a3df0);
  box-shadow: var(--shadow);
}
.kpi::after {
  content: ""; position: absolute; right: -40px; top: -40px;
  width: 140px; height: 140px; border-radius: 50%;
  background: rgba(255, 255, 255, .1);
}
.kpi[data-tone="ok"]    { background: linear-gradient(135deg, #10b981, #0b8f74); }
.kpi[data-tone="err"]   { background: linear-gradient(135deg, #ff8a3d, #e5533b); }
.kpi[data-tone="warn"]  { background: linear-gradient(135deg, #f59e0b, #b26a00); }
.kpi[data-tone="info"]  { background: linear-gradient(135deg, #0ea5e9, #2563eb); }
.kpi[data-tone="brass"] { background: linear-gradient(135deg, #f0a93b, #b26a00); }
.kpi[data-tone="brand"] { background: linear-gradient(135deg, #3b6cff, #6a3df0); }
a.kpi:hover, button.kpi:hover { filter: brightness(1.06); color: #fff; }
.kpi-lbl { position: relative; display: block; font-size: 13.5px; font-weight: 700; opacity: .95; }
.kpi-val {
  position: relative; display: block; margin-top: 8px;
  font-size: clamp(21px, 2vw, 27px); font-weight: 800;
  letter-spacing: -.02em; line-height: 1.1;
  font-variant-numeric: tabular-nums; white-space: nowrap;
}
.kpi-sub { position: relative; display: block; margin-top: 4px; font-size: 12.5px; font-weight: 700; opacity: .92; }
.kpi-dot {
  position: absolute; top: 12px; right: 12px; z-index: 1;
  width: 9px; height: 9px; border-radius: 50%;
  background: #fff; box-shadow: 0 0 0 3px rgba(255, 255, 255, .3);
}

/* .stat içinde <span> kullanılırsa değer ve etiket yan yana yapışıyordu;
   satır olarak akmaları için blok yapılıyor. */
.stat .v, .stat .l { display: block; }

/* Sade istatistik satırı (örnek dosyadaki .stat ile aynı aile) */
.stat-l { font-size: 12.5px; color: var(--muted); font-weight: 700; }
.stat-v { font-size: 19px; font-weight: 800; letter-spacing: -.02em; font-variant-numeric: tabular-nums; }

/* ---------------------------------------------------------------------
   6. TABLO — eski .tbl-wrap / .num / .tbl-stack
   --------------------------------------------------------------------- */
.tbl-wrap { overflow-x: auto; -webkit-overflow-scrolling: touch; }
.tbl { min-width: 0; }
.tbl td.num, .tbl th.num { text-align: right; font-variant-numeric: tabular-nums; white-space: nowrap; }
.tbl tbody tr.is-click { cursor: pointer; }
.tbl tbody tr.is-click:hover td { background: var(--brand-50); }
.tbl tbody tr.is-late td { background: var(--danger-bg); }
.cell-main { font-weight: 800; }
.cell-sub { display: block; color: var(--muted); font-size: 12px; font-weight: 600; margin-top: 2px; }
.tbl-ft {
  display: flex; align-items: center; gap: 12px; flex-wrap: wrap;
  padding: 12px 16px; border-top: 1px solid var(--line);
}
.ln-total { text-align: right; font-weight: 800; font-variant-numeric: tabular-nums; }

/* Mobilde tabloyu karta çevir: <table class="tbl tbl-stack"> + td[data-th] */
@media (max-width: 760px) {
  .tbl-stack { min-width: 0; }
  .tbl-stack thead { display: none; }
  .tbl-stack, .tbl-stack tbody, .tbl-stack tr, .tbl-stack td { display: block; width: 100%; }
  .tbl-stack tbody tr {
    padding: 12px 14px; margin-bottom: 10px;
    border: 1px solid var(--line); border-radius: var(--radius);
    background: var(--surface); box-shadow: var(--shadow-sm);
  }
  .tbl-stack tbody td { padding: 2px 0; border: 0; text-align: left; }
  .tbl-stack tbody td.num { text-align: left; }
  .tbl-stack tbody td[data-th]::before {
    content: attr(data-th); display: inline-block; min-width: 92px;
    color: var(--muted); font-size: 11px; font-weight: 800;
    letter-spacing: .05em; text-transform: uppercase;
  }
  .tbl-stack tbody td.stack-main { font-size: 15.5px; margin-bottom: 4px; }
  .tbl-stack tbody td.stack-act {
    margin-top: 10px; padding-top: 10px;
    border-top: 1px solid var(--line) !important;
  }
  .tbl-stack tbody td.stack-act > .row { justify-content: flex-start !important; }
  .tbl-stack .hide-md, .tbl-stack .hide-lg { display: none !important; }
}

/* ---------------------------------------------------------------------
   7. FORM — eski .inp/.sel/.ta/.lbl
   --------------------------------------------------------------------- */
.lbl {
  display: block; margin-bottom: 6px;
  font-size: 13.5px; font-weight: 700; color: var(--text-2);
}
/* ÇAKIŞMA UYARISI — .opt iki ayrı şey için kullanılıyordu:
   örnek dosyada paylaş menüsündeki BÜYÜK KUTU, bu projede ise
   etiketin yanındaki ince açıklama. Etiket içindekini sade metne
   döndürüyoruz; paylaş menüsü (.opts .opt) etkilenmiyor. */
.lbl .opt, .field > label .opt {
  display: inline; padding: 0; border: 0; background: none;
  border-radius: 0; flex-direction: row; align-items: baseline;
  font-weight: 600; font-size: inherit; color: var(--muted); text-align: left;
}
/* Etiket blok akışında kalsın; uzun açıklama alt satıra sarsın */
.field > label.lbl, label.lbl { display: block; }
.lbl2 { display: block; margin-bottom: 6px; font-size: 12.5px; font-weight: 700; color: var(--muted); }
.inp, .sel, .ta {
  display: block; width: 100%;
  min-height: var(--tap); padding: 0 15px;
  background: var(--surface); color: var(--text);
  border: 1.5px solid var(--line-strong);
  border-radius: var(--radius-sm);
  font-weight: 600;
  transition: border-color .15s, box-shadow .15s;
}
.ta { padding: 12px 15px; min-height: 92px; resize: vertical; }
.inp:focus, .sel:focus, .ta:focus {
  outline: 0; border-color: var(--brand);
  box-shadow: 0 0 0 4px var(--brand-50);
}
.inp:disabled, .sel:disabled, .ta:disabled, .inp[readonly] {
  background: var(--surface-3); color: var(--muted);
}
.inp:disabled, .sel:disabled, .ta:disabled { cursor: not-allowed; }
.inp-num { text-align: right; font-variant-numeric: tabular-nums; }
.sel {
  appearance: none; padding-right: 38px;
  background-image: url("data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' width='14' height='14' viewBox='0 0 24 24' fill='none' stroke='%2366728a' stroke-width='2.5'%3E%3Cpath d='M6 9l6 6 6-6'/%3E%3C/svg%3E");
  background-repeat: no-repeat; background-position: right 14px center;
}
/* .field içindeki ham input'u örnek dosya da biçimlendiriyor (.field input);
   o seçici daha baskın olduğu için küçük boy kuralını .field ile de yazıyoruz,
   yoksa .field içindeki küçük alanlar tam boy çıkıyor. */
.inp-sm, .sel-sm, .field .inp-sm, .field .sel-sm {
  min-height: 42px; padding: 0 12px; font-size: 14.5px; border-radius: 10px;
}
.sel-sm, .field .sel-sm { padding-right: 32px; background-position: right 10px center; }
.inp.is-err, .sel.is-err, .ta.is-err { border-color: var(--danger) !important; }
.err-msg { margin-top: 5px; color: var(--danger); font-size: 12.5px; font-weight: 700; }
.hint { margin-top: 5px; color: var(--muted); font-size: 12.5px; font-weight: 600; }

/* ---------------------------------------------------------------------
   FLEX İÇİNDE ALAN GENİŞLİĞİ — bir kez hataya sebep oldu, dikkat.
   .inp varsayılan width:100% taşır; .row (flex) çocuğu olunca satırın
   tamamına çözülür ve yanındaki .grow 0 piksele ezilir (arama kutusu
   kaybolmuştu). Flex içindeki alan içeriğine göre genişler; büyümesi
   isteniyorsa .grow açıkça verilir.
   --------------------------------------------------------------------- */
.row > .inp, .row > .sel, .row > .ta { width: auto; flex: 0 1 auto; }
.row > .sel { min-width: 150px; }
.row > .inp { min-width: 160px; }
.row > .grow, .row > .search.grow { flex: 1 1 0; min-width: 0; }
.row > .search.grow .inp { width: 100%; }
.row.wrap > .search.grow, .row.wrap > .grow { flex: 1 1 220px; }
.toolbar > .sel, .toolbar > .inp { width: auto; flex: 0 1 auto; min-width: 140px; }

.search { position: relative; }
.search .inp { padding-left: 46px; }
.search > svg {
  position: absolute; left: 15px; top: 50%; transform: translateY(-50%);
  width: 19px; height: 19px; color: var(--muted); pointer-events: none;
}

.chk { display: inline-flex; align-items: center; gap: 9px; cursor: pointer; user-select: none; font-weight: 600; }
.chk input { width: 20px; height: 20px; margin: 0; accent-color: var(--brand); cursor: pointer; }

.with-unit { position: relative; }
.with-unit .inp { padding-right: 44px; }
.with-unit .unit {
  position: absolute; right: 14px; top: 50%; transform: translateY(-50%);
  color: var(--muted); font-size: 13px; font-weight: 800; pointer-events: none;
}

.readout {
  min-height: var(--tap); padding: 0 15px;
  display: flex; align-items: center; justify-content: flex-end;
  background: var(--surface-2); border: 1.5px solid var(--line);
  border-radius: var(--radius-sm);
  font-weight: 800; font-variant-numeric: tabular-nums;
}

.pwd-wrap { position: relative; }
.pwd-wrap .inp { padding-right: 56px; }
.pwd-eye {
  position: absolute; right: 5px; top: 50%; transform: translateY(-50%);
  width: 44px; height: 44px; border-radius: 10px;
  display: grid; place-items: center; color: var(--brand);
}
.pwd-eye:hover { background: var(--brand-50); }

.chk-row { display: flex; flex-wrap: wrap; gap: 12px; }

/* ---------------------------------------------------------------------
   8. BUTONLAR — eski adların karşılıkları
   NOT: projede .btn-ghost "beyaz, çerçeveli ikincil buton" anlamında
   kullanılıyordu; örnek dosyadaki .btn-light bu role denk geliyor.
   Şeffaf buton isteyen yerler .btn-quiet kullanır.
   --------------------------------------------------------------------- */
.btn-ghost {
  background: var(--surface); color: var(--text);
  border-color: var(--line-strong);
}
.btn-ghost:hover { background: var(--surface-2); color: var(--text); }
.btn-quiet { color: var(--text-2); background: none; border-color: transparent; }
.btn-quiet:hover { background: var(--surface-3); }
.btn-acc { background: var(--acc); color: #fff; }
.btn-acc:hover { filter: brightness(1.08); color: #fff; }
.btn-brass { background: var(--warn); color: #fff; }
.btn-brass:hover { filter: brightness(1.08); color: #fff; }
.btn-primary:hover, .btn-ok:hover, .btn-danger:hover { color: #fff; }
.btn svg { width: 19px; height: 19px; flex: none; }
.btn-sm svg { width: 17px; height: 17px; }

.burger, .menu-btn {
  width: 46px; height: 46px; border-radius: 13px;
  display: grid; place-items: center; color: var(--text-2);
}
.burger:hover { background: var(--surface-3); }
.burger svg { width: 22px; height: 22px; }

.bell { position: relative; }
.bell-count {
  position: absolute; top: 5px; right: 5px;
  min-width: 18px; height: 18px; padding: 0 4px;
  border-radius: 9px; background: #ff5d7a; color: #fff;
  font-size: 10.5px; font-weight: 800;
  display: grid; place-items: center;
  border: 2px solid var(--surface);
  font-variant-numeric: tabular-nums;
}

.spin {
  width: 17px; height: 17px;
  border: 2px solid rgba(255, 255, 255, .35);
  border-top-color: #fff; border-radius: 50%;
  animation: spin .7s linear infinite;
}
.btn-ghost .spin, .btn-quiet .spin, .btn-light .spin {
  border-color: rgba(54, 66, 92, .25); border-top-color: var(--text-2);
}
@keyframes spin { to { transform: rotate(360deg); } }

/* ---------------------------------------------------------------------
   9. DURUM ETİKETLERİ — eski .pill[data-tone] → örnek .badge
   --------------------------------------------------------------------- */
.pill {
  display: inline-flex; align-items: center; gap: 5px;
  height: 26px; padding: 0 10px; border-radius: 13px;
  font-size: 12px; font-weight: 800; white-space: nowrap;
  background: var(--surface-3); color: var(--text-2);
  border: 1px solid var(--line);
}
.pill::before {
  content: ''; width: 7px; height: 7px; border-radius: 50%;
  background: currentColor; flex: none;
}
.pill-plain::before { display: none; }
.pill[data-tone="wait"], .pill[data-tone="neutral"] { background: var(--surface-3); color: var(--text-2); border-color: var(--line); }
.pill[data-tone="supply"], .pill[data-tone="warning"], .pill[data-tone="warn"] { background: var(--warn-bg); color: var(--warn); border-color: var(--warn-line); }
.pill[data-tone="prod"], .pill[data-tone="brand"] { background: var(--brand-50); color: var(--brand-700); border-color: var(--brand-100); }
.pill[data-tone="ready"] { background: var(--teal-bg); color: var(--teal); border-color: transparent; }
.pill[data-tone="install"], .pill[data-tone="info"] { background: var(--info-bg); color: var(--info); border-color: var(--info-line); }
.pill[data-tone="done"], .pill[data-tone="ok"] { background: var(--ok-bg); color: var(--ok); border-color: var(--ok-line); }
.pill[data-tone="critical"], .pill[data-tone="err"] { background: var(--danger-bg); color: var(--danger); border-color: var(--danger-line); }
.pill[data-tone="late"] { background: var(--danger); color: #fff; border-color: transparent; }
[data-theme="dark"] .pill { border-color: transparent; }

.swatch {
  display: inline-block; width: 13px; height: 13px;
  border-radius: 4px; border: 1px solid rgba(14, 22, 48, .12);
  vertical-align: -2px;
}
.swatch[data-tone="wait"]    { background: var(--sw-wait); }
.swatch[data-tone="supply"]  { background: var(--sw-supply); }
.swatch[data-tone="prod"]    { background: var(--sw-prod); }
.swatch[data-tone="ready"]   { background: var(--sw-ready); }
.swatch[data-tone="install"] { background: var(--sw-install); }
.swatch[data-tone="done"]    { background: var(--sw-done); }
.swatch[data-tone="late"]    { background: var(--sw-late); }

.tag {
  display: inline-flex; align-items: center;
  padding: 3px 9px; border-radius: 10px;
  background: var(--surface-3); border: 1px solid var(--line);
  color: var(--text-2); font-size: 12px; font-weight: 700;
}
.tag[data-tone="warn"] { background: var(--warn-bg); border-color: var(--warn-line); color: var(--warn); }
.tag[data-tone="ok"]   { background: var(--ok-bg);   border-color: var(--ok-line);   color: var(--ok); }
.calc-notes { display: flex; flex-wrap: wrap; gap: 5px; margin-top: 7px; }

/* ---------------------------------------------------------------------
   10. ÇİP, SEKME, SEGMENT — eski .is-active adı
   --------------------------------------------------------------------- */
.chip.is-active { background: var(--nav); border-color: var(--nav); color: #fff; }
[data-theme="dark"] .chip.is-active { background: var(--brand); border-color: var(--brand); }
.chip-sm { height: 32px; padding: 0 12px; font-size: 12.5px; }
.chips { flex-wrap: wrap; }

.tabs button.is-active, .tabs a.is-active {
  background: var(--surface); color: var(--brand-700); box-shadow: var(--shadow-sm);
}
[data-theme="dark"] .tabs button.is-active { color: #b9c9ff; }
.tabs .cnt {
  min-width: 22px; height: 22px; padding: 0 6px; border-radius: 11px;
  display: inline-grid; place-items: center; margin-left: 6px;
  font-size: 11.5px; font-weight: 800;
  background: var(--surface-3); color: var(--text-2);
}
.tabs button.is-active .cnt { background: var(--brand-50); color: var(--brand-700); }
.tabs .cnt[data-tone="err"] { background: var(--danger); color: #fff; }

.seg button.is-active { background: var(--brand); border-color: var(--brand); color: #fff; }
.seg button:disabled { opacity: .5; cursor: not-allowed; }

/* ---------------------------------------------------------------------
   11. MODAL — eski .modal-hd/.modal-bd/.modal-ft
   --------------------------------------------------------------------- */
.modal-back { display: none; }
.modal-back.is-open { display: flex; }
.modal-lg { width: min(960px, 100%); }
.modal-xl { width: min(1180px, 100%); }
.modal-hd {
  position: sticky; top: 0; z-index: 2; background: var(--surface);
  display: flex; align-items: center; gap: 12px;
  padding: 14px 16px; border-bottom: 1px solid var(--line);
  border-radius: var(--radius-lg) var(--radius-lg) 0 0;
}
.modal-hd h2, .modal-hd h3 { font-size: 17.5px; font-weight: 800; flex: 1; min-width: 0; }
.modal-bd { padding: 16px; }
.modal-ft {
  position: sticky; bottom: 0; background: var(--surface);
  border-top: 1px solid var(--line);
  display: flex; gap: 10px; padding: 12px 16px; flex-wrap: wrap;
}
.modal-ft .btn { flex: 1 1 130px; }
.modal-x {
  width: 42px; height: 42px; border-radius: 12px; flex: none;
  display: grid; place-items: center;
  font-size: 22px; line-height: 1; color: var(--muted);
}
.modal-x:hover { background: var(--surface-3); color: var(--text); }
@media (max-width: 640px) {
  .modal-lg, .modal-xl { width: 100%; }
  .modal-hd { border-radius: 0; }
}

/* ---------------------------------------------------------------------
   12. BİLDİRİM — proje üst üste yığılan bildirim kullanıyor
   --------------------------------------------------------------------- */
.toast-host {
  position: fixed; z-index: 200;
  left: 12px; right: 12px;
  bottom: calc(var(--bottom-h) + 14px + env(safe-area-inset-bottom));
  display: flex; flex-direction: column; gap: 10px;
  pointer-events: none;
}
@media (min-width: 761px) { .toast-host { left: auto; right: 24px; bottom: 24px; width: 400px; } }
.toast {
  position: static; transform: none; left: auto;
  display: flex; align-items: flex-start; gap: 0;
  padding: 0; border-radius: 14px;
  background: #0e1630; color: #fff;
  box-shadow: var(--shadow-lg);
  pointer-events: auto; overflow: hidden;
  animation: pop .2s ease;
}
.toast.is-closing { opacity: 0; transform: translateY(8px); transition: .18s ease; }
.toast-msg { flex: 1; padding: 13px 16px; font-size: 14px; font-weight: 600; }
.toast-act { padding: 13px 14px; font-weight: 800; font-size: 13px; color: #9ec1ff; flex: none; }
.toast-act:hover { color: #fff; }
.toast-x { padding: 13px 14px; color: rgba(255, 255, 255, .6); font-size: 18px; line-height: 1; flex: none; }
.toast-x:hover { color: #fff; }
.toast[data-tone="success"] { background: #0b6b3f; }
.toast[data-tone="error"]   { background: #8e1f19; }
.toast[data-tone="warning"] { background: #b45309; }
.toast[data-tone="info"]    { background: #0e1630; }

/* ---------------------------------------------------------------------
   13. BOŞ DURUM, İSKELET, UYARI KUTUSU
   --------------------------------------------------------------------- */
.empty-ico {
  width: 54px; height: 54px; margin: 0 auto 12px;
  border-radius: 16px; display: grid; place-items: center;
  background: var(--brand-50); color: var(--brand);
}
.empty-ico svg { width: 26px; height: 26px; }
.empty h3 { font-size: 16px; font-weight: 800; color: var(--text); margin-bottom: 4px; }
.empty p { margin: 0 auto 16px; color: var(--muted); font-size: 14px; max-width: 46ch; font-weight: 600; }
.empty-sm { padding: 24px 12px; text-align: center; color: var(--muted); font-size: 13.5px; font-weight: 600; }

.skel { background: linear-gradient(90deg, var(--surface-3) 25%, var(--surface-2) 50%, var(--surface-3) 75%); background-size: 200% 100%; animation: sk 1.2s infinite; border-radius: 10px; }
.skel-line { height: 13px; }
.skel-row td { padding: 13px 14px; border-bottom: 1px solid var(--line); }

.note {
  display: flex; gap: 12px; align-items: flex-start;
  padding: 13px 16px;
  border: 1px solid var(--line); border-radius: var(--radius);
  background: var(--surface); color: var(--text-2);
  font-size: 14px; font-weight: 600;
}
.note svg { width: 20px; height: 20px; flex: none; margin-top: 1px; }
.note p { margin: 3px 0 0; }
.note[data-tone="err"]   { background: var(--danger-bg); border-color: var(--danger-line); color: var(--danger); }
.note[data-tone="warn"]  { background: var(--warn-bg);   border-color: var(--warn-line);   color: var(--warn); }
.note[data-tone="ok"]    { background: var(--ok-bg);     border-color: var(--ok-line);     color: var(--ok); }
.note[data-tone="info"]  { background: var(--info-bg);   border-color: var(--info-line);   color: var(--info); }
.note[data-tone="brand"] { background: var(--brand-50);  border-color: var(--brand-100);   color: var(--brand-700); }
[data-theme="dark"] .note { border-color: transparent; }

/* Tasarruf önerisi (teklif ekranı) — .ac ile karıştırmayın */
.suggest {
  display: flex; align-items: center; gap: 8px;
  margin-top: 8px; padding: 8px 12px;
  background: var(--ok-bg); border: 1px solid var(--ok-line);
  border-radius: 10px; color: var(--ok); font-size: 13px; font-weight: 700;
}
.suggest button { font-weight: 800; text-decoration: underline; color: inherit; }

/* ---------------------------------------------------------------------
   14. AÇILIR MENÜ VE OTOMATİK TAMAMLAMA
   --------------------------------------------------------------------- */
.menu-pop {
  position: fixed; z-index: 150;
  min-width: 248px; max-width: min(340px, calc(100vw - 24px));
  max-height: min(480px, calc(100vh - 24px)); overflow-y: auto;
  padding: 7px;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow-lg);
  animation: pop .14s ease;
}
.menu-hd { padding: 9px 11px 5px; color: var(--muted); font-size: 10.5px; font-weight: 800; letter-spacing: .08em; text-transform: uppercase; }
.menu-item {
  display: flex; align-items: center; gap: 11px; width: 100%;
  min-height: 44px; padding: 8px 11px; border-radius: 11px;
  text-align: left; color: var(--text); font-size: 14.5px; font-weight: 700;
  text-decoration: none;
}
.menu-item svg { width: 19px; height: 19px; color: var(--muted); flex: none; }
.menu-item:hover, .menu-item:focus-visible { background: var(--brand-50); color: var(--brand-700); outline: 0; }
.menu-item:hover svg { color: var(--brand); }
.menu-item small { display: block; color: var(--muted); font-size: 12px; font-weight: 600; }
.menu-item.danger { color: var(--danger); }
.menu-item.danger svg { color: var(--danger); }
.menu-item.danger:hover { background: var(--danger-bg); color: var(--danger); }
.menu-item[disabled] { opacity: .45; pointer-events: none; }
.menu-sep { height: 1px; margin: 6px 5px; background: var(--line); }

.ac {
  position: absolute; z-index: 30; left: 0; right: 0; top: 100%;
  margin-top: 5px; max-height: 300px; overflow-y: auto;
  background: var(--surface); border: 1px solid var(--line);
  border-radius: var(--radius); box-shadow: var(--shadow-lg);
}
.ac-item {
  display: block; width: 100%; padding: 11px 14px; text-align: left;
  border-bottom: 1px solid var(--line); color: var(--text);
}
.ac-item:last-child { border-bottom: 0; }
.ac-item:hover, .ac-item:focus { background: var(--brand-50); outline: 0; }
.ac-item b { display: block; font-size: 14.5px; font-weight: 800; }
.ac-item span { display: block; color: var(--muted); font-size: 12.5px; font-weight: 600; margin-top: 1px; }
.ac-empty { padding: 14px; color: var(--muted); font-size: 13.5px; text-align: center; font-weight: 600; }

/* ---------------------------------------------------------------------
   15. BİLGİ SATIRI, KART SATIRI, ÖLÇER, GRAFİK
   --------------------------------------------------------------------- */
.kv { display: flex; align-items: baseline; gap: 12px; padding: 8px 0; font-size: 14px; font-weight: 600; }
.kv + .kv { border-top: 1px dashed var(--line); }
.kv > span:first-child { color: var(--muted); flex: none; }
.kv > b, .kv > span:last-child { margin-left: auto; text-align: right; font-weight: 800; font-variant-numeric: tabular-nums; }
.kv.kv-total > b { font-size: 22px; letter-spacing: -.02em; color: var(--acc); }

.card-row {
  display: block; padding: 14px 16px;
  background: var(--surface); border: 1px solid var(--line);
  border-radius: var(--radius); box-shadow: var(--shadow-sm); color: inherit;
}
.card-row:hover { border-color: var(--brand-100); box-shadow: var(--shadow); color: inherit; }

/* display:block ZORUNLU — <span> içinde height uygulanmaz (bir kez yaşandı) */
.meter { display: block; height: 8px; border-radius: 4px; background: var(--surface-3); overflow: hidden; }
.meter i { display: block; height: 100%; border-radius: 4px; background: var(--brand-grad); }
.meter i[data-tone="over"] { background: var(--danger); }
.meter i[data-tone="warn"] { background: var(--warn); }

.chart { width: 100%; }
.chart svg { width: 100%; height: 160px; overflow: visible; }
.chart-svg { width: 100%; height: 190px; display: block; }
.chart-bar { fill: var(--brand-100); transition: fill .15s; }
.chart-bar:hover { fill: var(--brand); }
.chart-bar.is-now { fill: url(#pfBarNow); }
.chart-x { display: flex; margin-top: 6px; }
.chart-x span { flex: 1; text-align: center; color: var(--muted); font-size: 11px; font-weight: 700; }

.scroll { scrollbar-width: thin; }
.scroll::-webkit-scrollbar { width: 10px; height: 10px; }
.scroll::-webkit-scrollbar-thumb { background: var(--line-strong); border-radius: 5px; border: 2px solid transparent; background-clip: content-box; }
.sr { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0,0,0,0); white-space: nowrap; border: 0; }
.spacer-bottom { height: 32px; }

/* ---------------------------------------------------------------------
   16. ÜRETİM HATTI ŞERİDİ
   --------------------------------------------------------------------- */
.pipeline { display: grid; gap: 10px; grid-template-columns: repeat(2, minmax(0, 1fr)); }
@media (min-width: 680px)  { .pipeline { grid-template-columns: repeat(4, minmax(0, 1fr)); } }
@media (min-width: 1100px) { .pipeline { grid-template-columns: repeat(7, minmax(0, 1fr)); } }
.pipe-step {
  display: block; padding: 14px;
  background: var(--surface); border: 1px solid var(--line);
  border-radius: var(--radius); color: inherit; text-decoration: none;
  transition: border-color .15s, box-shadow .15s, transform .1s;
}
a.pipe-step:hover, button.pipe-step:hover { border-color: var(--brand-100); box-shadow: var(--shadow); transform: translateY(-2px); }
.pipe-n { display: block; font-size: 23px; font-weight: 800; letter-spacing: -.025em; line-height: 1.1; font-variant-numeric: tabular-nums; }
.pipe-lbl { display: block; color: var(--muted); font-size: 12.5px; font-weight: 700; margin-top: 2px; }
/* display:block ZORUNLU — <span> satır içi olduğundan height uygulanmaz */
.pipe-bar { display: block; margin-top: 9px; height: 7px; border-radius: 4px; background: var(--surface-3); overflow: hidden; }
.pipe-bar i { display: block; height: 100%; width: 0; border-radius: 4px; background: var(--brand-grad); animation: fill .62s ease forwards; }
@keyframes fill { to { width: var(--w, 0%); } }
.pipe-step[data-tone="wait"]    .pipe-bar i { background: var(--sw-wait); }
.pipe-step[data-tone="supply"]  .pipe-bar i { background: var(--sw-supply); }
.pipe-step[data-tone="ready"]   .pipe-bar i { background: var(--sw-ready); }
.pipe-step[data-tone="install"] .pipe-bar i { background: var(--sw-install); }
.pipe-step[data-tone="done"]    .pipe-bar i { background: var(--sw-done); }
.pipe-step[data-tone="late"]    .pipe-bar i { background: var(--sw-late); }
.pipe-step[data-tone="supply"]  .pipe-n { color: var(--warn); }
.pipe-step[data-tone="prod"]    .pipe-n { color: var(--brand); }
.pipe-step[data-tone="ready"]   .pipe-n { color: var(--teal); }
.pipe-step[data-tone="install"] .pipe-n { color: var(--info); }
.pipe-step[data-tone="done"]    .pipe-n { color: var(--ok); }
.pipe-step[data-tone="late"]    .pipe-n { color: var(--danger); }
.pipe-step.is-empty .pipe-n, .pipe-step.is-empty .pipe-lbl { color: var(--muted); }

/* ---------------------------------------------------------------------
   17. KANBAN
   --------------------------------------------------------------------- */
.kanban-wrap { overflow-x: auto; overflow-y: hidden; }
.kanban { display: flex; gap: 14px; align-items: flex-start; min-width: max-content; padding-bottom: 12px; }
.kcol { width: 290px; flex: none; }
.kcol-hd {
  display: flex; align-items: center; gap: 10px;
  padding: 11px 14px; margin-bottom: 10px;
  background: var(--surface); border: 1px solid var(--line);
  border-radius: var(--radius); box-shadow: var(--shadow-sm);
}
.kcol-hd .swatch { width: 9px; height: 24px; border-radius: 4px; border: 0; }
.kcol-hd b { font-size: 14px; font-weight: 800; }
.kcol-hd .cnt {
  margin-left: auto; min-width: 24px; padding: 2px 7px;
  background: var(--surface-3); color: var(--text-2);
  border-radius: 11px; font-size: 12px; font-weight: 800;
  text-align: center; font-variant-numeric: tabular-nums;
}
.kcol-sum { display: block; color: var(--muted); font-size: 11.5px; font-weight: 600; }
.kcol-body { min-height: 120px; padding: 4px; border-radius: var(--radius); transition: background-color .15s, box-shadow .15s; }
.kcol-body.is-over { background: var(--brand-50); box-shadow: inset 0 0 0 2px var(--brand-100); }
.kcol-empty { padding: 26px 0; text-align: center; color: var(--muted); font-size: 12.5px; font-weight: 600; }
.kcard {
  background: var(--surface); border: 1px solid var(--line);
  border-radius: var(--radius); padding: 14px; margin-bottom: 10px;
  box-shadow: var(--shadow-sm); cursor: grab;
  transition: box-shadow .15s, border-color .15s, transform .12s;
}
.kcard:hover { box-shadow: var(--shadow); border-color: var(--brand-100); }
.kcard.is-drag { opacity: .45; }
.kcard:active { cursor: grabbing; }
.kcard-top { display: flex; align-items: flex-start; gap: 8px; margin-bottom: 6px; }
.kcard-no { font-size: 14px; font-weight: 800; }
.kcard-cust { font-size: 14px; color: var(--text-2); margin: 0; font-weight: 600; }
.kcard-meta { color: var(--muted); font-size: 12px; margin: 2px 0 0; font-weight: 600; }
.kcard-ft { display: flex; align-items: center; gap: 5px; margin-top: 12px; padding-top: 10px; border-top: 1px dashed var(--line); }
.kcard-bal { display: block; font-size: 11.5px; margin-top: 2px; font-weight: 700; }
.kcard-bal.is-due { color: var(--danger); } .kcard-bal.is-paid { color: var(--ok); }

/* ---------------------------------------------------------------------
   18. YAZDIRMA
   --------------------------------------------------------------------- */
@media print {
  .rail, .topbar, .scrim, .toast-host, .no-print, .field-actions,
  .tabbar, .bottom-nav, .fab, .menu-pop { display: none !important; }
  .main, .shell { margin-left: 0; padding: 0; }
  body { background: #fff; }
  .panel, .card { border: 0; box-shadow: none; }
  .page, .content { padding: 0; max-width: none; }
  .tbl th { position: static; background: #fff; }
  a[href]::after { content: ''; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: .01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: .01ms !important;
  }
  .pipe-bar i { width: var(--w, 0%); }
}


/* =====================================================================
   SAYFAYA ÖZEL BÖLÜMLER
   Atölye, montaj planlama, saha arayüzü, satın alma gibi tek bir
   ekrana ait kurallar. Hepsi yukarıdaki tema değişkenlerini kullanır,
   bu yüzden yeni tasarıma ve koyu temaya kendiliğinden uyar.
   ===================================================================== */

/* =====================================================================
   19. ATÖLYE — iş emri okutma ve kumaş topu seçimi
   Atölyede fare yok, eller meşgul, ekran tozlu: dokunma alanları büyük,
   kontrast yüksek, bilgi tek bakışta okunur.
   ===================================================================== */

/* --- Kumaş topu seçenekleri --- */
.roll-opt {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 2px var(--s3);
  width: 100%;
  padding: 11px var(--s3);
  text-align: left;
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: var(--r-md);
  cursor: pointer;
  transition: border-color .14s, background-color .14s, box-shadow .14s;
}
.roll-opt:hover { border-color: var(--brand-line); background: var(--brand-soft); }
.roll-opt + .roll-opt { margin-top: var(--s2); }

/* Odada zaten kullanılan parti: renk tonu tutsun diye öne çıkar */
.roll-opt.is-match { border-color: var(--ok-line); background: var(--ok-soft); }
.roll-opt.is-match:hover { border-color: var(--ok); }

.roll-no  { font-weight: 700; font-size: 14px; color: var(--ink); }
.roll-lot { grid-column: 1; color: var(--slate-2); font-size: 11.5px; }
.roll-qty {
  grid-row: 1 / span 2; grid-column: 2;
  align-self: center;
  font-variant-numeric: tabular-nums;
  font-weight: 700; font-size: 14px; color: var(--slate);
}
.roll-flag {
  grid-column: 1 / -1;
  margin-top: 3px;
  font-size: 10.5px; font-weight: 700; letter-spacing: .02em;
  color: var(--ok); text-transform: uppercase;
}

/* --- Okutulan iş emri künyesi --- */
.scan-card {
  margin-top: var(--s3);
  padding: var(--s4);
  background: var(--page);
  border: 1px solid var(--line);
  border-radius: var(--r-lg);
}
.scan-hd {
  display: flex; align-items: center; justify-content: space-between;
  gap: var(--s2);
  padding-bottom: var(--s3);
  margin-bottom: var(--s3);
  border-bottom: 1px solid var(--line);
}
.scan-hd b { font-size: 15px; letter-spacing: -.01em; }
.scan-card .readout { margin-bottom: var(--s4); }
.scan-card .btn-lg { min-height: 52px; font-size: 15px; }

/* --- Kart üzerinde parti durumu --- */
.lot-ok   { color: var(--ok) !important; font-weight: 600; }
.lot-none { color: var(--warn) !important; font-weight: 600; }

/* Atölye panosunda kart düğmeleri yan yana ve geniş */
.kcard-ft .btn-sm { min-height: 34px; }
@media (max-width: 640px) {
  .kcard-ft .btn-sm { min-height: 44px; flex: 1; }
}

/* =====================================================================
   20. MONTAJ PLANLAMA — gün gün program
   ===================================================================== */

.day { padding: var(--s3) var(--s4); border-top: 1px solid var(--line-2); }
.day:first-child { border-top: 0; }
.day.is-today { background: var(--brand-soft); }

.day-hd {
  display: flex; align-items: baseline; gap: var(--s2);
  margin-bottom: 3px;
}
.day-hd b { font-size: 13.5px; letter-spacing: -.01em; }
.day-dow { color: var(--slate-2); font-size: 11.5px; }
.day-cnt { color: var(--slate-3); font-size: 11.5px; font-variant-numeric: tabular-nums; }
.day.is-today .day-hd b { color: var(--brand-ink); }

/* Görev satırı: sol saat, orta bilgi, sağ durum */
.task-row.is-click { cursor: pointer; border-radius: var(--r-sm); }
.task-row.is-click:hover { background: rgba(66, 38, 166, .05); }
.task-end {
  display: flex; flex-direction: column; align-items: flex-end; gap: 2px;
  flex-shrink: 0; text-align: right;
}

.empty-sm { padding: var(--s4); text-align: center; font-size: 12.5px; }

/* --- Özet kutucukları --- */
.stat {
  padding: var(--s3);
  background: var(--page);
  border: 1px solid var(--line);
  border-radius: var(--r-md);
}
.stat-v {
  font-size: 19px; font-weight: 750; letter-spacing: -.02em;
  font-variant-numeric: tabular-nums; line-height: 1.15;
}
.stat-l { color: var(--slate-2); font-size: 11.5px; font-weight: 600; margin-top: 2px; }
.stat.is-ok  .stat-v { color: var(--ok); }
.stat.is-err .stat-v { color: var(--err); }

/* =====================================================================
   21. OTOMATİK TAMAMLAMA (müşteri/ürün arama açılır listesi)
   NOT: .suggest sınıfı BAŞKA bir şey için kullanılıyor (teklif ekranındaki
   yeşil tasarruf önerisi). Karıştırmayın; bu liste .ac sınıfını kullanır.
   ===================================================================== */
.ac {
  position: absolute; z-index: 30;
  left: 0; right: 0;
  margin-top: 3px;
  max-height: 260px; overflow-y: auto;
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: var(--r-md);
  box-shadow: var(--sh-3);
}
.field { position: relative; }
.ac-item {
  display: block; width: 100%;
  padding: 8px 11px;
  text-align: left;
  border-bottom: 1px solid var(--line-2);
  cursor: pointer;
  transition: background-color .12s;
}
.ac-item:last-child { border-bottom: 0; }
.ac-item:hover { background: var(--brand-soft); }
.ac-item b { display: block; font-size: 13px; font-weight: 600; color: var(--ink); }
.ac-item span { display: block; color: var(--slate-2); font-size: 11.5px; margin-top: 1px; }
.ac-empty { padding: 11px; color: var(--slate-2); font-size: 12.5px; text-align: center; }

/* =====================================================================
   22. SAHA ARAYÜZÜ — montajcının telefonu
   Başparmak bölgesi, büyük dokunma hedefleri, tek elle kullanım.
   ===================================================================== */

.field-ttl { flex: 1; min-width: 0; }
.field-ttl h1 { font-size: 15px; font-weight: 700; letter-spacing: -.01em; }
.field-ttl p  { color: var(--slate-2); font-size: 11.5px; margin-top: 1px; }

.field-main { padding: var(--s4); padding-bottom: 96px; }

/* Gün sekmeleri */
.field-tabs {
  display: flex; gap: var(--s2);
  margin-bottom: var(--s4);
  padding: 3px;
  background: #eef1f7;
  border-radius: var(--r-md);
}
.field-tabs button {
  flex: 1; min-height: 40px;
  border-radius: 8px;
  font-size: 13px; font-weight: 650; color: var(--slate);
  transition: background-color .14s, color .14s, box-shadow .14s;
}
.field-tabs button.is-active { background: #fff; color: var(--ink); box-shadow: var(--sh-1); }

/* Görev kartı — tüm kart tıklanabilir, 44px'ten büyük */
.task-card {
  display: block; width: 100%;
  padding: var(--s4);
  text-align: left;
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: var(--r-lg);
  box-shadow: var(--sh-1);
  transition: border-color .14s, box-shadow .14s, transform .12s var(--ease);
}
.task-card:active { transform: scale(.995); }
.task-card.is-done { opacity: .62; }
.task-card-top {
  display: flex; align-items: center; justify-content: space-between;
  gap: var(--s2); margin-bottom: 6px;
}
.task-card b { display: block; font-size: 15px; letter-spacing: -.01em; }
.task-card-ft {
  display: flex; justify-content: space-between; gap: var(--s2);
  margin-top: 9px; padding-top: 9px;
  border-top: 1px solid var(--line-2);
  font-size: 12px; font-weight: 600;
}

/* Kontrol listesi satırı — tüm satır dokunulabilir */
.chk-row {
  width: 100%; min-height: 44px;
  padding: 8px 11px;
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: var(--r-md);
  font-size: 13.5px;
}
.chk-row input:checked + span { color: var(--slate-3); text-decoration: line-through; }

/* Pencere kartı — ne takılacak */
.win-card {
  padding: var(--s3) var(--s4);
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: var(--r-md);
}
.win-hd {
  display: flex; align-items: center; justify-content: space-between;
  gap: var(--s2); margin-bottom: 5px;
}
.win-hd b { font-size: 13.5px; }
.win-note {
  padding: 6px 9px; margin-bottom: 6px;
  background: var(--warn-soft);
  border: 1px solid var(--warn-line);
  border-radius: var(--r-sm);
  color: #7a4d08; font-size: 12px; font-weight: 600;
}
.win-item {
  display: flex; justify-content: space-between; gap: var(--s3);
  padding: 4px 0; font-size: 12.5px;
  border-top: 1px solid var(--line-2);
}

/* Fotoğraflar */
.photo-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: var(--s2); margin-top: var(--s2); }
.photo-item { position: relative; aspect-ratio: 1; border-radius: var(--r-md); overflow: hidden; border: 1px solid var(--line); }
.photo-item img { width: 100%; height: 100%; object-fit: cover; display: block; }
.photo-x {
  position: absolute; top: 4px; right: 4px;
  width: 26px; height: 26px; border-radius: 50%;
  background: rgba(17, 26, 46, .72); color: #fff;
  font-size: 17px; line-height: 1;
}

/* İmza alanı */
.sig-pad {
  width: 100%; height: 170px;
  background: #fff;
  border: 2px dashed var(--line);
  border-radius: var(--r-md);
  touch-action: none;          /* parmakla çizerken sayfa kaymasın */
  cursor: crosshair;
}

.spacer-bottom { height: 24px; }
.g2 { gap: var(--s2); }
.mt3 { margin-top: var(--s3); }

/* Alt aksiyon çubuğundaki birincil düğme devre dışıyken */
.field-actions .btn-lg { min-height: 52px; font-size: 15px; }
.field-actions .btn.is-done { background: var(--ok); border-color: var(--ok); }

/* --- Saha: üst çubuk yatay hizalanır ---------------------------------
   .field-top yalnızca install_mobile.html tarafından kullanılır.
   Geri düğmesi, başlık ve eşitleme düğmesi aynı satırda durmalı. */
.field-top {
  display: flex;
  align-items: center;
  gap: var(--s3);
}
.field-top .btn-icon { color: #fff; flex-shrink: 0; position: relative; }
.field-top .btn-icon:hover { background: rgba(255, 255, 255, .12); }

/* --- Saha: müşteri künyesi ------------------------------------------
   DİKKAT: .task-hd kullanmayın — o sınıf display:flex'tir ve burada
   isim/adres bloklarını dar sütunlara sıkıştırır (bir kez oldu). */
.cust-hd {
  padding: var(--s4);
  margin-bottom: var(--s4);
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: var(--r-lg);
}
.cust-hd h2 { font-size: 18px; font-weight: 750; letter-spacing: -.02em; }
.cust-hd p { margin-top: 3px; font-size: 13px; line-height: 1.45; }
.cust-hd .warn-t { font-weight: 600; }
.cust-hd .btn { min-height: 46px; }

/* =====================================================================
   23. SATIN ALMA — eksik malzeme önerisi ve mal kabul
   ===================================================================== */

.sg-group { padding: var(--s3) var(--s4); border-top: 1px solid var(--line-2); }
.sg-group:first-child { border-top: 0; }
.sg-hd {
  display: flex; align-items: center; gap: var(--s2);
  margin-bottom: var(--s2);
  flex-wrap: wrap;
}
.sg-hd b { font-size: 13.5px; }
.sg-hd .muted { font-size: 11.5px; }

.sg-row {
  display: flex; align-items: center; gap: var(--s3);
  padding: 6px 0;
  border-top: 1px solid var(--line-2);
}
.sg-nums { display: flex; flex-direction: column; align-items: flex-end; gap: 1px; flex-shrink: 0; }
.sg-nums span { font-size: 11px; }
.sg-nums b { font-size: 12.5px; font-variant-numeric: tabular-nums; }

/* Sipariş kalem satırı: ürün / miktar / fiyat / toplam / sil */
.po-line {
  display: grid;
  grid-template-columns: minmax(0,1fr) 92px 104px 104px 32px;
  gap: var(--s2);
  align-items: center;
}
.po-line + .po-line { margin-top: var(--s2); }
.ln-total { font-weight: 650; font-variant-numeric: tabular-nums; font-size: 13px; }
@media (max-width: 640px) {
  .po-line { grid-template-columns: minmax(0,1fr) 1fr; }
  .po-line .ln-total { grid-column: 1 / -1; text-align: right; }
}

/* Mal kabul satırı */
.rc-line {
  padding: var(--s3);
  background: var(--page);
  border: 1px solid var(--line);
  border-radius: var(--r-md);
}
.rc-line + .rc-line { margin-top: var(--s2); }

/* =====================================================================
   24. RAPOR GRAFİĞİ — saf SVG, kütüphane yok
   ===================================================================== */
.chart-svg { width: 100%; height: 190px; display: block; }

/* =====================================================================
   v3 SONRASI DÜZELTMELER
   ---------------------------------------------------------------------
   Tasarım v3'e geri döndürüldü. Aradaki sürümde ÇÖZÜLEN gerçek hatalar
   ve o sürümde eklenen yeni ekranların ihtiyaç duyduğu stiller burada
   toplandı; v3'ün görünümü değişmiyor, yalnızca bozukluklar gideriliyor.
   Yeni kural eklerken bu bölümün SONUNA ekleyin.
   ===================================================================== */

/* ---------------------------------------------------------------------
   1. TABLO SÜTUNU GİZLEME — gerçek bir hata düzeltmesi
   .hide-sm / .hide-md / .hide-lg hem TABLO HÜCRELERİNDE (td/th) hem de
   düğme içindeki METİNLERDE (span) kullanılıyor. Tek bir display değeri
   ikisine birden uymuyordu: .hide-sm'e "inline" verilince tablo hücresi
   satırdan kopuyor ve satırın dışında kayan beyaz bir kutu gibi
   görünüyordu (telefon sütunlarında belirgindi).
   --------------------------------------------------------------------- */
.hide-sm, .hide-md, .hide-lg { display: none; }
@media (min-width: 640px) {
  .hide-sm { display: inline; }
  td.hide-sm, th.hide-sm { display: table-cell; }
  div.hide-sm, section.hide-sm, p.hide-sm { display: block; }
}
@media (min-width: 900px) {
  .hide-md { display: inline; }
  td.hide-md, th.hide-md { display: table-cell; }
  div.hide-md, section.hide-md, p.hide-md { display: block; }
}
@media (min-width: 1200px) {
  .hide-lg { display: inline; }
  td.hide-lg, th.hide-lg { display: table-cell; }
  div.hide-lg, section.hide-lg, p.hide-lg { display: block; }
}

/* ---------------------------------------------------------------------
   2. SATIR SONUNDAKİ İŞLEM DÜĞMELERİ
   Hücre dar olduğu için ikonlar alt alta düşüyor ve satır yüksekliği
   katlanıyordu. Gerekirse hücre genişler, düğmeler yan yana kalır.
   --------------------------------------------------------------------- */
.tbl td > .row, table td > .row { flex-wrap: nowrap; }
.tbl td > .row.wrap, table td > .row.wrap { flex-wrap: wrap; }

/* ---------------------------------------------------------------------
   3. "DİĞER İŞLEMLER" (…) DÜĞMESİ — daha belirgin
   Üç nokta düz bir ikon olduğu için tıklanabilir olduğu anlaşılmıyordu.
   Artık kendi çerçeveli kutusunda duruyor, üstüne gelince marka rengine
   dönüyor. Dokunma hedefi 40px.
   --------------------------------------------------------------------- */
.btn-icon[data-more], .btn-icon.btn-more, .tbtn[data-more] {
  width: 40px; height: 40px;
  border: 1px solid var(--line-strong);
  border-radius: var(--radius-sm);
  background: var(--surface);
  color: var(--text);
  box-shadow: var(--shadow-sm);
  transition: background-color .15s, border-color .15s, color .15s, transform .12s;
}
.btn-icon[data-more] svg, .btn-icon.btn-more svg, .tbtn[data-more] svg {
  width: 20px; height: 20px;
  stroke-width: 3;              /* üç nokta daha koyu görünsün */
}
.btn-icon[data-more]:hover, .btn-icon.btn-more:hover, .tbtn[data-more]:hover,
.btn-icon[data-more]:focus-visible, .btn-icon.btn-more:focus-visible {
  background: var(--brand-50);
  border-color: var(--brand);
  color: var(--brand);
  outline: 0;
}
.btn-icon[data-more]:active, .btn-icon.btn-more:active { transform: scale(.94); }
/* Satır seçiliyken de görünür kalsın */
tr:hover .btn-icon[data-more], tr:hover .btn-icon.btn-more {
  border-color: var(--brand-line);
}

/* ---------------------------------------------------------------------
   4. İKON VE BİRİM PAYI  (gerçek hata düzeltmesi)
   Arama büyüteci yazının üstüne, birim rozeti (₺ / cm / % / m) sayının
   üstüne biniyordu.
   Sebep: .field içindeki alanları biçimleyen taban kural
   ".field input" (0,2,1) özgüllüğünde; ".search .inp" ise (0,2,0).
   Taban kural daha baskın olduğu için ikon payı eziliyordu.
   Çözüm iki seviyeli yazılır:
     • .field DIŞINDA  → .search .inp          (0,2,0)
     • .field İÇİNDE   → .field .search .inp   (0,3,0) > (0,2,1)
   Yeni bir ikonlu alan türü eklerken İKİSİNİ BİRDEN yazın.
   --------------------------------------------------------------------- */
.search .inp, .search input, .search textarea,
.input-icon .inp, .input-icon input,
.field .search .inp, .field .search input, .field .search textarea,
.field .input-icon .inp, .field .input-icon input {
  padding-left: 46px;
}
/* Küçük boy alanlarda ikon da küçülür, pay ona göre */
.search .inp-sm, .field .search .inp-sm { padding-left: 40px; }

/* Birim rozeti (sağda duran ₺ / cm / % / m / ay) */
.with-unit .inp, .with-unit input, .with-unit .sel,
.field .with-unit .inp, .field .with-unit input, .field .with-unit .sel {
  padding-right: 48px;
}
.with-unit .inp-sm, .field .with-unit .inp-sm { padding-right: 42px; }
/* Birimi uzun olanlar (ay, m2, adet) için daha geniş pay */
.with-unit.wide .inp, .field .with-unit.wide .inp { padding-right: 62px; }

/* Parola göster/gizle düğmesi */
.pwd-wrap .inp, .field .pwd-wrap .inp, .field .pwd-wrap input { padding-right: 56px; }

.search { min-width: 184px; }
@media (max-width: 640px) {
  .toolbar .search, .row > .search, .row > .search.grow,
  .row.wrap > .search.grow { flex: 1 1 100%; min-width: 100%; }
  .grid > .search { grid-column: 1 / -1; }
}

/* ---------------------------------------------------------------------
   5. SATIN ALMA KALEM SATIRI
   Eskiden iki çıplak kutu yan yanaydı; hangisinin miktar hangisinin
   fiyat olduğu belli değildi ve miktar girmek zordu. Başlık satırı,
   ± düğmeli miktar kutusu ve birim eklendi.
   --------------------------------------------------------------------- */
.po-head, .po-line {
  display: grid; gap: var(--s2); align-items: center;
  grid-template-columns: minmax(0,1fr) 148px 54px 132px 112px 40px;
}
.po-head {
  padding: 0 var(--s2) 6px;
  font-size: 11px; font-weight: 700; letter-spacing: .05em;
  text-transform: uppercase; color: var(--muted);
  white-space: nowrap;
}
.po-line { padding: var(--s2); border-radius: var(--radius-sm); }
.po-line + .po-line { margin-top: 4px; }
.po-line:hover { background: var(--surface-2); }
.ln-unit { color: var(--muted); font-size: 12.5px; font-weight: 650; }

.qty-box {
  display: grid; grid-template-columns: 38px minmax(0,1fr) 38px;
  align-items: center;
  background: var(--surface-3); border: 1.5px solid transparent;
  border-radius: var(--radius-sm); overflow: hidden;
}
.qty-box:focus-within {
  background: var(--surface); border-color: var(--brand);
  box-shadow: 0 0 0 4px var(--brand-50);
}
.qty-btn {
  height: 44px; display: grid; place-items: center;
  color: var(--text-2); font-size: 19px; font-weight: 700; line-height: 1;
  transition: background-color .15s, color .15s;
}
.qty-btn:hover { background: var(--brand-50); color: var(--brand); }
.qty-box .inp {
  min-height: 44px; padding: 0 2px; text-align: center;
  background: none; border: 0; box-shadow: none;
  font-weight: 700; font-variant-numeric: tabular-nums;
}
.qty-box .inp:focus { background: none; box-shadow: none; }
/* Tarayıcının kendi ok düğmeleri ± düğmeleriyle çakışıyordu */
.qty-box .inp::-webkit-outer-spin-button,
.qty-box .inp::-webkit-inner-spin-button { -webkit-appearance: none; margin: 0; }
.qty-box .inp[type=number] { -moz-appearance: textfield; }

@media (max-width: 760px) {
  .po-head { display: none; }
  .po-line {
    grid-template-columns: repeat(2, minmax(0,1fr));
    padding: var(--s3); background: var(--surface-3); margin-top: var(--s2);
  }
  .po-line > .ln-prod { grid-column: 1 / -1; }
  .po-line > .ln-unit { display: none; }
  .po-line > .ln-total { grid-column: 1; text-align: left; font-size: 16px; }
  .po-line > .ln-del { justify-self: end; }
  .po-line [data-th]::before {
    content: attr(data-th); display: block;
    font-size: 10.5px; font-weight: 700; letter-spacing: .05em;
    text-transform: uppercase; color: var(--muted); margin-bottom: 4px;
  }
}
