/* UYSA Kokpit v2 — AÇIK TEMA (CateringPro broşürü esinli).
   Beyaz kartlar, açık zemin, turuncu birincil renk, yumuşak gölge, yuvarlak köşe.
   Kendine yeten: Bootstrap grid'e bağımlı değil; sadece bootstrap-icons (dekoratif) CDN.
   Referans: vault/projeler/uysa-erp-v2/referans/cateringpro-brosur-1.jpg (sol mobil ekranlar). */
:root {
  --bg: #eef3f8;
  --surface: #ffffff;
  --surface-2: #f4f7fb;
  --surface-3: #e9eff6;
  --line: rgba(16, 32, 51, 0.09);
  --line-2: rgba(16, 32, 51, 0.06);
  --text: #14233b;
  --muted: #6b7b8d;

  --primary: #0e6e74; /* koyu turkuaz — UYSA Kokpit */
  --primary-600: #0a565b;
  --primary-tint: #e4f4f4;
  --primary-tint-2: #c2e7e6;

  --green: #16a34a;
  --green-tint: #e7f6ee;
  --blue: #2563eb;
  --blue-tint: #e8f0fe;
  --amber: #d97706;
  --amber-tint: #fdf1dd;
  --red: #e5484d;
  --red-tint: #fdeaea;

  --radius: 16px;
  --radius-sm: 12px;
  --shadow: 0 6px 22px rgba(20, 40, 80, 0.07), 0 1px 2px rgba(20, 40, 80, 0.04);
  --shadow-sm: 0 2px 8px rgba(20, 40, 80, 0.05);
}
* {
  box-sizing: border-box;
}
html {
  min-height: 100%;
  background: var(--bg);
  scroll-behavior: smooth;
}
body {
  min-height: 100%;
  margin: 0;
  background:
    radial-gradient(
      circle at 50% -8%,
      rgba(14, 110, 116, 0.1),
      transparent 30rem
    ),
    linear-gradient(180deg, #f2f6fa 0%, #eef3f8 100%);
  color: var(--text);
  font-family:
    -apple-system, BlinkMacSystemFont, "SF Pro Text", system-ui, Inter,
    "Segoe UI", sans-serif;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  overflow-x: hidden;
  -webkit-tap-highlight-color: transparent;
}
a {
  color: inherit;
  text-decoration: none;
}

.app-shell {
  width: 100%;
  max-width: 400px;
  min-height: 100vh;
  margin: 0 auto;
  padding: 18px 15px calc(122px + env(safe-area-inset-bottom));
  position: relative;
  overflow-x: hidden;
}

.topbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  min-height: 48px;
  margin-bottom: 18px;
}
.brand-mark {
  width: 42px;
  height: 42px;
  border-radius: 12px;
  display: grid;
  place-items: center;
  background: linear-gradient(135deg, var(--primary), #14a8a0);
  color: #fff;
  font-weight: 900;
  box-shadow: 0 6px 16px rgba(14, 110, 116, 0.32);
}
.brand-copy {
  min-width: 0;
}
.eyebrow {
  margin: 0;
  color: var(--muted);
  font-size: 12px;
  line-height: 1.25;
}
h1,
h2,
h3,
p {
  margin-top: 0;
}
h1 {
  margin-bottom: 2px;
  font-size: 22px;
  line-height: 1.18;
  font-weight: 800;
  letter-spacing: -0.01em;
}
h2 {
  margin-bottom: 12px;
  font-size: 16px;
  line-height: 1.25;
  font-weight: 780;
}
h3 {
  margin-bottom: 6px;
  font-size: 14px;
  line-height: 1.25;
  font-weight: 750;
}

.icon-btn,
.chip,
.btn-action,
.step-btn,
.tab-item {
  min-height: 44px;
}
.icon-btn {
  width: 44px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: var(--surface);
  color: var(--text);
  display: grid;
  place-items: center;
  cursor: pointer;
  box-shadow: var(--shadow-sm);
}

.screen-stack {
  display: grid;
  gap: 13px;
}
.cardx {
  min-width: 0;
  border: 1px solid var(--line-2);
  border-radius: var(--radius);
  background: var(--surface);
  box-shadow: var(--shadow);
  overflow: hidden;
}
.card-pad {
  padding: 16px;
}

/* ── Broşür "Panel" — 3 yumuşak renkli istatistik kartı ─────── */
.stat-stack {
  display: grid;
  gap: 11px;
}
.stat-card {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 15px 16px;
  border-radius: var(--radius);
  border: 1px solid var(--line-2);
  box-shadow: var(--shadow-sm);
  min-width: 0;
}
.stat-card .ico {
  width: 46px;
  height: 46px;
  flex: 0 0 auto;
  border-radius: 13px;
  display: grid;
  place-items: center;
  font-size: 21px;
  background: #fff;
}
.stat-card .txt {
  min-width: 0;
}
.stat-card .lbl {
  margin: 0 0 3px;
  font-size: 12.5px;
  font-weight: 650;
  color: var(--muted);
}
.stat-card .val {
  margin: 0;
  font-size: 24px;
  line-height: 1.1;
  font-weight: 850;
  letter-spacing: -0.01em;
  overflow-wrap: anywhere;
}
.stat-green {
  background: var(--green-tint);
}
.stat-green .ico {
  color: var(--green);
}
.stat-green .val {
  color: #12813b;
}
.stat-orange {
  background: var(--primary-tint);
}
.stat-orange .ico {
  color: var(--primary);
}
.stat-orange .val {
  color: var(--primary-600);
}
.stat-blue {
  background: var(--blue-tint);
}
.stat-blue .ico {
  color: var(--blue);
}
.stat-blue .val {
  color: #1d4ed8;
}

/* ── Klasik özet kartları (finans/rapor/cari) — beyaz ──────── */
.summary-grid {
  min-width: 0;
  display: grid;
  grid-template-columns: 1fr;
  gap: 10px;
}
.summary-card {
  min-width: 0;
  padding: 14px;
  border: 1px solid var(--line-2);
  border-radius: var(--radius);
  background: var(--surface);
  box-shadow: var(--shadow-sm);
}
.summary-card.wide {
  grid-column: 1 / -1;
}
.summary-card.tint-green {
  background: var(--green-tint);
  border-color: transparent;
}
.summary-card.tint-orange {
  background: var(--primary-tint);
  border-color: transparent;
}
.summary-card.tint-blue {
  background: var(--blue-tint);
  border-color: transparent;
}
.label {
  margin: 0 0 5px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 600;
}
.metric {
  margin: 0;
  font-size: clamp(19px, 5.1vw, 23px);
  line-height: 1.12;
  font-weight: 850;
  overflow-wrap: anywhere;
  word-break: break-word;
  letter-spacing: -0.01em;
}
.metric.small {
  font-size: 18px;
}
.metric.pos {
  color: var(--green);
}
.metric.neg {
  color: var(--red);
}
.delta {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  color: var(--green);
  font-size: 12px;
  font-weight: 700;
  margin-top: 4px;
}
.delta.warn {
  color: var(--amber);
}

.date-row,
.segmented,
.actions-row {
  display: flex;
  align-items: center;
  gap: 8px;
}
.date-row {
  justify-content: space-between;
}
.segmented {
  flex-wrap: wrap;
}
.date-pill,
.chip {
  border: 1px solid var(--line);
  border-radius: 12px;
  background: var(--surface);
  color: var(--text);
  box-shadow: var(--shadow-sm);
}
.date-pill {
  padding: 10px 13px;
  min-height: 44px;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-weight: 700;
}
.date-pill input {
  border: 0;
  background: transparent;
  color: var(--text);
  font: inherit;
  font-weight: 700;
}
.chip {
  padding: 0 14px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: var(--muted);
  font-size: 13px;
  font-weight: 700;
  cursor: pointer;
}
.chip.active {
  background: var(--primary);
  border-color: var(--primary);
  color: #fff;
  box-shadow: 0 4px 12px rgba(14, 110, 116, 0.28);
}
/* Tek-dokunuş "dünkü ile aynı" — sayı alanını doldurur (ios-011) */
.chip-fill {
  gap: 6px;
  border-color: var(--primary);
  color: var(--primary);
  background: var(--surface);
}

/* ── Bölüm başlığı (kart dışı) ─────────────────────────────── */
.section-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin: 4px 2px -2px;
}
.section-head h2 {
  margin: 0;
}
.section-head .link {
  color: var(--primary);
  font-size: 13px;
  font-weight: 750;
}

