/* css/analytics.css — FAZ E-1 Return Analytics sayfası */

.ra-wrap { padding: 16px 20px 40px; }
/* E-1R: Returns 3. tab'ı içinde sayfa başlığı zaten var — çift başlık gizle */
#rp3-pane-analytics .ra-head { display: none; }
#rp3-pane-analytics .ra-wrap { padding: 8px 0 30px; }
.ra-head { display: flex; align-items: baseline; gap: 12px; margin-bottom: 14px; }
.ra-head h2 { margin: 0; font-size: 20px; }
.ra-sub { color: #6b7280; font-size: 12px; }
.ra-noaccess { padding: 40px; text-align: center; color: #6b7280; }
.ra-empty { padding: 30px; text-align: center; color: #6b7280; }

/* KPI şeridi */
.ra-kpis { display: grid; grid-template-columns: repeat(4, 1fr); gap: 12px; margin-bottom: 8px; }
.ra-kpi { background: #fff; border: 1px solid #e5e7eb; border-radius: 10px; padding: 12px 14px; }
.ra-kpi-label { font-size: 11px; text-transform: uppercase; letter-spacing: .04em; color: #6b7280; }
.ra-kpi-value { font-size: 24px; font-weight: 700; margin-top: 2px; }
.ra-kpi-note { font-size: 11px; color: #6b7280; margin-top: 2px; }
.ra-delta-up { color: #cc0000; font-size: 12px; font-weight: 600; }
.ra-delta-down { color: #38761d; font-size: 12px; font-weight: 600; }
.ra-dq { font-size: 11px; color: #92400e; background: #fef3c7; border: 1px solid #fde68a;
  border-radius: 8px; padding: 6px 10px; margin-bottom: 12px; display: inline-block; }

/* Filtre barı — yapışkan */
.ra-filters { position: sticky; top: 0; z-index: 5; background: #f9fafb;
  border: 1px solid #e5e7eb; border-radius: 10px; padding: 10px 12px;
  display: flex; flex-wrap: wrap; gap: 10px; align-items: center; margin-bottom: 16px; }
.ra-filter { display: flex; flex-direction: column; gap: 2px; }
.ra-filter label { font-size: 10px; text-transform: uppercase; color: #6b7280; }
.ra-filter select { min-width: 120px; padding: 4px 6px; border: 1px solid #d1d5db;
  border-radius: 6px; font-size: 12px; background: #fff; }
.ra-reset { margin-left: auto; font-size: 12px; padding: 6px 10px; border: 1px solid #d1d5db;
  border-radius: 6px; background: #fff; cursor: pointer; }
.ra-reset:hover { background: #f3f4f6; }

/* Rapor kartları */
.ra-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 16px; }
.ra-card { background: #fff; border: 1px solid #e5e7eb; border-radius: 10px; padding: 14px; }
.ra-card-head { display: flex; align-items: center; gap: 8px; margin-bottom: 8px; }
.ra-card-head h3 { margin: 0; font-size: 14px; flex: 1; }
.ra-card-note { font-size: 11px; color: #6b7280; margin-top: 6px; }
.ra-exp { font-size: 11px; padding: 3px 8px; border: 1px solid #d1d5db; border-radius: 6px;
  background: #fff; cursor: pointer; }
.ra-exp:hover { background: #f3f4f6; }
.ra-canvas-box { position: relative; height: 260px; }

/* Leaderboard tablosu */
.ra-table { width: 100%; border-collapse: collapse; font-size: 12px; margin-top: 8px; }
.ra-table th { text-align: left; padding: 5px 8px; background: #f3f4f6; color: #374151;
  border-bottom: 1px solid #e5e7eb; }
.ra-table td { padding: 5px 8px; border-bottom: 1px solid #f3f4f6; }
.ra-table td.num, .ra-table th.num { text-align: right; }
.ra-rate-hot { color: #cc0000; font-weight: 700; }

/* E-3 — Benchmark & Alarm kartı */
.ra-bench-rate { font-size: 34px; font-weight: 800; display: flex; align-items: center; gap: 10px; padding: 14px 4px; }
.ra-bench-lines { font-size: 12px; color: #6b7280; display: flex; gap: 18px; padding: 0 4px 10px; }
.ra-bench-empty { padding: 30px 10px; color: #6b7280; font-size: 13px; }
.ra-bench-empty a { color: #0369a1; font-weight: 600; }
.ra-pill { font-size: 11px; font-weight: 800; letter-spacing: .05em; padding: 4px 10px; border-radius: 12px; }
.ra-pill-ok { background: #dcfce7; color: #14532d; }
.ra-pill-warn { background: #ffedd5; color: #9a3412; }
.ra-pill-alert { background: #fee2e2; color: #991b1b; }

/* E-3 — Analytics Settings modal */
.ra-set-overlay { position: fixed; inset: 0; background: rgba(15,23,42,.45); z-index: 50;
  display: flex; align-items: center; justify-content: center; }
.ra-set-modal { background: #fff; border-radius: 12px; padding: 18px 20px; width: 460px;
  max-height: 82vh; overflow-y: auto; box-shadow: 0 20px 50px rgba(0,0,0,.25); }
.ra-set-modal h3 { margin: 0 0 10px; font-size: 16px; }
.ra-set-sec { border-top: 1px solid #e5e7eb; padding: 10px 0; }
.ra-set-sec h4 { margin: 0 0 4px; font-size: 13px; }
.ra-set-hint { margin: 0 0 8px; font-size: 11px; color: #6b7280; }
.ra-set-sec label { display: flex; justify-content: space-between; align-items: center;
  font-size: 12px; margin-bottom: 6px; gap: 10px; }
.ra-set-sec input { width: 90px; padding: 4px 6px; border: 1px solid #d1d5db; border-radius: 6px; }
.ra-set-flags { max-height: 240px; overflow-y: auto; }
.ra-flag-row span { flex: 1; }
.ra-flag-sel { padding: 3px 6px; border: 1px solid #d1d5db; border-radius: 6px; font-size: 12px; }
.ra-set-btns { display: flex; justify-content: flex-end; gap: 8px; padding-top: 12px; }
.ra-set-btns button { padding: 6px 14px; border-radius: 6px; border: 1px solid #d1d5db;
  background: #fff; cursor: pointer; font-size: 13px; }
.ra-set-primary { background: #0369a1 !important; color: #fff; border-color: #0369a1 !important; }

@media (max-width: 1100px) {
  .ra-kpis { grid-template-columns: repeat(2, 1fr); }
  .ra-grid { grid-template-columns: 1fr; }
}

/* E-4a — Risk-Adjusted negatif net */
.ra-neg { color: #cc0000; font-weight: 700; }
