/* ═══════════════════════════════════════════
   Design4Room — Kurumsal Kimlik v2
   Minimal & Modern · Pastel Aksan
═══════════════════════════════════════════ */

/* ── ROBOTO FONTS ── */
@font-face { font-family: 'Roboto'; src: url('fonts/Roboto-Variable.ttf') format('truetype'); font-weight: 600; font-style: normal; font-display: swap; }

/* ── JOST FONTS ── */
@font-face { font-family: 'JetBrains Mono'; src: url('fonts/JetBrainsMono-Variable.ttf') format('truetype'); font-weight: 100 800; font-style: normal; font-display: swap; }
@font-face { font-family: 'Cormorant Garamond'; src: url('fonts/CormorantGaramond-Variable.ttf') format('truetype'); font-weight: 300 700; font-style: normal; font-display: swap; }
@font-face { font-family: 'Jost'; src: url('fonts/Jost-Variable.ttf') format('truetype'); font-weight: 100 900; font-style: normal; font-display: swap; }
@font-face { font-family: 'Jost Light'; src: url('fonts/Jost-Variable.ttf') format('truetype'); font-weight: 350; font-style: normal; font-display: swap; }
@font-face { font-family: 'Jost Medium'; src: url('fonts/Jost-Variable.ttf') format('truetype'); font-weight: 500; font-style: normal; font-display: swap; }

/* ── RESET ── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

.document-open-link {
  padding: 0; border: 0; background: transparent; color: inherit;
  font: inherit; text-align: inherit; text-decoration: underline; cursor: pointer;
}
button.doc-open-link { padding: 0; border: 0; background: transparent; cursor: pointer; }
button.sio-document, button.psif-document { background: transparent; color: inherit; cursor: pointer; }

/* ── TOKENS ── */
:root {
  /* Ana Renkler */
  --primary:          #1F2328;
  --primary-hover:    #2C3138;
  --sage:             #B5C4C1;
  --sage-deep:        #7FA89F;
  --sand:             #D4BFA8;
  --sand-deep:        #B89E85;

  /* Nötrler */
  --bg:               #F5F3F0;
  --surface:          #FFFFFF;
  --border:           #E8E4DE;
  --text:             #1F2328;
  --text-muted:       #9A9590;

  /* Status — Pastel */
  --status-active:        #6A9E7F;
  --status-active-bg:     #EAF4EE;
  --status-completed:     #8B8E96;
  --status-completed-bg:  #EEEFF2;
  --status-pending:       #B8895A;
  --status-pending-bg:    #FAF1E6;
  --status-cancelled:     #B8606E;
  --status-cancelled-bg:  #FAECEE;

  /* Tipografi */
  --font-display: 'Cormorant Garamond', Georgia, serif;
  --font-body:    'Jost',  -apple-system, BlinkMacSystemFont, sans-serif;
  --font-mono:    'JetBrains Mono', 'Courier New', monospace;

  /* Boyut */
  --sidebar-w: 220px;
  --radius:    8px;
  --radius-lg: 12px;
  --shadow:    0 1px 3px rgba(0,0,0,.06), 0 1px 2px rgba(0,0,0,.04);
  --shadow-md: 0 4px 16px rgba(0,0,0,.08);
}

/* ── BASE ── */
body {
  font-family: var(--font-body);
  font-weight: 350;
  background: var(--bg);
  color: var(--text);
  display: flex;
  height: 100vh;
  overflow: hidden;
  font-size: 14px;
  -webkit-font-smoothing: antialiased;
}

/* ═══════════════════════════════════════════
   SIDEBAR — Koyu (marka gücü)
═══════════════════════════════════════════ */
.sidebar {
  width: var(--sidebar-w);
  background: var(--primary);
  display: flex;
  flex-direction: column;
  flex-shrink: 0;
  overflow-y: auto;
}

.sidebar-logo {
  padding: 18px 16px 16px;
  border-bottom: 1px solid rgba(255,255,255,.08);
  display: flex;
  align-items: center;
  justify-content: center;
}

.sidebar-logo a {
  display: block;
  line-height: 0;
  border-radius: 6px;
  transition: opacity .15s;
}
.sidebar-logo a:hover { opacity: .8; }

.sidebar-logo-img {
  width: 172px;
  height: auto;
  display: block;
}

