/* ProjemizTakip — Kurumsal, Sade ve Yüksek Okunabilirlikli Tasarım Sistemi (v2) */
@import url('https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700&display=swap');

:root {
  --bg: #f8fafc;
  --surface: #ffffff;
  --surface-subtle: #f1f5f9;
  --ink: #0f172a;
  --ink-secondary: #334155;
  --muted: #64748b;
  --border: #e2e8f0;
  --border-strong: #cbd5e1;

  --primary: #1e3a8a;
  --primary-hover: #172554;
  --primary-soft: #eff6ff;
  --accent: #2563eb;

  --success: #047857;
  --success-bg: #ecfdf5;
  --success-border: #a7f3d0;

  --warning: #b45309;
  --warning-bg: #fffbeb;
  --warning-border: #fde68a;

  --danger: #b91c1c;
  --danger-bg: #fef2f2;
  --danger-border: #fecaca;

  --sidebar-w: 240px;
  --radius-sm: 6px;
  --radius: 8px;
  --radius-lg: 10px;
  --shadow-xs: 0 1px 2px rgba(15, 23, 42, 0.04);
  --shadow-sm: 0 1px 3px rgba(15, 23, 42, 0.06), 0 1px 2px rgba(15, 23, 42, 0.04);
  --shadow-modal: 0 20px 40px -12px rgba(15, 23, 42, 0.22);
}

*, *::before, *::after {
  box-sizing: border-box;
}

html, body {
  margin: 0;
  padding: 0;
  width: 100%;
  max-width: 100%;
  overflow-x: clip;
  font-family: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  background: var(--bg);
  color: var(--ink);
  font-size: 13.5px;
  line-height: 1.5;
  font-variant-numeric: tabular-nums;
  -webkit-font-smoothing: antialiased;
}

a {
  color: inherit;
  text-decoration: none;
}

svg.ic {
  width: 16px;
  height: 16px;
  stroke: currentColor;
  stroke-width: 1.8;
  fill: none;
  stroke-linecap: round;
  stroke-linejoin: round;
  flex-shrink: 0;
}

/* Uygulama İskeleti */
.app-shell {
  display: flex;
  min-height: 100vh;
  width: 100%;
  max-width: 100%;
  min-width: 0;
}

.sidebar {
  width: var(--sidebar-w);
  background: var(--surface);
  border-right: 1px solid var(--border);
  display: flex;
  flex-direction: column;
  position: fixed;
  inset: 0 auto 0 0;
  z-index: 200;
}

.brand-header {
  height: 60px;
  padding: 0 20px;
  border-bottom: 1px solid var(--border);
  display: flex;
  align-items: center;
  gap: 10px;
}

.brand-mark {
  width: 30px;
  height: 30px;
  border-radius: 6px;
  background: var(--primary);
  color: #ffffff;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 12px;
  letter-spacing: 0.04em;
  flex-shrink: 0;
}

.brand-title {
  display: flex;
  flex-direction: column;
  line-height: 1.2;
}

.brand-title strong {
  font-size: 14px;
  font-weight: 700;
  color: var(--ink);
  letter-spacing: -0.01em;
}

.brand-title span {
  font-size: 11px;
  color: var(--muted);
  font-weight: 500;
}

.side-section-label {
  padding: 18px 20px 6px;
  font-size: 10.5px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--muted);
}

.side-nav {
  padding: 4px 12px;
  display: flex;
  flex-direction: column;
  gap: 2px;
  flex: 1;
}

.side-link {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 9px 10px;
  border-radius: var(--radius-sm);
  color: var(--ink-secondary);
  font-weight: 500;
  font-size: 13.5px;
  transition: background 0.12s ease, color 0.12s ease;
}

.side-link:hover {
  background: var(--surface-subtle);
  color: var(--ink);
}

.side-link.active {
  background: var(--primary-soft);
  color: var(--primary);
  font-weight: 600;
}

.side-footer {
  border-top: 1px solid var(--border);
  padding: 14px 16px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}

.user-meta {
  min-width: 0;
}

.user-meta strong {
  display: block;
  font-size: 12.5px;
  font-weight: 600;
  color: var(--ink);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.user-meta span {
  display: block;
  font-size: 11px;
  color: var(--muted);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.logout-link {
  padding: 6px 8px;
  border-radius: var(--radius-sm);
  color: var(--muted);
  font-size: 12px;
  font-weight: 500;
  border: 1px solid transparent;
}

.logout-link:hover {
  color: var(--danger);
  background: var(--danger-bg);
  border-color: var(--danger-border);
}

/* Ana İçerik Alanı */
.main-area {
  flex: 1;
  margin-left: var(--sidebar-w);
  min-width: 0;
  display: flex;
  flex-direction: column;
}

.topbar {
  min-height: 60px;
  background: var(--surface);
  border-bottom: 1px solid var(--border);
  padding: 10px 28px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  position: sticky;
  top: 0;
  z-index: 100;
}

.topbar-title-wrap {
  display: flex;
  align-items: center;
  gap: 12px;
  min-width: 0;
}

.page-title {
  margin: 0;
  font-size: 16px;
  font-weight: 600;
  color: var(--ink);
  letter-spacing: -0.01em;
}

.page-subtitle {
  margin: 1px 0 0;
  font-size: 12px;
  color: var(--muted);
}

.topbar-actions {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}

.mob-menu-btn {
  display: none;
  background: var(--surface);
  border: 1px solid var(--border-strong);
  border-radius: var(--radius-sm);
  width: 34px;
  height: 34px;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  color: var(--ink);
}

.page-wrap {
  padding: 24px 28px 48px;
  max-width: 1360px;
  width: 100%;
  min-width: 0;
  margin: 0 auto;
}

/* Butonlar */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  height: 34px;
  padding: 0 13px;
  border-radius: var(--radius-sm);
  border: 1px solid transparent;
  font-family: inherit;
  font-size: 12.5px;
  font-weight: 600;
  cursor: pointer;
  transition: background 0.12s ease, border-color 0.12s ease, color 0.12s ease;
  white-space: nowrap;
}

.btn-sm {
  height: 28px;
  padding: 0 9px;
  font-size: 12px;
}

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

.btn-outline {
  background: var(--surface);
  border-color: var(--border-strong);
  color: var(--ink-secondary);
}
.btn-outline:hover {
  background: var(--surface-subtle);
  color: var(--ink);
}

.btn-success {
  background: var(--success);
  color: #ffffff;
}
.btn-success:hover {
  background: #065f46;
}

.btn-warning {
  background: var(--warning-bg);
  border-color: var(--warning-border);
  color: var(--warning);
}
.btn-warning:hover {
  background: #fef3c7;
}

.btn-danger {
  background: var(--surface);
  border-color: var(--danger-border);
  color: var(--danger);
}
.btn-danger:hover {
  background: var(--danger-bg);
}

/* Kartlar & Özet Metrik Şeridi */
.card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-xs);
  padding: 18px 20px;
}

.card-flush {
  padding: 0;
  overflow: hidden;
}

.card-head {
  padding: 14px 20px;
  border-bottom: 1px solid var(--border);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
}

.card-head h2, .card-head h3 {
  margin: 0;
  font-size: 14px;
  font-weight: 600;
  color: var(--ink);
}

.metric-strip {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-xs);
  margin-bottom: 20px;
  overflow: hidden;
}

.metric-cell {
  padding: 16px 20px;
  border-right: 1px solid var(--border);
}
.metric-cell:last-child {
  border-right: none;
}

.metric-label {
  font-size: 11.5px;
  font-weight: 500;
  color: var(--muted);
  margin-bottom: 4px;
}

.metric-value {
  font-size: 21px;
  font-weight: 700;
  color: var(--ink);
  letter-spacing: -0.02em;
}

.metric-sub {
  font-size: 11.5px;
  color: var(--muted);
  margin-top: 3px;
}

/* Durum Etiketleri (Sade Noktalı Kurumsal Rozetler) */
.status-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 2px 9px;
  border-radius: 999px;
  font-size: 11.5px;
  font-weight: 600;
  border: 1px solid transparent;
  white-space: nowrap;
}
.status-badge::before {
  content: "";
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: currentColor;
}

.st-active {
  background: #eff6ff;
  color: #1d4ed8;
  border-color: #bfdbfe;
}
.st-done {
  background: var(--success-bg);
  color: var(--success);
  border-color: var(--success-border);
}
.st-paused {
  background: var(--warning-bg);
  color: var(--warning);
  border-color: var(--warning-border);
}
.st-danger {
  background: var(--danger-bg);
  color: var(--danger);
  border-color: var(--danger-border);
}
.st-neutral {
  background: var(--surface-subtle);
  color: var(--ink-secondary);
  border-color: var(--border);
}

.tag-plain {
  display: inline-flex;
  align-items: center;
  padding: 2px 7px;
  border-radius: 4px;
  font-size: 11px;
  font-weight: 500;
  background: var(--surface-subtle);
  color: var(--ink-secondary);
  border: 1px solid var(--border);
}

/* İlerleme Çubuğu */
.prog-bar {
  width: 100%;
  height: 6px;
  background: var(--surface-subtle);
  border-radius: 999px;
  overflow: hidden;
}
.prog-bar-fill {
  height: 100%;
  background: var(--primary);
  border-radius: 999px;
  transition: width 0.25s ease;
}
.prog-bar-fill.done {
  background: var(--success);
}

/* Kurumsal Tablolar */
.table-wrap {
  width: 100%;
  overflow-x: auto;
}

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