.customer-row {
  min-width: 0;
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(104px, 118px);
  gap: 10px;
  align-items: center;
  padding: 13px 0;
  border-top: 1px solid var(--line-2);
}
.customer-row:first-child {
  border-top: 0;
  padding-top: 2px;
}
.customer-row.missing {
  background: linear-gradient(90deg, var(--amber-tint), transparent 72%);
  margin-inline: -16px;
  padding-inline: 16px;
}
.customer-row > div {
  min-width: 0;
}
.row-title {
  display: flex;
  align-items: center;
  gap: 8px;
  min-width: 0;
}
.row-title strong {
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  font-weight: 720;
}
.row-meta {
  margin: 4px 0 0;
  color: var(--muted);
  font-size: 12px;
}
.status-dot {
  width: 9px;
  height: 9px;
  border-radius: 999px;
  background: var(--green);
  flex: 0 0 auto;
}
.status-dot.warn {
  background: var(--amber);
}

.counter {
  display: grid;
  grid-template-columns: 36px minmax(0, 1fr) 36px;
  align-items: center;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: var(--surface-2);
  min-height: 44px;
  overflow: hidden;
  min-width: 0;
}
.step-btn {
  border: 0;
  background: transparent;
  color: var(--primary);
  font-size: 20px;
  font-weight: 800;
  cursor: pointer;
}
.count-input {
  width: 100%;
  border: 0;
  background: transparent;
  color: var(--text);
  text-align: center;
  font-size: clamp(16px, 4.5vw, 18px);
  font-weight: 850;
  outline: 0;
  -moz-appearance: textfield;
}
.count-input::-webkit-outer-spin-button,
.count-input::-webkit-inner-spin-button {
  -webkit-appearance: none;
  margin: 0;
}

