/* ═══ Sayfa-spesifik küçük override'lar ═══
   base.css yetmediğinde, sayfaya özel kurallar buraya.
   Mümkün olduğunca base.css kullan. */

/* Canlı (L6) — LIVE rozeti pulse */
.live-pill {
  display: inline-flex; align-items: center; gap: 6px;
  background: var(--bad); color: white;
  padding: 3px 10px;
  border-radius: 999px;
  font-size: 11px; font-weight: 700;
  text-transform: uppercase; letter-spacing: .06em;
}
.live-pill::before {
  content: ''; width: 6px; height: 6px;
  background: white; border-radius: 50%;
  animation: pulse 1.4s infinite;
}
@keyframes pulse {
  0%, 100% { opacity: 1; transform: scale(1); }
  50% { opacity: .4; transform: scale(1.4); }
}

/* Upload wizard (L8) */
.wiz-steps { display: flex; gap: 8px; margin-bottom: 20px; }
.wiz-step { flex: 1; padding: 10px 14px; border: 1px solid var(--line); border-radius: 10px; background: var(--surface); color: var(--ink-3); font-size: 12px; font-weight: 600; }
.wiz-step.is-active { border-color: var(--brand); color: var(--brand-deep); background: var(--brand-soft); }
.wiz-step.is-done { background: var(--ink); color: white; border-color: var(--ink); }
.dropzone {
  border: 2px dashed var(--line);
  border-radius: var(--radius);
  padding: 48px;
  text-align: center;
  background: var(--surface-2);
}
.dropzone:hover, .dropzone.is-over { border-color: var(--brand); background: var(--brand-soft); }

/* Print (L9) */
@media print {
  .sidebar, .topbar, .page-actions, .filter-bar, .pagination { display: none !important; }
  .app { grid-template-columns: 1fr !important; }
  .page { padding: 0 !important; max-width: 100% !important; }
  .card { border: 1px solid #ccc !important; break-inside: avoid; }
  body { background: white; }
}

/* Login (L10) */
.auth-wrap { min-height: 100vh; display: grid; place-items: center; background: var(--bg); padding: 20px; }
.auth-card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 40px; width: 100%; max-width: 420px; box-shadow: var(--shadow); }
.auth-logo { width: 56px; height: 56px; border-radius: 14px; background: var(--brand); color: white; display: grid; place-items: center; font-weight: 800; font-size: 20px; margin: 0 auto 18px; }
.auth-title { text-align: center; font-size: 20px; font-weight: 700; margin: 0 0 4px; }
.auth-sub { text-align: center; color: var(--ink-3); font-size: 13px; margin-bottom: 28px; }

/* ═══════════════════════════════════════════════════════════════
   POLISH PASS EXTENSIONS — Faz 2
   (Handoff orijinal pages.css satırları yukarıda korundu)
   ═══════════════════════════════════════════════════════════════ */