.corp-table th {
  text-align: left;
  padding: 10px 16px;
  font-size: 11px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: var(--muted);
  background: #f8fafc;
  border-bottom: 1px solid var(--border);
  white-space: nowrap;
}

.corp-table td {
  padding: 12px 16px;
  border-bottom: 1px solid var(--border);
  vertical-align: middle;
  color: var(--ink-secondary);
}

.corp-table tbody tr:last-child td {
  border-bottom: none;
}

.corp-table tbody tr:hover td {
  background: #fafbfd;
}

.code-mono {
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-size: 12px;
  font-weight: 600;
  color: var(--ink-secondary);
}

/* Canlı Çalışan Adım Şeridi */
.active-timer-banner {
  background: var(--surface);
  border: 1px solid #bfdbfe;
  border-left: 4px solid var(--accent);
  border-radius: var(--radius-lg);
  padding: 12px 18px;
  margin-bottom: 18px;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.active-timer-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
}

/* Alt Çizgili Kurumsal Sekmeler */
.corp-tabs {
  display: flex;
  gap: 22px;
  border-bottom: 1px solid var(--border);
  margin-bottom: 20px;
  overflow-x: auto;
}

.corp-tab {
  background: none;
  border: none;
  border-bottom: 2px solid transparent;
  padding: 10px 2px;
  margin-bottom: -1px;
  font-family: inherit;
  font-size: 13.5px;
  font-weight: 500;
  color: var(--muted);
  cursor: pointer;
  white-space: nowrap;
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

.corp-tab:hover {
  color: var(--ink);
}

.corp-tab.active {
  color: var(--primary);
  border-bottom-color: var(--primary);
  font-weight: 600;
}

.tab-count {
  font-size: 11px;
  padding: 1px 6px;
  border-radius: 999px;
  background: var(--surface-subtle);
  color: var(--muted);
}
.corp-tab.active .tab-count {
  background: var(--primary-soft);
  color: var(--primary);
}

/* Sıralı İşlem Satırları */
.steps-container {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  overflow: hidden;
}

.step-item {
  display: grid;
  grid-template-columns: 52px 1fr auto;
  gap: 16px;
  padding: 16px 20px;
  border-bottom: 1px solid var(--border);
  align-items: flex-start;
  transition: background 0.12s ease;
}
.step-item:last-child {
  border-bottom: none;
}
.step-item.running {
  background: #f8fbff;
}
.step-item.completed {
  background: #fcfdfd;
}

.step-index-col {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
}

.step-circle {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  border: 1.5px solid var(--border-strong);
  background: var(--surface);
  color: var(--ink-secondary);
  font-weight: 600;
  font-size: 12.5px;
  display: flex;
  align-items: center;
  justify-content: center;
}
.step-item.running .step-circle {
  border-color: var(--accent);
  background: var(--accent);
  color: #ffffff;
}
.step-item.completed .step-circle {
  border-color: var(--success);
  background: var(--success-bg);
  color: var(--success);
}

.reorder-btns {
  display: flex;
  gap: 2px;
}
.reorder-btn {
  border: none;
  background: transparent;
  color: #94a3b8;
  cursor: pointer;
  padding: 2px 4px;
  font-size: 11px;
  border-radius: 4px;
}
.reorder-btn:hover {
  background: var(--surface-subtle);
  color: var(--ink);
}

.step-title-row {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}

.step-title {
  font-size: 14px;
  font-weight: 600;
  color: var(--ink);
}
.step-item.completed .step-title {
  color: var(--ink-secondary);
}

.step-meta-row {
  display: flex;
  align-items: center;
  gap: 16px;
  flex-wrap: wrap;
  margin-top: 6px;
  font-size: 12px;
  color: var(--muted);
}

.step-note-box {
  margin-top: 8px;
  padding: 8px 12px;
  border-radius: var(--radius-sm);
  font-size: 12.5px;
  background: var(--surface-subtle);
  border-left: 3px solid var(--border-strong);
  color: var(--ink-secondary);
}
.step-note-box.result {
  background: #f8fafc;
  border-left-color: var(--success);
}
.step-note-box.blocker {
  background: var(--danger-bg);
  border-left-color: var(--danger);
  color: var(--danger);
}

.step-right-col {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 8px;
}

.timer-box {
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-size: 14.5px;
  font-weight: 600;
  padding: 4px 10px;
  border-radius: var(--radius-sm);
  background: var(--surface-subtle);
  border: 1px solid var(--border);
  color: var(--ink);
  letter-spacing: 0.03em;
}
.timer-box.running {
  background: var(--primary-soft);
  border-color: #93c5fd;
  color: var(--primary);
}

/* Gantt Zaman Çizelgesi */
.gantt-row {
  display: grid;
  grid-template-columns: 260px 1fr 120px;
  gap: 14px;
  align-items: center;
  padding: 10px 0;
  border-bottom: 1px solid var(--border);
}
.gantt-row:last-child {
  border-bottom: none;
}

.gantt-track {
  position: relative;
  height: 22px;
  background: var(--surface-subtle);
  border-radius: 4px;
  overflow: hidden;
}

.gantt-bar {
  position: absolute;
  top: 3px;
  bottom: 3px;
  border-radius: 3px;
  background: var(--primary);
  color: #ffffff;
  font-size: 10.5px;
  font-weight: 600;
  display: flex;
  align-items: center;
  padding: 0 6px;
  white-space: nowrap;
  overflow: hidden;
}
.gantt-bar.done { background: var(--success); }
.gantt-bar.paused { background: #d97706; }
.gantt-bar.delayed { background: var(--danger); }

/* Form Elemanları */
.form-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 12px;
}

.team-layout-grid {
  display: grid;
  grid-template-columns: 310px 1fr;
  gap: 18px;
  align-items: start;
}

.field {
  display: flex;
  flex-direction: column;
  gap: 5px;
}

.field > span {
  font-size: 12px;
  font-weight: 600;
  color: var(--ink-secondary);
}

.input, .select, .textarea {
  width: 100%;
  border: 1px solid var(--border-strong);
  border-radius: var(--radius-sm);
  padding: 7px 10px;
  font-size: 13px;
  font-family: inherit;
  color: var(--ink);
  background: #ffffff;
  transition: border-color 0.12s ease, box-shadow 0.12s ease;
}

.input:focus, .select:focus, .textarea:focus {
  outline: none;
  border-color: var(--accent);
  box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.1);
}

.textarea {
  min-height: 76px;
  resize: vertical;
}

/* Kurumsal Pop-up / Modal (Sadece ✕ ile kapanır) */
.pt-modal-backdrop {
  display: none;
  position: fixed;
  inset: 0;
  z-index: 9999;
  background: rgba(15, 23, 42, 0.45);
  align-items: center;
  justify-content: center;
  padding: 16px;
}
.pt-modal-backdrop.open {
  display: flex;
}

.pt-modal {
  background: var(--surface);
  width: 100%;
  max-width: 640px;
  max-height: 90vh;
  border-radius: var(--radius-lg);
  border: 1px solid var(--border);
  box-shadow: var(--shadow-modal);
  display: flex;
  flex-direction: column;
  overflow: hidden;
}

.pt-modal-head {
  padding: 14px 20px;
  border-bottom: 1px solid var(--border);
  background: var(--surface);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.pt-modal-head h3 {
  margin: 0;
  font-size: 15px;
  font-weight: 600;
  color: var(--ink);
}

.pt-modal-close {
  width: 30px;
  height: 30px;
  border-radius: var(--radius-sm);
  border: 1px solid var(--border-strong);
  background: var(--surface);
  color: var(--ink-secondary);
  font-size: 14px;
  font-weight: 700;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  transition: background 0.12s ease, color 0.12s ease, border-color 0.12s ease;
}
.pt-modal-close:hover {
  background: var(--danger-bg);
  border-color: var(--danger-border);
  color: var(--danger);
}

.pt-modal-body {
  padding: 18px 20px;
  overflow-y: auto;
}

/* Sadeleştirilmiş Hiyerarşik Proje Kartı (Başlık + Adımlar + Alt Projeler) */
.prj-head-row {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 10px;
}

.prj-head-left {
  display: flex;
  align-items: center;
  gap: 7px;
  flex-wrap: wrap;
  min-width: 0;
  flex: 1;
}

.prj-card-title-lg {
  font-size: 20.5px;
  font-weight: 800;
  color: #0f172a;
  line-height: 1.28;
  letter-spacing: -0.015em;
  overflow-wrap: anywhere;
  word-break: break-word;
}
.prj-card-title-lg:hover {
  color: var(--accent);
}

.prj-head-corners {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  flex-shrink: 0;
}

.btn-xs {
  height: 26px;
  padding: 0 9px;
  font-size: 11.5px;
  font-weight: 600;
  border-radius: 6px;
}

.inline-plus-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 23px;
  height: 23px;
  border-radius: 6px;
  border: 1px solid #93c5fd;
  background: #eff6ff;
  color: #1d4ed8;
  font-family: inherit;
  font-size: 14px;
  font-weight: 800;
  line-height: 1;
  cursor: pointer;
  flex-shrink: 0;
  transition: background 0.12s ease, color 0.12s ease, border-color 0.12s ease;
}
.inline-plus-btn.lg {
  width: 26px;
  height: 26px;
  font-size: 15px;
}
.inline-plus-btn:hover {
  background: #2563eb;
  border-color: #2563eb;
  color: #ffffff;
}