.btn-action {
  border: 0;
  border-radius: 12px;
  padding: 0 16px;
  min-height: 46px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  font-weight: 800;
  font: inherit;
  font-weight: 800;
  cursor: pointer;
}
.btn-primaryx {
  background: linear-gradient(135deg, var(--primary), #14a8a0);
  color: #fff;
  box-shadow: 0 8px 18px rgba(14, 110, 116, 0.3);
}
.btn-secondaryx {
  background: var(--surface);
  border: 1px solid var(--line);
  color: var(--text);
  box-shadow: var(--shadow-sm);
}
.btn-ghost {
  background: transparent;
  border: 1px solid var(--line);
  color: var(--muted);
}
.btn-full {
  width: 100%;
}

.hint-card {
  padding: 13px 14px;
  border: 1px solid var(--primary-tint-2);
  border-radius: var(--radius);
  background: var(--primary-tint);
  color: #0a4a4e;
  font-size: 13px;
  overflow-wrap: anywhere;
}

.list-groupx {
  display: grid;
  gap: 9px;
}
.flow-item {
  display: grid;
  grid-template-columns: 42px minmax(0, 1fr) auto;
  gap: 11px;
  align-items: center;
  padding: 12px;
  border: 1px solid var(--line-2);
  border-radius: var(--radius-sm);
  background: var(--surface);
  box-shadow: var(--shadow-sm);
}
.flow-icon {
  width: 42px;
  height: 42px;
  border-radius: 12px;
  display: grid;
  place-items: center;
  background: var(--green-tint);
  color: var(--green);
}
.flow-icon.out {
  background: var(--red-tint);
  color: var(--red);
}
.amount {
  font-weight: 850;
  white-space: nowrap;
}
.amount.out {
  color: var(--red);
}
.amount.in {
  color: var(--green);
}

.badge-soft {
  min-height: 26px;
  border-radius: 999px;
  padding: 4px 10px;
  display: inline-flex;
  align-items: center;
  gap: 5px;
  font-size: 12px;
  font-weight: 800;
}
.badge-ok {
  background: var(--green-tint);
  color: var(--green);
}
.badge-warn {
  background: var(--amber-tint);
  color: var(--amber);
}
.badge-blue {
  background: var(--blue-tint);
  color: var(--blue);
}
.badge-orange {
  background: var(--primary-tint);
  color: var(--primary-600);
}
.badge-neg {
  background: var(--red-tint);
  color: var(--red);
}

.fab-sheet {
  border: 1px solid var(--line-2);
  border-radius: var(--radius);
  background: var(--surface);
  padding: 16px;
  box-shadow: var(--shadow);
}
.form-grid {
  display: grid;
  gap: 11px;
}
.field {
  display: grid;
  gap: 6px;
}
.field label {
  color: var(--muted);
  font-size: 12px;
  font-weight: 700;
}
.inputx,
.selectx,
.textareax {
  min-height: 46px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: var(--surface);
  color: var(--text);
  padding: 11px 13px;
  font: inherit;
  width: 100%;
}
.inputx:focus,
.selectx:focus,
.textareax:focus {
  outline: 0;
  border-color: var(--primary);
  box-shadow: 0 0 0 3px var(--primary-tint);
}
.textareax {
  min-height: 92px;
  resize: none;
}

.tablex {
  width: 100%;
  border-collapse: collapse;
  font-size: 13px;
}
.tablex th,
.tablex td {
  padding: 10px 8px;
  border-bottom: 1px solid var(--line-2);
  vertical-align: middle;
}
.tablex th {
  color: var(--muted);
  font-size: 11px;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.02em;
}
.tablex tr:last-child td {
  border-bottom: 0;
}
.tablex td.num,
.tablex th.num {
  text-align: right;
  font-variant-numeric: tabular-nums;
}
.tablex tr.is-total td {
  font-weight: 850;
  border-top: 2px solid var(--line);
  background: var(--surface-2);
}

/* ── Bar grafik (broşür "Bugün Sipariş Veren Firmalar") ─────── */
.barchart {
  display: grid;
  gap: 9px;
  margin-top: 4px;
}
.bar-row {
  display: grid;
  grid-template-columns: 84px minmax(0, 1fr) 44px;
  align-items: center;
  gap: 9px;
}
.bar-name {
  font-size: 12px;
  font-weight: 700;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  color: var(--text);
}
.bar-track {
  height: 12px;
  border-radius: 999px;
  background: var(--surface-3);
  overflow: hidden;
}
.bar-fill {
  height: 100%;
  border-radius: 999px;
  background: linear-gradient(90deg, var(--primary), #2cc2b6);
  min-width: 4px;
}
.bar-val {
  font-size: 12px;
  font-weight: 800;
  text-align: right;
  font-variant-numeric: tabular-nums;
  color: var(--muted);
}

/* ── Drill-down (rapor müşteri günlük) ─────────────────────── */
.mini-cal {
  width: 100%;
  border-collapse: collapse;
  font-size: 12.5px;
}
.mini-cal th,
.mini-cal td {
  padding: 9px 6px;
  border-bottom: 1px solid var(--line-2);
  text-align: right;
  font-variant-numeric: tabular-nums;
}
.mini-cal th:first-child,
.mini-cal td:first-child {
  text-align: left;
}
.mini-cal th {
  color: var(--muted);
  font-size: 10.5px;
  font-weight: 800;
  text-transform: uppercase;
}
.mini-cal tr.is-total td {
  font-weight: 850;
  border-top: 2px solid var(--line);
  background: var(--surface-2);
}

.empty-state {
  padding: 20px;
  text-align: center;
  color: var(--muted);
  border: 1px dashed var(--line);
  border-radius: var(--radius);
  background: var(--surface-2);
}

/* ── Günün menüsü kartı (broşür yeşil tonu) ────────────────── */
.meal-card {
  padding: 15px 16px;
  border-radius: var(--radius);
  border: 1px solid var(--line-2);
  background: var(--green-tint);
  box-shadow: var(--shadow-sm);
}
.meal-card .label {
  color: #12813b;
}
.meal-card h2 {
  margin: 0;
  color: #0f6b32;
}

/* ── Talep mesaj dizisi (sohbet balonları) ─────────────────── */
.msg-thread {
  display: grid;
  gap: 9px;
  padding: 4px 0;
}
.msg {
  max-width: 86%;
  padding: 10px 12px;
  border-radius: 14px;
  box-shadow: var(--shadow-sm);
}
.msg.mine {
  justify-self: end;
  background: var(--primary-tint);
  border: 1px solid var(--primary-tint-2);
  border-bottom-right-radius: 4px;
}
.msg.theirs {
  justify-self: start;
  background: var(--surface-2);
  border: 1px solid var(--line-2);
  border-bottom-left-radius: 4px;
}
.msg-body {
  margin: 0;
  font-size: 13.5px;
  line-height: 1.4;
  overflow-wrap: anywhere;
}
.msg-meta {
  display: block;
  margin-top: 5px;
  font-size: 10.5px;
  color: var(--muted);
  font-weight: 700;
}

/* Müşteri alt-nav 6 sekme (FAB yok) */
.customer .bottom-tabs,
body.customer-page .bottom-tabs {
  grid-template-columns: repeat(6, minmax(0, 1fr));
}

/* ── Modül grid'i (broşür alt kartları: Stok, Reçete, Faturalar…) ─ */
.mod-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 11px;
}
.mod-card {
  position: relative;
  display: flex;
  flex-direction: column;
  gap: 9px;
  padding: 14px;
  border-radius: var(--radius);
  background: var(--surface);
  border: 1px solid var(--line-2);
  box-shadow: var(--shadow-sm);
  min-height: 104px;
}
.mod-card .mico {
  width: 42px;
  height: 42px;
  border-radius: 12px;
  display: grid;
  place-items: center;
  font-size: 20px;
  background: var(--primary-tint);
  color: var(--primary);
}
.mod-card.i-green .mico {
  background: var(--green-tint);
  color: var(--green);
}
.mod-card.i-blue .mico {
  background: var(--blue-tint);
  color: var(--blue);
}
.mod-card.i-amber .mico {
  background: var(--amber-tint);
  color: var(--amber);
}
.mod-card .mt {
  font-weight: 780;
  font-size: 14px;
  line-height: 1.2;
}
.mod-card .md {
  font-size: 11.5px;
  color: var(--muted);
  line-height: 1.3;
  margin-top: auto;
}
.mod-card.soon {
  opacity: 0.9;
}
.mod-card .soon-chip {
  position: absolute;
  top: 11px;
  right: 11px;
  font-size: 9.5px;
  font-weight: 800;
  padding: 3px 8px;
  border-radius: 999px;
  background: var(--amber-tint);
  color: var(--amber);
}

/* Placeholder ("yakında") ekran görseli */
.soon-hero {
  display: grid;
  place-items: center;
  gap: 14px;
  padding: 34px 20px;
  text-align: center;
}
.soon-hero .big-ico {
  width: 76px;
  height: 76px;
  border-radius: 22px;
  display: grid;
  place-items: center;
  font-size: 34px;
  background: var(--primary-tint);
  color: var(--primary);
}

/* ── Alt navigasyon + ortada turuncu (+) FAB ──────────────── */
.bottom-tabs {
  position: fixed;
  left: 50%;
  transform: translateX(-50%);
  bottom: 0;
  z-index: 20;
  width: 100%;
  max-width: 400px;
  display: grid;
  grid-template-columns: 1fr 1fr 68px 1fr 1fr;
  align-items: end;
  gap: 2px;
  padding: 8px 8px calc(9px + env(safe-area-inset-bottom));
  border-top: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.96);
  backdrop-filter: blur(14px);
  box-shadow: 0 -6px 20px rgba(20, 40, 80, 0.06);
}
.tab-item {
  min-width: 0;
  border-radius: 12px;
  display: grid;
  place-items: center;
  gap: 3px;
  color: var(--muted);
  font-size: 11px;
  font-weight: 700;
  padding: 6px 2px;
  white-space: nowrap;
}
.tab-item i {
  font-size: 19px;
}
.tab-item.active {
  color: var(--primary);
}
.tab-item .soon {
  font-size: 9px;
  color: var(--amber);
}
.fab-slot {
  position: relative;
  display: grid;
  place-items: center;
}
.fab {
  position: absolute;
  bottom: 4px;
  width: 58px;
  height: 58px;
  border: 0;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--primary), #14a8a0);
  color: #fff;
  font-size: 28px;
  display: grid;
  place-items: center;
  cursor: pointer;
  box-shadow: 0 10px 22px rgba(14, 110, 116, 0.42);
}
.fab i {
  font-size: 26px;
}