/* Sayfa-özel eyebrow renkleri */
.page-eyebrow.eyebrow-brand  { color: var(--brand-deep); }
.page-eyebrow.eyebrow-navy   { color: var(--navy); }
.page-eyebrow.eyebrow-info   { color: var(--info); }
.page-eyebrow.eyebrow-warn   { color: var(--warn); }
.page-eyebrow.eyebrow-violet { color: #7c3aed; }
.page-eyebrow.eyebrow-ok     { color: var(--ok); }
.page-eyebrow.eyebrow-bad    { color: var(--bad); }

/* Metric polish — hover + ikon kutusu */
.metric { transition: border-color .15s, box-shadow .15s, transform .15s; position: relative; }
.metric:hover { transform: translateY(-2px); box-shadow: var(--shadow); border-color: var(--brand-soft); }
.metric-ic {
  width: 38px; height: 38px; border-radius: 10px;
  display: grid; place-items: center; font-size: 17px;
  margin-bottom: 10px;
}
.metric-ic.brand  { background: var(--brand-soft); color: var(--brand-deep); }
.metric-ic.navy   { background: #e3e7f1; color: var(--navy); }
.metric-ic.ok     { background: #e3f5e8; color: var(--ok); }
.metric-ic.info   { background: #e0f0fa; color: var(--info); }
.metric-ic.warn   { background: #fef3e0; color: var(--warn); }
.metric-ic.violet { background: #eee8f7; color: #7c3aed; }
.metric-ic.bad    { background: #fbe5e5; color: var(--bad); }

/* Tablo satır-başı ikon */
.table td .row-ic,
.table td > i.bi.row-ic { font-size: 15px; width: 24px; text-align: center; display: inline-block; line-height: 1; }
.row-ic.brand  { color: var(--brand); }
.row-ic.navy   { color: var(--navy); }
.row-ic.info   { color: var(--info); }
.row-ic.warn   { color: var(--warn); }
.row-ic.violet { color: #7c3aed; }
.row-ic.ok     { color: var(--ok); }
.row-ic.bad    { color: var(--bad); }
.row-ic.muted  { color: var(--ink-4); }

/* Empty state illustration */
.empty-visual {
  padding: 54px 24px; text-align: center; color: var(--ink-3);
}
.empty-visual i {
  font-size: 52px; color: var(--line); display: block;
  margin: 0 auto 14px; line-height: 1;
}
.empty-visual .title {
  font-size: 16px; font-weight: 700; color: var(--ink-2); margin: 0 0 6px;
}
.empty-visual .sub {
  font-size: 13px; margin: 0 auto 18px; max-width: 420px; line-height: 1.5;
}

/* Card hover micro-interaction */
.card { transition: border-color .15s, box-shadow .15s, transform .15s; }
.card-hover:hover { transform: translateY(-2px); box-shadow: var(--shadow); border-color: var(--brand-soft); }

/* Button polish — base.css'e taşındı */

/* Page fade-in */
@keyframes pageFadeIn { from { opacity: 0; transform: translateY(4px); } to { opacity: 1; transform: none; } }
.page > main.page,
.page { animation: pageFadeIn .25s ease; }

/* Form field enhanced */
.form-field .lbl-ic { display: inline-flex; align-items: center; gap: 6px; }
.form-field .lbl-ic i { font-size: 13px; color: var(--ink-3); }
.form-field input:hover:not(:focus),
.form-field select:hover:not(:focus),
.form-field textarea:hover:not(:focus) { border-color: var(--ink-4); }

/* Row-icon inline helpers */
.ri-wrap { display: inline-flex; align-items: center; gap: 8px; }

/* Reduced motion */
@media (prefers-reduced-motion: reduce) {
  .card, .metric, .btn-primary, .stat, .page { animation: none !important; transition: none !important; }
  .card:hover, .metric:hover, .stat:hover { transform: none !important; }
}

/* NEW badge (for raporlar/yeni sayfa işaretleri) */
.badge-new { background: var(--brand); color: white; font-size: 9px; padding: 2px 7px; border-radius: 999px; letter-spacing: .08em; font-weight: 800; text-transform: uppercase; }

/* Rank fade — audit_log en_aktif */
.rank-fade li { transition: opacity .15s; }
.rank-fade li:nth-child(n+4) { opacity: .82; }
.rank-fade li:nth-child(n+7) { opacity: .64; }
.rank-fade li:nth-child(n+10) { opacity: .5; }

/* ═══════════════════════════════════════════════════════════════════
   FAZ 0 — V2 NATIVE COMPONENT LIBRARY
   Tüm sayfa native dönüşümünde kullanılacak. tokens.css ile bağlı.
═══════════════════════════════════════════════════════════════════ */

/* ─────────── SPLIT 2-COL (TIP B Detay) ─────────── */
.split-2col {
  display: grid;
  grid-template-columns: minmax(0, 2fr) minmax(0, 1fr);
  gap: 18px;
  align-items: flex-start;
}
.split-main { min-width: 0; display: flex; flex-direction: column; gap: 14px; }
.split-side { min-width: 0; display: flex; flex-direction: column; gap: 14px; }
@media (max-width: 980px) {
  .split-2col { grid-template-columns: 1fr; }
}

/* ─────────── SECTION TABS (TIP B alt-tab) ─────────── */
.section-tabs {
  display: inline-flex; gap: 2px;
  padding: 4px;
  background: var(--surface-2);
  border: 1px solid var(--line);
  border-radius: 11px;
  margin-bottom: 14px;
  flex-wrap: wrap;
}
.section-tab {
  display: inline-flex; align-items: center; gap: 6px;
  padding: 7px 13px;
  border-radius: 8px;
  font-family: var(--sans);
  font-size: 13px; font-weight: 600;
  color: var(--ink-3);
  text-decoration: none;
  background: transparent;
  border: 0;
  cursor: pointer;
  transition: all .15s;
  white-space: nowrap;
}
.section-tab:hover { color: var(--ink); }
.section-tab.is-on {
  background: var(--surface);
  color: var(--ink);
  box-shadow: 0 1px 2px rgba(13,27,54,.10), 0 0 0 1px var(--line);
}
.section-tab .section-tab-count {
  font-family: var(--mono);
  font-size: 11px;
  padding: 1px 6px;
  border-radius: 6px;
  background: rgba(13,27,54,.06);
  color: var(--ink-3);
  font-variant-numeric: tabular-nums;
}
.section-tab.is-on .section-tab-count { background: var(--brand-soft); color: var(--brand-deep); }

/* ─────────── QUICK LINKS (page-header altı kompakt link strip) ─────────── */
.quick-links {
  display: flex; gap: 10px; flex-wrap: wrap;
  margin-bottom: 14px;
}
.quick-link {
  display: inline-flex; align-items: center; gap: 10px;
  padding: 10px 14px;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 12px;
  text-decoration: none;
  color: var(--ink-2);
  font-size: 13px; font-weight: 600;
  transition: transform .12s, box-shadow .15s, border-color .15s;
  flex: 1 1 240px;
  min-width: 0;
  font-family: var(--sans);
}
.quick-link:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow);
  border-color: var(--line-2);
  color: var(--ink);
}
.quick-link-ic {
  width: 38px; height: 38px;
  display: grid; place-items: center;
  border-radius: 10px;
  flex-shrink: 0;
  font-size: 17px;
  background: var(--brand-soft); color: var(--brand-deep);
}
.quick-link-ic.tone-info { background: rgba(30,111,184,.10); color: var(--info); }
.quick-link-ic.tone-ok   { background: rgba(21,138,68,.10);  color: var(--ok); }
.quick-link-ic.tone-warn { background: rgba(217,119,6,.10);  color: var(--warn); }
.quick-link-ic.tone-bad  { background: rgba(196,38,38,.10);  color: var(--bad); }
.quick-link-body { min-width: 0; flex: 1; }
.quick-link-title { font-weight: 700; color: var(--ink); margin-bottom: 1px; }
.quick-link-sub { font-size: 11.5px; color: var(--ink-3); font-weight: 500; }
.quick-link-arrow { color: var(--ink-4); font-size: 14px; }

/* ─────────── TREE VIEW (TIP E hiyerarşik) ─────────── */
.tree-view {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 6px;
  font-family: var(--sans);
  box-shadow: var(--shadow-sm);
}
.tree-item {
  display: flex; align-items: center; gap: 8px;
  padding: 8px 10px;
  border-radius: 9px;
  cursor: pointer;
  transition: background .12s;
  user-select: none;
}
.tree-item:hover { background: var(--surface-2); }
.tree-toggle {
  width: 18px; height: 18px;
  display: inline-grid; place-items: center;
  font-size: 10px;
  color: var(--ink-3);
  flex-shrink: 0;
  transition: transform .15s;
}
.tree-item.is-open > .tree-row > .tree-toggle { transform: rotate(90deg); }
.tree-item.is-leaf > .tree-row > .tree-toggle { visibility: hidden; }
.tree-row { display: flex; align-items: center; gap: 8px; flex: 1; min-width: 0; }
.tree-icon {
  width: 22px; height: 22px;
  display: grid; place-items: center;
  border-radius: 6px;
  font-size: 12px;
  background: var(--brand-soft); color: var(--brand-deep);
}
.tree-label { font-size: 13.5px; color: var(--ink); font-weight: 600; flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; }
.tree-meta { font-size: 11.5px; color: var(--ink-3); font-family: var(--mono); font-variant-numeric: tabular-nums; }
.tree-actions { display: inline-flex; gap: 4px; opacity: 0; transition: opacity .15s; }
.tree-item:hover .tree-actions { opacity: 1; }
.tree-children { padding-left: 24px; display: none; }
.tree-item.is-open + .tree-children { display: block; }

/* ─────────── TIMELINE (TIP M audit/gorev_detay) ─────────── */
.timeline {
  position: relative;
  padding-left: 30px;
}
.timeline::before {
  content: '';
  position: absolute;
  left: 13px; top: 4px; bottom: 4px;
  width: 2px;
  background: var(--line-2);
}
.timeline-item {
  position: relative;
  padding: 6px 0 18px 0;
}
.timeline-item:last-child { padding-bottom: 0; }
.timeline-icon {
  position: absolute;
  left: -30px; top: 4px;
  width: 28px; height: 28px;
  border-radius: 50%;
  display: grid; place-items: center;
  background: var(--surface);
  border: 2px solid var(--line);
  font-size: 12px;
  color: var(--ink-3);
}
.timeline-icon.tone-ok   { background: rgba(21,138,68,.10);  color: var(--ok);   border-color: var(--ok); }
.timeline-icon.tone-warn { background: rgba(217,119,6,.10);  color: var(--warn); border-color: var(--warn); }
.timeline-icon.tone-bad  { background: rgba(196,38,38,.10);  color: var(--bad);  border-color: var(--bad); }
.timeline-icon.tone-info { background: rgba(30,111,184,.10); color: var(--info); border-color: var(--info); }
.timeline-content { background: var(--surface); border: 1px solid var(--line); border-radius: 10px; padding: 12px 14px; }
.timeline-title { font-size: 13.5px; font-weight: 700; color: var(--ink); margin-bottom: 2px; }
.timeline-time { font-family: var(--mono); font-size: 11px; color: var(--ink-3); }
.timeline-meta { font-size: 12px; color: var(--ink-3); margin-top: 4px; }
.timeline-body { font-size: 13px; color: var(--ink-2); margin-top: 6px; line-height: 1.45; }

/* ─────────── KPI ROW (TIP H stratejik analiz) ─────────── */
.kpi-row {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
  gap: 14px;
  margin-bottom: 18px;
}
.kpi {
  background: linear-gradient(135deg, var(--surface) 0%, var(--surface-2) 100%);
  border: 1px solid var(--line);
  border-radius: 14px;
  padding: 16px 18px;
  position: relative;
  overflow: hidden;
}
.kpi::after {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0; height: 3px;
  background: var(--brand);
}
.kpi.tone-ok::after   { background: var(--ok); }
.kpi.tone-warn::after { background: var(--warn); }
.kpi.tone-bad::after  { background: var(--bad); }
.kpi.tone-info::after { background: var(--info); }
.kpi-l {
  font-size: 11px; font-weight: 700;
  letter-spacing: .08em; text-transform: uppercase;
  color: var(--ink-3);
  margin-bottom: 8px;
}
.kpi-v {
  font-family: var(--sans);
  font-size: 28px; font-weight: 800;
  color: var(--ink);
  line-height: 1.05;
  letter-spacing: -.02em;
  font-variant-numeric: tabular-nums;
}
.kpi-d {
  font-size: 12px; color: var(--ink-3);
  margin-top: 4px;
}

/* ─────────── INLINE BAR CHART (.bar-r) ─────────── */
.bar-row { display: flex; align-items: center; gap: 10px; padding: 6px 0; }
.bar-row-label { font-size: 12.5px; color: var(--ink-2); min-width: 120px; flex-shrink: 0; font-weight: 500; }
.bar-r {
  flex: 1; height: 8px;
  background: var(--surface-2);
  border-radius: 4px;
  overflow: hidden;
  position: relative;
}
.bar-r::before {
  content: '';
  position: absolute;
  left: 0; top: 0; bottom: 0;
  width: var(--bar-w, 0%);
  background: var(--brand);
  border-radius: 4px;
  transition: width .4s cubic-bezier(.32,.72,0,1);
}
.bar-r.tone-ok::before   { background: var(--ok); }
.bar-r.tone-warn::before { background: var(--warn); }
.bar-r.tone-bad::before  { background: var(--bad); }
.bar-r.tone-info::before { background: var(--info); }
.bar-row-value {
  font-family: var(--mono);
  font-size: 12px; font-weight: 600;
  color: var(--ink);
  font-variant-numeric: tabular-nums;
  min-width: 50px;
  text-align: right;
}

/* ─────────── ANALİZ SECTION + COMPARE TABLE ─────────── */
.sa-sec {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 18px 20px;
  margin-bottom: 14px;
  box-shadow: var(--shadow-sm);
}
.sa-title {
  font-family: var(--sans);
  font-size: 11.5px;
  font-weight: 800;
  letter-spacing: .08em;
  text-transform: uppercase;
  color: var(--ink-3);
  margin: 0 0 14px;
  display: flex; align-items: center; gap: 8px;
}
.sa-title i { color: var(--brand); font-size: 13px; }
.sa-tbl { width: 100%; font-family: var(--sans); font-size: 13px; }
.sa-tbl th, .sa-tbl td { padding: 8px 10px; border-bottom: 1px solid var(--line-2); text-align: left; }
.sa-tbl th { font-weight: 700; color: var(--ink-3); font-size: 11px; text-transform: uppercase; letter-spacing: .04em; }
.sa-tbl tr:last-child td { border-bottom: 0; }
.sa-tbl td.num { font-family: var(--mono); font-variant-numeric: tabular-nums; text-align: right; }

/* ─────────── UPLOAD ZONE (TIP I) ─────────── */
.upload-zone {
  display: flex; flex-direction: column; align-items: center;
  padding: 60px 30px;
  background: var(--surface);
  border: 2px dashed var(--line-2);
  border-radius: var(--radius);
  text-align: center;
  cursor: pointer;
  transition: border-color .15s, background .15s, transform .12s;
}
.upload-zone:hover { border-color: var(--brand); background: var(--surface-2); }
.upload-zone.drag-over {
  border-color: var(--brand);
  background: var(--brand-soft);
  transform: scale(1.005);
}
.upload-zone i {
  font-size: 36px;
  color: var(--brand);
  margin-bottom: 10px;
}
.upload-zone-title { font-size: 16px; font-weight: 700; color: var(--ink); margin-bottom: 4px; }
.upload-zone-sub { font-size: 13px; color: var(--ink-3); }
.upload-zone input[type="file"] { display: none; }
.upload-progress {
  width: 100%; height: 6px;
  background: var(--surface-2);
  border-radius: 3px;
  overflow: hidden;
  margin-top: 14px;
}
.upload-progress-bar {
  height: 100%;
  background: linear-gradient(90deg, var(--brand) 0%, var(--brand-deep) 100%);
  width: var(--upload-pct, 0%);
  transition: width .3s;
}
.upload-preview { margin-top: 18px; }

/* ─────────── MAP WRAP (TIP F harita) ─────────── */
.map-wrap {
  position: relative;
  height: calc(100vh - 220px);
  min-height: 480px;
  border-radius: var(--radius);
  overflow: hidden;
  background: var(--surface-2);
  border: 1px solid var(--line);
  box-shadow: var(--shadow-sm);
}
.map-canvas { position: absolute; inset: 0; }
.map-toolbar {
  position: absolute; top: 14px; left: 14px;
  display: flex; flex-direction: column; gap: 8px;
  z-index: 100;
}
.map-toolbar-card {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 10px;
  padding: 10px 12px;
  box-shadow: var(--shadow-sm);
  font-family: var(--sans);
  font-size: 12.5px;
}
.map-legend {
  position: absolute; bottom: 14px; right: 14px;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 10px;
  padding: 10px 14px;
  box-shadow: var(--shadow-sm);
  font-family: var(--sans);
  font-size: 11.5px;
  z-index: 100;
}
.map-legend-row { display: flex; align-items: center; gap: 8px; padding: 2px 0; }
.map-legend-color { width: 14px; height: 14px; border-radius: 3px; }
.drawer {
  position: absolute; top: 0; right: 0; bottom: 0;
  width: min(380px, 90%);
  background: var(--surface);
  border-left: 1px solid var(--line);
  box-shadow: -8px 0 24px rgba(13,27,54,.12);
  transform: translateX(100%);
  transition: transform .28s cubic-bezier(.32,.72,0,1);
  z-index: 200;
  display: flex; flex-direction: column;
  overflow: hidden;
}
.drawer.is-open { transform: translateX(0); }
.drawer-header {
  display: flex; align-items: center; justify-content: space-between;
  padding: 14px 18px;
  border-bottom: 1px solid var(--line);
}
.drawer-title { font-family: var(--sans); font-weight: 800; color: var(--ink); font-size: 16px; }
.drawer-close {
  width: 32px; height: 32px;
  display: grid; place-items: center;
  background: var(--surface-2);
  border: 1px solid var(--line);
  border-radius: 8px;
  cursor: pointer;
  font-size: 12px;
}
.drawer-body { flex: 1; padding: 16px 18px; overflow-y: auto; font-family: var(--sans); }

/* ─────────── EMPTY STATE ─────────── */
.empty-state {
  display: flex; flex-direction: column; align-items: center;
  padding: 70px 30px;
  text-align: center;
  color: var(--ink-3);
  font-family: var(--sans);
}
.empty-illust {
  font-size: 44px;
  color: var(--ink-4);
  margin-bottom: 14px;
}
.empty-state .empty-title {
  font-size: 17px; font-weight: 700; color: var(--ink);
  margin: 0 0 4px;
}
.empty-state .empty-sub {
  font-size: 13px; color: var(--ink-3);
  margin: 0 0 18px;
}

/* ─────────── SKELETON (HTMX yükleme placeholder) ─────────── */
@keyframes skel-shine {
  0% { background-position: -200px 0; }
  100% { background-position: calc(200px + 100%) 0; }
}
.skeleton {
  background: linear-gradient(90deg, var(--surface-2) 0px, var(--line-2) 40px, var(--surface-2) 80px);
  background-size: 200px 100%;
  background-repeat: no-repeat;
  animation: skel-shine 1.4s linear infinite;
  border-radius: 6px;
  display: inline-block;
}
.skeleton-line { height: 12px; width: 100%; margin: 4px 0; }
.skeleton-row { display: flex; gap: 10px; padding: 12px; align-items: center; }
.skeleton-circle { width: 32px; height: 32px; border-radius: 50%; }

/* ─────────── TOAST STACK (Django messages) ─────────── */
.toast-stack {
  position: fixed; top: 78px; right: 18px;
  display: flex; flex-direction: column; gap: 8px;
  z-index: 1100;
  pointer-events: none;
}
.toast {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 10px;
  padding: 12px 14px;
  box-shadow: var(--shadow);
  display: flex; align-items: center; gap: 10px;
  min-width: 280px; max-width: 380px;
  pointer-events: auto;
  font-family: var(--sans);
  font-size: 13.5px;
  color: var(--ink-2);
  animation: toast-in .28s cubic-bezier(.32,.72,0,1);
}
@keyframes toast-in { from { transform: translateX(20px); opacity: 0; } to { transform: translateX(0); opacity: 1; } }
.toast.is-leaving { animation: toast-out .22s ease-in forwards; }
@keyframes toast-out { to { transform: translateX(20px); opacity: 0; } }
.toast i { font-size: 17px; flex-shrink: 0; }
.toast.toast-success { border-left: 3px solid var(--ok); }
.toast.toast-success i { color: var(--ok); }
.toast.toast-warning { border-left: 3px solid var(--warn); }
.toast.toast-warning i { color: var(--warn); }
.toast.toast-error,
.toast.toast-danger { border-left: 3px solid var(--bad); }
.toast.toast-error i,
.toast.toast-danger i { color: var(--bad); }
.toast.toast-info { border-left: 3px solid var(--info); }
.toast.toast-info i { color: var(--info); }
.toast-close {
  background: transparent; border: 0;
  color: var(--ink-4); cursor: pointer;
  font-size: 16px; line-height: 1;
  padding: 0 0 0 8px;
  margin-left: auto;
}
.toast-close:hover { color: var(--ink-2); }

/* ─────────── CONFIRM DIALOG ─────────── */
.confirm-overlay {
  position: fixed; inset: 0;
  background: rgba(13,27,54,.5);
  backdrop-filter: blur(2px);
  z-index: 1200;
  display: flex; align-items: center; justify-content: center;
  opacity: 0; pointer-events: none;
  transition: opacity .2s;
}
.confirm-overlay.is-open { opacity: 1; pointer-events: auto; }
.confirm-dialog {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 14px;
  padding: 22px 24px;
  width: min(420px, 92vw);
  box-shadow: var(--shadow-lg);
  font-family: var(--sans);
  transform: scale(.96);
  transition: transform .22s cubic-bezier(.32,.72,0,1);
}
.confirm-overlay.is-open .confirm-dialog { transform: scale(1); }
.confirm-title { font-size: 17px; font-weight: 800; color: var(--ink); margin: 0 0 6px; letter-spacing: -.01em; }
.confirm-body { font-size: 13.5px; color: var(--ink-2); margin: 0 0 18px; line-height: 1.5; }
.confirm-actions { display: flex; justify-content: flex-end; gap: 8px; }
.confirm-cancel {
  padding: 8px 14px; border-radius: 9px;
  background: var(--surface-2); border: 1px solid var(--line);
  color: var(--ink-2); font-weight: 600; font-size: 13px;
  cursor: pointer; transition: all .12s;
}
.confirm-cancel:hover { background: var(--line-2); color: var(--ink); }
.confirm-ok {
  padding: 8px 16px; border-radius: 9px;
  background: var(--brand); border: 0;
  color: white; font-weight: 700; font-size: 13px;
  cursor: pointer; transition: all .12s;
  box-shadow: 0 2px 6px rgba(255,122,26,.25);
}
.confirm-ok:hover { background: var(--brand-deep); transform: translateY(-1px); }
.confirm-ok.tone-bad { background: var(--bad); box-shadow: 0 2px 6px rgba(196,38,38,.25); }
.confirm-ok.tone-bad:hover { background: #9d1f1f; }

/* ─────────── PAGER ─────────── */
.pager {
  display: flex; align-items: center; justify-content: center; gap: 4px;
  padding: 16px;
  font-family: var(--sans);
}
.pager-btn,
.pager-current {
  min-width: 34px; height: 34px;
  display: inline-flex; align-items: center; justify-content: center;
  padding: 0 10px;
  border-radius: 8px;
  border: 1px solid var(--line);
  background: var(--surface);
  color: var(--ink-2);
  font-size: 13px; font-weight: 600;
  text-decoration: none;
  transition: all .12s;
  font-variant-numeric: tabular-nums;
}
.pager-btn:hover { background: var(--surface-2); color: var(--ink); border-color: var(--line-2); }
.pager-current { background: var(--brand); color: white; border-color: var(--brand); cursor: default; }
.pager-disabled { opacity: .4; pointer-events: none; }
.pager-info { color: var(--ink-3); font-size: 12.5px; padding: 0 10px; font-family: var(--mono); }

/* ─────────── PRINT (TIP J — V2 ortak yazdırma stili) ─────────── */
@page { margin: 12mm 12mm 14mm 12mm; }
@media print {
  /* Renkleri zorla bas (AK Parti markası, navy hero, vb) */
  *, *::before, *::after { -webkit-print-color-adjust: exact !important; print-color-adjust: exact !important; }
  /* UI gizle */
  .sidebar, .topbar, .mobile-bottom, .toast-stack, .av-panel, .av-panel-overlay,
  .confirm-overlay, .av-strip, .av-cmdbar, .av-progress, .htmx-indicator,
  .page-actions, .filter-bar, .av-cluster-btn, .av-icon-btn,
  .no-print, .modal, .modal-backdrop, .av-fab, button.btn-icon { display: none !important; }
  /* Layout sıfırla */
  html, body { background: #fff !important; color: #1a1a2e !important; margin: 0 !important; padding: 0 !important; -webkit-font-smoothing: antialiased; }
  .main, .page, .container, .container-fluid { padding: 0 !important; margin: 0 !important; }
  /* Linkleri okunabilir yap */
  a, a:visited { color: #1a1a2e !important; text-decoration: none !important; }
  /* Sayfa kırılması ipuçları */
  h1, h2, h3, h4 { page-break-after: avoid; }
  table, .card, .av-listcard, section { page-break-inside: avoid; }
  thead { display: table-header-group; }
  tr { page-break-inside: avoid; }
  /* Kart sadeleştir */
  .card, .av-listcard, .od-card, .sd-card, .sec-card, .gd-card { border: 1px solid #d0d6e0 !important; box-shadow: none !important; border-radius: 6px !important; background: #fff !important; }
  /* Tablo */
  table { font-size: 9.5pt !important; border-collapse: collapse !important; }
  th { background: #1a1a2e !important; color: #fff !important; font-weight: 700 !important; padding: 6px !important; border-bottom: 2px solid #ff7a1a !important; }
  td { padding: 5px 6px !important; border-bottom: 1px solid #e7ebf3 !important; }
  /* Hero koyu navy korunur */
  .od-hero, .sd-hero, .sec-hero, .gd-hero, .sa-hero { box-shadow: none !important; border-radius: 6px !important; }
  /* Görsel düzeltmeler */
  .badge { border: 1px solid currentColor !important; }
}
.print-only { display: none; }
@media print { .print-only { display: block; } }

/* ─────────── TAKVIM (TIP G — yenilenmiş) ─────────── */
.takvim-table {
  width: 100%;
  border-collapse: separate;
  border-spacing: 0;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  overflow: hidden;
  font-family: var(--sans);
}
.takvim-table th {
  background: var(--surface-2);
  color: var(--ink-3);
  font-size: 11px; font-weight: 700;
  letter-spacing: .06em; text-transform: uppercase;
  padding: 12px 8px;
  text-align: center;
  border-bottom: 1px solid var(--line);
}
.takvim-table td {
  vertical-align: top;
  padding: 0;
  border-right: 1px solid var(--line-2);
  border-bottom: 1px solid var(--line-2);
  height: 110px;
}
.takvim-table td:last-child { border-right: 0; }
.takvim-table tr:last-child td { border-bottom: 0; }
.takvim-gun {
  padding: 8px;
  height: 100%;
  display: flex; flex-direction: column; gap: 3px;
}
.takvim-gun.is-other { background: var(--surface-2); opacity: .55; }
.takvim-gun.is-today { background: var(--brand-soft); }
.takvim-gun-num {
  font-family: var(--mono);
  font-size: 12px; font-weight: 600;
  color: var(--ink-3);
}
.takvim-gun.is-today .takvim-gun-num { color: var(--brand-deep); font-weight: 800; }
.takvim-etkinlik {
  font-size: 10.5px; font-weight: 600;
  padding: 2px 6px;
  border-radius: 4px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  text-decoration: none;
  display: block;
  border-left: 2px solid transparent;
}
.takvim-etkinlik.tur-toplanti { background: rgba(124,58,237,.10); color: #6d28d9; border-left-color: #7c3aed; }
.takvim-etkinlik.tur-ziyaret  { background: rgba(30,111,184,.10); color: var(--info); border-left-color: var(--info); }
.takvim-etkinlik.tur-miting   { background: rgba(196,38,38,.10);  color: var(--bad);  border-left-color: var(--bad); }
.takvim-etkinlik.tur-egitim   { background: rgba(21,138,68,.10);  color: var(--ok);   border-left-color: var(--ok); }
.takvim-etkinlik.tur-diger    { background: rgba(217,119,6,.10);  color: var(--warn); border-left-color: var(--warn); }

/* ═══════════════════════════════════════════════════════════════════
   FAZ 0 SONU
═══════════════════════════════════════════════════════════════════ */

/* ═══════════════════════════════════════════════════════════════════
   AV-CMDBAR — paylaşımlı komuta çubuğu (12 listeleme sayfası)
   Daha önce sadece avukatlar_listesi.html style bloğunda tanımlıydı,
   bu nedenle gorevli/sandik/secmen/okul/etkinlik/gorev/teskilat/
   sokak_hamileri/mahalle_hamileri/kullanici_paneli vs. sayfaları
   stilsiz dikey istifleniyordu. Tek yerden tüm sayfaları tedavi.
═══════════════════════════════════════════════════════════════════ */
.av-cmdbar {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 14px;
  margin-bottom: 18px;
  overflow: visible;
  box-shadow: 0 1px 2px rgba(13,27,54,.04);
}
.av-cmdbar .dropdown-menu {
  z-index: 1050;
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 6px;
  box-shadow: 0 12px 32px rgba(13,27,54,.12);
  background: var(--surface);
}
.av-cmdbar .dropdown-item {
  border-radius: 8px;
  padding: 9px 11px;
  font-size: 13.5px;
  color: var(--ink-2);
}
.av-cmdbar .dropdown-item:hover { background: var(--surface-2); color: var(--ink); }

.av-cmdbar-row { display: flex; flex-wrap: wrap; align-items: center; gap: 10px; }
.av-cmdbar-tabs {
  padding: 14px 18px;
  border-bottom: 1px solid var(--line);
  justify-content: space-between;
}
.av-cmdbar-actions { padding: 14px 18px; align-items: center; }

/* Pillbar (segmented kademe seçici) */
.av-pillbar {
  display: inline-flex; flex-wrap: wrap; align-items: center;
  gap: 2px; padding: 4px;
  background: var(--surface-2); border-radius: 11px;
}
.av-pill {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 8px 14px; border-radius: 8px;
  font-family: var(--sans); font-size: 13.5px; font-weight: 600;
  color: var(--ink-3); text-decoration: none;
  background: transparent; border: 0;
  transition: all .15s; cursor: pointer; white-space: nowrap;
}
.av-pill:hover { color: var(--ink); }
.av-pill-dot { width: 7px; height: 7px; border-radius: 50%; display: inline-block; flex-shrink: 0; }
.dot-all  { background: var(--ink-4); }
.dot-ok   { background: var(--ok); }
.dot-warn { background: var(--warn); }
.dot-bad  { background: var(--bad); }
.dot-info { background: var(--info); }
.av-pill-label { line-height: 1; }
.av-pill-count {
  font-family: var(--mono); font-size: 11px; font-weight: 600;
  font-variant-numeric: tabular-nums;
  padding: 2px 7px; border-radius: 6px;
  background: rgba(13,27,54,.06); color: var(--ink-3);
  min-width: 22px; text-align: center;
}
.av-pill.is-on {
  background: var(--surface); color: var(--ink);
  box-shadow: 0 1px 2px rgba(13,27,54,.10), 0 0 0 1px var(--line);
}
.av-pill.is-on .av-pill-count { background: var(--brand-soft); color: var(--brand-deep); }

/* CTA — turuncu solid */
.av-cta {
  display: inline-flex; align-items: center; gap: 7px;
  padding: 9px 16px; background: var(--brand);
  color: white; border: 0; border-radius: 10px;
  font-family: var(--sans); font-size: 13.5px; font-weight: 700;
  cursor: pointer; transition: transform .1s, background .15s, box-shadow .15s;
  white-space: nowrap; text-decoration: none;
  box-shadow: 0 2px 8px rgba(255,122,26,.30);
}
.av-cta:hover {
  background: var(--brand-deep); transform: translateY(-1px);
  box-shadow: 0 4px 14px rgba(255,122,26,.40); color: white;
}
.av-cta-plus {
  width: 18px; height: 18px;
  display: inline-grid; place-items: center;
  background: rgba(255,255,255,.22); border-radius: 5px;
  font-family: var(--mono); font-size: 14px; font-weight: 700; line-height: 1;
}

/* Search */
.av-search {
  flex: 1 1 320px; max-width: 480px; min-width: 240px;
  position: relative; display: flex; align-items: center;
  background: var(--surface-2); border: 1px solid var(--line);
  border-radius: 11px; height: 42px; padding: 0 14px;
  transition: all .15s;
}
.av-search:focus-within {
  background: var(--surface); border-color: var(--brand);
  box-shadow: 0 0 0 4px var(--brand-soft);
}
.av-search-ic { color: var(--ink-4); font-size: 14px; margin-right: 10px; }
.av-search-input {
  flex: 1; border: 0; background: transparent; outline: none;
  font-family: var(--sans); font-size: 14px; color: var(--ink); padding: 0;
}
.av-search-input::placeholder { color: var(--ink-4); font-weight: 500; }
.av-search-hint {
  font-family: var(--mono); font-size: 10.5px; font-weight: 600;
  letter-spacing: .04em; padding: 3px 7px;
  background: var(--surface); border: 1px solid var(--line);
  border-radius: 5px; color: var(--ink-4); margin-left: 8px;
}
.av-htmx-spinner { width: 14px; height: 14px; margin-left: 6px; }
.av-spin-dot {
  display: block; width: 14px; height: 14px;
  border: 2px solid var(--line); border-top-color: var(--brand);
  border-radius: 50%; animation: av-spin .7s linear infinite;
}
@keyframes av-spin { to { transform: rotate(360deg); } }

/* Filtre chip */
.av-chip {
  display: inline-flex; align-items: center; gap: 7px;
  height: 42px; padding: 0 14px;
  background: var(--surface-2); border: 1px solid var(--line);
  border-radius: 11px; font-size: 13.5px; font-weight: 500;
  color: var(--ink-2); text-decoration: none;
  cursor: pointer; transition: all .15s; white-space: nowrap;
}
.av-chip:hover { border-color: var(--brand); color: var(--ink); background: var(--surface); }
.av-chip.is-active {
  background: var(--brand); color: white; border-color: var(--brand);
  box-shadow: 0 2px 6px rgba(255,122,26,.25);
}
.av-chip i { font-size: 13px; opacity: .85; }
.av-chip-count {
  font-family: var(--mono); font-size: 11px; font-weight: 600;
  font-variant-numeric: tabular-nums;
  padding: 1px 8px; background: var(--surface); color: var(--ink-3);
  border-radius: 999px; border: 1px solid var(--line);
}
.av-chip.is-active .av-chip-count { background: rgba(255,255,255,.22); color: white; border-color: transparent; }

/* Aksiyon kümesi */
.av-actions-cluster {
  display: inline-flex; align-items: center; gap: 4px;
  margin-left: auto; padding: 4px;
  background: var(--surface-2); border-radius: 11px;
}
.av-icon-btn {
  width: 34px; height: 34px;
  display: grid; place-items: center;
  background: transparent; border: 0; border-radius: 7px;
  color: var(--ink-3); cursor: pointer; transition: all .12s;
  text-decoration: none;
}
.av-icon-btn:hover { background: var(--surface); color: var(--ink); box-shadow: 0 1px 2px rgba(13,27,54,.08); }
.av-icon-btn i { font-size: 14px; }

.av-cluster-btn {
  display: inline-flex; align-items: center; gap: 6px;
  height: 34px; padding: 0 11px;
  background: transparent; border: 0; border-radius: 7px;
  font-family: var(--sans); font-size: 13px; font-weight: 600;
  color: var(--ink-2); cursor: pointer; transition: all .12s;
  text-decoration: none;
}
.av-cluster-btn:hover { background: var(--surface); color: var(--ink); box-shadow: 0 1px 2px rgba(13,27,54,.08); }
.av-cluster-btn i { font-size: 13px; }
.av-cluster-btn.dropdown-toggle::after { margin-left: 4px; opacity: .5; }

/* Mobil cmdbar */
@media (max-width: 768px) {
  .av-cmdbar-tabs { flex-direction: column; align-items: stretch; }
  .av-cmdbar-actions { flex-wrap: wrap; }
  .av-actions-cluster { margin-left: 0; width: 100%; justify-content: space-between; }
  .av-search { flex: 1 1 100%; max-width: none; }
}