.inline-start-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 23px;
  height: 23px;
  padding: 0;
  border-radius: 6px;
  border: 1px solid #fbbf24;
  background: #fffbeb;
  color: #d97706;
  cursor: pointer;
  flex-shrink: 0;
  transition: background 0.12s ease, color 0.12s ease, border-color 0.12s ease;
}
.inline-start-btn.lg {
  width: 26px;
  height: 26px;
}
.inline-start-btn:hover {
  background: #f59e0b;
  border-color: #d97706;
  color: #ffffff;
}
.inline-start-btn.is-running {
  background: #2563eb;
  border-color: #1d4ed8;
  color: #ffffff;
}
.inline-start-btn.is-running:hover {
  background: #1d4ed8;
  border-color: #1e40af;
}

.inline-done-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 23px;
  height: 23px;
  padding: 0;
  border-radius: 6px;
  border: 1px solid #15803d;
  background: #16a34a;
  color: #ffffff;
  font-family: inherit;
  font-size: 13px;
  font-weight: 800;
  line-height: 1;
  cursor: pointer;
  flex-shrink: 0;
  transition: background 0.12s ease, border-color 0.12s ease, box-shadow 0.12s ease;
}
.inline-done-btn.lg {
  width: 26px;
  height: 26px;
  font-size: 14px;
}
.inline-done-btn:hover {
  background: #15803d;
  border-color: #166534;
  color: #ffffff;
}
.inline-done-btn.is-done {
  background: #15803d;
  border-color: #14532d;
  color: #ffffff;
  box-shadow: 0 0 0 2px #86efac;
}
.inline-done-btn.is-done:hover {
  background: #166534;
  border-color: #14532d;
}

.role-person-tag {
  display: inline-flex;
  align-items: center;
  gap: 3px;
  font-size: 12px;
  color: var(--ink-secondary);
  white-space: nowrap;
}
.role-person-tag strong {
  color: var(--ink);
  font-weight: 600;
}

.tree-subproj-row.is-done {
  background: #f0fdf4;
  border-color: #a7f3d0;
  border-left-color: #059669;
}
.tree-subproj-row.is-done:hover {
  background: #dcfce7;
  border-color: #6ee7b7;
}

.inline-del-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  height: 23px;
  padding: 0 7px;
  border-radius: 6px;
  border: 1px solid var(--danger-border);
  background: #ffffff;
  color: var(--danger);
  font-family: inherit;
  font-size: 11px;
  font-weight: 600;
  line-height: 1;
  cursor: pointer;
  flex-shrink: 0;
  transition: background 0.12s ease, border-color 0.12s ease;
}
.inline-del-btn.lg {
  height: 26px;
  padding: 0 8px;
  font-size: 11.5px;
}
.inline-del-btn:hover {
  background: var(--danger-bg);
  border-color: #f87171;
}

.done-count-pill {
  display: inline-flex;
  align-items: center;
  padding: 2px 9px;
  border-radius: 999px;
  background: #f1f5f9;
  border: 1px solid #cbd5e1;
  color: #0f172a;
  font-size: 11.5px;
  font-weight: 700;
  white-space: nowrap;
}

.done-count-sm {
  font-size: 11.5px;
  font-weight: 700;
  color: var(--primary);
  white-space: nowrap;
}

.prj-steps-tree {
  margin-top: 11px;
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.prj-steps-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}

.prj-steps-lbl {
  font-size: 11.5px;
  font-weight: 700;
  color: var(--muted);
  text-transform: uppercase;
  letter-spacing: 0.03em;
}

.steps-add-inline-btn {
  border: 1px solid #bfdbfe;
  background: #eff6ff;
  color: #1d4ed8;
  border-radius: 999px;
  padding: 2px 10px;
  font-family: inherit;
  font-size: 11.5px;
  font-weight: 700;
  cursor: pointer;
  white-space: nowrap;
  transition: background 0.12s ease, border-color 0.12s ease, color 0.12s ease;
}
.steps-add-inline-btn:hover {
  background: #2563eb;
  border-color: #2563eb;
  color: #ffffff;
}

.steps-all-toggle-btn {
  border: 1px solid #cbd5e1;
  background: #ffffff;
  color: var(--primary);
  border-radius: 999px;
  padding: 2px 10px;
  font-family: inherit;
  font-size: 11.5px;
  font-weight: 700;
  cursor: pointer;
  white-space: nowrap;
  transition: background 0.12s ease, border-color 0.12s ease;
}
.steps-all-toggle-btn:hover,
.steps-all-toggle-btn.active {
  background: var(--primary-soft);
  border-color: var(--accent);
}

.prj-steps-list {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.tree-step-block[hidden] {
  display: none !important;
}

.tree-step-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px 14px;
  flex-wrap: wrap;
  padding: 8px 11px;
  border-radius: 8px;
  background: #f8fafc;
  border: 1px solid #e2e8f0;
  cursor: pointer;
  transition: background 0.12s ease, border-color 0.12s ease;
}
.tree-step-row:hover {
  border-color: #cbd5e1;
  background: #f1f5f9;
}
.tree-step-row.is-done {
  background: #f8fdfb;
  border-color: #a7f3d0;
}

.tree-step-left {
  display: flex;
  align-items: center;
  gap: 6px;
  flex-wrap: wrap;
  min-width: 0;
  flex: 1;
}

.tree-step-title {
  font-size: 13.5px;
  font-weight: 600;
  color: var(--ink);
  overflow-wrap: anywhere;
  word-break: break-word;
}
.tree-step-title:hover {
  color: var(--accent);
  text-decoration: underline;
}
.tree-step-row.is-done .tree-step-title {
  color: var(--ink-secondary);
}

.tree-step-right {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
  font-size: 12px;
}

.tree-step-person {
  color: var(--ink-secondary);
  font-size: 12px;
}

.tree-step-subs {
  margin: 5px 0 2px 18px;
  padding-left: 10px;
  border-left: 2px solid #93c5fd;
  display: flex;
  flex-direction: column;
  gap: 5px;
}

.prj-direct-subs {
  margin-top: 8px;
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.tree-subproj-wrap {
  display: flex;
  flex-direction: column;
  gap: 5px;
}

.tree-subproj-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 6px 12px;
  padding: 7px 11px;
  background: #eff6ff;
  border: 1px solid #bfdbfe;
  border-left: 3px solid #2563eb;
  border-radius: 8px;
  cursor: pointer;
  transition: background 0.12s ease, border-color 0.12s ease, box-shadow 0.12s ease;
}
.tree-subproj-row:hover {
  background: #dbeafe;
  border-color: #60a5fa;
  box-shadow: 0 2px 6px rgba(37, 99, 235, 0.1);
}

.tree-subproj-left {
  display: flex;
  align-items: center;
  gap: 6px;
  flex-wrap: wrap;
  min-width: 0;
  flex: 1;
}

.tree-subproj-arrow {
  color: #2563eb;
  font-weight: 800;
  font-size: 13px;
}

.tree-subproj-title {
  font-weight: 700;
  font-size: 13.5px;
  color: #0f172a;
  overflow-wrap: anywhere;
  word-break: break-word;
}
.tree-subproj-title:hover {
  color: #1d4ed8;
}

.tree-subproj-right {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
  font-size: 11.5px;
  color: var(--ink-secondary);
}

.tree-nested-subs {
  margin-left: 16px;
  padding-left: 10px;
  border-left: 2px dashed #93c5fd;
  display: flex;
  flex-direction: column;
  gap: 5px;
}

@media (max-width: 768px) {
  .prj-card-title-lg {
    font-size: 18.5px;
  }
  .tree-step-subs {
    margin-left: 8px;
    padding-left: 8px;
  }
  .tree-nested-subs {
    margin-left: 8px;
    padding-left: 8px;
  }
}

/* Proje Altındaki Alt Proje Satırları & Alt Proje Detay Pop-up Penceresi */
.dash-subproj-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 10px;
  padding: 8px 12px;
  background: #f8fafc;
  border: 1px solid #dbeafe;
  border-left: 3px solid #2563eb;
  border-radius: 8px;
  cursor: pointer;
  transition: background 0.14s ease, border-color 0.14s ease, box-shadow 0.14s ease;
}
.dash-subproj-row:hover {
  background: #eff6ff;
  border-color: #93c5fd;
  box-shadow: 0 2px 8px rgba(37, 99, 235, 0.08);
}

.subproj-iframe-backdrop {
  z-index: 9980;
  padding: 16px;
}

.subproj-iframe-window {
  width: min(1240px, 96vw);
  max-width: 1240px;
  height: min(91dvh, 920px);
  max-height: 92dvh;
  border-radius: 14px;
  border: 1px solid var(--border-strong);
  box-shadow: 0 25px 60px -15px rgba(15, 23, 42, 0.38);
  display: flex;
  flex-direction: column;
  overflow: hidden;
}

.subproj-iframe-head {
  padding: 11px 18px;
  background: #f8fafc;
  border-bottom: 1px solid var(--border-strong);
  flex-shrink: 0;
}

.subproj-iframe-title-wrap {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
  min-width: 0;
}

.subproj-iframe-badge {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 2px 8px;
  border-radius: 999px;
  font-size: 11.5px;
  font-weight: 700;
  background: #dbeafe;
  color: #1e40af;
  white-space: nowrap;
}

.subproj-iframe-body {
  position: relative;
  flex: 1 1 auto;
  min-height: 0;
  background: var(--bg);
}

.subproj-iframe-loader {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 13.5px;
  font-weight: 600;
  color: var(--muted);
  background: var(--bg);
  z-index: 2;
}
.subproj-iframe-loader[hidden] {
  display: none !important;
}

.subproj-iframe-el {
  width: 100%;
  height: 100%;
  border: none;
  display: block;
  background: var(--bg);
}