/* FAB aksiyon menüsü (Cari/Menü dahil tüm hızlı işler) */
.fab-menu {
  position: fixed;
  left: 50%;
  transform: translateX(-50%);
  bottom: calc(84px + env(safe-area-inset-bottom));
  z-index: 25;
  width: min(92%, 372px);
  background: var(--surface);
  border: 1px solid var(--line-2);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: 8px;
  display: none;
}
.fab-menu.open {
  display: grid;
  gap: 2px;
}
.quick-tiles {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
  gap: 10px;
  margin-bottom: 13px;
}
.q-tile {
  display: flex;
  align-items: center;
  gap: 11px;
  padding: 13px 14px;
  border-radius: var(--radius-sm);
  background: var(--surface);
  border: 1px solid var(--line-2);
  box-shadow: var(--shadow-sm);
  font-weight: 750;
  font-size: 13.5px;
  min-height: 44px;
}
.q-tile i {
  font-size: 19px;
  color: var(--primary);
  flex: 0 0 auto;
}
.q-tile:active {
  background: var(--surface-2);
}
.q-tile .q-badge {
  margin-left: auto;
  font-size: 11px;
  font-weight: 800;
  padding: 2px 8px;
  border-radius: 999px;
  background: var(--red-tint);
  color: var(--red);
}
.fab-menu .fab-label {
  margin: 12px 6px 2px;
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  color: var(--muted);
}
.fab-menu .fab-label:first-child {
  margin-top: 2px;
}
.fab-menu a {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 12px;
  border-radius: 12px;
  font-weight: 700;
}
.fab-menu a:active {
  background: var(--surface-2);
}
.fab-menu a i {
  width: 34px;
  height: 34px;
  border-radius: 10px;
  display: grid;
  place-items: center;
  background: var(--primary-tint);
  color: var(--primary);
  font-size: 17px;
}
.fab-backdrop {
  position: fixed;
  inset: 0;
  z-index: 24;
  background: rgba(16, 32, 51, 0.28);
  display: none;
}
.fab-backdrop.open {
  display: block;
}

