/* ==========================================================================
   Lojistik Panel - stil dosyasi
   Koyu degrade menu, cam efektli ust cubuk, renkli KPI kartlari, SVG grafikler.
   Acik ve koyu tema ayni degiskenlerle calisir.
   ========================================================================== */

:root {
  --font: "Inter", "Segoe UI", system-ui, -apple-system, Roboto, Arial, sans-serif;
  --font-head: "Plus Jakarta Sans", "Inter", "Segoe UI", system-ui, sans-serif;

  --bg: #f3f5fb;
  --surface: #ffffff;
  --surface-2: #f7f8fc;
  --surface-3: #eef1f8;
  --border: #e5e9f2;
  --border-strong: #d3d9e6;
  --text: #0f172a;
  --text-2: #475569;
  --muted: #8490a6;

  --accent: #3b5bfd;
  --accent-2: #7c4dff;
  --accent-soft: #eef1ff;
  --accent-ink: #2f47d6;
  --grad: linear-gradient(135deg, #3b5bfd 0%, #6a4dff 60%, #9b5cff 100%);

  --ok: #059669;
  --ok-soft: #e6f7f0;
  --warn: #d97706;
  --warn-ink: #b45309;
  --warn-soft: #fff5e3;
  --danger: #e11d48;
  --danger-soft: #feecef;
  --info: #0284c7;
  --info-soft: #e6f5fd;
  --violet: #7c3aed;
  --violet-soft: #f1ebff;

  --shadow-xs: 0 1px 2px rgba(15, 23, 42, .05);
  --shadow: 0 1px 2px rgba(15, 23, 42, .04), 0 4px 16px -4px rgba(15, 23, 42, .07);
  --shadow-md: 0 2px 4px rgba(15, 23, 42, .04), 0 12px 32px -8px rgba(15, 23, 42, .14);
  --shadow-lg: 0 24px 60px -12px rgba(15, 23, 42, .28);

  --radius: 16px;
  --radius-sm: 10px;
  --side-w: 268px;
  --side-mini: 84px;
  --top-h: 70px;

  --side-bg: linear-gradient(180deg, #0b1230 0%, #0e1840 45%, #121b4a 100%);
  --g-track: #e8ecf5;
  color-scheme: light;
}

:root[data-theme="dark"] {
  --bg: #080d1c;
  --surface: #0f1629;
  --surface-2: #131c33;
  --surface-3: #1a2440;
  --border: #1f2a47;
  --border-strong: #2c3a5e;
  --text: #e8edf7;
  --text-2: #aab5cc;
  --muted: #7885a3;

  --accent: #6b86ff;
  --accent-2: #a283ff;
  --accent-soft: #19234a;
  --accent-ink: #9eb0ff;

  --ok: #34d399;
  --ok-soft: #0f2c24;
  --warn: #fbbf24;
  --warn-ink: #fbbf24;
  --warn-soft: #2e2410;
  --danger: #fb7185;
  --danger-soft: #34151f;
  --info: #38bdf8;
  --info-soft: #0d2536;
  --violet: #a78bfa;
  --violet-soft: #221a44;

  --shadow-xs: 0 1px 2px rgba(0, 0, 0, .3);
  --shadow: 0 1px 2px rgba(0, 0, 0, .3), 0 6px 18px -6px rgba(0, 0, 0, .45);
  --shadow-md: 0 12px 32px -8px rgba(0, 0, 0, .6);
  --shadow-lg: 0 28px 70px -12px rgba(0, 0, 0, .75);

  --side-bg: linear-gradient(180deg, #070b1d 0%, #0a1130 50%, #0d1438 100%);
  --g-track: #1c2645;
  color-scheme: dark;
}

/* Renk anahtarlari: ikon kutulari, KPI kartlari, bilgi kutulari */
.c-blue { --c: #3b5bfd; --c2: #7a8cff; }
.c-violet { --c: #8b5cf6; --c2: #c084fc; }
.c-cyan { --c: #0891b2; --c2: #22d3ee; }
.c-green { --c: #059669; --c2: #34d399; }
.c-amber { --c: #f59e0b; --c2: #fbbf24; }
.c-rose { --c: #e11d48; --c2: #fb7185; }
.c-teal { --c: #0d9488; --c2: #2dd4bf; }
.c-orange { --c: #ea580c; --c2: #fb923c; }

* { box-sizing: border-box; }
html, body { height: 100%; }

body {
  margin: 0;
  background:
    radial-gradient(1100px 520px at 100% -8%, rgba(99, 102, 241, .10), transparent 60%),
    radial-gradient(900px 480px at 10% -10%, rgba(14, 165, 233, .08), transparent 60%),
    var(--bg);
  background-attachment: fixed;
  color: var(--text);
  font: 14px/1.5 var(--font);
  font-feature-settings: "cv11", "ss01";
  -webkit-font-smoothing: antialiased;
}

a { color: var(--accent); text-decoration: none; }
h1, h2, h3, h4 { margin: 0; font-family: var(--font-head); font-weight: 700; letter-spacing: -.02em; }
kbd {
  font: 600 10.5px/1 var(--font);
  padding: 3px 6px; border-radius: 6px;
  background: var(--surface-3); border: 1px solid var(--border); color: var(--muted);
}
hr { border: 0; border-top: 1px solid var(--border); margin: 6px 0; }
::selection { background: rgba(59, 91, 253, .22); }

.muted { color: var(--muted); }
.small { font-size: 12.5px; }
.xs { font-size: 11.5px; }
.right { text-align: right; }
.center { text-align: center; }
.nowrap { white-space: nowrap; }
.mono { font-variant-numeric: tabular-nums; white-space: nowrap; }
table.table td .t-sub { white-space: nowrap; }
.row { display: flex; align-items: center; gap: 8px; }
.row-between { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.wrap { flex-wrap: wrap; }
.grow { flex: 1; min-width: 0; }
.mt { margin-top: 18px; }
.mb { margin-bottom: 18px; }
.hidden { display: none !important; }
.truncate { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.clickable { cursor: pointer; }
.ic { flex: none; }

/* Izgaralar */
.grid { display: grid; grid-template-columns: repeat(var(--cols, 2), minmax(0, 1fr)); gap: 18px; }
.g-main { display: grid; grid-template-columns: minmax(0, 1.7fr) minmax(0, 1fr); gap: 18px; }
.g-side { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.7fr); gap: 18px; }
.stack { display: grid; gap: 18px; align-content: start; }

/* ================================================================ Giris */
.login { min-height: 100vh; display: grid; grid-template-columns: 1.1fr .9fr; }

.login-hero {
  position: relative;
  overflow: hidden;
  color: #e6ecff;
  padding: 44px 56px;
  display: flex; flex-direction: column; justify-content: space-between; gap: 28px;
  background:
    radial-gradient(700px 400px at 90% 10%, rgba(139, 92, 246, .45), transparent 60%),
    radial-gradient(600px 420px at 0% 100%, rgba(6, 182, 212, .35), transparent 60%),
    linear-gradient(145deg, #0a1030 0%, #111a4d 55%, #1a1560 100%);
}

.hero-bg { position: absolute; inset: 0; opacity: .55; pointer-events: none; }
.hero-bg svg { width: 100%; height: 100%; }
.rota { fill: none; stroke-width: 3; stroke-dasharray: 10 12; stroke-linecap: round; animation: rota 22s linear infinite; }
.rota.r2 { stroke-width: 2; opacity: .6; animation-duration: 30s; }
@keyframes rota { to { stroke-dashoffset: -440; } }

.hero-in { position: relative; max-width: 560px; }
.brand-lg { display: flex; align-items: center; gap: 12px; margin-bottom: 46px; }
.brand-lg b { font: 800 18px/1.1 var(--font-head); letter-spacing: -.01em; display: block; }
.brand-lg span { font-size: 12px; color: #a5b4fc; }
.login-hero h1 { font-size: 38px; line-height: 1.16; letter-spacing: -.035em; margin-bottom: 16px; font-weight: 800; }
.login-hero h1 em { font-style: normal; background: linear-gradient(90deg, #67e8f9, #a5b4fc 50%, #f0abfc); -webkit-background-clip: text; background-clip: text; color: transparent; }
.login-hero > .hero-in > p { color: #b4c0e8; font-size: 15px; margin: 0 0 30px; max-width: 480px; }

.flow { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.flow li {
  display: flex; gap: 12px; align-items: center;
  padding: 12px 14px;
  border-radius: 14px;
  background: rgba(255, 255, 255, .06);
  border: 1px solid rgba(255, 255, 255, .10);
  backdrop-filter: blur(6px);
  animation: rise .5s both calc(var(--i) * 70ms + 120ms);
}
.flow li > span { width: 36px; height: 36px; border-radius: 11px; display: grid; place-items: center; flex: none; color: #fff; background: linear-gradient(135deg, rgba(99, 102, 241, .9), rgba(6, 182, 212, .75)); box-shadow: 0 6px 16px -6px rgba(99, 102, 241, .8); }
.flow b { display: block; font-size: 13.5px; font-weight: 600; }
.flow small { color: #a3b1da; font-size: 12px; }
.hero-foot { position: relative; display: flex; gap: 20px; flex-wrap: wrap; color: #a3b1da; font-size: 12.5px; }
.hero-foot span { display: inline-flex; align-items: center; gap: 7px; }

.login-side { display: grid; place-items: center; padding: 36px 26px; background: var(--bg); }
.login-card { width: 100%; max-width: 440px; }
.brand-sm { display: none; align-items: center; gap: 10px; margin-bottom: 26px; font: 800 17px var(--font-head); }
.login-card h2 { font-size: 26px; letter-spacing: -.03em; margin-bottom: 6px; }
.login-card > p { margin: 0 0 26px; }
.login-card .field { margin-bottom: 16px; }
.login-card .input { height: 48px; border-radius: 12px; font-size: 14.5px; }
.login-card .err { min-height: 20px; margin: -4px 0 10px; font-size: 12.5px; }

.input-ic { position: relative; }
.input-ic > .ic { position: absolute; left: 14px; top: 50%; transform: translateY(-50%); color: var(--muted); pointer-events: none; }
.input-ic .input { padding-left: 42px; }
.eye { position: absolute; right: 8px; top: 50%; transform: translateY(-50%); border: 0; background: none; color: var(--muted); width: 34px; height: 34px; border-radius: 8px; cursor: pointer; display: grid; place-items: center; }
.eye:hover { background: var(--surface-3); color: var(--text); }

.demo { margin-top: 28px; }
.demo-h { display: flex; align-items: baseline; justify-content: space-between; margin-bottom: 10px; }
.demo-h span { font-weight: 700; font-size: 13px; }
.demo-h small { color: var(--muted); font-size: 11.5px; }
.demo-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.demo-btn {
  display: flex; align-items: center; gap: 10px; text-align: left;
  padding: 9px 10px; border-radius: 12px; cursor: pointer; font: inherit; color: var(--text);
  background: var(--surface); border: 1px solid var(--border);
  box-shadow: var(--shadow-xs);
  transition: border-color .15s, transform .15s, box-shadow .15s;
}
.demo-btn:hover { border-color: var(--accent); transform: translateY(-1px); box-shadow: var(--shadow); }
.demo-btn b { display: block; font-size: 12.5px; font-weight: 600; }
.demo-btn small { color: var(--muted); font-size: 11px; }

/* ============================================================== Yerlesim */
.shell { display: flex; min-height: 100vh; }

.side {
  width: var(--side-w);
  flex: none;
  position: sticky; top: 0;
  height: 100vh;
  display: flex; flex-direction: column;
  background: var(--side-bg);
  color: #c9d3f5;
  z-index: 60;
  overflow: hidden;
  transition: width .22s ease;
  box-shadow: 1px 0 0 rgba(255, 255, 255, .04), 8px 0 30px -18px rgba(8, 12, 40, .6);
}
.side-glow {
  position: absolute; pointer-events: none;
  width: 320px; height: 320px; left: -120px; top: -140px;
  background: radial-gradient(circle, rgba(99, 102, 241, .45), transparent 65%);
  filter: blur(8px);
}
.side::after {
  content: ""; position: absolute; pointer-events: none;
  width: 260px; height: 260px; right: -150px; bottom: 60px;
  background: radial-gradient(circle, rgba(6, 182, 212, .22), transparent 65%);
}

.brand { position: relative; height: var(--top-h); display: flex; align-items: center; gap: 12px; padding: 0 20px; flex: none; }
.brand-mark {
  width: 40px; height: 40px; border-radius: 12px; flex: none;
  display: grid; place-items: center; color: #fff;
  background: var(--grad);
  box-shadow: 0 8px 20px -6px rgba(99, 102, 241, .75), inset 0 1px 0 rgba(255, 255, 255, .25);
}
.brand-mark.lg { width: 48px; height: 48px; border-radius: 14px; }
.brand-t { min-width: 0; }
.brand-t b { display: block; font: 800 17px/1.1 var(--font-head); color: #fff; letter-spacing: -.02em; }
.brand-t b em { font-style: normal; background: linear-gradient(90deg, #7dd3fc, #c4b5fd); -webkit-background-clip: text; background-clip: text; color: transparent; margin-left: 5px; }
.brand-t small { display: block; font-size: 11.5px; color: #8793c4; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; margin-top: 2px; }

.nav { position: relative; flex: 1; overflow-y: auto; padding: 6px 14px 12px; scrollbar-width: thin; scrollbar-color: rgba(255, 255, 255, .12) transparent; }
.nav-sec { padding: 14px 10px 5px; font-size: 10.5px; font-weight: 700; letter-spacing: .14em; text-transform: uppercase; color: #6974a4; white-space: nowrap; }
.nav-sec:first-child { padding-top: 6px; }

.nav a {
  position: relative;
  display: flex; align-items: center; gap: 12px;
  height: 40px; padding: 0 10px;
  border-radius: 12px;
  color: #b3bee6;
  font-size: 13.8px; font-weight: 500;
  margin-bottom: 2px;
  white-space: nowrap;
  transition: background .15s, color .15s;
}
.nav-ic { width: 32px; height: 32px; border-radius: 10px; display: grid; place-items: center; flex: none; color: #8f9bd0; transition: background .15s, color .15s, box-shadow .15s; }
.nav a:hover { background: rgba(255, 255, 255, .06); color: #fff; }
.nav a:hover .nav-ic { color: #dbe3ff; }
.nav a.on { color: #fff; font-weight: 600; background: linear-gradient(90deg, rgba(99, 118, 255, .30), rgba(99, 118, 255, .06)); box-shadow: inset 0 0 0 1px rgba(129, 140, 248, .18); }
.nav a.on::before { content: ""; position: absolute; left: -14px; top: 9px; bottom: 9px; width: 4px; border-radius: 0 4px 4px 0; background: linear-gradient(180deg, #67e8f9, #818cf8); box-shadow: 0 0 12px rgba(129, 140, 248, .9); }
.nav a.on .nav-ic { color: #fff; background: var(--grad); box-shadow: 0 6px 16px -4px rgba(99, 102, 241, .8); }
.nav-t { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; }

.nav-badge { margin-left: auto; min-width: 22px; height: 20px; padding: 0 7px; border-radius: 10px; font-size: 11px; font-weight: 700; display: inline-grid; place-items: center; color: #fff; background: rgba(255, 255, 255, .14); }
.nav-badge.ok { background: linear-gradient(135deg, #059669, #34d399); }
.nav-badge.info { background: linear-gradient(135deg, #0284c7, #38bdf8); }
.nav-badge.warn { background: linear-gradient(135deg, #d97706, #fbbf24); color: #1f1300; }
.nav-badge.violet { background: linear-gradient(135deg, #7c3aed, #a78bfa); }

.live-dot { width: 8px; height: 8px; border-radius: 50%; background: #34d399; margin-left: auto; box-shadow: 0 0 0 0 rgba(52, 211, 153, .7); animation: pulse 2s infinite; }
@keyframes pulse { 70% { box-shadow: 0 0 0 8px rgba(52, 211, 153, 0); } 100% { box-shadow: 0 0 0 0 rgba(52, 211, 153, 0); } }

.side-widget { position: relative; margin: 14px 0 4px; padding: 14px; border-radius: 14px; background: rgba(255, 255, 255, .05); border: 1px solid rgba(255, 255, 255, .08); }
.side-widget:empty { display: none; }
.fw-head { display: flex; justify-content: space-between; align-items: baseline; font-size: 12px; color: #9aa6d6; margin-bottom: 8px; }
.fw-head b { font: 800 18px var(--font-head); color: #fff; }
.fw-bar { height: 8px; border-radius: 6px; background: rgba(255, 255, 255, .1); overflow: hidden; }
.fw-bar span { display: block; height: 100%; border-radius: 6px; background: linear-gradient(90deg, #22d3ee, #6366f1, #a855f7); box-shadow: 0 0 12px rgba(99, 102, 241, .8); transition: width .8s ease; }
.fw-stats { display: flex; flex-wrap: wrap; gap: 4px 12px; margin-top: 10px; font-size: 11.5px; color: #aab4de; }
.fw-stats i { display: inline-block; width: 7px; height: 7px; border-radius: 50%; margin-right: 5px; }
.d-ok { background: #34d399; } .d-info { background: #38bdf8; } .d-violet { background: #a78bfa; } .d-warn { background: #fbbf24; }

.side-user { position: relative; display: flex; align-items: center; gap: 11px; padding: 14px 18px; border-top: 1px solid rgba(255, 255, 255, .07); background: rgba(0, 0, 0, .15); }
.su-t { flex: 1; min-width: 0; }
.su-t b { display: block; font-size: 13px; color: #fff; font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.su-t small { color: #8b97c9; font-size: 11.5px; }
.su-out { width: 34px; height: 34px; border-radius: 10px; border: 0; cursor: pointer; display: grid; place-items: center; color: #aab4de; background: rgba(255, 255, 255, .06); transition: background .15s, color .15s; }
.su-out:hover { background: rgba(244, 63, 94, .25); color: #fff; }

/* Daraltilmis menu */
.shell.mini .side { width: var(--side-mini); }
.shell.mini .brand { padding: 0 22px; }
.shell.mini .brand-t, .shell.mini .nav-t, .shell.mini .nav-sec span, .shell.mini .side-widget, .shell.mini .su-t, .shell.mini .su-out, .shell.mini .live-dot { display: none; }
.shell.mini .nav { padding: 6px 16px; }
.shell.mini .nav-sec { height: 18px; padding: 0; margin: 8px 6px; border-top: 1px solid rgba(255, 255, 255, .08); }
.shell.mini .nav a { padding: 0 8px; justify-content: center; }
.shell.mini .nav a.on::before { left: -16px; }
.shell.mini .nav-badge { position: absolute; top: 2px; right: 0; min-width: 16px; height: 16px; font-size: 9.5px; padding: 0 4px; }
.shell.mini .side-user { justify-content: center; padding: 14px 0; }

.side-backdrop { display: none; }

.main { flex: 1; min-width: 0; display: flex; flex-direction: column; }

.top {
  position: sticky; top: 0; z-index: 40;
  height: var(--top-h);
  display: flex; align-items: center; gap: 10px;
  padding: 0 26px 0 20px;
  background: color-mix(in srgb, var(--bg) 78%, transparent);
  backdrop-filter: saturate(160%) blur(14px);
  -webkit-backdrop-filter: saturate(160%) blur(14px);
  border-bottom: 1px solid color-mix(in srgb, var(--border) 70%, transparent);
}

.icon-btn {
  position: relative;
  width: 40px; height: 40px; flex: none;
  display: grid; place-items: center;
  border-radius: 12px; cursor: pointer;
  color: var(--text-2);
  background: var(--surface);
  border: 1px solid var(--border);
  box-shadow: var(--shadow-xs);
  transition: color .15s, border-color .15s, background .15s;
}
.icon-btn:hover { color: var(--accent); border-color: color-mix(in srgb, var(--accent) 35%, var(--border)); }

.crumbs { display: flex; align-items: center; gap: 6px; font-size: 13px; color: var(--muted); margin-left: 6px; white-space: nowrap; }
.crumbs b { color: var(--text); font-weight: 600; }

.searchbar {
  display: flex; align-items: center; gap: 10px;
  height: 40px; width: 330px; padding: 0 8px 0 14px;
  border-radius: 12px; cursor: pointer;
  color: var(--muted); font: inherit; font-size: 13px;
  background: var(--surface); border: 1px solid var(--border);
  box-shadow: var(--shadow-xs);
  transition: border-color .15s, box-shadow .15s;
}
.searchbar span { flex: 1; text-align: left; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.searchbar:hover { border-color: color-mix(in srgb, var(--accent) 40%, var(--border)); box-shadow: 0 0 0 4px color-mix(in srgb, var(--accent) 10%, transparent); }

.clock { display: flex; flex-direction: column; align-items: flex-end; line-height: 1.15; padding: 0 8px; }
.clock b { font: 700 15px var(--font-head); font-variant-numeric: tabular-nums; }
.clock span { font-size: 11px; color: var(--muted); white-space: nowrap; }

.dot-count { position: absolute; top: -5px; right: -5px; min-width: 19px; height: 19px; padding: 0 5px; border-radius: 10px; font-size: 10.5px; font-weight: 700; display: grid; place-items: center; color: #fff; background: linear-gradient(135deg, #e11d48, #fb7185); border: 2px solid var(--bg); }

.user-chip {
  display: flex; align-items: center; gap: 9px;
  height: 44px; padding: 0 10px 0 5px;
  border-radius: 14px; cursor: pointer; font: inherit; color: var(--text-2);
  background: var(--surface); border: 1px solid var(--border);
  box-shadow: var(--shadow-xs);
}
.user-chip:hover { border-color: color-mix(in srgb, var(--accent) 35%, var(--border)); }
.uc-t { text-align: left; line-height: 1.2; }
.uc-t b { display: block; font-size: 13px; color: var(--text); font-weight: 600; }
.uc-t small { font-size: 11px; color: var(--muted); }

.content { flex: 1; padding: 24px 26px 30px; width: 100%; max-width: 1640px; }
.content.page-in > * { animation: rise .42s cubic-bezier(.2, .7, .3, 1) both; }
.content.page-in > *:nth-child(2) { animation-delay: .05s; }
.content.page-in > *:nth-child(3) { animation-delay: .1s; }
.content.page-in > *:nth-child(4) { animation-delay: .15s; }
.content.page-in > *:nth-child(n+5) { animation-delay: .2s; }
@keyframes rise { from { opacity: 0; transform: translateY(10px); } }

.page-loading { display: grid; place-items: center; min-height: 50vh; }

.foot { display: flex; justify-content: space-between; gap: 12px; flex-wrap: wrap; padding: 14px 26px 22px; font-size: 12px; color: var(--muted); }

/* ======================================================== Sayfa basligi */
.phead {
  position: relative; overflow: hidden;
  display: flex; align-items: center; justify-content: space-between; gap: 16px; flex-wrap: wrap;
  margin-bottom: 16px; padding: 16px 20px;
  border-radius: 18px;
  background: linear-gradient(110deg, color-mix(in srgb, var(--c) 13%, var(--surface)) 0%, var(--surface) 58%);
  border: 1px solid color-mix(in srgb, var(--c) 20%, var(--border));
  box-shadow: var(--shadow-xs);
}
.phead::after { content: ""; position: absolute; right: -50px; top: -70px; width: 220px; height: 220px; border-radius: 50%; background: radial-gradient(circle, color-mix(in srgb, var(--c) 16%, transparent), transparent 68%); pointer-events: none; }
.phead > * { position: relative; z-index: 1; }
.phead-l { display: flex; align-items: center; gap: 15px; min-width: 0; }
.phead-ic {
  width: 48px; height: 48px; border-radius: 15px; flex: none;
  display: grid; place-items: center; color: #fff;
  background: linear-gradient(135deg, var(--c), var(--c2));
  box-shadow: 0 10px 22px -10px var(--c), inset 0 1px 0 rgba(255, 255, 255, .3);
}
.phead-crumb { font-size: 10.5px; font-weight: 700; text-transform: uppercase; letter-spacing: .12em; color: var(--c); margin-bottom: 1px; }
.phead h2 { font-size: 22px; letter-spacing: -.03em; line-height: 1.15; }
.phead p { margin: 3px 0 0; color: var(--text-2); font-size: 13px; max-width: 720px; }
.phead-r { display: flex; gap: 10px; flex-wrap: wrap; align-items: center; }

/* ============================================================== Butonlar */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 7px;
  height: 38px; padding: 0 15px;
  border-radius: 11px;
  border: 1px solid var(--border-strong);
  background: var(--surface);
  color: var(--text);
  font: inherit; font-size: 13.3px; font-weight: 600;
  cursor: pointer; white-space: nowrap;
  box-shadow: var(--shadow-xs);
  transition: background .15s, border-color .15s, box-shadow .15s, transform .08s, filter .15s;
}
.btn:hover { background: var(--surface-2); border-color: color-mix(in srgb, var(--accent) 30%, var(--border-strong)); }
.btn:active { transform: translateY(1px); }
.btn:disabled { opacity: .5; cursor: not-allowed; transform: none; }
.btn-primary { border: 0; color: #fff; background: var(--grad); box-shadow: 0 8px 20px -8px rgba(79, 70, 229, .75), inset 0 1px 0 rgba(255, 255, 255, .2); }
.btn-primary:hover { background: var(--grad); filter: brightness(1.08); box-shadow: 0 12px 26px -8px rgba(79, 70, 229, .85); }
.btn-ok { border: 0; color: #fff; background: linear-gradient(135deg, #059669, #10b981 60%, #34d399); box-shadow: 0 8px 20px -8px rgba(5, 150, 105, .8); }
.btn-ok:hover { background: linear-gradient(135deg, #059669, #10b981 60%, #34d399); filter: brightness(1.06); }
.btn-danger { color: var(--danger); }
.btn-danger:hover { background: var(--danger-soft); border-color: color-mix(in srgb, var(--danger) 40%, var(--border)); }
.btn-danger-solid { border: 0; color: #fff; background: linear-gradient(135deg, #e11d48, #f43f5e); box-shadow: 0 8px 20px -8px rgba(225, 29, 72, .8); }
.btn-danger-solid:hover { background: linear-gradient(135deg, #e11d48, #f43f5e); filter: brightness(1.06); }
.btn-ghost { background: transparent; border-color: transparent; box-shadow: none; color: var(--text-2); }
.btn-ghost:hover { background: var(--surface-3); border-color: transparent; color: var(--text); }
.btn-soft { background: var(--accent-soft); border-color: transparent; color: var(--accent-ink); box-shadow: none; }
.btn-soft:hover { background: color-mix(in srgb, var(--accent) 16%, var(--surface)); border-color: transparent; }
.btn-sm { height: 32px; padding: 0 11px; font-size: 12.5px; border-radius: 9px; }
.btn-icon { width: 38px; padding: 0; }
.btn-sm.btn-icon { width: 32px; }
.btn-block { width: 100%; }
.btn-lg { height: 48px; font-size: 14.5px; border-radius: 12px; }

/* ================================================================== Form */
.field { margin-bottom: 14px; }
.field > label { display: block; font-size: 12.5px; font-weight: 600; margin-bottom: 6px; color: var(--text-2); }
.field > label em { color: var(--danger); font-style: normal; }
.field .hint { font-size: 11.5px; color: var(--muted); margin-top: 4px; }

.input, .select, textarea.input {
  width: 100%;
  height: 40px;
  padding: 0 12px;
  border: 1px solid var(--border-strong);
  border-radius: 11px;
  background: var(--surface);
  color: var(--text);
  font: inherit; font-size: 13.5px;
  transition: border-color .15s, box-shadow .15s;
}
.select { appearance: none; padding-right: 32px; background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 24 24' fill='none' stroke='%238490a6' stroke-width='2.5' stroke-linecap='round'%3E%3Cpath d='m6 9 6 6 6-6'/%3E%3C/svg%3E"); background-repeat: no-repeat; background-position: right 11px center; }
textarea.input { height: auto; padding: 10px 12px; resize: vertical; min-height: 70px; line-height: 1.5; }
.input:hover, .select:hover { border-color: color-mix(in srgb, var(--accent) 30%, var(--border-strong)); }
.input:focus, .select:focus { outline: 0; border-color: var(--accent); box-shadow: 0 0 0 4px color-mix(in srgb, var(--accent) 16%, transparent); }
.input:disabled { background: var(--surface-2); color: var(--text-2); }
.input[aria-invalid="true"], .select[aria-invalid="true"] { border-color: var(--danger); box-shadow: 0 0 0 4px color-mix(in srgb, var(--danger) 12%, transparent); }
.err { color: var(--danger); font-size: 11.5px; margin-top: 4px; }
.err:empty { display: none; }
.form-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 0 16px; }
.form-grid .full { grid-column: 1 / -1; }
.form-sec { display: flex; align-items: center; gap: 8px; margin: 6px 0 12px; padding-bottom: 8px; border-bottom: 1px dashed var(--border); font-size: 11.5px; font-weight: 700; text-transform: uppercase; letter-spacing: .08em; color: var(--accent-ink); }
.form-sec:first-child { margin-top: 0; }
.input-affix { position: relative; }
.input-affix .input { padding-right: 34px; }
.input-affix span { position: absolute; right: 12px; top: 50%; transform: translateY(-50%); color: var(--muted); font-weight: 600; }

.check { display: flex; align-items: center; gap: 8px; font-size: 13.5px; }
.check input { width: 16px; height: 16px; accent-color: var(--accent); }
.switch { display: inline-flex; align-items: center; gap: 10px; cursor: pointer; font-size: 13.5px; font-weight: 500; margin-top: 26px; }
.switch input { position: absolute; opacity: 0; pointer-events: none; }
.switch i { width: 40px; height: 23px; border-radius: 20px; background: var(--border-strong); position: relative; transition: background .2s; flex: none; }
.switch i::after { content: ""; position: absolute; left: 3px; top: 3px; width: 17px; height: 17px; border-radius: 50%; background: #fff; box-shadow: 0 1px 3px rgba(0, 0, 0, .3); transition: transform .2s; }
.switch input:checked + i { background: var(--grad); }
.switch input:checked + i::after { transform: translateX(17px); }
.switch input:focus-visible + i { box-shadow: 0 0 0 4px color-mix(in srgb, var(--accent) 20%, transparent); }
input[type="checkbox"] { accent-color: var(--accent); width: 16px; height: 16px; }

/* ================================================================== Kart */
.card { position: relative; background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); box-shadow: var(--shadow); }
.card + .card { margin-top: 18px; }
.g-main > .card, .g-side > .card, .grid > .card, .stack > .card, .load-top .card { margin-top: 0; }
.card-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 16px 20px; border-bottom: 1px solid var(--border); flex-wrap: wrap; }
.card-head h3 { font-size: 15px; letter-spacing: -.01em; }
.card-head p { margin: 2px 0 0; font-size: 12.3px; color: var(--muted); }
.card-ic { width: 36px; height: 36px; border-radius: 11px; display: grid; place-items: center; flex: none; color: var(--accent); background: var(--accent-soft); }
.card-act { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }
.card-body { padding: 18px 20px; }
.card-foot { padding: 12px 20px; border-top: 1px solid var(--border); background: var(--surface-2); border-radius: 0 0 var(--radius) var(--radius); }

/* ================================================================== KPI */
.kpis { --cols: 4; display: grid; grid-template-columns: repeat(var(--cols), minmax(0, 1fr)); gap: 14px; }
@media (max-width: 1360px) { .kpis[style*="--cols:6"] { --cols: 3 !important; } }
@media (max-width: 1200px) { .kpis[style*="--cols:5"] { --cols: 3 !important; } }
@media (max-width: 1000px) { .kpis, .kpis[style] { --cols: 2 !important; } }
@media (max-width: 380px) { .kpis, .kpis[style] { --cols: 1 !important; } }

.kpi {
  position: relative; overflow: hidden; container-type: inline-size;
  display: grid; grid-template-columns: auto minmax(0, 1fr) auto; align-items: center; gap: 14px;
  color: var(--text);
  padding: 15px 18px 15px 20px;
  border-radius: 16px;
  background: linear-gradient(120deg, color-mix(in srgb, var(--c) 7%, var(--surface)) 0%, var(--surface) 62%);
  border: 1px solid var(--border);
  box-shadow: var(--shadow);
  transition: transform .18s, box-shadow .18s, border-color .18s;
}
.kpi::before { content: ""; position: absolute; left: 0; top: 14px; bottom: 14px; width: 4px; border-radius: 0 4px 4px 0; background: linear-gradient(180deg, var(--c2), var(--c)); }
.kpi:hover { transform: translateY(-2px); box-shadow: var(--shadow-md); border-color: color-mix(in srgb, var(--c) 35%, var(--border)); }
.kpi-ic { width: 46px; height: 46px; border-radius: 14px; display: grid; place-items: center; color: #fff; background: linear-gradient(135deg, var(--c), var(--c2)); box-shadow: 0 8px 18px -8px var(--c), inset 0 1px 0 rgba(255, 255, 255, .28); }
.kpi-body { min-width: 0; display: grid; gap: 1px; }
.kpi-lbl { font-size: 12px; font-weight: 600; color: var(--text-2); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.kpi-val { font: 800 25px/1.15 var(--font-head); letter-spacing: -.03em; font-variant-numeric: tabular-nums; white-space: nowrap; }
.kpi-sub { font-size: 11.5px; color: var(--muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.kpi-spark { width: 84px; height: 34px; color: var(--c); opacity: .95; }
.kpi-spark .spark { width: 100%; height: 100%; display: block; }
.trend { display: inline-flex; align-items: center; gap: 4px; padding: 3px 8px; border-radius: 20px; font-size: 11.5px; font-weight: 700; }
.trend.up { background: var(--ok-soft); color: var(--ok); }
.trend.down { background: var(--danger-soft); color: var(--danger); }
@container (max-width: 250px) {
  .kpi-spark { display: none; }
  .kpi { gap: 10px; padding: 13px 12px 13px 16px; }
  .kpi-ic { width: 38px; height: 38px; border-radius: 12px; }
  .kpi-ic .ic { width: 18px; height: 18px; }
  .kpi-val { font-size: 22px; }
  .kpi-lbl, .kpi-sub { white-space: normal; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; line-height: 1.3; }
}

/* ============================================================= Dashboard */
.hero-dash {
  position: relative; overflow: hidden;
  display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 24px; align-items: center;
  padding: 28px 32px;
  border-radius: 22px;
  color: #eef2ff;
  background:
    radial-gradient(520px 260px at 88% 0%, rgba(236, 72, 153, .38), transparent 62%),
    radial-gradient(520px 300px at 0% 110%, rgba(6, 182, 212, .45), transparent 60%),
    linear-gradient(120deg, #1e2a8a 0%, #3b3bd1 45%, #6d38e0 100%);
  box-shadow: 0 24px 50px -24px rgba(67, 56, 202, .75);
  margin-bottom: 20px;
}
.hero-dash::before { content: ""; position: absolute; inset: 0; background-image: radial-gradient(rgba(255, 255, 255, .12) 1px, transparent 1px); background-size: 22px 22px; mask-image: linear-gradient(90deg, transparent, #000 60%); pointer-events: none; }
.hero-dash > * { position: relative; }
.hd-date { display: inline-flex; align-items: center; gap: 7px; font-size: 12.5px; color: #c7d2fe; padding: 5px 11px; border-radius: 20px; background: rgba(255, 255, 255, .12); border: 1px solid rgba(255, 255, 255, .16); }
.hero-dash h2 { font-size: 30px; letter-spacing: -.035em; margin: 14px 0 6px; color: #fff; }
.hero-dash p { margin: 0; color: #d4dbff; font-size: 14.5px; max-width: 640px; }
.hero-dash p b { color: #fff; }
.hd-actions { display: flex; gap: 10px; flex-wrap: wrap; margin-top: 20px; }
.hd-actions .btn { background: rgba(255, 255, 255, .14); color: #fff; border: 1px solid rgba(255, 255, 255, .22); box-shadow: none; backdrop-filter: blur(4px); }
.hd-actions .btn:hover { background: rgba(255, 255, 255, .24); }
.hd-actions .btn.btn-white { background: #fff; color: #3730a3; border-color: #fff; }
.hd-actions .btn.btn-white:hover { background: #eef2ff; }
.hd-r { display: flex; align-items: center; gap: 22px; }
.hd-r .gauge { --g-track: rgba(255, 255, 255, .16); color: #fff; }
.hd-r .gauge-v span, .hd-r .gauge-sub { color: #c7d2fe; }
.hd-pills { display: grid; gap: 8px; }
.hd-pill { display: flex; align-items: center; gap: 10px; min-width: 170px; padding: 9px 12px; border-radius: 12px; background: rgba(255, 255, 255, .1); border: 1px solid rgba(255, 255, 255, .14); font-size: 12.5px; color: #dbe1ff; }
.hd-pill b { margin-left: auto; font: 800 16px var(--font-head); color: #fff; }
.hd-pill i { width: 9px; height: 9px; border-radius: 50%; flex: none; }

/* Hazir arac kartlari */
.ready-list { display: grid; gap: 10px; }
.ready-item { display: flex; align-items: center; gap: 14px; padding: 12px 14px; border-radius: 14px; border: 1px solid var(--border); background: var(--surface-2); transition: border-color .15s, background .15s, transform .15s; cursor: pointer; }
.ready-item:hover { border-color: color-mix(in srgb, var(--ok) 45%, var(--border)); background: color-mix(in srgb, var(--ok) 5%, var(--surface)); transform: translateX(2px); }
.ready-item .grow { display: grid; gap: 2px; }
.ready-item .row { flex-wrap: wrap; }

/* ================================================================= Tablo */
.table-card { overflow: hidden; }
.toolbar { display: flex; gap: 10px; align-items: center; padding: 14px 16px; border-bottom: 1px solid var(--border); flex-wrap: wrap; background: linear-gradient(180deg, var(--surface), var(--surface-2)); }
.search-box { position: relative; display: flex; align-items: center; flex: 1; min-width: 220px; max-width: 360px; }
.search-box .ic { position: absolute; left: 12px; color: var(--muted); pointer-events: none; }
.search-box .search { width: 100%; height: 38px; padding: 0 12px 0 38px; border-radius: 11px; border: 1px solid var(--border-strong); background: var(--surface); color: var(--text); font: inherit; font-size: 13.3px; transition: border-color .15s, box-shadow .15s; }
.search-box .search:focus { outline: 0; border-color: var(--accent); box-shadow: 0 0 0 4px color-mix(in srgb, var(--accent) 14%, transparent); }
.select-wrap { position: relative; display: inline-flex; align-items: center; }
.select-wrap > .ic { position: absolute; left: 11px; color: var(--muted); pointer-events: none; z-index: 1; }
.select-wrap .select { height: 38px; width: auto; min-width: 150px; padding-left: 30px; font-size: 13px; }
.select-wrap.on .select { border-color: color-mix(in srgb, var(--accent) 50%, var(--border-strong)); background-color: var(--accent-soft); color: var(--accent-ink); font-weight: 600; }
.select-wrap.on > .ic { color: var(--accent); }
.toolbar .input { height: 38px; width: auto; }

.table-wrap { overflow-x: auto; }
table.table { width: 100%; border-collapse: separate; border-spacing: 0; font-size: 13.3px; }
table.table th {
  text-align: left;
  font-weight: 700; font-size: 11px;
  text-transform: uppercase; letter-spacing: .07em;
  color: var(--muted);
  background: var(--surface-2);
  padding: 11px 14px;
  border-bottom: 1px solid var(--border);
  white-space: nowrap;
  position: sticky; top: 0; z-index: 1;
}
table.table th.sortable { cursor: pointer; user-select: none; }
table.table th.sortable:hover, table.table th.sorted { color: var(--accent-ink); }
.sort-ic { display: inline-block; margin-left: 4px; opacity: .35; vertical-align: -1px; transition: transform .15s, opacity .15s; }
th.sorted .sort-ic { opacity: 1; }
th.sorted.asc .sort-ic { transform: rotate(180deg); }
table.table td { padding: 12px 14px; border-bottom: 1px solid var(--border); vertical-align: middle; }
table.table tbody tr:last-child td { border-bottom: 0; }
table.table tbody tr { transition: background .12s; }
table.table tbody tr:not(.skel-row) { animation: fadeRow .35s both calc(var(--i, 0) * 22ms); }
@keyframes fadeRow { from { opacity: 0; } }
table.table tbody tr.clickable { cursor: pointer; }
table.table tbody tr:hover td { background: color-mix(in srgb, var(--accent) 3.5%, transparent); }
table.table tbody tr.clickable:hover td:first-child { box-shadow: inset 3px 0 0 var(--accent); }
table.table tbody tr.on td { background: var(--accent-soft); }
table.table td.num, table.table th.num { text-align: right; font-variant-numeric: tabular-nums; }
table.table td.act { text-align: right; white-space: nowrap; }
table.table td.act .btn { margin-left: 5px; }
table.table tfoot th { position: static; background: var(--surface-2); border-top: 1px solid var(--border); border-bottom: 0; color: var(--text); font-size: 12px; }
.table.compact td { padding: 9px 14px; }
.t-main { font-weight: 600; color: var(--text); }
.t-sub { font-size: 11.8px; color: var(--muted); margin-top: 1px; }

.pager { display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 12px 16px; border-top: 1px solid var(--border); font-size: 12.5px; color: var(--muted); flex-wrap: wrap; background: var(--surface-2); }
.pager b { color: var(--text); }
.pages { display: flex; gap: 4px; align-items: center; }
.pg { min-width: 32px; height: 32px; padding: 0 8px; border-radius: 9px; border: 1px solid var(--border); background: var(--surface); color: var(--text-2); font: inherit; font-size: 12.5px; font-weight: 600; cursor: pointer; display: grid; place-items: center; }
.pg:hover:not(:disabled) { border-color: var(--accent); color: var(--accent); }
.pg.on { background: var(--grad); color: #fff; border-color: transparent; box-shadow: 0 6px 14px -6px rgba(79, 70, 229, .8); }
.pg:disabled { opacity: .4; cursor: not-allowed; }
.pg-gap { padding: 0 4px; }

/* Iskelet */
.skel { display: block; height: 12px; border-radius: 6px; background: linear-gradient(90deg, var(--surface-3) 25%, color-mix(in srgb, var(--surface-3) 40%, var(--surface)) 50%, var(--surface-3) 75%); background-size: 200% 100%; animation: shimmer 1.3s infinite linear; }
.skel-row td .skel { width: 70%; }
.skel-row td:first-child .skel { width: 85%; }
.skel-list { display: grid; gap: 12px; padding: 6px 0; }
.skel-list .skel { height: 44px; border-radius: 12px; }
@keyframes shimmer { to { background-position: -200% 0; } }

.empty { padding: 42px 16px; text-align: center; color: var(--muted); font-size: 13px; }
.empty > .ic, .empty-ic > .ic { opacity: .7; }
.empty-ic { width: 58px; height: 58px; border-radius: 18px; margin: 0 auto 12px; display: grid; place-items: center; color: var(--accent); background: var(--accent-soft); }
.empty b { display: block; color: var(--text); font-size: 14px; margin-bottom: 3px; }
.empty > .ic { display: block; margin: 0 auto 10px; }

/* ================================================================= Rozet */
.badge {
  display: inline-flex; align-items: center; gap: 6px;
  height: 24px; padding: 0 10px;
  border-radius: 20px;
  font-size: 11.8px; font-weight: 600;
  background: var(--surface-3); color: var(--text-2);
  white-space: nowrap;
}
.badge > i { width: 6px; height: 6px; border-radius: 50%; background: currentColor; flex: none; }
.badge.sm { height: 20px; padding: 0 8px; font-size: 10.8px; }
.badge.ok { background: var(--ok-soft); color: var(--ok); }
.badge.warn { background: var(--warn-soft); color: var(--warn-ink); }
.badge.danger { background: var(--danger-soft); color: var(--danger); }
.badge.info { background: var(--info-soft); color: var(--info); }
.badge.violet { background: var(--violet-soft); color: var(--violet); }
.badge.muted { background: var(--surface-3); color: var(--text-2); }
.badge.ok > i { box-shadow: 0 0 0 3px color-mix(in srgb, var(--ok) 20%, transparent); }
.badge.info > i { animation: blink 1.6s infinite; }
@keyframes blink { 50% { opacity: .35; } }

/* ================================================================= Plaka */
.plate {
  display: inline-flex; align-items: stretch;
  height: 26px; border-radius: 6px; overflow: hidden;
  background: #fff; color: #0b1220;
  border: 1.5px solid #1e293b;
  box-shadow: 0 1px 0 rgba(15, 23, 42, .1), inset 0 -2px 0 rgba(15, 23, 42, .06);
  font: 700 12.8px/1 var(--font-head); letter-spacing: .06em;
  white-space: nowrap;
}
.plate i { display: grid; place-items: end center; width: 15px; padding-bottom: 3px; background: linear-gradient(180deg, #1d4ed8, #1e40af); color: #fff; font: 700 6.5px/1 var(--font); font-style: normal; letter-spacing: 0; }
.plate b { display: grid; place-items: center; padding: 0 8px; font-weight: 700; }
.plate { flex: none; }
.plate.sm { height: 22px; font-size: 11.5px; }
.plate.sm i { width: 12px; font-size: 5.5px; }

/* ================================================================ Avatar */
.avatar {
  --s: 34px;
  position: relative; flex: none;
  width: var(--s); height: var(--s); border-radius: 50%;
  display: inline-grid; place-items: center;
  color: #fff; font-weight: 700; font-size: calc(var(--s) * .36);
  letter-spacing: .02em;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, .3), 0 3px 8px -3px rgba(15, 23, 42, .35);
}
.av-0 { background: linear-gradient(135deg, #3b5bfd, #7a8cff); }
.av-1 { background: linear-gradient(135deg, #8b5cf6, #c084fc); }
.av-2 { background: linear-gradient(135deg, #0891b2, #22d3ee); }
.av-3 { background: linear-gradient(135deg, #059669, #34d399); }
.av-4 { background: linear-gradient(135deg, #ea580c, #fbbf24); }
.av-5 { background: linear-gradient(135deg, #e11d48, #fb7185); }
.av-6 { background: linear-gradient(135deg, #0d9488, #5eead4); }
.av-7 { background: linear-gradient(135deg, #4f46e5, #ec4899); }
.avatar > i { position: absolute; right: -1px; bottom: -1px; width: calc(var(--s) * .3); height: calc(var(--s) * .3); min-width: 9px; min-height: 9px; border-radius: 50%; background: #94a3b8; border: 2px solid var(--surface); }
.avatar > i.on { background: #10b981; }
.side-user .avatar > i { border-color: #0e1840; }
.person { display: flex; align-items: center; gap: 10px; min-width: 0; }
.person > div { min-width: 0; }
.veh { display: flex; align-items: center; gap: 12px; }
.veh .t-main, .veh .t-sub { white-space: nowrap; }
.person .t-main, .person .t-sub, table.table td.num, .route-sm { white-space: nowrap; }

/* ======================================================= Doluluk cubugu */
.bar { flex: 1; height: 8px; border-radius: 6px; background: var(--surface-3); overflow: hidden; min-width: 70px; }
.bar.thick { height: 12px; }
.bar > span { display: block; height: 100%; border-radius: 6px; background: linear-gradient(90deg, #6d8bff, #3b5bfd); transition: width .7s cubic-bezier(.2, .7, .3, 1); }
.bar.ok > span { background: linear-gradient(90deg, #34d399, #059669); box-shadow: 0 0 10px rgba(16, 185, 129, .45); }
.bar.warn > span { background: linear-gradient(90deg, #fbbf24, #f59e0b); }
.bar.danger > span { background: linear-gradient(90deg, #fb7185, #e11d48); }
.fill-cell { display: flex; align-items: center; gap: 10px; min-width: 140px; }
.fill-cell b { font-size: 12.5px; font-variant-numeric: tabular-nums; width: 42px; text-align: right; }

.ring { position: relative; display: inline-grid; place-items: center; flex: none; }
.ring svg { position: absolute; inset: 0; width: 100%; height: 100%; }
.ring-bg { fill: none; stroke: var(--surface-3); }
.ring-fg { fill: none; stroke-linecap: round; transition: stroke-dasharray .7s ease; }
.ring.t-accent .ring-fg { stroke: var(--accent); }
.ring.t-ok .ring-fg { stroke: #10b981; }
.ring.t-warn .ring-fg { stroke: #f59e0b; }
.ring.t-danger .ring-fg { stroke: #f43f5e; }
.ring b { font-size: 10.5px; font-weight: 700; font-variant-numeric: tabular-nums; }

/* ================================================================= Sekme */
.tabs { display: inline-flex; gap: 3px; padding: 4px; margin-bottom: 14px; border-radius: 14px; background: var(--surface); border: 1px solid var(--border); box-shadow: var(--shadow-xs); overflow-x: auto; max-width: 100%; }
.tabs button {
  display: inline-flex; align-items: center; gap: 7px;
  border: 0; background: none;
  height: 34px; padding: 0 13px;
  border-radius: 10px;
  font: inherit; font-size: 13px; font-weight: 600;
  color: var(--text-2);
  cursor: pointer; white-space: nowrap;
  transition: background .15s, color .15s;
}
.tabs button:hover { background: var(--surface-3); color: var(--text); }
.tabs button.on { background: var(--grad); color: #fff; box-shadow: 0 6px 16px -8px rgba(79, 70, 229, .9); }
.tabs .count { min-width: 22px; height: 20px; padding: 0 6px; border-radius: 10px; font-size: 11px; display: inline-grid; place-items: center; background: var(--surface-3); color: var(--text-2); }
.tabs button.on .count { background: rgba(255, 255, 255, .24); color: #fff; }

/* ================================================================= Modal */
.modal-bg {
  position: fixed; inset: 0; z-index: 100;
  background: rgba(8, 12, 32, .52);
  backdrop-filter: blur(5px);
  -webkit-backdrop-filter: blur(5px);
  display: flex; align-items: flex-start; justify-content: center;
  padding: 36px 16px;
  overflow-y: auto;
  animation: fade .16s ease-out;
}
.modal-bg.out { animation: fadeOut .16s ease-in forwards; }
@keyframes fade { from { opacity: 0; } }
@keyframes fadeOut { to { opacity: 0; } }

.modal {
  width: 100%; max-width: 580px;
  background: var(--surface);
  border-radius: 20px;
  border: 1px solid var(--border);
  box-shadow: var(--shadow-lg);
  animation: pop .22s cubic-bezier(.2, .8, .3, 1.1);
  overflow: hidden;
}
@keyframes pop { from { transform: translateY(12px) scale(.98); opacity: 0; } }
.modal.md { max-width: 760px; }
.modal.lg { max-width: 1000px; }
.modal.xl { max-width: 1180px; }

.modal-head { position: relative; display: flex; align-items: center; gap: 14px; padding: 18px 22px; border-bottom: 1px solid var(--border); background: linear-gradient(180deg, color-mix(in srgb, var(--accent) 5%, var(--surface)), var(--surface)); }
.modal-head::before { content: ""; position: absolute; left: 0; right: 0; top: 0; height: 3px; background: var(--grad); }
.modal-head h3 { font-size: 17px; }
.modal-head p { margin: 2px 0 0; font-size: 12.8px; color: var(--muted); }
.modal-ic { width: 42px; height: 42px; border-radius: 13px; display: grid; place-items: center; flex: none; color: #fff; background: var(--grad); box-shadow: 0 8px 18px -8px rgba(79, 70, 229, .8); }
.modal-ic.danger { background: linear-gradient(135deg, #e11d48, #fb7185); box-shadow: 0 8px 18px -8px rgba(225, 29, 72, .8); }
.modal-ic.ok { background: linear-gradient(135deg, #059669, #34d399); box-shadow: 0 8px 18px -8px rgba(5, 150, 105, .8); }
.modal-ic.warn { background: linear-gradient(135deg, #d97706, #fbbf24); }
.modal-ic.info { background: linear-gradient(135deg, #0284c7, #38bdf8); }
.modal-body { padding: 20px 22px; max-height: calc(100vh - 220px); overflow-y: auto; }
.modal-foot { display: flex; justify-content: flex-end; align-items: center; gap: 10px; padding: 14px 22px; border-top: 1px solid var(--border); background: var(--surface-2); flex-wrap: wrap; }
.modal-foot .left { margin-right: auto; }
.confirm-text { margin: 0; font-size: 14px; color: var(--text-2); line-height: 1.6; }

.x { margin-left: auto; flex: none; width: 36px; height: 36px; border: 0; border-radius: 10px; background: var(--surface-3); color: var(--muted); cursor: pointer; display: grid; place-items: center; transition: background .15s, color .15s, transform .15s; }
.x:hover { background: var(--danger-soft); color: var(--danger); transform: rotate(90deg); }

/* ============================================================ Bildirim */
#toasts { position: fixed; right: 20px; bottom: 20px; z-index: 300; display: flex; flex-direction: column; gap: 10px; }
.toast {
  --t: var(--accent);
  position: relative; overflow: hidden;
  display: flex; gap: 12px; align-items: flex-start;
  width: 380px; max-width: calc(100vw - 40px);
  padding: 14px 14px 16px;
  border-radius: 16px;
  background: var(--surface);
  border: 1px solid var(--border);
  box-shadow: var(--shadow-lg);
  font-size: 13px; color: var(--text-2);
  animation: toastIn .3s cubic-bezier(.2, .8, .3, 1.2);
}
.toast b { display: block; font-size: 13.5px; color: var(--text); margin-bottom: 1px; }
.toast.ok { --t: #10b981; } .toast.warn { --t: #f59e0b; } .toast.danger { --t: #f43f5e; } .toast.info { --t: #3b5bfd; }
.toast-ic { width: 34px; height: 34px; border-radius: 11px; display: grid; place-items: center; flex: none; color: #fff; background: var(--t); box-shadow: 0 6px 14px -6px var(--t); }
.toast-x { border: 0; background: none; color: var(--muted); cursor: pointer; padding: 2px; border-radius: 6px; }
.toast-x:hover { color: var(--text); background: var(--surface-3); }
.toast-bar { position: absolute; left: 0; bottom: 0; height: 3px; width: 100%; background: var(--t); transform-origin: left; animation: toastBar var(--sure) linear forwards; opacity: .7; }
.toast.out { animation: toastOut .22s ease-in forwards; }
@keyframes toastIn { from { transform: translateX(30px) scale(.96); opacity: 0; } }
@keyframes toastOut { to { transform: translateX(30px); opacity: 0; } }
@keyframes toastBar { to { transform: scaleX(0); } }

/* ======================================================== Acilir paneller */
.pop {
  position: fixed; z-index: 150;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 18px;
  box-shadow: var(--shadow-lg);
  animation: popIn .16s ease-out;
  overflow: hidden;
}
.pop.out { animation: fadeOut .14s ease-in forwards; }
@keyframes popIn { from { transform: translateY(-6px); opacity: 0; } }
.pop-head { display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 14px 16px; border-bottom: 1px solid var(--border); }
.pop-head b { font: 700 15px var(--font-head); display: block; }
.pop-head small { font-size: 11.5px; color: var(--muted); }
.pop-body { max-height: 440px; overflow-y: auto; padding: 6px; }
.pop-list { padding: 6px; display: grid; }
.pop-list a, .pop-list button { display: flex; align-items: center; gap: 10px; padding: 10px 12px; border-radius: 10px; border: 0; background: none; font: inherit; font-size: 13.3px; color: var(--text); cursor: pointer; text-align: left; }
.pop-list a:hover, .pop-list button:hover { background: var(--surface-3); }
.pop-list .ic { color: var(--muted); }
.pop-list kbd { margin-left: auto; }
.pop-list .danger { color: var(--danger); }
.pop-list .danger .ic { color: var(--danger); }
.up-head { display: flex; gap: 12px; align-items: center; padding: 16px; background: linear-gradient(135deg, color-mix(in srgb, var(--accent) 10%, var(--surface)), var(--surface)); border-bottom: 1px solid var(--border); }
.up-head b { display: block; font-size: 14px; }
.up-head small { display: block; font-size: 12px; color: var(--muted); margin-bottom: 6px; }

.notif-list { list-style: none; margin: 0; padding: 0; }
.notif-list li { display: flex; gap: 12px; padding: 12px 10px; border-radius: 12px; align-items: flex-start; }
.notif-list li:hover { background: var(--surface-2); }
.notif-list li.read { opacity: .62; }
.notif-list li + li { border-top: 1px solid var(--border); border-radius: 0; }
.ni { width: 36px; height: 36px; border-radius: 11px; flex: none; display: grid; place-items: center; }
.t-ok { color: var(--ok); } .t-warn { color: var(--warn-ink); } .t-danger { color: var(--danger); } .t-info { color: var(--info); } .t-violet { color: var(--violet); } .t-muted { color: var(--muted); }
.ni.t-ok { background: var(--ok-soft); } .ni.t-warn { background: var(--warn-soft); } .ni.t-danger { background: var(--danger-soft); } .ni.t-info { background: var(--info-soft); }

/* ========================================================== Hizli arama */
.cmdk-bg { position: fixed; inset: 0; z-index: 180; background: rgba(8, 12, 32, .5); backdrop-filter: blur(6px); display: flex; justify-content: center; align-items: flex-start; padding: 12vh 16px 16px; animation: fade .14s ease-out; }
.cmdk { width: 100%; max-width: 640px; background: var(--surface); border: 1px solid var(--border); border-radius: 20px; box-shadow: var(--shadow-lg); overflow: hidden; animation: pop .2s cubic-bezier(.2, .8, .3, 1.1); }
.cmdk-in { display: flex; align-items: center; gap: 12px; padding: 16px 18px; border-bottom: 1px solid var(--border); color: var(--muted); }
.cmdk-in input { flex: 1; border: 0; outline: 0; background: none; font: inherit; font-size: 16px; color: var(--text); }
.cmdk-list { max-height: 420px; overflow-y: auto; padding: 8px; }
.cmdk-it { width: 100%; display: flex; align-items: center; gap: 12px; padding: 10px 12px; border-radius: 12px; border: 0; background: none; font: inherit; color: var(--text); cursor: pointer; text-align: left; }
.cmdk-it .ci { width: 36px; height: 36px; border-radius: 11px; display: grid; place-items: center; background: var(--surface-3); color: var(--text-2); flex: none; }
.cmdk-it b { display: block; font-size: 13.5px; font-weight: 600; }
.cmdk-it small { font-size: 12px; color: var(--muted); }
.cmdk-it em { font-style: normal; font-size: 11px; font-weight: 600; color: var(--muted); padding: 3px 8px; border-radius: 8px; background: var(--surface-3); }
.cmdk-it.on { background: var(--accent-soft); }
.cmdk-it.on .ci { background: var(--grad); color: #fff; }
.cmdk-foot { display: flex; gap: 16px; padding: 10px 16px; border-top: 1px solid var(--border); background: var(--surface-2); font-size: 11.5px; color: var(--muted); }
.cmdk-foot kbd { margin-right: 3px; }

/* ================================================================ Ipucu */
#tip { position: fixed; left: 0; top: 0; z-index: 400; pointer-events: none; opacity: 0; max-width: 280px; padding: 9px 12px; border-radius: 11px; background: rgba(12, 18, 44, .94); color: #e5e9ff; font-size: 12px; line-height: 1.5; box-shadow: 0 12px 30px -10px rgba(0, 0, 0, .5); transition: opacity .1s; }
#tip.on { opacity: 1; }
#tip b { color: #fff; }
#tip i { display: inline-block; width: 8px; height: 8px; border-radius: 3px; margin-right: 6px; }

/* ====================================================== Arac gorseli */
.arac-gorsel { position: relative; background: radial-gradient(120% 90% at 50% 100%, #eef2ff 0%, #ffffff 60%); border: 1px solid var(--border); border-radius: 18px; padding: 10px; overflow: hidden; }
:root[data-theme="dark"] .arac-gorsel { background: radial-gradient(120% 90% at 50% 100%, #e3e8f7 0%, #f8fafc 60%); }
.arac-gorsel svg { display: block; width: 100%; height: auto; }
.arac-etiket { position: absolute; left: 14px; top: 14px; background: rgba(255, 255, 255, .92); color: #0f172a; border: 1px solid #e2e8f0; border-radius: 14px; padding: 8px 12px; font-size: 12px; box-shadow: 0 8px 20px -10px rgba(15, 23, 42, .35); line-height: 1.35; backdrop-filter: blur(4px); }
.arac-etiket b { font: 800 22px var(--font-head); font-variant-numeric: tabular-nums; display: block; letter-spacing: -.02em; }
.arac-etiket .muted { color: #64748b; }

/* ========================================================= Uyari kutusu */
.note { display: flex; gap: 12px; align-items: flex-start; padding: 13px 15px; border-radius: 14px; font-size: 13px; border: 1px solid var(--border); background: var(--surface-2); color: var(--text-2); }
.note b { display: block; margin-bottom: 1px; color: var(--text); font-size: 13.5px; }
.note-ic { width: 32px; height: 32px; border-radius: 10px; display: grid; place-items: center; flex: none; background: var(--surface-3); color: var(--muted); }
.note.ok { background: var(--ok-soft); border-color: color-mix(in srgb, var(--ok) 22%, transparent); }
.note.ok .note-ic { background: #10b981; color: #fff; }
.note.warn { background: var(--warn-soft); border-color: color-mix(in srgb, var(--warn) 25%, transparent); }
.note.warn .note-ic { background: #f59e0b; color: #fff; }
.note.danger { background: var(--danger-soft); border-color: color-mix(in srgb, var(--danger) 22%, transparent); }
.note.danger .note-ic { background: #f43f5e; color: #fff; }
.note.info { background: var(--info-soft); border-color: color-mix(in srgb, var(--info) 22%, transparent); }
.note.info .note-ic { background: #0ea5e9; color: #fff; }

/* ======================================================== Bilgi kutulari */
.tiles { display: grid; grid-template-columns: repeat(auto-fit, minmax(135px, 1fr)); gap: 10px; }
.tile { display: flex; gap: 11px; align-items: center; padding: 12px; border-radius: 14px; background: var(--surface-2); border: 1px solid var(--border); min-width: 0; }
.tile-ic { width: 34px; height: 34px; border-radius: 10px; display: grid; place-items: center; flex: none; color: #fff; background: linear-gradient(135deg, var(--c), var(--c2)); }
.tile-k { font-size: 11.5px; color: var(--muted); }
.tile-v { font-weight: 700; font-size: 14px; font-variant-numeric: tabular-nums; }
.tile > div { min-width: 0; }

.docs { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; }
.docs li { display: flex; gap: 11px; align-items: center; padding: 10px 12px; border-radius: 12px; background: var(--surface-2); border: 1px solid var(--border); }
.docs b { font-size: 13px; white-space: nowrap; }
.doc-ic { width: 32px; height: 32px; border-radius: 10px; display: grid; place-items: center; background: var(--surface-3); flex: none; }

.sec-title { display: flex; align-items: center; gap: 8px; margin: 22px 0 12px; font: 700 13.5px var(--font-head); color: var(--text); }
.sec-title .ic { color: var(--accent); }
.sec-title .badge { margin-left: 4px; }

/* ============================================================ Zaman cizelgesi */
.tl { list-style: none; margin: 0; padding: 0; position: relative; }
.tl::before { content: ""; position: absolute; left: 15px; top: 6px; bottom: 6px; width: 2px; background: var(--border); border-radius: 2px; }
.tl li { position: relative; display: flex; gap: 14px; padding: 6px 0 12px; }
.tl-dot { position: relative; z-index: 1; width: 32px; height: 32px; border-radius: 50%; display: grid; place-items: center; flex: none; background: var(--surface); border: 2px solid currentColor; }
.tl-body { flex: 1; min-width: 0; padding-top: 5px; }
.tl-body b { font-size: 13px; color: var(--text); }

/* ================================================================ Harita */
.map-wrap { position: relative; height: calc(100vh - 330px); min-height: 480px; border: 1px solid var(--border); border-radius: var(--radius); overflow: hidden; background: var(--surface); box-shadow: var(--shadow); }
#map { position: absolute; inset: 0; }
.leaflet-container { background: var(--surface-2) !important; font: inherit !important; }
.leaflet-tile-pane { filter: saturate(.85) contrast(.97); }
:root[data-theme="dark"] .leaflet-tile-pane { filter: invert(1) hue-rotate(185deg) brightness(.92) contrast(.88) saturate(.6); }
.leaflet-popup-content-wrapper { border-radius: 14px !important; box-shadow: var(--shadow-md) !important; }
.map-panel { position: absolute; right: 14px; top: 14px; bottom: 14px; width: 300px; z-index: 500; background: color-mix(in srgb, var(--surface) 92%, transparent); backdrop-filter: blur(10px); border: 1px solid var(--border); border-radius: 16px; box-shadow: var(--shadow-lg); display: flex; flex-direction: column; overflow: hidden; }
.map-panel .head { padding: 12px 14px; border-bottom: 1px solid var(--border); display: flex; align-items: center; gap: 8px; }
.map-panel .list { overflow-y: auto; flex: 1; padding: 6px; }
.map-row { display: flex; gap: 10px; align-items: center; padding: 10px; border-radius: 12px; cursor: pointer; font-size: 12.5px; }
.map-row:hover { background: var(--surface-3); }
.map-row + .map-row { margin-top: 2px; }
.map-pin { background: none !important; border: 0 !important; }
.pin { width: 30px; height: 30px; border-radius: 50%; display: grid; place-items: center; color: #fff; font: 700 9.5px var(--font); border: 2.5px solid #fff; box-shadow: 0 4px 12px rgba(0, 0, 0, .35); }
.pin.moving { animation: pinPulse 2s infinite; }
@keyframes pinPulse { 0% { box-shadow: 0 0 0 0 rgba(59, 91, 253, .55), 0 4px 12px rgba(0, 0, 0, .35); } 70% { box-shadow: 0 0 0 12px rgba(59, 91, 253, 0), 0 4px 12px rgba(0, 0, 0, .35); } 100% { box-shadow: 0 0 0 0 rgba(59, 91, 253, 0), 0 4px 12px rgba(0, 0, 0, .35); } }
.dot { width: 9px; height: 9px; border-radius: 50%; flex: none; display: inline-block; }

/* ================================================================ Grafik */
.chart-box { position: relative; }
.chart { width: 100%; height: auto; display: block; overflow: visible; }
.chart .grid-line { stroke: var(--border); stroke-width: 1; stroke-dasharray: 3 4; }
.chart .zero-line { stroke: var(--border-strong); stroke-width: 1.2; }
.chart .axis-text { fill: var(--muted); font-size: 11px; font-family: var(--font); }
.area-line { stroke-linecap: round; stroke-linejoin: round; stroke-dasharray: 2400; stroke-dashoffset: 2400; animation: draw 1.4s cubic-bezier(.3, .6, .2, 1) forwards; }
.area-fill { opacity: 0; animation: fadeIn .8s .4s forwards; }
.area-dot { fill: var(--surface); stroke-width: 2.2; opacity: 0; animation: fadeIn .4s 1s forwards; }
@keyframes draw { to { stroke-dashoffset: 0; } }
@keyframes fadeIn { to { opacity: 1; } }
.hover-col { fill: transparent; cursor: crosshair; }
.hover-col:hover { fill: color-mix(in srgb, var(--accent) 7%, transparent); }
.bar-g path { transform-origin: bottom; transform-box: fill-box; animation: grow .7s cubic-bezier(.2, .7, .3, 1) both calc(var(--i) * 35ms); cursor: pointer; transition: filter .15s; }
.bar-g path:hover { filter: brightness(1.15) saturate(1.1); }
@keyframes grow { from { transform: scaleY(0); } }
.legend { display: flex; gap: 16px; flex-wrap: wrap; font-size: 12px; color: var(--text-2); margin-top: 10px; }
.legend span { display: inline-flex; align-items: center; }
.legend i { width: 10px; height: 10px; border-radius: 3px; display: inline-block; margin-right: 6px; }

.donut { display: flex; align-items: center; gap: 22px; flex-wrap: wrap; }
.donut svg { flex: none; }
.donut-seg { cursor: pointer; transition: stroke-width .15s; animation: fadeIn .6s both; }
.donut-seg:hover { stroke-width: 26; }
.donut-k { fill: var(--muted); font-size: 12px; font-family: var(--font); }
.donut-v { fill: var(--text); font-size: 19px; font-weight: 800; font-family: var(--font-head); }
.donut-legend { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; flex: 1; min-width: 180px; max-width: 480px; }
.donut-legend li { display: flex; align-items: center; gap: 9px; font-size: 12.8px; color: var(--text-2); }
.donut-legend i { width: 10px; height: 10px; border-radius: 3px; flex: none; }
.donut-legend b { color: var(--text); font-variant-numeric: tabular-nums; }
.donut-legend em { font-style: normal; font-size: 11.5px; color: var(--muted); width: 38px; text-align: right; }

.gauge { position: relative; text-align: center; }
.gauge svg { width: 100%; display: block; }
.gauge-fg { transition: stroke-dasharray 1s cubic-bezier(.2, .7, .3, 1); filter: drop-shadow(0 4px 10px rgba(99, 102, 241, .5)); }
.gauge-v { position: absolute; left: 0; right: 0; bottom: 8px; display: grid; }
.gauge-v b { font: 800 30px/1 var(--font-head); letter-spacing: -.03em; }
.gauge-v span { font-size: 12px; color: var(--muted); margin-top: 3px; }
.gauge-sub { font-size: 12px; color: var(--muted); margin-top: 6px; }

.barlist { list-style: none; margin: 0; padding: 0; display: grid; gap: 14px; }
.barlist li { display: grid; gap: 6px; }
.barlist li.clickable { cursor: pointer; border-radius: 10px; padding: 4px 6px; margin: -4px -6px; }
.barlist li.clickable:hover { background: var(--surface-2); }
.bl-l { font-size: 13px; color: var(--text-2); min-width: 0; display: flex; align-items: center; gap: 8px; }
.barlist b { font-size: 13px; font-variant-numeric: tabular-nums; }
.bl-bar { height: 9px; border-radius: 6px; background: var(--surface-3); overflow: hidden; }
.bl-bar span { display: block; height: 100%; border-radius: 6px; background: linear-gradient(90deg, color-mix(in srgb, var(--c) 60%, #fff), var(--c)); animation: barIn .9s cubic-bezier(.2, .7, .3, 1) both; transform-origin: left; }
@keyframes barIn { from { transform: scaleX(0); } }
.spark { overflow: visible; }

/* ================================================================== Liste */
.list-plain { list-style: none; margin: 0; padding: 0; }
.list-plain li { display: flex; gap: 12px; padding: 11px 0; border-bottom: 1px solid var(--border); font-size: 13px; align-items: flex-start; }
.list-plain li:last-child { border-bottom: 0; }
.kv { display: grid; grid-template-columns: 150px 1fr; gap: 0; font-size: 13.3px; margin: 0; }
.kv dt { color: var(--muted); font-size: 12.5px; padding: 9px 0; border-bottom: 1px dashed var(--border); }
.kv dd { margin: 0; font-weight: 500; padding: 8px 0; border-bottom: 1px dashed var(--border); min-width: 0; }
.kv dt:last-of-type, .kv dd:last-of-type { border-bottom: 0; }

.alert-row { display: flex; gap: 12px; align-items: flex-start; padding: 11px 12px; border-radius: 12px; }
.alert-row + .alert-row { margin-top: 4px; }
.alert-row:hover { background: var(--surface-2); }
.alert-row .ni { width: 34px; height: 34px; }

.spinner { width: 15px; height: 15px; border-radius: 50%; border: 2px solid currentColor; border-right-color: transparent; display: inline-block; animation: spin .6s linear infinite; vertical-align: -2px; }
.spinner.lg { width: 34px; height: 34px; border-width: 3px; color: var(--accent); }
@keyframes spin { to { transform: rotate(360deg); } }
.loading { padding: 40px; text-align: center; color: var(--muted); }

/* ======================================================== Ofis ana paneli */
.office-shell { --side-w: 232px; }
.office-shell .side { background: linear-gradient(180deg, #111d38, #182846 75%, #1d3152); }
.office-shell .brand-mark { width: 28px; height: 36px; background: none; box-shadow: none; }
.office-y-mark { font: italic 900 30px/1 var(--font-head); letter-spacing: -.13em; background: linear-gradient(140deg, #4389fb 30%, #8d50e7 70%); background-clip: text; -webkit-background-clip: text; color: transparent; }
.office-shell .brand-t b { font-size: 14px; letter-spacing: -.03em; }
.office-shell .brand-t small { color: #aabbd9; }
.office-shell .nav a.on { background: linear-gradient(100deg, #4659ed, #254d9b); box-shadow: 0 6px 16px #15236c66; }
.office-shell .content { max-width: 1760px; padding: 16px 17px 28px; }
.office-shell .top { background: color-mix(in srgb, var(--surface) 92%, transparent); }
.office-shell .top .crumbs { display: none; }
.office-shell .top .grow { flex: 0; }
.office-shell .top .searchbar { margin-right: auto; }
.office-dashboard { display: grid; gap: 11px; min-width: 0; }
.office-hero { position: relative; overflow: hidden; min-height: 226px; border-radius: 15px; border: 1px solid #2e3c66; background: #142746 url('/img/office-hero.png') center 54%/cover no-repeat; color: #fff; box-shadow: var(--shadow); padding: 24px 30px; }
.office-hero::before { content: ''; position: absolute; inset: 0; background: linear-gradient(90deg, #101e3ce8 0%, #18263e9c 29%, transparent 63%, #101c36a8 100%); }
.office-hero-content, .office-hero-quote { position: relative; z-index: 1; }
.office-hero-content > span { font-size: 10px; letter-spacing: .26em; font-weight: 700; color: #e4e9ff; }
.office-hero h1 { margin: 8px 0 3px; font-size: clamp(25px, 2.7vw, 36px); line-height: 1.04; letter-spacing: -.035em; }
.office-hero h1 em { font-style: normal; background: linear-gradient(90deg, #58a7ff, #a686ff); background-clip: text; -webkit-background-clip: text; color: transparent; }
.office-hero p { margin: 0; font-size: 12.5px; line-height: 1.45; color: #e0e7f5; }
.office-hero-actions { display: flex; gap: 9px; flex-wrap: wrap; margin-top: 13px; }
.office-hero-actions .btn { height: 35px; color: #fff; border-color: #ffffff55; background: #1b3150aa; backdrop-filter: blur(5px); font-size: 11px; }
.office-hero-actions .btn-primary { border: 0; background: linear-gradient(100deg, #6549f5, #3d79ee); }
.office-hero-quote { position: absolute; right: 3%; top: 58%; font: italic 700 16px/1.22 var(--font-head); text-align: right; text-shadow: 0 2px 8px #0a153c; }
.office-hero-quote::after { content: ''; display: block; height: 2px; width: 36px; margin: 9px 0 0 auto; background: #fff; }
.office-kpis { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 9px; }
.office-kpi { display: flex; align-items: center; gap: 11px; min-width: 0; min-height: 76px; padding: 10px 12px; border: 1px solid var(--border); border-radius: 12px; background: var(--surface); box-shadow: var(--shadow-xs); color: var(--text); transition: transform .16s, box-shadow .16s; }
.office-kpi:hover { transform: translateY(-2px); box-shadow: var(--shadow); }
.office-kpi-icon { flex: none; width: 48px; height: 48px; border-radius: 50%; display: grid; place-items: center; color: var(--accent); background: var(--accent-soft); }
.office-violet .office-kpi-icon { color: #7553e9; background: #eee8ff; }
.office-blue .office-kpi-icon { color: #285ae9; background: #e6ecff; }
.office-orange .office-kpi-icon { color: #ee800f; background: #fff0dc; }
.office-rose .office-kpi-icon { color: #e53b66; background: #ffe7ee; }
.office-green .office-kpi-icon { color: #05a66b; background: #dff9ee; }
.office-kpi-copy { display: block; min-width: 0; }
.office-kpi-copy small { display: block; color: var(--text-2); font-size: 10.5px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.office-kpi-copy strong { display: block; font: 800 19px/1.18 var(--font-head); letter-spacing: -.03em; white-space: nowrap; }
.office-kpi-copy em { display: block; color: var(--muted); font-size: 10px; font-style: normal; }
.office-primary-grid, .office-secondary-grid { display: grid; grid-template-columns: minmax(0, 1.36fr) minmax(0, 1fr); gap: 10px; }
.office-bottom-grid { display: grid; grid-template-columns: minmax(0, 1.22fr) minmax(0, 1fr) minmax(0, .95fr); gap: 10px; align-items: stretch; }
.office-card { min-width: 0; overflow: hidden; border: 1px solid var(--border); border-radius: 12px; background: var(--surface); box-shadow: var(--shadow-xs); }
.office-card-head { display: flex; align-items: center; gap: 8px; min-height: 40px; padding: 9px 12px 5px; }
.office-card-icon { display: grid; place-items: center; flex: none; width: 25px; height: 25px; color: #475df1; background: #edf0ff; border-radius: 8px; }
.office-card-head h2 { min-width: 0; flex: 1; font-size: 13px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.office-all { display: inline-flex; align-items: center; gap: 2px; white-space: nowrap; font-size: 10.5px; color: var(--accent-ink); font-weight: 700; }
button.office-all { padding: 0; border: 0; background: transparent; font-family: inherit; cursor: pointer; }
.office-card-body { padding: 7px 12px 12px; }
.office-period { display: flex; gap: 2px; flex-wrap: wrap; }
.office-period button { border: 1px solid var(--border); background: var(--surface-2); color: var(--text-2); border-radius: 7px; padding: 4px 7px; cursor: pointer; font: 600 10px var(--font); }
.office-period button.active { color: #fff; border-color: transparent; background: linear-gradient(100deg, #4653e9, #5985ee); }
.office-finance-summary { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 7px; margin-bottom: 7px; }
.office-finance-summary > div { min-width: 0; padding: 0 8px; border-right: 1px solid var(--border); }
.office-finance-summary > div:first-child { padding-left: 0; }
.office-finance-summary > div:last-child { border-right: 0; }
.office-finance-summary small { display: block; color: var(--muted); font-size: 10px; }
.office-finance-summary strong { display: block; font: 800 17px var(--font-head); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.office-finance-summary .positive { color: #078954; }
.office-finance-summary .negative { color: var(--danger); }
.office-finance .chart-box { margin: 0; }
.office-finance .chart { max-height: 226px; }
.office-finance .legend { justify-content: center; font-size: 10px; }
.office-fleet .donut { display: flex; gap: 6px; align-items: center; justify-content: space-around; }
.office-fleet .donut svg { flex: none; width: min(48%, 190px); height: auto; }
.office-fleet .donut-legend { flex: 1; min-width: 0; gap: 4px; }
.office-fleet .donut-legend li { font-size: 10.5px; gap: 5px; border-bottom: 1px solid var(--border); padding-bottom: 3px; }
.office-fleet .donut-legend em { font-size: 10px; width: 29px; }
.office-fleet-stats { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 5px; margin-top: 10px; }
.office-fleet-stats > div { display: flex; align-items: center; gap: 5px; padding: 7px; border: 1px solid var(--border); border-radius: 9px; color: #4763e9; }
.office-fleet-stats span { min-width: 0; }
.office-fleet-stats strong { display: block; color: var(--text); font: 800 12px var(--font-head); white-space: nowrap; }
.office-fleet-stats small { display: block; color: var(--muted); font-size: 9px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.office-list { padding: 0 12px 7px; }
.office-ready-row, .office-loading-row { display: flex; align-items: center; gap: 7px; min-width: 0; width: 100%; min-height: 53px; padding: 6px 0; border: 0; border-bottom: 1px solid var(--border); background: transparent; color: var(--text); font: inherit; text-align: left; }
.office-ready-row:last-child, .office-loading-row:last-child { border-bottom: 0; }
.office-ready-row { cursor: pointer; }
.office-ready-row:hover, .office-loading-row:hover { background: var(--surface-2); }
.office-ready-row img, .office-loading-row img { flex: none; width: 58px; height: 41px; object-fit: contain; }
.office-ready-name, .office-loading-text { min-width: 0; width: 128px; flex: none; }
.office-ready-name small, .office-loading-text small, .office-ready-route small { display: block; color: var(--muted); font-size: 9.5px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.office-ready-route { flex: 1; min-width: 0; font-size: 10px; font-weight: 600; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.office-ready-route .ic { vertical-align: -2px; color: var(--accent); }
.office-ready-row .btn { height: 28px; padding: 0 8px; font-size: 10px; }
.office-loading-row { cursor: pointer; }
.office-loading-text { width: 122px; }
.office-loading-progress { flex: 1; min-width: 50px; }
.office-loading-progress > div { height: 8px; border-radius: 5px; background: var(--surface-3); overflow: hidden; }
.office-loading-progress > div span { display: block; height: 100%; border-radius: inherit; }
.office-loading-progress small { display: block; margin-top: 4px; color: var(--muted); font-size: 9px; white-space: nowrap; }
.office-loading-row b { font-size: 10px; }
.office-map-card { display: flex; flex-direction: column; }
.office-map { position: relative; min-height: 230px; flex: 1; margin: 0 12px 8px; background: #d8eff5; border-radius: 8px; overflow: hidden; }
.office-map-fallback { display: grid; place-items: center; height: 230px; color: #50627f; font-size: 11px; text-align: center; padding: 14px; }
.office-map .leaflet-container { height: 100%; }
.office-bottom-link { display: flex; align-items: center; justify-content: center; gap: 4px; min-height: 25px; margin: 0 12px 12px; border-radius: 6px; background: var(--accent-soft); color: var(--accent-ink); font-size: 10px; font-weight: 700; }
.office-feed { padding: 2px 12px 10px; }
.office-alerts .office-feed.expanded { max-height: 310px; overflow-y: auto; }
.office-feed-row { display: flex; align-items: center; gap: 8px; min-width: 0; min-height: 44px; padding: 6px 0; border-bottom: 1px solid var(--border); color: var(--text); }
.office-feed-row:last-child { border-bottom: 0; }
.office-feed-icon { display: grid; place-items: center; flex: none; width: 29px; height: 29px; border-radius: 50%; color: #fff; background: #10aa74; }
.office-feed-1 { background: #315cf4; }.office-feed-2 { background: #f59e0b; }.office-feed-3 { background: #8056ee; }
.office-feed-row > div { min-width: 0; flex: 1; }
.office-feed-row strong { display: block; font-size: 10.5px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.office-feed-row small { display: block; color: var(--muted); font-size: 9.5px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.office-feed-row time { color: var(--muted); font-size: 9px; white-space: nowrap; align-self: start; }
.office-right-stack { display: grid; grid-template-rows: minmax(0, 1fr) auto; gap: 10px; min-width: 0; }
.office-alert-count { display: grid; place-items: center; width: 18px; height: 18px; border-radius: 50%; background: #ed4562; color: #fff; font-size: 10px; font-weight: 700; }
.office-goal { padding-bottom: 11px; }
.office-goal > strong { display: block; text-align: right; padding: 0 12px; color: #6044eb; font: 800 19px var(--font-head); }
.office-goal-track { height: 8px; margin: 2px 12px 4px; overflow: hidden; border-radius: 5px; background: var(--surface-3); }
.office-goal-track span { display: block; height: 100%; border-radius: inherit; background: linear-gradient(90deg, #315cf4, #894cf0); }
.office-goal > small { display: block; text-align: right; padding: 0 12px; color: var(--muted); font-size: 9px; }
@media (max-width: 1350px) { .office-kpis { grid-template-columns: repeat(3, minmax(0, 1fr)); } .office-bottom-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } .office-right-stack { grid-column: 1 / -1; grid-template-columns: minmax(0, 1fr) minmax(220px, .7fr); grid-template-rows: auto; } }
@media (max-width: 1050px) { .office-primary-grid, .office-secondary-grid { grid-template-columns: minmax(0, 1fr); } }
@media (max-width: 900px) { .office-bottom-grid { grid-template-columns: minmax(0, 1fr); } .office-right-stack { grid-column: auto; grid-template-columns: minmax(0, 1fr); } }
@media (max-width: 650px) {
  .office-shell .content { padding: 12px; }
  .office-hero { padding: 22px; min-height: 245px; background-position: 64% center; }
  .office-hero::before { background: linear-gradient(90deg, #101e3cf2, #18263ecc 64%, #101c3688); }
  .office-hero-quote { display: none; }
  .office-hero h1 { font-size: 28px; }
  .office-hero p br { display: none; }
  .office-kpis { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .office-kpi { padding: 8px; min-height: 70px; }
  .office-kpi-icon { width: 39px; height: 39px; }
  .office-kpi-copy strong { font-size: 16px; }
  .office-period { width: 100%; margin-top: 4px; }
  .office-card-head:has(.office-period) { flex-wrap: wrap; }
  .office-fleet .donut { flex-wrap: wrap; }
  .office-fleet .donut svg { width: 150px; }
  .office-ready-row, .office-loading-row { flex-wrap: wrap; }
  .office-ready-route, .office-loading-progress { flex-basis: 100%; order: 2; }
  .office-ready-row .btn { margin-left: auto; }
}
@media (max-width: 380px) { .office-kpis { grid-template-columns: minmax(0, 1fr); } .office-fleet-stats { grid-template-columns: minmax(0, 1fr); } }

/* ================================================================ Sofor */
.driver-dashboard { display: grid; gap: 14px; min-width: 0; }
.driver-hero { position: relative; min-height: 220px; overflow: hidden; border: 1px solid #dce7f7; border-radius: 16px; background: #eaf3fd url('/img/driver-hero.png') center 48%/cover no-repeat; box-shadow: var(--shadow); padding: 22px 24px 16px; display: flex; flex-direction: column; justify-content: space-between; gap: 14px; }
.driver-hero::before { content: ''; position: absolute; inset: 0; background: linear-gradient(90deg, rgba(255,255,255,.95) 0%, rgba(255,255,255,.7) 37%, transparent 72%); pointer-events: none; }
.driver-hero-copy, .driver-hero-quote, .driver-stats { position: relative; z-index: 1; }
.driver-date { display: inline-flex; align-items: center; gap: 7px; color: #4b6688; font-size: 12px; }
.driver-date .ic { color: #4b5cf4; }
.driver-hero h1 { color: #152342; font-size: clamp(23px, 2vw, 31px); line-height: 1.1; margin: 5px 0 3px; }
.driver-hero p { color: #526482; margin: 0; font-size: 13px; }
.driver-hero-quote { position: absolute; right: 3%; top: 25%; color: #fff; text-shadow: 0 2px 8px rgba(5,20,50,.6); font: italic 700 19px/1.2 var(--font-head); text-align: center; transform: rotate(-4deg); }
.driver-hero-quote small { display: block; font: 500 11px var(--font); margin-top: 10px; }
.driver-stats { display: grid; grid-template-columns: repeat(4, minmax(0, 145px)); gap: 8px; }
.driver-info { display: flex; align-items: center; gap: 10px; min-width: 0; background: var(--surface); border: 1px solid var(--border); border-radius: 12px; padding: 10px; color: var(--text); }
.driver-info > span:last-child { min-width: 0; }
.driver-info small { display: block; color: var(--muted); font-size: 10px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.driver-info strong { display: block; font: 800 14px var(--font-head); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.driver-icon, .driver-section-icon { flex: none; display: grid; place-items: center; width: 36px; height: 36px; border-radius: 10px; color: #fff; background: linear-gradient(135deg, #4e73ef, #365fe5); box-shadow: 0 5px 11px -6px currentColor; }
.driver-violet .driver-icon { background: linear-gradient(135deg, #8753fa, #5d53e9); }
.driver-green .driver-icon { background: linear-gradient(135deg, #18aa79, #06966b); }
.driver-orange .driver-icon { background: linear-gradient(135deg, #ffa526, #ed820b); }
.driver-rose .driver-icon { background: linear-gradient(135deg, #f24461, #d62148); }
.driver-cyan .driver-icon { background: linear-gradient(135deg, #28b2d7, #148dbb); }
.driver-actions { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 10px; }
.driver-action { display: flex; align-items: center; gap: 11px; min-width: 0; min-height: 64px; text-align: left; padding: 9px 12px; font: inherit; color: var(--text); background: var(--surface); border: 1px solid var(--border); border-radius: 12px; box-shadow: var(--shadow-xs); cursor: pointer; transition: transform .15s, border-color .15s, box-shadow .15s; }
.driver-action:hover { transform: translateY(-2px); border-color: color-mix(in srgb, var(--accent) 40%, var(--border)); box-shadow: var(--shadow); }
.driver-action > span:nth-child(2) { flex: 1; min-width: 0; }
.driver-action strong { display: block; font-weight: 700; font-size: 12px; }
.driver-action small { display: block; color: var(--muted); font-size: 10.5px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.driver-action > .ic { color: var(--muted); }
.driver-action-green { border-color: #c7ebdf; background: linear-gradient(90deg, var(--surface), #f1fff9); }
.driver-action-green .driver-icon { background: linear-gradient(135deg, #15ae7a, #06966b); }
.driver-notice { display: flex; align-items: center; gap: 13px; min-height: 56px; padding: 9px 14px; border-radius: 12px; border: 1px solid #c2e8da; background: linear-gradient(90deg, #f2fffa, #e9faf5); color: #175b49; }
.driver-notice-wait { background: var(--surface-2); border-color: var(--border); color: var(--text-2); }
.driver-notice-road { background: var(--info-soft); border-color: color-mix(in srgb, var(--info) 25%, var(--border)); color: var(--info); }
.driver-notice-icon { flex: none; display: grid; place-items: center; width: 34px; height: 34px; background: #0fa675; color: #fff; border-radius: 9px; }
.driver-notice-wait .driver-notice-icon { background: var(--muted); }
.driver-notice-road .driver-notice-icon { background: var(--info); }
.driver-notice > div { flex: 1; min-width: 0; }
.driver-notice strong { font-size: 12px; }
.driver-notice p { margin: 1px 0 0; color: var(--text-2); font-size: 10.5px; }
.driver-notice .btn { background: var(--surface); color: #087554; border: 1px solid #abe0ca; box-shadow: none; }
.driver-main-grid { display: grid; grid-template-columns: minmax(0, 1.58fr) minmax(320px, 1fr); gap: 12px; align-items: stretch; }
.driver-card { min-width: 0; overflow: hidden; background: var(--surface); border: 1px solid var(--border); border-radius: 13px; box-shadow: var(--shadow-xs); }
.driver-card-head { display: flex; align-items: center; gap: 10px; min-height: 61px; padding: 10px 14px; }
.driver-card-head > div:nth-child(2) { flex: 1; min-width: 0; }
.driver-card-head h2 { font-size: 13px; line-height: 1.2; }
.driver-card-head p { margin: 2px 0 0; color: var(--muted); font-size: 10.5px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.driver-section-icon { width: 37px; height: 37px; color: #4554ed; background: #eef0ff; box-shadow: none; }
.driver-head-right { display: flex; gap: 7px; align-items: center; justify-content: flex-end; flex-wrap: wrap; }
.driver-vehicle-body, .driver-trip-body { padding: 0 14px 12px; }
.driver-metrics { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 6px; }
.driver-metrics .driver-info { padding: 8px; border: 0; background: color-mix(in srgb, var(--accent) 5%, var(--surface)); }
.driver-metrics .driver-info:nth-child(1) { background: #f5f0ff; }
.driver-metrics .driver-info:nth-child(3) { background: #effbf7; }
.driver-metrics .driver-info:nth-child(4) { background: #fff8ec; }
.driver-metrics .driver-icon { width: 30px; height: 30px; }
.driver-metrics .driver-info strong { font-size: 12px; }
.driver-truck-stage { position: relative; height: 200px; overflow: hidden; }
.driver-truck-stage img { position: absolute; left: 0; top: 50%; width: 78%; height: auto; transform: translateY(-50%); }
.driver-truck-stage span { position: absolute; right: 5%; top: 34%; color: #5874ad; font: italic 600 19px/1.24 var(--font-head); transform: rotate(-7deg); }
.driver-vehicle-bottom { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 6px; }
.driver-vehicle-bottom .driver-info { padding: 7px; border: 0; background: var(--surface-2); }
.driver-vehicle-bottom .driver-icon { width: 30px; height: 30px; color: #4162ef; background: #e9edff; box-shadow: none; }
.driver-vehicle-bottom .driver-info strong { font-size: 11px; }
.driver-route { display: grid; grid-template-columns: minmax(70px, auto) 1fr minmax(70px, auto); align-items: center; gap: 8px; min-height: 72px; padding: 11px; margin-bottom: 8px; background: var(--surface-2); border: 1px solid var(--border); border-radius: 11px; }
.driver-route > div:last-child { text-align: right; }
.driver-route small { display: block; color: var(--muted); font-size: 10px; }
.driver-route strong { font: 800 13px var(--font-head); overflow-wrap: anywhere; }
.driver-route-line { display: flex; align-items: center; justify-content: center; gap: 7px; color: #5059fa; }
.driver-route-line::before, .driver-route-line::after { content: ''; height: 2px; flex: 1; min-width: 5px; background: repeating-linear-gradient(90deg, #645bfa 0 7px, transparent 7px 11px); }
.driver-route-line .ic { width: 35px; height: 35px; padding: 8px; border-radius: 50%; background: var(--surface); border: 1px solid #6366f1; box-shadow: 0 3px 9px #6366f133; }
.driver-trip-metrics { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 7px; margin-bottom: 10px; }
.driver-trip-metrics .driver-info { min-height: 58px; background: var(--surface-2); }
.driver-trip-metrics .driver-icon { width: 34px; height: 34px; }
.driver-trip-metrics .driver-info strong { font-size: 12px; white-space: normal; }
.driver-approved { color: var(--ok); font-size: 11px; display: flex; gap: 5px; align-items: center; }
.driver-report { margin-top: 7px; }
.driver-cargo-card .table-wrap, .driver-fuel-card .table-wrap { margin: 0 12px 12px; }
.driver-table { table-layout: auto; }
.driver-table th { font-size: 9.5px !important; padding: 7px 8px !important; }
.driver-table td { font-size: 11px; padding: 7px 8px !important; }
.driver-table .t-sub { font-size: 10px; }
.driver-fuel-empty { display: flex; flex-direction: column; align-items: center; justify-content: center; min-height: 145px; margin: 0 12px 12px; border: 1px solid var(--border); border-radius: 11px; background: linear-gradient(155deg, var(--surface) 55%, #eef4ff); text-align: center; padding: 14px; }
.driver-fuel-empty > span { display: grid; place-items: center; width: 45px; height: 45px; border-radius: 50%; color: #4b5af2; background: #e8edff; margin-bottom: 5px; }
.driver-fuel-empty strong { font-size: 12px; }
.driver-fuel-empty p { margin: 3px 0 7px; color: var(--muted); font-size: 10px; }
.driver-empty .empty { padding: 38px 16px; }
.driver-shift { display: flex; align-items: center; justify-content: flex-end; gap: 10px; color: var(--text-2); font-size: 11px; }
.driver-shift > span { display: inline-flex; align-items: center; gap: 5px; }
:root[data-theme="dark"] .driver-hero { border-color: var(--border); }
:root[data-theme="dark"] .driver-hero::before { background: linear-gradient(90deg, rgba(15,22,41,.92), rgba(15,22,41,.68) 42%, rgba(15,22,41,.08) 85%); }
:root[data-theme="dark"] .driver-hero h1, :root[data-theme="dark"] .driver-hero p, :root[data-theme="dark"] .driver-date { color: #f1f5ff; }
:root[data-theme="dark"] .driver-action-green, :root[data-theme="dark"] .driver-notice, :root[data-theme="dark"] .driver-metrics .driver-info { background: var(--surface-2); border-color: var(--border); }

@media (max-width: 1200px) {
  .driver-main-grid { grid-template-columns: minmax(0, 1fr); }
  .driver-actions { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 700px) {
  .driver-hero { min-height: 285px; padding: 18px; background-position: 58% center; }
  .driver-hero::before { background: linear-gradient(90deg, rgba(255,255,255,.96), rgba(255,255,255,.77) 75%, rgba(255,255,255,.4)); }
  .driver-hero-quote { display: none; }
  .driver-stats, .driver-metrics, .driver-vehicle-bottom { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .driver-actions { grid-template-columns: minmax(0, 1fr); }
  .driver-notice { flex-wrap: wrap; }
  .driver-notice .btn { width: 100%; }
  .driver-truck-stage { height: 150px; }
  .driver-truck-stage img { width: 78%; }
  .driver-truck-stage span { font-size: 13px; }
  .driver-card-head { flex-wrap: wrap; }
  .driver-head-right { margin-left: auto; }
  .driver-table thead { display: none; }
  .driver-table, .driver-table tbody, .driver-table tr, .driver-table td { display: block; width: 100%; }
  .driver-table tr { padding: 8px 0; border-bottom: 1px solid var(--border); }
  .driver-table td, .driver-table td.num { display: flex; justify-content: space-between; align-items: baseline; gap: 10px; text-align: right; border: 0; padding: 4px 8px !important; white-space: normal; }
  .driver-table td::before { content: attr(data-label); color: var(--muted); font-size: 10px; text-align: left; flex: none; }
  .driver-table .t-sub { display: none; }
}
@media (max-width: 380px) {
  .driver-stats, .driver-metrics, .driver-vehicle-bottom, .driver-trip-metrics { grid-template-columns: minmax(0, 1fr); }
  .driver-hero { min-height: 350px; }
  .driver-truck-stage span { display: none; }
  .driver-truck-stage img { width: 100%; }
}
.drv-hero { display: grid; grid-template-columns: auto 1fr auto; gap: 20px; align-items: center; }
.status-pill { display: inline-flex; align-items: center; gap: 8px; padding: 6px 12px; border-radius: 20px; font-size: 12.5px; font-weight: 600; background: rgba(255, 255, 255, .14); border: 1px solid rgba(255, 255, 255, .2); }
.status-pill i { width: 8px; height: 8px; border-radius: 50%; background: #34d399; box-shadow: 0 0 0 3px rgba(52, 211, 153, .3); }
.status-pill.off i { background: #94a3b8; box-shadow: none; }
.big-actions { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 10px; }
.big-actions .btn { height: 56px; border-radius: 14px; font-size: 14px; }

/* ======================================================= Sayfa parcalari */
.kpi-of { font-size: 14px; font-weight: 700; color: var(--muted); letter-spacing: 0; margin-left: 2px; }
.scroll-y { max-height: 380px; overflow-y: auto; margin: -6px -8px; padding: 6px 8px; }

.mini-stats { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; margin-top: 18px; padding-top: 16px; border-top: 1px dashed var(--border); }
.mini-stats div { display: grid; gap: 2px; }
.mini-stats span { font-size: 11.5px; color: var(--muted); }
.mini-stats b { font: 800 17px var(--font-head); letter-spacing: -.02em; }

.fin-sum { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 12px; margin-bottom: 14px; }
.fin-sum > div { padding: 12px 14px; border-radius: 14px; background: var(--surface-2); border: 1px solid var(--border); display: grid; gap: 2px; align-content: start; }
.fin-sum span { font-size: 11.5px; color: var(--muted); }
.fin-sum b { font: 800 19px var(--font-head); letter-spacing: -.02em; }
.fin-sum .trend { justify-self: start; margin-top: 4px; font-style: normal; }

.route-sm { display: inline-flex; align-items: center; gap: 6px; font-weight: 500; white-space: nowrap; }
.route-sm .ic { color: var(--muted); }
.route-big { display: grid; grid-template-columns: auto 1fr auto; gap: 16px; align-items: center; padding: 16px 18px; margin-bottom: 14px; border-radius: 16px; background: linear-gradient(135deg, color-mix(in srgb, var(--accent) 7%, var(--surface)), var(--surface-2)); border: 1px solid var(--border); }
.route-big small { display: block; font-size: 11.5px; color: var(--muted); }
.route-big b { font: 800 19px var(--font-head); letter-spacing: -.02em; }
.route-big.lg b { font-size: 22px; }
.route-line { position: relative; display: flex; align-items: center; gap: 10px; color: var(--accent); }
.route-line span { flex: 1; height: 3px; border-radius: 3px; background: repeating-linear-gradient(90deg, var(--border-strong) 0 8px, transparent 8px 14px); position: relative; overflow: hidden; }
.route-line span { min-width: 0; }
.route-line span:first-child::after { content: ""; position: absolute; inset: 0; background: var(--grad); border-radius: 3px; }
.route-line > .ic { flex: none; width: 38px; height: 38px; padding: 9px; border-radius: 50%; background: var(--surface); border: 2px solid currentColor; box-shadow: 0 6px 16px -8px currentColor; }
.route-line.t-ok { color: var(--ok); }
.route-line.t-warn { color: var(--warn); }
.route-line.t-danger { color: var(--danger); }
.route-line.t-info { color: var(--info); }
.route-line.t-violet { color: var(--violet); }

.steps { display: flex; gap: 4px; }
.steps i { width: 22px; height: 6px; border-radius: 4px; background: var(--surface-3); }
.steps i.on { background: var(--grad); }

.hero-dash.drv { grid-template-columns: minmax(0, 1fr) auto; }
.hero-dash.drv .avatar { border: 3px solid rgba(255, 255, 255, .35); }
.hero-dash.drv h2 { margin-top: 10px; }

.load-top { display: grid; grid-template-columns: minmax(300px, 1.1fr) minmax(280px, .9fr); gap: 20px; align-items: start; }
.load-meter { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; margin-top: 12px; }
.load-meter > div { padding: 12px 14px; border-radius: 14px; background: var(--surface-2); border: 1px solid var(--border); }
.load-meter span { font-size: 11.5px; color: var(--muted); }
.load-meter b { display: block; font: 800 16px var(--font-head); margin: 2px 0 8px; }
.load-meter b small { font: 500 12px var(--font); color: var(--muted); }
.load-meter .fill-cell { min-width: 0; }
.trip-strip { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; padding: 10px 12px; border-radius: 12px; background: var(--surface-2); border: 1px solid var(--border); }

.badge.live { height: 34px; padding: 0 14px; font-size: 12.5px; }
.badge.live > i { animation: blink 1.2s infinite; }
.map-row.on { background: var(--accent-soft); }
.map-panel .tabs { margin: 0 0 6px; width: 100%; padding: 3px; box-shadow: none; }
.map-panel .tabs button { flex: 1; height: 30px; padding: 0 8px; font-size: 12px; justify-content: center; }
.map-pop { font: 13px var(--font); min-width: 220px; color: #0f172a; }
.map-pop .muted { color: #64748b; }
.mp-row { display: flex; align-items: center; gap: 7px; padding: 2px 0; color: #334155; }
.mp-row .ic { color: #94a3b8; }
.mp-trip { margin-top: 8px; padding: 8px 10px; border-radius: 10px; background: #eef2ff; color: #3730a3; font-size: 12px; }

.date-range { display: inline-flex; align-items: center; gap: 6px; height: 38px; padding: 0 6px 0 12px; border-radius: 11px; border: 1px solid var(--border-strong); background: var(--surface); color: var(--muted); }
.date-range .input { height: 30px; border: 0; padding: 0 4px; width: 132px; background: transparent; box-shadow: none !important; font-size: 13px; }
.date-range span { color: var(--muted); }

.fuel-calc { display: flex; align-items: stretch; gap: 8px; flex-wrap: wrap; }
.fuel-calc > div:not(.op) { flex: 1; min-width: 110px; padding: 12px 14px; border-radius: 14px; background: var(--surface-2); border: 1px solid var(--border); }
.fuel-calc span { display: block; font-size: 11.5px; color: var(--muted); }
.fuel-calc b { font: 800 18px var(--font-head); font-variant-numeric: tabular-nums; }
.fuel-calc .op { display: grid; place-items: center; font: 800 20px var(--font-head); color: var(--muted); }
.fuel-calc .sum { background: var(--grad) !important; border: 0 !important; color: #fff; box-shadow: 0 10px 22px -12px rgba(79, 70, 229, .9); }
.fuel-calc .sum span { color: rgba(255, 255, 255, .8); }

.drv-card { display: flex; gap: 16px; align-items: center; margin-bottom: 14px; }
.doc-grid .docs { grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); }

.profile-card { overflow: hidden; }
.profile-cover { height: 110px; background: radial-gradient(300px 120px at 80% 0%, rgba(236, 72, 153, .5), transparent 60%), linear-gradient(120deg, #1e2a8a, #3b3bd1 50%, #6d38e0); }
.profile-card .avatar { border: 4px solid var(--surface); box-shadow: var(--shadow-md); }

.theme-pick { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 14px; }
.theme-opt { display: grid; gap: 12px; padding: 12px; border-radius: 16px; border: 2px solid var(--border); background: var(--surface); color: var(--text); font: inherit; font-weight: 600; cursor: pointer; text-align: left; transition: border-color .15s, box-shadow .15s; }
.theme-opt:hover { border-color: color-mix(in srgb, var(--accent) 40%, var(--border)); }
.theme-opt.on { border-color: var(--accent); box-shadow: 0 0 0 4px color-mix(in srgb, var(--accent) 15%, transparent); }
.tp-prev { position: relative; display: block; height: 110px; border-radius: 12px; overflow: hidden; }
.tp-prev.light { background: #f3f5fb; border: 1px solid #e5e9f2; }
.tp-prev.dark { background: #080d1c; border: 1px solid #1f2a47; }
.tp-prev i { position: absolute; left: 0; top: 0; bottom: 0; width: 28%; background: linear-gradient(180deg, #0b1230, #121b4a); }
.tp-prev b { position: absolute; left: 34%; top: 14px; right: 10px; height: 22px; border-radius: 6px; background: linear-gradient(120deg, #3b3bd1, #6d38e0); }
.tp-prev em { position: absolute; left: 34%; top: 46px; right: 10px; bottom: 12px; border-radius: 6px; }
.tp-prev.light em { background: #fff; border: 1px solid #e5e9f2; }
.tp-prev.dark em { background: #0f1629; border: 1px solid #1f2a47; }

@media (max-width: 1100px) {
  .load-top { grid-template-columns: 1fr; }
  .fin-sum { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 900px) {
  .route-big { grid-template-columns: 1fr; }
  .route-big .right { text-align: left; }
  .route-line { display: none; }
  .hero-dash.drv, .drv-hero { grid-template-columns: 1fr; }
  .mini-stats { grid-template-columns: 1fr 1fr; }
}

/* ================================================================= Mobil */
@media (max-width: 1280px) {
  .clock { display: none; }
  .searchbar { width: 260px; }
}

@media (max-width: 1100px) {
  .g-main, .g-side { grid-template-columns: minmax(0, 1fr); }
  .grid { grid-template-columns: minmax(0, 1fr); }
  .login { grid-template-columns: 1fr; }
  .login-hero { display: none; }
  .brand-sm { display: flex; }
  .hero-dash { grid-template-columns: 1fr; }
  .hd-r { justify-content: flex-start; flex-wrap: wrap; }
  .map-panel { position: static; width: auto; height: 260px; margin-top: 12px; }
  .map-wrap { height: auto; overflow: visible; border: 0; box-shadow: none; background: none; }
  #map { position: relative; height: 380px; border-radius: var(--radius); overflow: hidden; border: 1px solid var(--border); }
}

@media (max-width: 900px) {
  .side { position: fixed; left: 0; top: 0; transform: translateX(-100%); transition: transform .22s ease; width: var(--side-w) !important; }
  .shell.open .side { transform: none; }
  .shell.open .side-backdrop { display: block; position: fixed; inset: 0; z-index: 55; background: rgba(8, 12, 32, .5); backdrop-filter: blur(3px); }
  .shell.mini .brand-t, .shell.mini .nav-t, .shell.mini .nav-sec span, .shell.mini .side-widget, .shell.mini .su-t, .shell.mini .su-out { display: revert; }
  .searchbar { width: 44px; padding: 0; justify-content: center; }
  .searchbar span, .searchbar kbd, .uc-t, .user-chip > .ic, .crumbs span, .crumbs > .ic { display: none; }
  .top { padding: 0 14px; }
  .content { padding: 16px 14px 24px; }
  .form-grid { grid-template-columns: 1fr; }
  .phead h2 { font-size: 21px; }
  .phead-ic { width: 46px; height: 46px; }
  .hero-dash { padding: 22px; }
  .hero-dash h2 { font-size: 23px; }
  .hd-r { flex-direction: column; align-items: stretch; }
  .hd-r .gauge { margin: 0 auto; }
  .hd-pills { grid-template-columns: 1fr 1fr; }
  .hd-pill { min-width: 0; }
  .flow, .demo-grid { grid-template-columns: 1fr; }
  .kv { grid-template-columns: 120px 1fr; }
  .modal-body { max-height: calc(100vh - 190px); }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .001ms !important; animation-delay: 0s !important; transition-duration: .001ms !important; }
  .area-line { stroke-dashoffset: 0; }
}

@media print {
  .side, .top, .toolbar, .btn, .pager, .foot, .tabs { display: none !important; }
  body { background: #fff; }
  .content { padding: 0; }
  .card, .kpi { box-shadow: none; border-color: #ccc; }
}

/* Kismi yukleme: yuk basina adet girisi */
.qty { display: inline-flex; align-items: center; gap: 6px; white-space: nowrap; }
.qty .input { width: 76px; height: 32px; padding: 0 8px; text-align: center; font-weight: 700; }
.qty .of { color: var(--muted); font-size: 12.5px; }
table.table tbody tr.no-fit td { opacity: .5; cursor: not-allowed; }
table.table tbody tr.no-fit td:last-child { opacity: 1; }

/* Yukleme miktari penceresi */
.choice { border: 1px solid var(--border); border-radius: 14px; padding: 14px 16px; background: var(--surface); }
.choice-head { display: flex; align-items: baseline; justify-content: space-between; gap: 10px; margin-bottom: 10px; }
.choice-or { display: flex; align-items: center; gap: 12px; margin: 10px 0; color: var(--muted); font-size: 12.5px; text-transform: uppercase; letter-spacing: .06em; }
.choice-or::before, .choice-or::after { content: ""; flex: 1; height: 1px; background: var(--border); }
.qty-field { display: flex; flex-direction: column; gap: 4px; font-size: 12.5px; color: var(--text-2); font-weight: 600; }

/* Liste araclari: eklenme tarihi filtresi ve filtreleri temizle */
.date-range .dr-l { font-size: 12.5px; font-weight: 600; color: var(--text-2); white-space: nowrap; }
.toolbar .hidden { display: none; }