/* Pop-up İçinde Açılan Alt Proje Görünümü (?popup=1) */
body.popup-embed-mode .main-area {
  margin-left: 0 !important;
}
body.popup-embed-mode .topbar {
  padding: 10px 20px;
}
body.popup-embed-mode .page-wrap {
  padding: 16px 20px 32px;
  max-width: 100%;
}

@media (max-width: 768px) {
  .subproj-iframe-backdrop {
    padding: 0;
    align-items: flex-end;
  }
  .subproj-iframe-window {
    width: 100%;
    max-width: 100%;
    height: 94dvh;
    max-height: 94dvh;
    border-radius: 16px 16px 0 0;
  }
  body.popup-embed-mode .page-wrap {
    padding: 12px 12px 28px;
  }
}

/* Mobil Uyum */
@media (max-width: 960px) {
  .sidebar {
    transform: translateX(-102%);
    transition: transform 0.2s ease;
    box-shadow: var(--shadow-modal);
  }
  .sidebar.open {
    transform: translateX(0);
  }
  .main-area {
    margin-left: 0;
  }
  .mob-menu-btn {
    display: inline-flex;
  }
  .topbar {
    padding: 10px 16px;
  }
  .page-wrap {
    padding: 16px 16px 40px;
  }
  .metric-strip {
    grid-template-columns: 1fr 1fr;
  }
  .metric-cell:nth-child(2) {
    border-right: none;
  }
  .metric-cell:nth-child(1), .metric-cell:nth-child(2) {
    border-bottom: 1px solid var(--border);
  }
  .step-item {
    grid-template-columns: 40px 1fr;
  }
  .step-right-col {
    grid-column: 1 / -1;
    flex-direction: row;
    justify-content: space-between;
    align-items: center;
    width: 100%;
    padding-top: 8px;
    border-top: 1px dashed var(--border);
  }
  .gantt-row {
    grid-template-columns: 1fr;
    gap: 6px;
  }
  .team-layout-grid {
    grid-template-columns: 1fr;
  }
}

@media print {
  body {
    background: #ffffff !important;
    -webkit-print-color-adjust: exact !important;
    print-color-adjust: exact !important;
  }
  .no-print, .sidebar, .topbar {
    display: none !important;
  }
  .main-area {
    margin-left: 0 !important;
  }
  .page-wrap {
    padding: 0 !important;
    max-width: none !important;
  }
  .card, .metric-strip {
    box-shadow: none !important;
    break-inside: avoid;
  }
}

/* Bildirim Zili, Yaklaşan/Geciken Merkezi & Sağ Üst Profil Menüsü */
.notif-wrap,
.profile-wrap {
  position: relative;
}
.notif-btn {
  position: relative;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  height: 36px;
  padding: 0 12px;
  border-radius: var(--radius);
  border: 1px solid var(--border-strong);
  background: var(--surface);
  color: var(--ink-secondary);
  font-family: inherit;
  font-size: 12.5px;
  font-weight: 600;
  cursor: pointer;
  transition: background 0.14s ease, border-color 0.14s ease, color 0.14s ease;
}
.notif-btn:hover {
  background: var(--surface-subtle);
  color: var(--ink);
}
.notif-btn.has-warn {
  background: #fffbeb;
  border-color: #fcd34d;
  color: #92400e;
}
.notif-btn.has-warn:hover {
  background: #fef3c7;
}
.notif-btn.has-danger {
  background: #fffafa;
  border-color: #fca5a5;
  color: #991b1b;
}
.notif-btn.has-danger:hover {
  background: #fef2f2;
}
.notif-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 19px;
  height: 19px;
  padding: 0 5px;
  border-radius: 999px;
  background: var(--danger);
  color: #ffffff;
  font-size: 11px;
  font-weight: 700;
}
.notif-badge.tone-warning {
  background: #d97706;
}
.notif-badge.tone-info {
  background: var(--accent);
}
.notif-popover {
  display: none;
  position: absolute;
  right: 0;
  top: calc(100% + 8px);
  width: 470px;
  max-width: calc(100vw - 24px);
  background: var(--surface);
  border: 1px solid var(--border-strong);
  border-radius: 12px;
  box-shadow: var(--shadow-modal);
  z-index: 500;
  overflow: hidden;
}
.notif-popover.open {
  display: block;
}
.notif-head {
  padding: 12px 16px;
  border-bottom: 1px solid var(--border);
  background: #f8fafc;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}

.notif-kpi-strip {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 6px;
  padding: 10px 12px;
  background: #f8fafc;
  border-bottom: 1px solid var(--border);
}
.notif-kpi-box {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 6px 4px;
  border-radius: 8px;
  background: #ffffff;
  border: 1px solid var(--border);
  text-align: center;
  transition: border-color 0.12s ease, background 0.12s ease;
}
.notif-kpi-box:hover {
  border-color: var(--accent);
  background: #eff6ff;
}
.notif-kpi-box strong {
  font-size: 15px;
  font-weight: 700;
  color: var(--ink);
  line-height: 1.15;
}
.notif-kpi-box span {
  font-size: 10.5px;
  font-weight: 600;
  color: var(--muted);
  margin-top: 2px;
  white-space: nowrap;
}
.notif-kpi-box.warn {
  background: #fffbeb;
  border-color: #fde68a;
}
.notif-kpi-box.warn strong {
  color: var(--warning);
}
.notif-kpi-box.danger {
  background: #fef2f2;
  border-color: #fecaca;
}
.notif-kpi-box.danger strong {
  color: var(--danger);
}

.notif-tabs {
  display: grid;
  grid-template-columns: 1fr 1fr;
  border-bottom: 1px solid var(--border);
  background: #ffffff;
}
.notif-tab-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 9px 10px;
  border: none;
  border-bottom: 2px solid transparent;
  background: transparent;
  font-family: inherit;
  font-size: 12.5px;
  font-weight: 600;
  color: var(--muted);
  cursor: pointer;
  transition: color 0.12s ease, background 0.12s ease, border-color 0.12s ease;
}
.notif-tab-btn:hover {
  background: #f8fafc;
  color: var(--ink);
}
.notif-tab-btn.active {
  color: var(--primary);
  border-bottom-color: var(--primary);
  background: #f8fbff;
}
.notif-tab-cnt {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 18px;
  height: 18px;
  padding: 0 5px;
  border-radius: 999px;
  font-size: 11px;
  font-weight: 700;
  background: var(--surface-subtle);
  color: var(--muted);
}
.notif-tab-cnt.warn {
  background: var(--warning-bg);
  color: var(--warning);
  border: 1px solid var(--warning-border);
}
.notif-tab-cnt.danger {
  background: var(--danger-bg);
  color: var(--danger);
  border: 1px solid var(--danger-border);
}
.notif-tab-cnt.info {
  background: var(--primary-soft);
  color: var(--primary);
}

.notif-list {
  max-height: min(390px, 62dvh);
  overflow-y: auto;
}
.notif-list[hidden] {
  display: none !important;
}
.notif-alert-item {
  display: flex;
  flex-direction: column;
  gap: 5px;
  padding: 11px 15px;
  border-bottom: 1px solid var(--border);
  border-left: 3px solid #f59e0b;
  transition: background 0.12s ease;
}
.notif-alert-item.is-delayed {
  border-left-color: #dc2626;
  background: #fffdfd;
}
.notif-alert-item:last-child {
  border-bottom: none;
}
.notif-alert-item:hover {
  background: #f8fafc;
}
.notif-alert-top {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 8px;
}
.notif-alert-proj {
  display: flex;
  align-items: center;
  gap: 6px;
  flex-wrap: wrap;
  min-width: 0;
  font-size: 12.5px;
  color: var(--ink);
}
.notif-alert-step {
  font-size: 12px;
  font-weight: 500;
  color: var(--ink-secondary);
  line-height: 1.35;
}
.notif-alert-meta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  flex-wrap: wrap;
  font-size: 11.5px;
  color: var(--muted);
}
.notif-alert-meta strong {
  color: var(--ink);
}
.notif-go-lbl {
  font-style: normal;
  font-weight: 600;
  color: var(--accent);
}

.notif-item {
  display: block;
  padding: 11px 16px;
  border-bottom: 1px solid var(--border);
  transition: background 0.12s ease;
}
.notif-item:last-child {
  border-bottom: none;
}
.notif-item:hover {
  background: #f8fafc;
}
.notif-item.unread {
  background: #eff6ff;
  border-left: 3px solid var(--accent);
}