.login-shell {
  min-height: 100vh;
  width: min(100%, 430px);
  margin: 0 auto;
  padding: 40px 20px;
  display: grid;
  align-content: center;
}
.login-logo {
  width: 70px;
  height: 70px;
  border-radius: 18px;
  display: grid;
  place-items: center;
  margin-bottom: 18px;
  background: linear-gradient(135deg, var(--primary), #14a8a0);
  color: #fff;
  font-size: 30px;
  font-weight: 900;
  box-shadow: 0 12px 26px rgba(14, 110, 116, 0.34);
}

/* Flash / hata bildirimleri */
.flash {
  padding: 12px 14px;
  border-radius: var(--radius-sm);
  font-size: 13px;
  font-weight: 700;
}
.flash.ok {
  background: var(--green-tint);
  border: 1px solid rgba(22, 163, 74, 0.28);
  color: #12813b;
}
.flash.err {
  background: var(--red-tint);
  border: 1px solid rgba(229, 72, 77, 0.32);
  color: #b42318;
}

/* Küçük yardımcı sınıflar (Bootstrap yerine — kendine yeten) */
.d-flex {
  display: flex;
}
.align-items-center {
  align-items: center;
}
.align-items-end {
  align-items: end;
}
.justify-between {
  justify-content: space-between;
}
.gap-2 {
  gap: 8px;
}
.gap-3 {
  gap: 12px;
}
.flex-fill {
  flex: 1 1 auto;
}
.mt-1 {
  margin-top: 4px;
}
.mt-2 {
  margin-top: 8px;
}
.mt-3 {
  margin-top: 12px;
}
.mb-2 {
  margin-bottom: 8px;
}
.mb-3 {
  margin-bottom: 12px;
}
.mb-4 {
  margin-bottom: 18px;
}
.text-muted {
  color: var(--muted);
}

@media (min-width: 720px) {
  .app-shell,
  .login-shell {
    margin-inline: auto;
  }
  .bottom-tabs {
    left: 50%;
    transform: translateX(-50%);
  }
  .app-shell,
  .login-shell,
  .bottom-tabs {
    max-width: 520px;
  }
  .summary-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}
@media (max-width: 400px) {
  body.customer-page .tab-item {
    font-size: 10px;
    padding-inline: 0;
  }
  .summary-card.wide {
    grid-column: auto;
  }
  .customer-row {
    grid-template-columns: minmax(0, 1fr) 104px;
  }
  .counter {
    grid-template-columns: 32px minmax(0, 1fr) 32px;
  }
  .btn-action {
    padding-inline: 12px;
  }
  .bar-row {
    grid-template-columns: 72px minmax(0, 1fr) 40px;
  }
}

/* opus-010: menü hedef müşteri seçimi + malzeme talep/hakediş satırı */
.check-list {
  display: grid;
  gap: 0;
  max-height: 280px;
  overflow-y: auto;
  border: 1px solid var(--line-2);
  border-radius: 12px;
  padding: 2px 10px;
}
.check-row {
  display: flex;
  align-items: center;
  gap: 11px;
  padding: 10px 2px;
  border-top: 1px solid var(--line-2);
  font-size: 14px;
  cursor: pointer;
}
.check-row:first-child {
  border-top: 0;
}
.check-row input {
  width: 19px;
  height: 19px;
  accent-color: var(--primary);
  flex: 0 0 auto;
}
.supply-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 104px;
  gap: 10px;
  align-items: center;
  padding: 11px 0;
  border-top: 1px solid var(--line-2);
}
.supply-row:first-child {
  border-top: 0;
}
.supply-row .s-name {
  min-width: 0;
  font-weight: 650;
  font-size: 14px;
}
.supply-row .s-meta {
  color: var(--muted);
  font-size: 12px;
  margin-top: 2px;
}
.qty-input {
  min-height: 42px;
  text-align: center;
  padding-inline: 6px;
}
.ent-tag {
  display: inline-block;
  margin-top: 3px;
  font-size: 11.5px;
  font-weight: 800;
  color: var(--green);
  background: var(--green-tint);
  border-radius: 999px;
  padding: 2px 9px;
}