a[href="dashboard.html"].nav-item svg { stroke: #D6A35C; }
.nav-item.active svg { stroke: #D6A35C; }

.logo-d4r {
  border: 1.5px solid var(--sage);
  color: var(--sage);
  font-family: var(--font-display);
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 1.5px;
  padding: 3px 6px;
  border-radius: 4px;
  flex-shrink: 0;
}

.logo-text {
  font-family: var(--font-display);
  font-size: 15px;
  font-weight: 300;
  color: rgba(255,255,255,.85);
  letter-spacing: 0.3px;
}

.sidebar-nav { padding: 14px 10px; flex: 1; }

.nav-group { margin-bottom: 22px; }

.nav-group-label {
  font-size: 9px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 2px;
  color: rgba(255,255,255,.28);
  padding: 0 8px;
  display: block;
  margin-bottom: 4px;
}

.nav-item {
  display: flex;
  align-items: center;
  gap: 9px;
  padding: 8px;
  border-radius: 6px;
  color: rgba(255,255,255,.5);
  text-decoration: none;
  font-size: 13px;
  transition: background .15s, color .15s;
  cursor: pointer;
}

.nav-item svg {
  width: 15px;
  height: 15px;
  stroke: currentColor;
  fill: none;
  stroke-width: 2;
  flex-shrink: 0;
}

.nav-item:hover {
  background: rgba(255,255,255,.06);
  color: rgba(255,255,255,.8);
}

.nav-item.active {
  background: rgba(255,255,255,.08);
  color: #fff;
}

.nav-item.disabled { opacity: .3; pointer-events: none; }

.nav-group-admin {
  margin-top: 6px;
  padding-top: 8px;
  border-top: 1px solid rgba(255,255,255,.07);
}
.nav-group-admin .nav-group-label { color: rgba(255,255,255,.18); }
.nav-group-admin .nav-item { opacity: .55; }
.nav-group-admin .nav-item:hover,
.nav-group-admin .nav-item.active { opacity: 1; }

/* ═══════════════════════════════════════════
   MAIN
═══════════════════════════════════════════ */
.main { flex: 1; display: flex; flex-direction: column; overflow: hidden; }

/* ── TOPBAR ── */
.topbar {
  background: var(--surface);
  border-bottom: 1px solid var(--border);
  padding: 0 24px;
  height: 58px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-shrink: 0;
}

.topbar-title { display: flex; align-items: baseline; gap: 10px; min-width: 0; flex-shrink: 1; overflow: hidden; }
.topbar-title h1 { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.topbar-actions { display: flex; align-items: center; gap: 8px; flex-shrink: 0; overflow-x: auto; max-width: 70%; }

.topbar-title h1 {
  font-family: var(--font-sans);
  font-size: 18px;
  font-weight: 600;
  letter-spacing: 0;
}

.record-count { font-size: 12px; color: var(--text-muted); }

/* ── BUTONLAR ── */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 8px 14px;
  border-radius: 7px;
  border: none;
  font-family: var(--font-body);
  font-size: 13px;
  font-weight: 500;
  cursor: pointer;
  transition: background .15s, box-shadow .15s;
}

.btn svg {
  width: 14px;
  height: 14px;
  stroke: currentColor;
  fill: none;
  stroke-width: 2;
}

.btn-primary { background: var(--primary); color: #fff; }
.btn-primary:hover { background: var(--primary-hover); }

.btn-secondary {
  background: var(--bg);
  color: var(--text);
  border: 1px solid var(--border);
}
.btn-secondary:hover { background: var(--border); }

.btn-danger { background: var(--status-cancelled); color: #fff; }
.btn-danger:hover { background: #a5535f; }

/* ── FILTERS BAR ── */
.filters-bar {
  padding: 10px 24px;
  background: var(--surface);
  border-bottom: 1px solid var(--border);
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
  flex-shrink: 0;
}

.client-overview {
  margin: 10px 24px 0;
  background:
    linear-gradient(120deg, rgba(75,115,160,.16), rgba(255,255,255,0) 55%),
    #edf3fa;
  border: 1px solid rgba(75,115,160,.22);
  border-radius: var(--radius-lg);
  padding: 20px 24px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
  box-shadow: 0 8px 26px rgba(31,35,40,.06);
  flex-shrink: 0;
}

.client-overview h2 {
  font-family: var(--font-mono);
  font-size: 32px;
  font-weight: 700;
  letter-spacing: .4px;
  color: var(--text);
  transform: translateY(5px);
}

.client-overview-metrics {
  display: flex;
  flex: 1;
  justify-content: flex-end;
  gap: 16px;
  text-align: right;
}

.client-overview-metric {
  width: 200px;
  flex-shrink: 0;
  padding: 7px 12px;
  border-radius: 7px;
  border: 1px solid rgba(0,0,0,.10);
  background: rgba(255,255,255,.66);
}

.client-overview-label {
  display: block;
  font-size: 9px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: .7px;
  color: var(--text-muted);
  margin-bottom: 3px;
}

.client-overview-metrics strong {
  font-family: var(--font-mono);
  font-size: 20px;
  font-weight: 700;
  color: var(--text);
  display: block;
  margin-top: 8px;
}

.client-overview-metric.active   { background: rgba(46,125,50,.09); border-color: rgba(46,125,50,.22); }
.client-overview-metric.active strong   { color: var(--status-active); }
.client-overview-metric.reconnect { background: rgba(184,137,90,.11); border-color: rgba(184,137,90,.28); }
.client-overview-metric.reconnect strong { color: #b8895a; }
.client-overview-metric.balance  { background: rgba(192,72,79,.09); border-color: rgba(192,72,79,.22); }
.client-overview-metric.balance strong  { color: #b8606e; }

.project-overview {
  margin: 10px 24px 0;
  background:
    linear-gradient(120deg, rgba(100,155,135,.20), rgba(255,255,255,0) 55%),
    #edf5f0;
  border: 1px solid rgba(100,155,135,.28);
  border-radius: var(--radius-lg);
  padding: 20px 24px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 20px;
  box-shadow: 0 8px 26px rgba(31,35,40,.06);
  flex-shrink: 0;
}

.project-overview h2 {
  font-family: var(--font-mono);
  font-size: 32px;
  font-weight: 700;
  letter-spacing: .4px;
  color: var(--text);
  transform: translateY(5px);
}

.project-overview-metrics {
  display: flex;
  flex: 1;
  justify-content: flex-end;
  gap: 16px;
  text-align: right;
}

.project-overview-metric {
  width: 200px;
  flex-shrink: 0;
  padding: 7px 12px;
  border-radius: 7px;
  border: 1px solid rgba(0,0,0,.10);
  background: rgba(255,255,255,.66);
}

.project-overview-label {
  display: block;
  font-size: 9px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: .7px;
  color: var(--text-muted);
  margin-bottom: 3px;
}

.project-overview-metrics strong {
  font-family: var(--font-mono);
  font-size: 20px;
  font-weight: 700;
  display: block;
  margin-top: 8px;
  color: var(--text);
}

.project-overview-metric.active  { background: rgba(46,125,50,.09); border-color: rgba(46,125,50,.22); }
.project-overview-metric.active strong  { color: var(--status-active); }
.project-overview-metric.overdue { background: rgba(192,72,79,.09); border-color: rgba(192,72,79,.22); }
.project-overview-metric.overdue strong { color: #b8606e; }
.project-overview-metric.invoice { background: rgba(184,137,90,.11); border-color: rgba(184,137,90,.28); }
.project-overview-metric.invoice strong { color: #b8895a; }
.project-overview-metric.balance { background: rgba(192,72,79,.09); border-color: rgba(192,72,79,.22); }
.project-overview-metric.balance strong { color: #b8606e; }

.contractor-overview {
  margin: 10px 24px 0;
  background:
    linear-gradient(120deg, rgba(180,140,80,.20), rgba(255,255,255,0) 55%),
    #f7f2ea;
  border: 1px solid rgba(180,140,80,.28);
  border-radius: var(--radius-lg);
  padding: 20px 24px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 20px;
  box-shadow: 0 8px 26px rgba(31,35,40,.06);
  flex-shrink: 0;
}

.contractor-overview h2 {
  font-family: var(--font-mono);
  font-size: 32px;
  font-weight: 700;
  letter-spacing: .4px;
  color: var(--text);
  transform: translateY(5px);
}

.contractor-overview-metrics {
  display: flex;
  flex: 1;
  justify-content: flex-end;
  gap: 16px;
  text-align: right;
}

.contractor-overview-metric {
  width: 200px;
  flex-shrink: 0;
  padding: 7px 12px;
  border-radius: 7px;
  border: 1px solid rgba(0,0,0,.10);
  background: rgba(255,255,255,.66);
}

.contractor-overview-label {
  display: block;
  font-size: 9px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: .7px;
  color: var(--text-muted);
  margin-bottom: 3px;
}

.contractor-overview-metrics strong {
  font-family: var(--font-mono);
  font-size: 20px;
  font-weight: 700;
  display: block;
  margin-top: 8px;
  color: var(--text);
}

.contractor-overview-metric.active  { background: rgba(46,125,50,.09); border-color: rgba(46,125,50,.22); }
.contractor-overview-metric.active strong  { color: var(--status-active); }
.contractor-overview-metric.overdue { background: rgba(192,72,79,.09); border-color: rgba(192,72,79,.22); }
.contractor-overview-metric.overdue strong { color: #b8606e; }
.contractor-overview-metric.current { background: rgba(184,137,90,.11); border-color: rgba(184,137,90,.28); }
.contractor-overview-metric.current strong { color: #b8895a; }
.contractor-overview-metric.payable { background: rgba(192,72,79,.09); border-color: rgba(192,72,79,.22); }
.contractor-overview-metric.payable strong { color: #b8606e; }

.module-table-heading {
  margin: 16px 24px 0;
  border: 1px solid rgba(31,35,40,.08);
  border-radius: 12px 12px 0 0;
  padding: 13px 18px;
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
  gap: 18px;
  flex-shrink: 0;
}

.module-table-heading h2 {
  margin: 0;
  font-size: 18px;
  font-weight: 700;
  letter-spacing: .5px;
  color: var(--text);
}

.module-table-heading span {
  font-size: 12px;
  color: var(--text-muted);
  text-align: right;
  line-height: 1.4;
}

.module-table-heading + .content-area {
  padding-top: 0;
}

.module-table-heading + .content-area .table-wrapper {
  border-top-left-radius: 0;
  border-top-right-radius: 0;
}

.module-table-heading-quotes {
  background:
    linear-gradient(120deg, rgba(196,183,217,.28), rgba(255,255,255,0) 48%),
    #f4f1f8;
}

.module-table-heading-construction {
  background:
    linear-gradient(120deg, rgba(127,168,159,.25), rgba(255,255,255,0) 48%),
    #eef6f3;
}

.module-table-heading-invoices {
  background:
    linear-gradient(120deg, rgba(184,96,110,.16), rgba(255,255,255,0) 48%),
    #fbf1f3;
}

.module-table-heading-contractor-payments {
  background:
    linear-gradient(120deg, rgba(184,137,90,.20), rgba(255,255,255,0) 48%),
    #f8f3ec;
}

.search-box { position: relative; flex: 1; min-width: 200px; }

.search-box svg {
  position: absolute;
  left: 10px;
  top: 50%;
  transform: translateY(-50%);
  width: 14px;
  height: 14px;
  stroke: var(--text-muted);
  fill: none;
  stroke-width: 2;
}

.search-box input {
  width: 100%;
  padding: 8px 10px 8px 32px;
  border: 1px solid var(--border);
  border-radius: 7px;
  font-size: 13px;
  font-family: var(--font-body);
  background: var(--bg);
  color: var(--text);
  outline: none;
  transition: border-color .15s, background .15s;
}

.search-box input:focus {
  border-color: var(--sage-deep);
  background: var(--surface);
}

.filters-bar select {
  padding: 8px 10px;
  border: 1px solid var(--border);
  border-radius: 7px;
  font-size: 13px;
  font-family: var(--font-body);
  background: var(--bg);
  color: var(--text);
  outline: none;
  cursor: pointer;
  transition: border-color .15s;
}

.filters-bar select:focus { border-color: var(--sage-deep); }

.view-toggle {
  display: flex;
  gap: 2px;
  background: var(--bg);
  padding: 3px;
  border-radius: 8px;
  border: 1px solid var(--border);
}

.view-btn {
  background: none;
  border: none;
  padding: 5px 7px;
  border-radius: 5px;
  cursor: pointer;
  color: var(--text-muted);
  display: flex;
  align-items: center;
  transition: background .15s, color .15s;
}

.view-btn svg { width: 14px; height: 14px; stroke: currentColor; fill: none; stroke-width: 2; }

.view-btn.active {
  background: var(--surface);
  color: var(--text);
  box-shadow: var(--shadow);
}

/* ── CONTENT ── */
.content-area { flex: 1; overflow-y: auto; overflow-x: auto; padding: 20px 24px; }
.hidden { display: none !important; }

/* ── TABLO ── */
.table-wrapper {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  overflow-x: auto;   /* yatay kaydırma — geniş tablolar için */
}

.data-table { width: 100%; border-collapse: collapse; }

.data-table thead {
  background: #4f4f4d;
  border-bottom: 1px solid #4f4f4d;
}

.data-table th {
  padding: 11px 14px;
  text-align: left;
  font-size: 11px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: .6px;
  color: #fff;
  white-space: nowrap;
}

.data-table-light thead { background: #edeae4; border-bottom: 1px solid var(--border); }
.data-table-light th { color: var(--text); font-size: 10px; padding: 8px 14px; }

.data-table td {
  padding: 11px 14px;
  border-bottom: 1px solid var(--border);
  vertical-align: middle;
}

.data-table tbody tr:last-child td { border-bottom: none; }
.data-table tbody tr:hover { background: #FAFAF8; }
.data-table td .status-badge:first-child { min-width: 0; margin-right: 0; }
.data-table td .status-select { width: auto; text-align: left; }

/* ── Module Overview (shared) ── */
.mod-overview {
  margin: 10px 24px 0;
  border-radius: var(--radius-lg);
  padding: 20px 24px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
  box-shadow: 0 8px 26px rgba(31,35,40,.06);
  flex-shrink: 0;
  height: 124px;
  box-sizing: border-box;
  overflow: hidden;
}
.mod-overview-quotes   { background: linear-gradient(120deg, rgba(120,90,175,.20), rgba(255,255,255,0) 55%), #f1edf8; border: 1px solid rgba(120,90,175,.28); }
.mod-overview-invoices { background: linear-gradient(120deg, rgba(190,110,55,.16), rgba(255,255,255,0) 55%), #f9f0e8; border: 1px solid rgba(190,110,55,.22); }
.mod-overview-offers   { background: linear-gradient(120deg, rgba(115,145,65,.20), rgba(255,255,255,0) 55%), #f1f5e9; border: 1px solid rgba(115,145,65,.28); }
.mod-overview-payments { background: linear-gradient(120deg, rgba(45,125,140,.18), rgba(255,255,255,0) 55%), #e9f3f5; border: 1px solid rgba(45,125,140,.26); }
.mod-overview h2 { font-family: var(--font-mono); font-size: 32px; font-weight: 700; letter-spacing: .4px; color: var(--text); }
.mod-overview-metrics { display: flex; gap: 10px; text-align: right; flex: 1; justify-content: flex-end; flex-wrap: wrap; }
.mod-overview-metric { width: 200px; flex-shrink: 1; min-width: 130px; padding: 7px 12px; border-radius: 7px; border: 1px solid rgba(0,0,0,.10); background: rgba(255,255,255,.66); }
.mod-overview-label { display: block; font-size: 9px; font-weight: 700; text-transform: uppercase; letter-spacing: .7px; color: var(--text-muted); margin-bottom: 3px; }
.mod-overview-metrics strong { font-family: var(--font-mono); font-size: 20px; font-weight: 700; display: block; margin-top: 8px; color: var(--text); }
.mod-overview-metric.om-accepted { background: rgba(46,125,50,.09); border-color: rgba(46,125,50,.22); }
.mod-overview-metric.om-accepted strong { color: #2e7d32; }
.mod-overview-metric.om-warn { background: rgba(184,137,90,.11); border-color: rgba(184,137,90,.28); }
.mod-overview-metric.om-warn strong { color: #9a6520; }
.mod-overview-metric.om-danger { background: rgba(192,72,79,.09); border-color: rgba(192,72,79,.22); }
.mod-overview-metric.om-danger strong { color: #b8404a; }
.mod-overview-metric.om-rejected { background: rgba(192,72,79,.09); border-color: rgba(192,72,79,.22); }
.mod-overview-metric.om-rejected strong { color: #b8404a; }
.mod-overview-metric.om-pending { background: rgba(180,135,0,.09); border-color: rgba(180,135,0,.22); }
.mod-overview-metric.om-pending strong { color: #9a7800; }
.mod-overview-metric.om-total { background: rgba(65,105,150,.09); border-color: rgba(65,105,150,.22); }
.mod-overview-metric.om-total strong { color: #3a6080; }

/* ── Table Panel (shared card wrapper) ── */
.table-panel {
  margin: 14px 24px 24px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 8px;
  box-shadow: var(--shadow);
  overflow: hidden;
  flex: 1;
  min-height: 0;
  display: flex;
  flex-direction: column;
}
.table-panel .client-filter-bar { margin: 0; padding-left: 16px; padding-right: 16px; }
.table-panel .content-area { padding: 0; flex: 1; overflow-y: auto; }
.table-panel .table-wrapper { border: none; border-radius: 0; box-shadow: none; }

/* ── Panel Header ── */
.panel-header {
  min-height: 54px;
  padding: 12px 16px;
  border-bottom: 1px solid var(--border);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  background: #f4f0e9;
  flex-shrink: 0;
}
.panel-header h3 {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
  margin: 0;
  font-size: 13px;
  font-family: var(--font-body);
  letter-spacing: .06em;
  text-transform: uppercase;
}

/* ── Client Filter Bar ── */
.client-filter-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 10px 24px;
  border-bottom: 1px solid var(--border);
  background: var(--surface);
  flex-shrink: 0;
  gap: 16px;
}
.focus-tabs {
  display: flex;
  align-items: center;
}
.focus-tab {
  background: none;
  border: none;
  border-bottom: 2px solid transparent;
  cursor: pointer;
  padding: 10px 18px;
  font-size: 13px;
  font-family: var(--font-body);
  font-weight: 500;
  color: var(--text-muted);
  white-space: nowrap;
  transition: color .15s;
  margin-bottom: -1px;
}
.focus-tab:hover { color: var(--text); }
.focus-tab.active {
  color: var(--text);
  font-weight: 700;
  border-bottom: 2px solid var(--primary);
}
.focus-dropdowns {
  display: flex;
  align-items: center;
  gap: 8px;
}
.focus-select {
  appearance: none;
  -webkit-appearance: none;
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 9px 28px 9px 12px;
  font-size: 12px;
  font-family: var(--font-body);
  color: var(--text);
  background: var(--surface);
  cursor: pointer;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%239A9590' stroke-width='2'%3E%3Cpolyline points='6 9 12 15 18 9'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 6px center;
  background-size: 14px;
  transition: border-color .15s;
  min-width: 80px;
}
.focus-select:hover { border-color: var(--text-muted); }
.focus-select:focus { outline: none; border-color: var(--primary); }
.focus-search-box {
  display: flex;
  align-items: center;
  gap: 6px;
  border: 1.5px solid #c8c3bc;
  border-radius: 8px;
  padding: 9px 14px;
  background: var(--surface);
  transition: border-color .15s;
  box-shadow: inset 0 1px 3px rgba(0,0,0,.06);
}

.focus-search-box:focus-within { border-color: var(--primary); }
.focus-search-box { flex: 1; }
.focus-search-box svg { width: 13px; height: 13px; stroke: var(--text-muted); fill: none; stroke-width: 2; flex-shrink: 0; }
.focus-search-box input { border: none; outline: none; font-size: 13px; font-family: var(--font-body); color: var(--text); background: transparent; width: 100%; }
.focus-search-box input::placeholder { color: var(--text-muted); }

.client-list-toggle {
  display: flex;
  justify-content: center;
  padding: 14px 0 4px;
  border-top: 1px solid var(--border);
  background: linear-gradient(180deg, rgba(255,255,255,.86), rgba(245,243,240,.46));
}

.client-list-toggle.hidden { display: none; }

.client-list-toggle button {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  border: 1px solid var(--border);
  background: var(--surface);
  color: var(--text);
  border-radius: 999px;
  padding: 7px 14px;
  font-family: var(--font-body);
  font-size: 12px;
  font-weight: 600;
  cursor: pointer;
  box-shadow: var(--shadow);
}

.client-list-toggle button:hover { background: var(--bg); }

.client-list-toggle svg {
  width: 13px;
  height: 13px;
  stroke: currentColor;
  fill: none;
  stroke-width: 2;
}

.client-list-toggle.expanded svg { transform: rotate(180deg); }

.project-list-toggle {
  display: flex;
  justify-content: center;
  padding: 14px 0 4px;
  border-top: 1px solid var(--border);
  background: linear-gradient(180deg, rgba(255,255,255,.86), rgba(245,243,240,.46));
}

.project-list-toggle.hidden { display: none; }

.project-list-toggle button {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  border: 1px solid var(--border);
  background: var(--surface);
  color: var(--text);
  border-radius: 999px;
  padding: 7px 14px;
  font-family: var(--font-body);
  font-size: 12px;
  font-weight: 600;
  cursor: pointer;
  box-shadow: var(--shadow);
}

.project-list-toggle button:hover { background: var(--bg); }

.project-list-toggle svg {
  width: 13px;
  height: 13px;
  stroke: currentColor;
  fill: none;
  stroke-width: 2;
}

.project-list-toggle.expanded svg { transform: rotate(180deg); }

.contractor-list-toggle {
  display: flex;
  justify-content: center;
  padding: 14px 0 4px;
  border-top: 1px solid var(--border);
  background: linear-gradient(180deg, rgba(255,255,255,.86), rgba(245,243,240,.46));
}

.contractor-list-toggle.hidden { display: none; }

.contractor-list-toggle button {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  border: 1px solid var(--border);
  background: var(--surface);
  color: var(--text);
  border-radius: 999px;
  padding: 7px 14px;
  font-family: var(--font-body);
  font-size: 12px;
  font-weight: 600;
  cursor: pointer;
  box-shadow: var(--shadow);
}

.contractor-list-toggle button:hover { background: var(--bg); }

.contractor-list-toggle svg {
  width: 13px;
  height: 13px;
  stroke: currentColor;
  fill: none;
  stroke-width: 2;
}

.contractor-list-toggle.expanded svg { transform: rotate(180deg); }

.data-table th.project-action-col,
.data-table td.project-action-col,
.data-table th.project-status-col,
.data-table td.project-status-col {
  padding-left: 14px;
}

.projects-table {
  table-layout: fixed;
}

.projects-table th.project-action-col,
.projects-table td.project-action-col {
  padding-left: 34px !important;
}

.projects-table th:nth-child(3),
.projects-table th:nth-child(4),
.projects-table th:nth-child(5),
.projects-table td:nth-child(3),
.projects-table td:nth-child(4),
.projects-table td:nth-child(5) {
  padding-left: 8px;
  padding-right: 8px;
}

.projects-table th.project-next-action-col,
.projects-table td.project-next-action-col {
  padding-left: 68px !important;
}

.projects-table th.project-status-col,
.projects-table td.project-status-col {
  padding-left: 18px !important;
}

.projects-table th.project-next-action-col span,
.projects-table th.project-status-col span {
  display: inline-flex;
  padding-left: 9px;
}

.projects-table th.project-action-col,
.projects-table td.project-action-col {
  display: table-cell;
}

.projects-table th.project-action-col {
  white-space: nowrap;
}

.projects-table th.project-action-col span,
.projects-table td.project-action-col .status-badge {
  display: inline-flex;
}

.projects-table th.project-action-col span {
  padding-left: 9px;
}

.projects-table th.project-action-col span:first-child,
.projects-table td.project-action-col .status-badge:first-child {
  min-width: 112px;
  margin-right: 28px;
}
/* overdue — shared */
.project-table-profile {
  display: flex;
  align-items: center;
  gap: 12px;
  min-width: 0;
}

.project-table-badge {
  min-width: 48px;
  height: 28px;
  padding: 0 8px;
  border-radius: 8px;
  border: 1px solid rgba(127,168,159,.28);
  background: #eef6f3;
  color: #2f6f63;
  font-family: var(--font-mono);
  font-size: 11px;
  font-weight: 700;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex: 0 0 auto;
}

.project-table-info {
  min-width: 0;
}

.project-table-link {
  color: inherit;
  text-decoration: none;
  font-weight: 700;
}

.project-table-link:hover {
  text-decoration: underline;
}

.project-table-client {
  margin-top: 2px;
  font-size: 12px;
  color: var(--text-muted);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.project-table-meta {
  margin-top: 2px;
  font-size: 12px;
  color: var(--text-muted);
  white-space: nowrap;
}

.project-progress-cell {
  display: flex;
  align-items: center;
  gap: 8px;
  width: 100%;
  min-width: 0;
}

.project-progress-track {
  width: 100%;
  max-width: 132px;
  min-width: 92px;
  height: 5px;
  border-radius: 99px;
  background: #ebe7df;
  overflow: hidden;
  flex: 0 0 auto;
}

.project-progress-track span {
  display: block;
  height: 100%;
  border-radius: inherit;
  background: var(--sage-deep);
}

.project-progress-cell strong {
  font-family: var(--font-mono);
  font-size: 11px;
  font-weight: 700;
  color: var(--text);
}

.data-table tbody tr.row-overdue td { background: #fff8f6 !important; }
.data-table tbody tr.row-overdue:hover td { background: #ffecea !important; }
/* overdue — due (kırmızı) */
.data-table tbody tr.row-overdue-due td:first-child { box-shadow: inset 5px 0 0 var(--status-cancelled) !important; }
.row-overdue-due td:nth-child(9) { color: var(--status-cancelled) !important; }
.row-overdue-due .inv-status-due { color: var(--status-cancelled) !important; background: var(--status-cancelled-bg) !important; }
.row-overdue-due .action-btn[title="Send Payment Reminder"] { color: var(--status-cancelled); }
.row-overdue-due .action-btn[title="Send Payment Reminder"]:hover { background: var(--status-cancelled-bg); color: var(--status-cancelled); }
/* overdue — partially paid (turuncu) */
.data-table tbody tr.row-overdue-partial td:first-child { box-shadow: inset 5px 0 0 var(--status-pending) !important; }
.row-overdue-partial td:nth-child(9) { color: var(--status-pending) !important; }
.row-overdue-partial .inv-status-partial { color: var(--status-pending) !important; background: var(--status-pending-bg) !important; }
.row-overdue-partial .action-btn[title="Send Payment Reminder"] { color: var(--status-pending); }
.row-overdue-partial .action-btn[title="Send Payment Reminder"]:hover { background: var(--status-pending-bg); color: var(--status-pending); }

/* Adres sütunları — uzun metin kırpılır, hover'da title ile tam görülür */
.td-address {
  max-width: 160px;
  color: var(--text-muted);
  font-size: 12px;
  font-family: var(--font-body);
}

.td-address-inner {
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  line-height: 1.4;
}

.client-name { font-weight: 600; font-size: 13px; }

.client-row,
.project-row,
.contractor-row {
  cursor: pointer;
}

.client-row:hover td,
.project-row:hover td,
.contractor-row:hover td {
  background: #FAFAF8;
}

.client-table-profile {
  display: flex;
  align-items: center;
  gap: 12px;
  min-width: 210px;
}

.client-table-badge {
  min-width: 48px;
  height: 28px;
  padding: 0 8px;
  border-radius: 8px;
  border: 1px solid rgba(184,96,110,.18);
  background: #fbf1f3;
  color: #b8606e;
  font-family: var(--font-mono);
  font-size: 11px;
  font-weight: 700;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex: 0 0 auto;
}

.client-table-info {
  min-width: 0;
}

.client-table-company {
  margin-top: 2px;
  font-size: 12px;
  color: var(--text-muted);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.client-table-meta {
  margin-top: 2px;
  font-size: 12px;
  color: var(--text-muted);
  white-space: nowrap;
}

.client-last-activity-col,
.client-row td:nth-child(7) {
  padding-left: 40px !important;
}

.client-link-button {
  border: 0;
  background: transparent;
  padding: 0;
  margin: 0;
  font: inherit;
  font-weight: 600;
  color: inherit;
  cursor: pointer;
  text-align: left;
  text-decoration: none;
}

.client-link-button:hover { text-decoration: underline; }

.client-contact-link {
  color: var(--text-muted);
  text-decoration: none;
  font-size: 12px;
  font-weight: 400;
}

.client-contact-link:hover {
  color: var(--text);
  text-decoration: underline;
}

.client-card { cursor: pointer; }

.project-name { font-size: 12px; color: var(--text-muted); margin-top: 1px; }

.project-no-badge {
  font-family: var(--font-mono);
  font-size: 11px;
  font-weight: 400;
  color: var(--text-muted);
  background: var(--bg);
  padding: 2px 7px;
  border-radius: 4px;
  border: 1px solid var(--border);
}

/* ── Module-specific number badges ── */
.quote-no-badge {
  min-width: 44px;
  height: 26px;
  padding: 0 8px;
  border-radius: 8px;
  border: 1px solid rgba(196,183,217,.40);
  background: #f4f1f8;
  color: #6b58a0;
  font-family: var(--font-mono);
  font-size: 11px;
  font-weight: 700;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex: 0 0 auto;
}
.invoice-no-badge {
  min-width: 44px;
  height: 26px;
  padding: 0 8px;
  border-radius: 8px;
  border: 1px solid rgba(184,96,110,.18);
  background: #fbf1f3;
  color: #b8606e;
  font-family: var(--font-mono);
  font-size: 11px;
  font-weight: 700;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex: 0 0 auto;
}
.offer-no-badge {
  min-width: 44px;
  height: 26px;
  padding: 0 8px;
  border-radius: 8px;
  border: 1px solid rgba(127,168,159,.28);
  background: #eef6f3;
  color: #2f6f63;
  font-family: var(--font-mono);
  font-size: 11px;
  font-weight: 700;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex: 0 0 auto;
}
.payment-no-badge {
  min-width: 44px;
  height: 26px;
  padding: 0 8px;
  border-radius: 8px;
  border: 1px solid rgba(184,137,90,.24);
  background: #f8f3ec;
  color: #7a5c2e;
  font-family: var(--font-mono);
  font-size: 11px;
  font-weight: 700;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex: 0 0 auto;
}

/* Size column mono font */
.data-table td:nth-child(9) {
  font-family: var(--font-mono);
  font-size: 12px;
}

.client-row td:nth-child(9) {
  font-family: var(--font-body);
  font-size: inherit;
}

.subcontractors-table td:nth-child(9) {
  font-family: var(--font-body);
  font-size: inherit;
}

.contractor-table-profile {
  display: flex;
  align-items: center;
  gap: 12px;
  min-width: 220px;
}

.contractor-table-badge {
  min-width: 48px;
  height: 28px;
  padding: 0 8px;
  border-radius: 8px;
  border: 1px solid rgba(184,137,90,.24);
  background: #f8f3ec;
  color: #b8895a;
  font-family: var(--font-mono);
  font-size: 11px;
  font-weight: 700;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex: 0 0 auto;
}

.contractor-table-info {
  min-width: 0;
}

.contractor-table-link {
  color: inherit;
  text-decoration: none;
  font-weight: 700;
}

.contractor-table-link:hover {
  text-decoration: underline;
}

.contractor-table-meta {
  margin-top: 2px;
  font-size: 12px;
  color: var(--text-muted);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.row-actions { display: flex; gap: 4px; opacity: 0; transition: opacity .15s; }
.data-table tbody tr:hover .row-actions { opacity: 1; }

.action-btn {
  background: none;
  border: none;
  padding: 5px;
  border-radius: 5px;
  cursor: pointer;
  color: var(--text-muted);
  display: flex;
  align-items: center;
  transition: background .12s, color .12s;
}
.action-btn:hover { background: var(--bg); color: var(--text); }
.action-btn.danger:hover { background: var(--status-cancelled-bg); color: var(--status-cancelled); }
.action-btn svg { width: 14px; height: 14px; stroke: currentColor; fill: none; stroke-width: 2; }

/* ── DURUM ETİKETLERİ ── */
.status-badge {
  display: inline-flex;
  align-items: center;
  font-size: 11px;
  font-weight: 600;
  padding: 3px 9px;
  border-radius: 20px;
  white-space: nowrap;
  letter-spacing: 0.2px;
}

.status-active      { color: var(--status-active);      background: var(--status-active-bg); }
.status-completed { color: var(--status-tamamlandi);  background: var(--status-tamamlandi-bg); }
.status-pending  { color: var(--status-pending);   background: var(--status-pending-bg); }
.status-cancelled      { color: var(--status-cancelled);       background: var(--status-cancelled-bg); }


.job-badge {
  font-size: 11px;
  font-weight: 500;
  color: var(--text-muted);
  background: var(--bg);
  border: 1px solid var(--border);
  padding: 2px 8px;
  border-radius: 4px;
  white-space: nowrap;
}

.client-drawer-backdrop {
  position: fixed;
  inset: 0;
  background: transparent;
  z-index: 850;
  pointer-events: none;
}

.client-drawer {
  position: fixed;
  top: 0;
  right: 0;
  width: 430px;
  max-width: calc(100vw - 24px);
  height: 100vh;
  background: var(--surface);
  border-left: 1px solid var(--border);
  box-shadow: -20px 0 50px rgba(31,35,40,.14);
  z-index: 900;
  display: flex;
  flex-direction: column;
}

.client-drawer.hidden,
.client-drawer-backdrop.hidden {
  display: none;
}

.client-drawer-header {
  min-height: 70px;
  padding: 18px 20px;
  border-bottom: 1px solid var(--border);
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
}

.client-drawer-header h2 {
  margin: 0;
  font-size: 18px;
  font-weight: 700;
}

.client-drawer-header span {
  display: block;
  margin-top: 4px;
  font-size: 12px;
  color: var(--text-muted);
}

.client-drawer-body {
  padding: 18px;
  overflow-y: auto;
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.drawer-client-hero {
  display: grid;
  grid-template-columns: 48px 1fr;
  gap: 12px;
  align-items: start;
}

.drawer-avatar {
  width: 48px;
  height: 48px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  background: #f7dde1;
  color: #b8606e;
  font-weight: 700;
  letter-spacing: .4px;
}

.drawer-client-name {
  font-size: 15px;
  font-weight: 700;
  color: var(--text);
}

.drawer-client-titleline {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}

.drawer-client-location {
  margin-top: 8px;
  font-size: 12px;
  color: var(--text-muted);
}

.drawer-muted {
  margin-top: 2px;
  font-size: 12px;
  color: var(--text-muted);
}

.drawer-actions {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 8px;
}

.drawer-action-btn {
  min-height: 54px;
  border: 1px solid var(--border);
  border-radius: 8px;
  background: var(--surface);
  color: var(--text);
  text-decoration: none;
  font-size: 11px;
  font-weight: 600;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 6px;
  cursor: pointer;
}

.drawer-action-btn:hover {
  background: var(--bg);
}

.drawer-action-btn[type="button"] {
  font-family: var(--font-body);
}

.drawer-action-btn svg {
  width: 15px;
  height: 15px;
  stroke: currentColor;
  fill: none;
  stroke-width: 2;
}

.drawer-project-picker {
  border: 1px solid rgba(127,168,159,.26);
  background: #f3f8f6;
  border-radius: 10px;
  padding: 12px;
}

.drawer-project-picker label {
  display: block;
  font-size: 10px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: .6px;
  color: var(--text-muted);
  margin-bottom: 8px;
}

.drawer-project-picker div {
  display: flex;
  gap: 8px;
}

.drawer-project-picker select {
  min-width: 0;
  flex: 1;
  border: 1px solid var(--border);
  border-radius: 7px;
  background: var(--surface);
  padding: 7px 9px;
  font-family: var(--font-body);
  font-size: 12px;
}

.drawer-panel {
  border: 1px solid var(--border);
  border-radius: 10px;
  background: var(--surface);
  padding: 14px;
}

.drawer-panel-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 12px;
}

.drawer-panel-header h3 {
  margin: 0;
  font-size: 13px;
  font-weight: 700;
}

.drawer-panel-header a {
  font-size: 11px;
  color: var(--text-muted);
  text-decoration: none;
}

.drawer-panel-header a:hover {
  color: var(--text);
  text-decoration: underline;
}

.drawer-figures {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px 14px;
}

.drawer-figures div {
  min-width: 0;
}

.drawer-figures span {
  display: block;
  font-size: 10px;
  text-transform: uppercase;
  letter-spacing: .5px;
  color: var(--text-muted);
  margin-bottom: 5px;
}

.drawer-figures strong {
  font-family: var(--font-mono);
  font-size: 13px;
  color: var(--text);
}

.drawer-figures strong.good { color: var(--status-active); }
.drawer-figures strong.danger { color: #b8606e; }
.drawer-figures strong.muted { color: var(--text-muted); }

.project-drawer-hero {
  display: grid;
  grid-template-columns: 58px 1fr;
  gap: 12px;
  align-items: start;
}

.project-drawer-badge {
  min-width: 48px;
  height: 34px;
  padding: 0 8px;
  border-radius: 9px;
  border: 1px solid rgba(127,168,159,.28);
  background: #eef6f3;
  color: #2f6f63;
  font-family: var(--font-mono);
  font-size: 12px;
  font-weight: 700;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.contractor-drawer-badge {
  min-width: 48px;
  height: 34px;
  padding: 0 8px;
  border-radius: 9px;
  border: 1px solid rgba(184,137,90,.24);
  background: #f8f3ec;
  color: #b8895a;
  font-family: var(--font-mono);
  font-size: 12px;
  font-weight: 700;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.project-drawer-actions {
  grid-template-columns: repeat(4, 1fr);
}

.drawer-progress-wide {
  margin-top: 13px;
}

.drawer-progress-wide .project-progress-track {
  width: 100%;
  max-width: none;
  min-width: 0;
}

.drawer-action-line {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 12px;
  color: var(--text-muted);
}

.drawer-project-actions strong.good { color: var(--status-active); }
.drawer-project-actions strong.danger { color: #b8606e; }

.drawer-project-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.drawer-project-card {
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 10px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 10px;
  color: inherit;
  text-decoration: none;
  background: #fbfaf8;
}

.drawer-project-card:hover { background: var(--bg); }

.drawer-project-link {
  color: inherit;
  text-decoration: none;
}

.drawer-project-link:hover strong { text-decoration: underline; }

.drawer-project-card strong {
  display: block;
  font-size: 12px;
}

.drawer-project-card span,
.drawer-project-card small {
  display: block;
  margin-top: 2px;
  font-size: 11px;
  color: var(--text-muted);
}

.drawer-project-card .status-badge {
  display: inline-flex;
  margin-top: 0;
  color: var(--status-active);
}

.drawer-project-actions {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 4px;
  flex-shrink: 0;
}

.drawer-mini-action {
  font-size: 11px;
  font-weight: 600;
  color: var(--text);
  text-decoration: none;
  border: 1px solid var(--border);
  border-radius: 999px;
  padding: 3px 8px;
  background: var(--surface);
}

.drawer-mini-action:hover { background: var(--bg); }

.drawer-activity-list {
  display: flex;
  flex-direction: column;
  gap: 9px;
}

.drawer-activity-row {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  font-size: 12px;
}

.drawer-activity-row span { color: var(--text-muted); }
.drawer-activity-row strong { font-weight: 600; text-align: right; }

.drawer-note {
  margin-top: 4px;
  padding: 10px;
  border-radius: 8px;
  background: var(--bg);
  color: var(--text-muted);
  font-size: 12px;
  line-height: 1.55;
}

.link {
  color: var(--accent, #2563eb);
  text-decoration: none;
  font-size: 13px;
}
.link:hover { text-decoration: underline; }

/* ── KART GÖRÜNÜMÜ ── */
.cards-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 14px;
}

.project-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 16px;
  transition: box-shadow .2s, border-color .2s;
}

.project-card:hover {
  box-shadow: var(--shadow-md);
  border-color: var(--sage);
}

.card-header { display: flex; justify-content: space-between; align-items: flex-start; margin-bottom: 10px; }

.card-project-no {
  font-family: var(--font-mono);
  font-size: 10px;
  color: var(--text-muted);
  background: var(--bg);
  padding: 2px 7px;
  border-radius: 4px;
  border: 1px solid var(--border);
}

.card-project-name { font-weight: 700; font-size: 14px; margin-bottom: 3px; }
.card-client { font-size: 13px; color: var(--text-muted); margin-bottom: 6px; }
.card-company { font-size: 12px; color: var(--text-muted); font-style: italic; margin-bottom: 10px; }

.card-meta { display: flex; flex-direction: column; gap: 3px; margin-bottom: 12px; }

.card-meta-row {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 12px;
  color: var(--text-muted);
}

.card-meta-row svg { width: 11px; height: 11px; stroke: currentColor; fill: none; stroke-width: 2; flex-shrink: 0; }

.card-footer { display: flex; justify-content: space-between; align-items: center; }
.card-actions { display: flex; gap: 4px; }

/* ── MODAL ── */
.modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(31,35,40,.55);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 2000;
  padding: 20px;
  backdrop-filter: blur(2px);
}

.modal {
  background: var(--surface);
  border-radius: var(--radius-lg);
  width: 100%;
  max-width: 640px;
  max-height: 90vh;
  display: flex;
  flex-direction: column;
  box-shadow: 0 24px 64px rgba(0,0,0,.15);
}

.modal-sm { max-width: 400px; }

.modal-header {
  padding: 18px 20px;
  border-bottom: 1px solid var(--border);
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.modal-header h2 {
  font-family: 'Jost',  sans-serif;
  font-size: 18px;
  font-weight: 600;
}

.modal-close {
  background: none;
  border: none;
  cursor: pointer;
  padding: 5px;
  border-radius: 6px;
  color: var(--text-muted);
  display: flex;
  transition: background .12s;
}

.modal-close svg { width: 17px; height: 17px; stroke: currentColor; fill: none; stroke-width: 2; }
.modal-close:hover { background: var(--bg); }

.modal-body { padding: 20px; overflow-y: auto; flex: 1; }
.modal-body p { color: var(--text-muted); font-size: 14px; line-height: 1.55; }

.delete-project-name {
  font-weight: 600;
  color: var(--text);
  margin-top: 8px;
  font-size: 15px;
}

.modal-footer {
  padding: 14px 20px;
  border-top: 1px solid var(--border);
  display: flex;
  justify-content: flex-end;
  gap: 8px;
}

/* ── FORM ── */
.form-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.form-group { display: flex; flex-direction: column; gap: 5px; }
.form-group.full-width { grid-column: 1 / -1; }

/* Bölüm başlığı (Müşteri Adresi / Proje Adresi) */
.form-section-header {
  grid-column: 1 / -1;
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 2px;
  text-transform: uppercase;
  color: var(--text-muted);
  padding: 10px 0 4px;
  border-bottom: 1px solid var(--border);
  margin-top: 4px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

/* Label + checkbox yan yana */
.label-with-check {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.check-label {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  font-size: 11px;
  font-weight: 500;
  color: var(--text-muted);
  cursor: pointer;
  white-space: nowrap;
  text-transform: none;
  letter-spacing: 0;
}

.check-label input[type="checkbox"] {
  accent-color: var(--sage-deep);
  width: 13px;
  height: 13px;
  cursor: pointer;
}

.form-group label {
  font-size: 11px;
  font-weight: 700;
  color: #7a7470;
  letter-spacing: 0.4px;
  text-transform: uppercase;
}

.form-group input,
.form-group select,
.form-group textarea {
  padding: 8px 10px;
  border: 1px solid #C8C2BA;
  border-radius: 7px;
  font-size: 13px;
  font-family: var(--font-body);
  background: var(--surface);
  color: var(--text);
  outline: none;
  resize: vertical;
  transition: border-color .15s, box-shadow .15s;
  box-shadow: inset 0 1px 2px rgba(0,0,0,.04);
}

.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
  border-color: var(--sage-deep);
  box-shadow: 0 0 0 3px rgba(95,130,120,.12), inset 0 1px 2px rgba(0,0,0,.04);
}

/* ── TOAST ── */
.toast {
  position: fixed;
  bottom: 24px;
  right: 24px;
  background: var(--primary);
  color: #fff;
  padding: 12px 18px;
  border-radius: 8px;
  font-size: 13px;
  font-weight: 500;
  z-index: 200;
  box-shadow: var(--shadow-md);
  animation: slideUp .2s ease;
}

.toast.success { background: var(--status-active); }
.toast.error   { background: var(--status-cancelled); }

@keyframes slideUp {
  from { opacity: 0; transform: translateY(10px); }
  to   { opacity: 1; transform: translateY(0); }
}

/* ── EMPTY STATE ── */
.empty-state { text-align: center; padding: 60px 20px; color: var(--text-muted); }
.empty-state svg { width: 44px; height: 44px; stroke: var(--border); fill: none; stroke-width: 1.5; margin-bottom: 12px; }
.empty-state p { font-size: 15px; }

.modal-overlay.hidden { display: none; }
.modal, .modal-box {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  width: 580px;
  max-width: 95vw;
  max-height: 90vh;
  display: flex;
  flex-direction: column;
}
.modal-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px 20px;
  border-bottom: 1px solid var(--border);
  flex-shrink: 0;
}
.modal-header h2 {
  font-family: 'Jost',  sans-serif;
  font-size: 14px;
  font-weight: 600;
  color: var(--text);
}
.modal-close {
  background: none; border: none; cursor: pointer;
  color: var(--text-muted); padding: 4px; border-radius: 4px;
  display: flex; align-items: center;
}
.modal-close:hover { background: var(--bg); color: var(--text); }
.modal-close svg { width: 16px; height: 16px; stroke: currentColor; fill: none; stroke-width: 2; }
.modal-body {
  padding: 20px;
  overflow-y: auto;
  display: flex;
  flex-direction: column;
  gap: 12px;
}
.modal-field label {
  display: block;
  font-size: 10px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: .7px;
  color: var(--text-muted);
  margin-bottom: 5px;
}
.modal-field input, .modal-field textarea {
  width: 100%;
  padding: 8px 10px;
  border: 1px solid var(--border);
  border-radius: 6px;
  font-family: inherit;
  font-size: 13px;
  background: var(--bg);
  color: var(--text);
  outline: none;
}
.modal-field input:focus, .modal-field textarea:focus { border-color: var(--sage-deep); }
.modal-field textarea { font-family: var(--font-mono); font-size: 12px; line-height: 1.65; resize: vertical; }
.modal-footer {
  padding: 12px 20px;
  border-top: 1px solid var(--border);
  display: flex;
  justify-content: flex-end;
  gap: 8px;
  flex-shrink: 0;
}

/* ── RESPONSIVE ── */
@media (max-width: 1400px) {
  :root { --sidebar-w: 200px; }
  .mod-overview { margin: 10px 16px 0; padding: 16px 18px; }
  .mod-overview h2 { font-size: 24px; }
  .mod-overview-metric { width: 170px; }
  .mod-overview-metrics strong { font-size: 18px; }
  .content-area { padding: 16px 18px; }
  .topbar { padding: 0 18px; }
  .client-filter-bar { padding: 8px 18px; }
}

@media (max-width: 1200px) {
  .mod-overview { flex-direction: column; align-items: flex-start; gap: 12px; }
  .mod-overview-metrics { justify-content: flex-start; }
  .mod-overview h2 { font-size: 20px; }
  .mod-overview-metric { width: 160px; }
}

@media (max-width: 768px) {
  .sidebar { display: none; }
  .topbar { padding: 0 16px; }
  .filters-bar { padding: 10px 16px; }
  .content-area { padding: 14px 16px; }
  .form-grid { grid-template-columns: 1fr; }
  .form-group.full-width { grid-column: 1; }
}

/* ── Number input spinners — global remove ── */
input[type="number"]::-webkit-outer-spin-button,
input[type="number"]::-webkit-inner-spin-button { -webkit-appearance: none; margin: 0; }
input[type="number"] { -moz-appearance: textfield; }

/* ── Input suffix wrapper (€ / %) ── */
.inp-sfx { position: relative; display: block; }
.inp-sfx input { padding-right: 26px; width: 100%; }
.inp-sfx::after {
  position: absolute;
  right: 9px;
  top: 50%;
  transform: translateY(-50%);
  color: var(--text-muted);
  font-size: 11px;
  font-family: var(--font-mono);
  pointer-events: none;
}
.inp-eur::after { content: "€"; }
.inp-pct::after { content: "%"; }

/* legacy — keep for existing money-field usages */
.suffix-field { position: relative; }
.suffix-field input { padding-right: 28px; }
.suffix-eur.suffix-field::after { content: "€"; position: absolute; right: 9px; bottom: 9px; color: var(--text-muted); font-size: 11px; font-family: var(--font-mono); pointer-events: none; }
.suffix-pct.suffix-field::after { content: "%"; position: absolute; right: 9px; bottom: 9px; color: var(--text-muted); font-size: 11px; font-family: var(--font-mono); pointer-events: none; }