/* Sağ Üst Köşe Kullanıcı Profili */
.profile-btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  height: 36px;
  padding: 0 10px 0 5px;
  border-radius: 999px;
  border: 1px solid var(--border-strong);
  background: var(--surface);
  color: var(--ink);
  font-family: inherit;
  cursor: pointer;
  transition: background 0.14s ease, border-color 0.14s ease, box-shadow 0.14s ease;
}
.profile-btn:hover {
  background: var(--surface-subtle);
  border-color: #94a3b8;
}
.profile-avatar {
  width: 26px;
  height: 26px;
  border-radius: 50%;
  background: var(--primary);
  color: #ffffff;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.02em;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}
.profile-avatar.lg {
  width: 38px;
  height: 38px;
  font-size: 13.5px;
}
.profile-btn-meta {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  line-height: 1.15;
  text-align: left;
  max-width: 145px;
}
.profile-btn-meta strong {
  font-size: 12px;
  font-weight: 600;
  color: var(--ink);
  max-width: 100%;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.profile-btn-meta span {
  font-size: 10.5px;
  color: var(--muted);
  max-width: 100%;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.profile-chevron {
  width: 13px !important;
  height: 13px !important;
  color: var(--muted);
}
.profile-popover {
  display: none;
  position: absolute;
  right: 0;
  top: calc(100% + 8px);
  width: 265px;
  max-width: calc(100vw - 24px);
  background: var(--surface);
  border: 1px solid var(--border-strong);
  border-radius: 12px;
  box-shadow: var(--shadow-modal);
  z-index: 510;
  overflow: hidden;
}
.profile-popover.open {
  display: block;
}
.profile-pop-head {
  padding: 14px 16px;
  background: #f8fafc;
  border-bottom: 1px solid var(--border);
  display: flex;
  align-items: center;
  gap: 11px;
}
.profile-pop-name {
  display: block;
  font-size: 13px;
  font-weight: 700;
  color: var(--ink);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.profile-pop-sub {
  display: block;
  font-size: 11.5px;
  color: var(--muted);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.profile-role-pill {
  display: inline-block;
  margin-top: 4px;
  padding: 1px 7px;
  border-radius: 999px;
  font-size: 10.5px;
  font-weight: 600;
  background: var(--primary-soft);
  color: var(--primary);
}
.profile-pop-links {
  padding: 6px;
  display: flex;
  flex-direction: column;
  gap: 2px;
}
.profile-pop-item {
  display: flex;
  align-items: center;
  gap: 9px;
  padding: 8px 10px;
  border-radius: 7px;
  font-size: 12.5px;
  font-weight: 500;
  color: var(--ink-secondary);
  transition: background 0.12s ease, color 0.12s ease;
}
.profile-pop-item:hover {
  background: var(--surface-subtle);
  color: var(--ink);
}
.profile-pop-item.danger {
  color: var(--danger);
}
.profile-pop-item.danger:hover {
  background: var(--danger-bg);
  color: var(--danger);
}
.profile-pop-divider {
  height: 1px;
  background: var(--border);
  margin: 4px 6px;
}

.side-badge {
  margin-left: auto;
  padding: 1px 7px;
  border-radius: 999px;
  font-size: 11px;
  font-weight: 700;
  background: var(--primary-soft);
  color: var(--primary);
}
.side-badge.urgent {
  background: var(--warning-bg);
  color: var(--warning);
  border: 1px solid var(--warning-border);
}

/* Ek Dosya Kartları & Vurgulama */
.step-item:target {
  background: #eff6ff;
  box-shadow: inset 4px 0 0 var(--accent);
}
.att-chip-list {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  margin-top: 10px;
}
.att-chip {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 4px 9px;
  border-radius: var(--radius-sm);
  background: #f8fafc;
  border: 1px solid var(--border-strong);
  font-size: 12px;
  color: var(--ink);
}
.att-chip a:hover {
  color: var(--accent);
  text-decoration: underline;
}
.att-del-btn {
  border: none;
  background: transparent;
  color: #94a3b8;
  cursor: pointer;
  padding: 0 2px;
  font-size: 12px;
  line-height: 1;
}
.att-del-btn:hover {
  color: var(--danger);
}

/* Araya '+' İle Ekleme Çizgileri ve Sürükle-Bırak (Tut-Taşı) Stilleri */
.insert-between-row {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 4px 12px;
  background: #f8fafc;
  border-bottom: 1px dashed #e2e8f0;
}
.insert-between-row::before {
  content: "";
  position: absolute;
  left: 16px;
  right: 16px;
  height: 1px;
  background: linear-gradient(90deg, transparent, #cbd5e1 20%, #cbd5e1 80%, transparent);
  pointer-events: none;
}
.insert-between-btn {
  position: relative;
  z-index: 1;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 3px 11px;
  border-radius: 999px;
  border: 1px dashed #93c5fd;
  background: #ffffff;
  color: var(--primary);
  font-family: inherit;
  font-size: 11.5px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.14s ease;
}
.insert-between-btn:hover {
  background: #eff6ff;
  border-style: solid;
  border-color: var(--accent);
  color: var(--accent);
  transform: translateY(-1px);
  box-shadow: 0 2px 6px rgba(37, 99, 235, 0.12);
}
.plus-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 17px;
  height: 17px;
  border-radius: 50%;
  background: #dbeafe;
  color: var(--primary);
  font-size: 12px;
  font-weight: 700;
  line-height: 1;
}
.insert-between-btn:hover .plus-badge {
  background: var(--accent);
  color: #ffffff;
}

.proj-insert-row td {
  padding: 0 !important;
  border-bottom: none !important;
  background: transparent !important;
}
.proj-insert-row:hover td {
  background: transparent !important;
}

.drag-handle {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 24px;
  height: 24px;
  border-radius: 5px;
  color: #94a3b8;
  font-size: 15px;
  line-height: 1;
  cursor: grab;
  user-select: none;
  transition: background 0.12s ease, color 0.12s ease;
}
.drag-handle:hover {
  background: #eef2ff;
  color: var(--primary);
}
.drag-handle:active {
  cursor: grabbing;
}

.dragging-card {
  opacity: 0.48;
  background: #eff6ff !important;
}
.drag-over-top {
  box-shadow: inset 0 3px 0 0 var(--accent) !important;
}
.drag-over-bottom {
  box-shadow: inset 0 -3px 0 0 var(--accent) !important;
}
tr.drag-over-top td {
  border-top: 2.5px solid var(--accent) !important;
}
tr.drag-over-bottom td {
  border-bottom: 2.5px solid var(--accent) !important;
}

/* ==========================================================================
   YENİ SADE & MOBİL UYUMLU PROJE PORTFÖYÜ TASARIMI (v5)
   ========================================================================== */

.show-on-mob {
  display: none;
}

.sidebar-backdrop {
  display: none;
}

.mob-sidebar-close {
  display: none;
  border: 1px solid var(--border);
  background: var(--surface-subtle);
  color: var(--ink-secondary);
  width: 30px;
  height: 30px;
  border-radius: 6px;
  font-size: 14px;
  cursor: pointer;
}

.mob-bottom-nav {
  display: none;
}

/* 1. Daraltılabilir Erken Takip Uyarı Kartı */
.alert-panel {
  background: #ffffff;
  border: 1px solid #fde68a;
  border-left: 4px solid #f59e0b;
  border-radius: 12px;
  box-shadow: var(--shadow-xs);
  margin-bottom: 18px;
  overflow: hidden;
}

.alert-panel-head {
  padding: 11px 16px;
  background: #fffbeb;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  cursor: pointer;
  user-select: none;
}

.alert-panel-title {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 12.5px;
  font-weight: 700;
  color: #92400e;
}

.alert-pulse-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #f59e0b;
  box-shadow: 0 0 0 3px rgba(245, 158, 11, 0.2);
  flex-shrink: 0;
}

.alert-panel-link {
  font-size: 12px;
  font-weight: 600;
  color: var(--primary);
  white-space: nowrap;
}
.alert-panel-link:hover {
  text-decoration: underline;
}

.alert-toggle-btn {
  border: 1px solid #fcd34d;
  background: #ffffff;
  color: #92400e;
  border-radius: 6px;
  padding: 3px 8px;
  font-size: 11px;
  font-weight: 600;
  cursor: pointer;
  white-space: nowrap;
}

.alert-panel-body {
  border-top: 1px solid #fef3c7;
}

.alert-row-card {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 10px 16px;
  border-bottom: 1px solid #f1f5f9;
  transition: background 0.12s ease;
}
.alert-row-card:last-child {
  border-bottom: none;
}
.alert-row-card:hover {
  background: #f8fafc;
}

.alert-row-main {
  min-width: 0;
  flex: 1;
}

.alert-row-proj {
  display: flex;
  align-items: center;
  gap: 7px;
  flex-wrap: wrap;
  font-size: 13px;
  color: var(--ink);
}

.alert-row-step {
  font-size: 12.5px;
  color: var(--ink-secondary);
  margin-top: 2px;
}

.alert-row-person {
  color: var(--muted);
  font-size: 12px;
}

.alert-row-right {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-shrink: 0;
}

.alert-due-date {
  font-size: 12px;
  color: var(--muted);
}
.alert-due-date strong {
  color: var(--ink);
}

.alert-go-arrow {
  font-size: 12px;
  font-weight: 600;
  color: var(--accent);
}

/* 2. Sade Özet KPI Kartları */
.kpi-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 12px;
  margin-bottom: 18px;
}

.kpi-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 14px 16px;
  display: flex;
  align-items: center;
  gap: 12px;
  box-shadow: var(--shadow-xs);
}

.kpi-icon {
  width: 40px;
  height: 40px;
  border-radius: 10px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 17px;
  flex-shrink: 0;
}
.kpi-icon.blue { background: #eff6ff; color: #1d4ed8; }
.kpi-icon.amber { background: #fffbeb; color: #b45309; }
.kpi-icon.green { background: #ecfdf5; color: #047857; }
.kpi-icon.red { background: #fef2f2; color: #b91c1c; }
.kpi-icon.slate { background: #f1f5f9; color: #334155; }

.kpi-info {
  min-width: 0;
}

.kpi-val {
  font-size: 20px;
  font-weight: 700;
  color: var(--ink);
  line-height: 1.15;
  letter-spacing: -0.02em;
}

.kpi-lbl {
  font-size: 12px;
  font-weight: 600;
  color: var(--ink-secondary);
  margin-top: 2px;
}

.kpi-sub {
  font-size: 11px;
  color: var(--muted);
}

/* 3. Filtre & Arama Çubuğu */
.portfolio-toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 14px;
  flex-wrap: wrap;
  width: 100%;
  max-width: 100%;
  min-width: 0;
}

.filter-pills-scroll {
  display: flex;
  align-items: center;
  gap: 6px;
  max-width: 100%;
  min-width: 0;
  overflow-x: auto;
  padding-bottom: 2px;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none;
}
.filter-pills-scroll::-webkit-scrollbar {
  display: none;
}

.filter-pill {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  height: 34px;
  padding: 0 12px;
  border-radius: 999px;
  background: var(--surface);
  border: 1px solid var(--border-strong);
  color: var(--ink-secondary);
  font-size: 12.5px;
  font-weight: 600;
  white-space: nowrap;
  transition: all 0.14s ease;
}
.filter-pill:hover {
  background: var(--surface-subtle);
  color: var(--ink);
}
.filter-pill.active {
  background: var(--primary);
  border-color: var(--primary);
  color: #ffffff;
}

.filter-pill-cnt {
  font-size: 11px;
  padding: 1px 6px;
  border-radius: 999px;
  background: var(--surface-subtle);
  color: var(--muted);
}
.filter-pill.active .filter-pill-cnt {
  background: rgba(255, 255, 255, 0.2);
  color: #ffffff;
}

.toolbar-right-group {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}

.toolbar-search-form {
  position: relative;
  display: flex;
  align-items: center;
  width: 270px;
}

.search-ic {
  position: absolute;
  left: 10px;
  width: 15px;
  height: 15px;
  color: var(--muted);
  pointer-events: none;
}

.toolbar-search-inp {
  width: 100%;
  height: 34px;
  padding: 0 28px 0 32px;
  border-radius: 8px;
  border: 1px solid var(--border-strong);
  background: var(--surface);
  font-family: inherit;
  font-size: 13px;
  color: var(--ink);
}
.toolbar-search-inp:focus {
  outline: none;
  border-color: var(--accent);
  box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.1);
}

.search-clear-btn {
  position: absolute;
  right: 8px;
  font-size: 12px;
  color: var(--muted);
  padding: 2px 4px;
}

.reorder-toggle-btn.active {
  background: var(--primary-soft);
  border-color: var(--accent);
  color: var(--primary);
}

.reorder-mode-banner {
  background: #eff6ff;
  border: 1px solid #bfdbfe;
  color: #1e3a8a;
  border-radius: 10px;
  padding: 10px 14px;
  margin-bottom: 12px;
  font-size: 12.5px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  flex-wrap: wrap;
}
.reorder-mode-banner[hidden] {
  display: none !important;
}

/* 4. Modern Proje Kartları (Yatay Scrollsuz, Okunaklı Kart Görünümü) */
.prj-card-list {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.prj-insert-slot {
  display: none;
  justify-content: center;
  padding: 2px 0;
}
.prj-card-list.reorder-mode .prj-insert-slot {
  display: flex;
}

.prj-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-left: 4px solid #94a3b8;
  border-radius: 12px;
  padding: 16px 20px;
  box-shadow: var(--shadow-xs);
  transition: border-color 0.15s ease, box-shadow 0.15s ease, transform 0.15s ease;
}
.prj-card:hover {
  border-color: #cbd5e1;
  box-shadow: 0 6px 18px -6px rgba(15, 23, 42, 0.08);
}
.prj-card.tone-active { border-left-color: #2563eb; }
.prj-card.tone-done { border-left-color: #059669; }
.prj-card.tone-paused { border-left-color: #d97706; }
.prj-card.tone-danger { border-left-color: #dc2626; }
.prj-card.tone-neutral { border-left-color: #94a3b8; }

.prj-card-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 260px;
  gap: 20px;
  align-items: center;
}

.prj-card-main {
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.prj-top-tags {
  display: flex;
  align-items: center;
  gap: 7px;
  flex-wrap: wrap;
}

.prj-order-chip {
  display: inline-flex;
  align-items: center;
  gap: 3px;
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-size: 11.5px;
  font-weight: 700;
  color: var(--muted);
  background: #f8fafc;
  border: 1px solid var(--border);
  border-radius: 6px;
  padding: 1px 6px 1px 4px;
}
.prj-order-chip .drag-handle {
  width: 16px;
  height: 18px;
  font-size: 13px;
}

.code-pill {
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-size: 11.5px;
  font-weight: 600;
  color: var(--primary);
  background: #eff6ff;
  border: 1px solid #dbeafe;
  padding: 1px 7px;
  border-radius: 6px;
  white-space: nowrap;
}

.prj-cat-lbl {
  font-size: 12px;
  font-weight: 500;
  color: var(--muted);
}

.prio-pill {
  font-size: 11px;
  font-weight: 700;
  color: var(--danger);
  background: var(--danger-bg);
  border: 1px solid var(--danger-border);
  padding: 1px 7px;
  border-radius: 6px;
}

.prj-card-title {
  font-size: 16px;
  font-weight: 700;
  color: var(--ink);
  line-height: 1.35;
  letter-spacing: -0.01em;
  display: inline-block;
}
.prj-card-title:hover {
  color: var(--accent);
}

/* Sıradaki Adım Önizleme Kutusu */
.prj-next-box {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
  padding: 7px 11px;
  border-radius: 8px;
  background: #f8fafc;
  border: 1px solid #e2e8f0;
  font-size: 12.5px;
  color: var(--ink-secondary);
  transition: background 0.12s ease, border-color 0.12s ease;
}
a.prj-next-box:hover,
button.prj-next-box:hover {
  background: #eff6ff;
  border-color: #bfdbfe;
  color: var(--primary);
}
.prj-next-box.done {
  background: #ecfdf5;
  border-color: #a7f3d0;
  color: #047857;
  font-weight: 600;
}
.prj-next-box.empty {
  background: #fafafa;
  border-style: dashed;
  color: var(--muted);
}

.prj-next-tag {
  font-size: 11px;
  font-weight: 700;
  color: var(--primary);
  background: #dbeafe;
  padding: 1px 6px;
  border-radius: 4px;
  white-space: nowrap;
}

.prj-next-title {
  font-weight: 600;
  color: var(--ink);
}

.prj-next-due {
  margin-left: auto;
  font-size: 11.5px;
  font-weight: 600;
  color: var(--muted);
}
.prj-next-due.warn { color: var(--warning); }
.prj-next-due.danger { color: var(--danger); }

.prj-meta-strip {
  display: flex;
  align-items: center;
  gap: 16px;
  flex-wrap: wrap;
  font-size: 12.5px;
  color: var(--ink-secondary);
  margin-top: 2px;
}

.prj-meta-item {
  display: inline-flex;
  align-items: center;
  gap: 4px;
}

.prj-backup-lbl {
  color: var(--muted);
  font-size: 12px;
}

/* Sağ Sütun: İlerleme & Butonlar */
.prj-card-side {
  display: flex;
  flex-direction: column;
  gap: 12px;
  padding-left: 18px;
  border-left: 1px solid var(--border);
}

.prj-prog-block {
  display: flex;
  flex-direction: column;
  gap: 5px;
}

.prj-prog-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
}

.prj-prog-steps {
  font-size: 12px;
  font-weight: 500;
  color: var(--muted);
}

.prj-prog-pct {
  font-size: 15px;
  font-weight: 700;
  color: var(--ink);
}

.prj-actions-row {
  display: flex;
  align-items: center;
  gap: 6px;
  flex-wrap: wrap;
}

.prj-open-btn {
  flex: 1;
  height: 32px;
  font-size: 12.5px;
}

.prj-reorder-bar {
  display: none;
  align-items: center;
  gap: 4px;
  flex-wrap: wrap;
  padding-top: 8px;
  border-top: 1px dashed var(--border);
}
.prj-card-list.reorder-mode .prj-reorder-bar {
  display: flex;
}

.reorder-chip-btn {
  border: 1px solid var(--border-strong);
  background: #f8fafc;
  color: var(--ink-secondary);
  border-radius: 6px;
  padding: 3px 7px;
  font-size: 11px;
  font-weight: 600;
  cursor: pointer;
}
.reorder-chip-btn:hover {
  background: #eff6ff;
  border-color: var(--accent);
  color: var(--primary);
}

/* ==========================================================================
   TABLET & CEP TELEFONU (MOBİL) TAM UYUM KATMANI
   ========================================================================== */

@media (max-width: 960px) {
  .sidebar-backdrop.open {
    display: block;
    position: fixed;
    inset: 0;
    background: rgba(15, 23, 42, 0.45);
    z-index: 195;
  }

  .mob-sidebar-close {
    display: inline-flex;
    align-items: center;
    justify-content: center;
  }

  .prj-card-grid {
    grid-template-columns: 1fr;
    gap: 14px;
  }

  .prj-card-side {
    padding-left: 0;
    padding-top: 12px;
    border-left: none;
    border-top: 1px solid var(--border);
  }
}

@media (max-width: 768px) {
  .hide-on-mob {
    display: none !important;
  }

  .show-on-mob {
    display: flex;
  }

  .mob-proj-quickbar {
    gap: 6px;
    overflow-x: auto;
    padding-bottom: 4px;
    margin-bottom: 12px;
    -webkit-overflow-scrolling: touch;
  }

  .page-subtitle {
    display: none;
  }

  .page-title {
    font-size: 15px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    max-width: 48vw;
  }

  .notif-btn {
    padding: 0 9px;
    height: 34px;
  }
  .notif-btn-label {
    display: none;
  }
  .profile-btn {
    padding: 0 4px;
    height: 34px;
  }
  .profile-btn-meta,
  .profile-chevron {
    display: none;
  }

  .topbar {
    min-height: 54px;
    padding: 8px 12px;
    gap: 8px;
    width: 100%;
    max-width: 100vw;
  }

  .notif-popover {
    position: fixed;
    left: 10px;
    right: 10px;
    top: 58px;
    width: auto;
    max-width: none;
  }

  .profile-popover {
    position: fixed;
    right: 10px;
    left: auto;
    top: 58px;
    width: min(270px, calc(100vw - 20px));
  }

  .page-wrap {
    width: 100%;
    max-width: 100vw;
    min-width: 0;
    overflow-x: clip;
    padding: 12px 12px calc(78px + env(safe-area-inset-bottom, 0px));
  }

  .filter-pills-scroll {
    flex-wrap: wrap;
    overflow-x: visible;
    gap: 6px;
  }

  .filter-pill {
    height: 30px;
    padding: 0 10px;
    font-size: 12px;
  }

  /* Mobil En Altta Sabit & Ekrana Tam Sığan Kısayol Çubuğu */
  .mob-bottom-nav {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    position: fixed;
    left: 0;
    right: 0;
    bottom: 0;
    width: 100%;
    max-width: 100vw;
    z-index: 900;
    background: #ffffff;
    border-top: 1px solid var(--border-strong);
    padding: 5px 2px calc(5px + env(safe-area-inset-bottom, 0px));
    box-shadow: 0 -4px 16px rgba(15, 23, 42, 0.08);
    transform: translateZ(0);
    -webkit-transform: translateZ(0);
  }

  .mob-bottom-nav.has-5 {
    grid-template-columns: repeat(5, minmax(0, 1fr));
  }

  .mob-bottom-nav.has-6 {
    grid-template-columns: repeat(6, minmax(0, 1fr));
  }

  .mob-nav-item {
    min-width: 0;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 2px;
    padding: 4px 2px;
    color: var(--muted);
    font-size: 10.5px;
    line-height: 1.15;
    font-weight: 600;
    border-radius: 8px;
    text-align: center;
    -webkit-tap-highlight-color: transparent;
  }
  .mob-nav-item > span:last-child {
    display: block;
    max-width: 100%;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
  }
  .mob-nav-item svg.ic {
    width: 18px;
    height: 18px;
  }
  .mob-nav-item.active {
    color: var(--primary);
    font-weight: 700;
  }

  .mob-nav-ic-wrap {
    position: relative;
    display: inline-flex;
  }

  .mob-nav-dot {
    position: absolute;
    top: -4px;
    right: -8px;
    min-width: 15px;
    height: 15px;
    padding: 0 3px;
    border-radius: 999px;
    background: var(--accent);
    color: #ffffff;
    font-size: 9.5px;
    font-weight: 700;
    display: inline-flex;
    align-items: center;
    justify-content: center;
  }
  .mob-nav-dot.urgent {
    background: var(--danger);
  }

  /* KPI Grid 2x2 Kompakt */
  .kpi-grid {
    grid-template-columns: 1fr 1fr;
    gap: 8px;
    margin-bottom: 14px;
  }

  .kpi-card {
    padding: 11px 12px;
    gap: 10px;
    border-radius: 10px;
  }

  .kpi-icon {
    width: 34px;
    height: 34px;
    font-size: 15px;
    border-radius: 8px;
  }

  .kpi-val {
    font-size: 17.5px;
  }

  .kpi-sub {
    display: none;
  }

  /* Toolbar Mobilde Tam Genişlik */
  .portfolio-toolbar {
    flex-direction: column;
    align-items: stretch;
    gap: 10px;
  }

  .toolbar-right-group {
    width: 100%;
    display: flex;
    gap: 8px;
  }

  .toolbar-search-form {
    flex: 1;
    width: auto;
  }

  /* Erken Uyarı Satırları Mobilde Dikey Hizalı */
  .alert-row-card {
    flex-direction: column;
    align-items: flex-start;
    gap: 8px;
    padding: 11px 14px;
  }

  .alert-row-right {
    width: 100%;
    justify-content: space-between;
    flex-wrap: wrap;
  }

  /* Proje Kartları Mobilde Rahat Okuma & Taşma Engeli */
  .prj-card {
    padding: 14px;
    border-radius: 11px;
    width: 100%;
    max-width: 100%;
    min-width: 0;
  }

  .prj-card-title {
    font-size: 15px;
    overflow-wrap: anywhere;
    word-break: break-word;
  }

  .prj-next-title {
    overflow-wrap: anywhere;
    word-break: break-word;
  }

  .prj-next-due {
    margin-left: 0;
    width: 100%;
  }

  .prj-meta-strip {
    gap: 8px 14px;
    font-size: 12px;
  }

  /* Modallar Mobilde Alt Çekmece (Bottom Sheet) & iOS Zoom Engeli */
  .pt-modal-backdrop {
    align-items: flex-end;
    padding: 0;
  }

  .pt-modal {
    max-width: 100%;
    max-height: 92dvh;
    border-radius: 16px 16px 0 0;
    border-bottom: none;
  }

  .input, .select, .textarea, .toolbar-search-inp {
    font-size: 16px;
  }

  .corp-tabs {
    max-width: 100%;
    min-width: 0;
  }
}

/* Yönetici Sistem İşlem Logları (Audit Logs) Kartları */
.audit-log-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.audit-log-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-left: 4px solid #3b82f6;
  border-radius: 10px;
  padding: 12px 16px;
  box-shadow: var(--shadow-xs);
  display: flex;
  flex-direction: column;
  gap: 6px;
}
.audit-log-card.sev-success { border-left-color: #059669; }
.audit-log-card.sev-warning { border-left-color: #d97706; background: #fffefb; }
.audit-log-card.sev-danger { border-left-color: #dc2626; background: #fffafa; }
.audit-log-card.sev-info { border-left-color: #2563eb; }

.audit-log-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  flex-wrap: wrap;
}

.audit-log-time {
  font-size: 12px;
  font-weight: 600;
  color: var(--muted);
  white-space: nowrap;
}

.audit-log-summary {
  font-size: 13px;
  font-weight: 500;
  color: var(--ink);
  line-height: 1.45;
}

.audit-log-meta {
  display: flex;
  align-items: center;
  gap: 14px;
  flex-wrap: wrap;
  font-size: 12px;
  color: var(--ink-secondary);
  padding-top: 4px;
  border-top: 1px dashed #f1f5f9;
}

/* Açılır-Kapanır Yan Menü (EĞİTİMLERİM Alt Menüleri) */
.side-nav {
  overflow-y: auto;
}

.side-group {
  display: flex;
  flex-direction: column;
}

.side-group-btn {
  width: 100%;
  border: none;
  background: transparent;
  font-family: inherit;
  text-align: left;
  cursor: pointer;
}

.side-chevron {
  margin-left: auto;
  width: 14px !important;
  height: 14px !important;
  color: var(--muted);
  transition: transform 0.18s ease;
}

.side-badge + .side-chevron {
  margin-left: 4px;
}

.side-group.open .side-chevron {
  transform: rotate(180deg);
}

.side-submenu {
  display: none;
  flex-direction: column;
  gap: 2px;
  margin: 3px 0 6px 18px;
  padding-left: 10px;
  border-left: 1.5px solid #cbd5e1;
}

.side-group.open .side-submenu {
  display: flex;
}

.side-sublink {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 6px;
  padding: 6px 10px;
  border-radius: 6px;
  font-size: 12.5px;
  font-weight: 500;
  color: var(--ink-secondary);
  transition: background 0.12s ease, color 0.12s ease;
}
.side-sublink:hover {
  background: var(--surface-subtle);
  color: var(--ink);
}
.side-sublink.active {
  background: var(--primary-soft);
  color: var(--primary);
  font-weight: 700;
}

.side-sub-cnt {
  font-size: 10.5px;
  font-weight: 700;
  padding: 1px 6px;
  border-radius: 999px;
  background: var(--primary-soft);
  color: var(--primary);
}
.side-sub-cnt.urgent {
  background: var(--danger-bg);
  color: var(--danger);
}

/* ==========================================================================
   HAYIRDA YARIŞ TABLOSU (ÜYE TAKİP & SORUMLU SKOR DASHBOARD)
   ========================================================================== */

.hy-top-btn {
  background: #fffbeb;
  border: 1px solid #f59e0b;
  color: #92400e;
  font-weight: 700;
  gap: 6px;
}
.hy-top-btn:hover {
  background: #fef3c7;
  border-color: #d97706;
  color: #78350f;
}

.hy-board-root {
  background: var(--surface);
  border: 1px solid var(--border-strong);
  border-radius: 14px;
  padding: 18px 20px;
  box-shadow: var(--shadow-xs);
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.hy-head-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
  padding-bottom: 12px;
  border-bottom: 1px solid var(--border);
}

.hy-title-group {
  display: flex;
  align-items: center;
  gap: 12px;
  min-width: 0;
}

.hy-trophy-badge {
  width: 40px;
  height: 40px;
  border-radius: 10px;
  background: linear-gradient(135deg, #fef3c7, #fde68a);
  border: 1px solid #f59e0b;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 20px;
  flex-shrink: 0;
}

.hy-main-title {
  margin: 0;
  font-size: 18px;
  font-weight: 800;
  color: var(--ink);
  letter-spacing: -0.015em;
}

.hy-main-sub {
  font-size: 12px;
  color: var(--muted);
  margin-top: 2px;
}

.hy-head-controls {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}

.hy-scope-pills {
  display: inline-flex;
  align-items: center;
  background: #f1f5f9;
  padding: 3px;
  border-radius: 9px;
  border: 1px solid var(--border);
  gap: 2px;
}

.hy-scope-btn {
  border: none;
  background: transparent;
  color: var(--ink-secondary);
  font-family: inherit;
  font-size: 12px;
  font-weight: 600;
  padding: 5px 11px;
  border-radius: 6px;
  cursor: pointer;
  white-space: nowrap;
  transition: background 0.14s ease, color 0.14s ease, box-shadow 0.14s ease;
}
.hy-scope-btn:hover {
  color: var(--ink);
}
.hy-scope-btn.active {
  background: #ffffff;
  color: var(--primary);
  font-weight: 700;
  box-shadow: 0 1px 3px rgba(15, 23, 42, 0.08);
}

.hy-kpi-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
}

.hy-kpi-card {
  background: #f8fafc;
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 11px 14px;
  display: flex;
  flex-direction: column;
  gap: 3px;
}
.hy-kpi-card.takip {
  background: #eff6ff;
  border-color: #bfdbfe;
}
.hy-kpi-card.sorumlu {
  background: #fffbeb;
  border-color: #fde68a;
}
.hy-kpi-card.done {
  background: #ecfdf5;
  border-color: #a7f3d0;
}

.hy-kpi-lbl {
  font-size: 11.5px;
  font-weight: 700;
  color: var(--ink-secondary);
}
.hy-kpi-val {
  font-size: 21px;
  font-weight: 800;
  color: var(--ink);
  line-height: 1.15;
}
.hy-kpi-card.takip .hy-kpi-val { color: #1d4ed8; }
.hy-kpi-card.sorumlu .hy-kpi-val { color: #b45309; }
.hy-kpi-card.done .hy-kpi-val { color: #047857; }
.hy-kpi-note {
  font-size: 11px;
  color: var(--muted);
}

.hy-podium-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
}

.hy-podium-card {
  border: 1px solid var(--border);
  border-radius: 11px;
  padding: 12px 14px;
  background: #ffffff;
  display: flex;
  flex-direction: column;
  gap: 9px;
}
.hy-podium-card.rank-1 {
  background: linear-gradient(180deg, #fffbeb 0%, #ffffff 100%);
  border-color: #f59e0b;
  box-shadow: 0 4px 12px -4px rgba(245, 158, 11, 0.22);
}
.hy-podium-card.rank-2 {
  background: linear-gradient(180deg, #f8fafc 0%, #ffffff 100%);
  border-color: #94a3b8;
}
.hy-podium-card.rank-3 {
  background: linear-gradient(180deg, #fff7ed 0%, #ffffff 100%);
  border-color: #fdba74;
}

.hy-podium-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 6px;
}
.hy-medal {
  font-size: 14px;
  font-weight: 800;
  color: var(--ink);
}
.hy-podium-score-pill {
  font-size: 11.5px;
  font-weight: 800;
  padding: 2px 8px;
  border-radius: 999px;
  background: var(--primary-soft);
  color: var(--primary);
}

.hy-podium-user {
  display: flex;
  align-items: center;
  gap: 10px;
}
.hy-avatar {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: var(--primary);
  color: #ffffff;
  font-size: 12.5px;
  font-weight: 800;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}
.hy-avatar.rank-1 { background: #d97706; }
.hy-avatar.rank-2 { background: #475569; }
.hy-avatar.rank-3 { background: #c2410c; }
.hy-avatar.sm {
  width: 30px;
  height: 30px;
  font-size: 11px;
}

.hy-podium-name {
  display: block;
  font-size: 13.5px;
  font-weight: 700;
  color: var(--ink);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.hy-nesil-tag,
.hy-nesil-inline {
  display: inline-block;
  font-size: 11px;
  font-weight: 600;
  color: var(--primary);
}

.hy-podium-metrics {
  display: flex;
  align-items: center;
  gap: 6px;
  flex-wrap: wrap;
}
.hy-pill {
  font-size: 11.5px;
  padding: 2px 8px;
  border-radius: 6px;
  border: 1px solid var(--border);
  background: #f8fafc;
  color: var(--ink-secondary);
}
.hy-pill.takip { background: #eff6ff; border-color: #bfdbfe; color: #1e40af; }
.hy-pill.sorumlu { background: #fffbeb; border-color: #fde68a; color: #92400e; }
.hy-pill.done { background: #ecfdf5; border-color: #a7f3d0; color: #065f46; }

.hy-table-wrap {
  border: 1px solid var(--border);
  border-radius: 10px;
  overflow-x: auto;
}

.hy-member-row {
  cursor: pointer;
  transition: background 0.12s ease;
}
.hy-member-row:hover td {
  background: #f8fafc;
}
.hy-member-row.is-top1 td {
  background: #fffdf5;
}

.hy-rank-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 40px;
  padding: 2px 7px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 700;
  background: #f1f5f9;
  color: var(--ink-secondary);
}
.hy-rank-badge.r1 { background: #fef3c7; color: #92400e; border: 1px solid #f59e0b; }
.hy-rank-badge.r2 { background: #e2e8f0; color: #334155; border: 1px solid #94a3b8; }
.hy-rank-badge.r3 { background: #ffedd5; color: #9a3412; border: 1px solid #fb923c; }

.hy-user-cell {
  display: flex;
  align-items: center;
  gap: 9px;
}
.hy-user-name {
  display: block;
  font-size: 13.5px;
  font-weight: 700;
  color: var(--ink);
}

.hy-count-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 34px;
  padding: 3px 10px;
  border-radius: 999px;
  font-size: 13.5px;
  font-weight: 800;
}
.hy-count-badge.takip {
  background: #eff6ff;
  border: 1px solid #93c5fd;
  color: #1d4ed8;
}
.hy-count-badge.sorumlu {
  background: #fffbeb;
  border: 1px solid #fcd34d;
  color: #b45309;
}
.hy-sub-break {
  font-size: 10.5px;
  color: var(--muted);
  margin-top: 2px;
  white-space: nowrap;
}

.hy-done-badge {
  display: inline-flex;
  align-items: center;
  gap: 3px;
  padding: 3px 9px;
  border-radius: 999px;
  background: #ecfdf5;
  border: 1px solid #a7f3d0;
  color: #047857;
  font-size: 12px;
  font-weight: 700;
}

.hy-score-bar-wrap {
  display: flex;
  flex-direction: column;
  gap: 4px;
}
.hy-score-head {
  display: flex;
  align-items: baseline;
  gap: 4px;
}
.hy-score-num {
  font-size: 15px;
  font-weight: 800;
  color: var(--ink);
}
.hy-score-unit {
  font-size: 11px;
  color: var(--muted);
  font-weight: 600;
}
.hy-bar-track {
  width: 100%;
  height: 7px;
  border-radius: 999px;
  background: #e2e8f0;
  overflow: hidden;
}
.hy-bar-fill {
  height: 100%;
  border-radius: 999px;
  background: linear-gradient(90deg, #2563eb, #10b981);
  transition: width 0.25s ease;
}

.hy-detail-row[hidden] {
  display: none !important;
}
.hy-detail-row td {
  background: #f8fafc !important;
  padding: 10px 14px !important;
}
.hy-assign-list {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}
.hy-assign-chip {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 5px 10px;
  border-radius: 8px;
  background: #ffffff;
  border: 1px solid var(--border-strong);
  font-size: 12px;
  color: var(--ink);
  transition: border-color 0.12s ease, background 0.12s ease;
}
.hy-assign-chip:hover {
  border-color: var(--accent);
  background: #eff6ff;
}
.hy-asg-role {
  font-size: 11px;
  font-weight: 700;
  padding: 1px 6px;
  border-radius: 5px;
}
.hy-asg-role.takip { background: #dbeafe; color: #1d4ed8; }
.hy-asg-role.sorumlu { background: #fef3c7; color: #92400e; }
.hy-asg-type {
  font-size: 11px;
  color: var(--muted);
}

@media (max-width: 860px) {
  .hy-kpi-grid {
    grid-template-columns: 1fr 1fr;
  }
  .hy-podium-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 640px) {
  .hy-board-root {
    padding: 14px 12px;
  }
  .hy-top-btn-txt {
    display: none;
  }
  .hy-top-btn {
    padding: 0 9px;
    height: 34px;
  }
  .hy-scope-pills {
    width: 100%;
    justify-content: space-between;
  }
  .hy-scope-btn {
    flex: 1;
    text-align: center;
    padding: 5px 6px;
    font-size: 11px;
  }
}

.export-all-group {
  display: inline-flex;
  align-items: center;
  gap: 6px;
}
.export-all-btn {
  font-weight: 700;
  font-size: 12.5px;
  padding: 0 11px;
  white-space: nowrap;
}
.export-all-btn.pdf {
  border-color: #fecaca;
  background: #fffafa;
  color: #b91c1c;
}
.export-all-btn.pdf:hover {
  background: #fef2f2;
  border-color: #ef4444;
  color: #991b1b;
}
.export-all-btn.excel {
  border-color: #a7f3d0;
  background: #f0fdf4;
  color: #047857;
}
.export-all-btn.excel:hover {
  background: #dcfce7;
  border-color: #10b981;
  color: #065f46;
}
@media (max-width: 768px) {
  .toolbar-right-group {
    flex-wrap: wrap;
  }
  .toolbar-search-form {
    min-width: 100%;
  }
  .export-all-group {
    flex: 1;
  }
  .export-all-btn {
    flex: 1;
    justify-content: center;
  }
}