/* iOS/WKWebView: klavye açıkken fixed alt bar ekran ortasında asılı kalıyor →
   app.js body'ye .kb-open basar, bar+FAB gizlenir; klavye kapanınca geri gelir. */
body.kb-open .bottom-tabs,
body.kb-open .fab-menu,
body.kb-open .fab-backdrop {
  display: none;
}

/* Çevrimdışı şeridi (app.js netBanner) */
.net-banner {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 40;
  padding: 10px 14px calc(10px + env(safe-area-inset-top) * 0.3);
  padding-top: calc(10px + env(safe-area-inset-top));
  background: #b91c1c;
  color: #fff;
  font-size: 12.5px;
  font-weight: 700;
  text-align: center;
}

/* Native app köprüsü: login tonu, pull-to-refresh ve foreground push bildirimi. */
html.native-app [data-web-only] {
  display: none !important;
}
.native-login-note {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  text-align: left;
}
.native-login-note[hidden] {
  display: none !important;
}
.native-login-note i {
  color: var(--primary);
  font-size: 18px;
  line-height: 1.2;
}
.pull-refresh {
  position: fixed;
  left: 50%;
  top: calc(8px + env(safe-area-inset-top));
  z-index: 55;
  min-width: 112px;
  height: 38px;
  padding: 0 14px;
  border: 1px solid var(--line);
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  background: rgba(255, 255, 255, 0.98);
  color: var(--text);
  box-shadow: var(--shadow-sm);
  font-size: 11px;
  font-weight: 800;
  opacity: 0;
  transform: translate(-50%, -58px);
  transition:
    opacity 120ms ease,
    transform 120ms ease;
  pointer-events: none;
}
.pull-refresh.active {
  opacity: 1;
  transition: none;
}
.pull-refresh.armed {
  color: var(--primary);
}
.pull-refresh.refreshing i {
  animation: native-spin 700ms linear infinite;
}
.native-push-toast {
  appearance: none;
  position: fixed;
  left: 50%;
  top: calc(10px + env(safe-area-inset-top));
  z-index: 65;
  width: min(calc(100% - 24px), 372px);
  min-height: 58px;
  padding: 11px 13px;
  border: 1px solid var(--line);
  border-radius: 12px;
  display: grid;
  grid-template-columns: 32px minmax(0, 1fr);
  align-items: center;
  gap: 10px;
  background: rgba(255, 255, 255, 0.98);
  color: var(--text);
  box-shadow: 0 10px 28px rgba(20, 40, 80, 0.18);
  text-align: left;
  opacity: 0;
  transform: translate(-50%, -18px);
  transition:
    opacity 160ms ease,
    transform 160ms ease;
}
.native-push-toast.show {
  opacity: 1;
  transform: translate(-50%, 0);
}
.native-push-toast > i {
  color: var(--primary);
  font-size: 20px;
  text-align: center;
}
.native-push-toast span {
  min-width: 0;
  display: grid;
  gap: 2px;
}
.native-push-toast strong,
.native-push-toast small {
  display: block;
  overflow-wrap: anywhere;
  letter-spacing: 0;
}
.native-push-toast strong {
  font-size: 13px;
}
.native-push-toast small {
  color: var(--muted);
  font-size: 11.5px;
  line-height: 1.35;
}
@keyframes native-spin {
  to {
    transform: rotate(360deg);
  }
}
@media (prefers-reduced-motion: reduce) {
  .pull-refresh,
  .native-push-toast {
    transition: none;
  }
  .pull-refresh.refreshing i {
    animation: none;
  }
}
