/* ===========================================================
   retros.css — Retrospectives module (js/retrospectives.js).
   Uses the app design tokens. Modern SaaS board + dashboard.
   =========================================================== */
.retros { display: flex; flex-direction: column; gap: 14px; }

/* header + tabs */
.rt-head { display: flex; align-items: center; justify-content: space-between; gap: 16px; flex-wrap: wrap; padding: 14px 18px; }
.rt-title { display: flex; align-items: center; gap: 10px; }
.rt-title h3 { margin: 0; font-family: var(--fh); font-size: 18px; }
.rt-badge { font-size: 9.5px; font-weight: 800; letter-spacing: .12em; color: #fff; background: var(--grad); border-radius: 999px; padding: 3px 9px; }
.rt-head-sub { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; font-size: 12px; margin-top: 6px; }
.rt-scope { font: inherit; font-size: 12.5px; font-weight: 600; color: var(--ink); background: var(--card); border: 1px solid var(--line-2); border-radius: 999px; padding: 6px 12px; cursor: pointer; max-width: 260px; }
.rt-tabs { display: flex; gap: 6px; flex-wrap: wrap; }
.rt-tab { border: 1px solid var(--line); background: var(--card); color: var(--muted); border-radius: 999px; padding: 7px 15px; font: inherit; font-size: 13px; font-weight: 600; cursor: pointer; transition: .12s; }
.rt-tab:hover { border-color: var(--brand); color: var(--brand); }
.rt-tab.on { background: var(--grad); color: #fff; border-color: transparent; }

/* KPIs */
.rt-kpis { display: grid; grid-template-columns: repeat(7, 1fr); gap: 10px; }
.rt-kpi { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 12px 14px; }
.rt-kpi-v { font-family: var(--fh); font-size: 1.7rem; font-weight: 700; line-height: 1; }
.rt-kpi-l { font-size: 11px; color: var(--muted); margin-top: 6px; }
.rt-kpi.accent { background: linear-gradient(135deg, #fff, #fbf3ea); border-color: #eccba6; }
.rt-kpi.accent .rt-kpi-v { background: var(--grad); -webkit-background-clip: text; background-clip: text; -webkit-text-fill-color: transparent; }
.rt-kpi.ok .rt-kpi-v { color: var(--leaf); }
.rt-kpi.bad .rt-kpi-v { color: var(--block); }

/* dashboard grid + charts */
.rt-dash-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; }
.rt-card { padding: 14px 16px; }
.rt-card-h { font-family: var(--fh); font-weight: 700; font-size: 13px; margin-bottom: 10px; color: var(--ink); }
.rt-chart { display: flex; align-items: center; gap: 14px; flex-wrap: wrap; }
.rt-donut-v { font: 700 20px var(--fh); fill: var(--ink); }
.rt-donut-l { font: 600 9px var(--fb); fill: var(--muted); text-transform: uppercase; letter-spacing: .06em; }
.rt-legend { display: flex; flex-direction: column; gap: 5px; font-size: 11.5px; color: var(--muted); }
.rt-leg { display: flex; align-items: center; gap: 7px; }
.rt-leg i { width: 10px; height: 10px; border-radius: 3px; flex: none; }
.rt-bars { display: flex; flex-direction: column; gap: 7px; }
.rt-bar-row { display: flex; align-items: center; gap: 8px; font-size: 12px; }
.rt-bar-lbl { flex: 0 0 34%; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; color: var(--ink); }
.rt-bar-track { flex: 1; height: 9px; background: rgba(0,0,0,.06); border-radius: 999px; overflow: hidden; }
.rt-bar-fill { display: block; height: 100%; background: var(--brand); border-radius: 999px; transition: width .3s; min-width: 2px; }
.rt-bar-v { flex: none; color: var(--muted); font-size: 11px; }
.rt-empty { font-size: 12.5px; color: var(--muted); padding: 12px 4px; text-align: center; }

/* filter bar */
.rt-filter { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.rt-filter .fld { max-width: 200px; }
.rt-filter input[type=search] { min-width: 220px; flex: 1; max-width: none; }
.rt-spacer { flex: 1; }

/* retro list */
.rt-list { display: grid; grid-template-columns: repeat(auto-fill, minmax(290px, 1fr)); gap: 14px; }
.rt-rcard { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 14px; cursor: pointer; transition: border-color .12s, box-shadow .12s, transform .12s; box-shadow: var(--shadow-sm); }
.rt-rcard:hover { border-color: var(--brand-2); box-shadow: var(--shadow-md); transform: translateY(-2px); }
.rt-rcard-top { display: flex; justify-content: space-between; gap: 8px; margin-bottom: 8px; }
.rt-rcard-title { font-family: var(--fh); font-weight: 700; font-size: 15px; line-height: 1.35; margin-bottom: 8px; }
.rt-rcard-meta { display: flex; flex-direction: column; gap: 4px; font-size: 12px; margin-bottom: 10px; }
.rt-rcard-foot { display: flex; gap: 14px; border-top: 1px solid var(--line); padding-top: 8px; }
.rt-mini { font-size: 11px; color: var(--muted); } .rt-mini b { color: var(--ink); font-size: 13px; }
.rt-empty-card { padding: 26px; text-align: center; color: var(--muted); line-height: 1.7; }

/* type + status chips */
.rt-type, .rt-status { font-size: 10px; font-weight: 700; border-radius: 999px; padding: 2px 9px; white-space: nowrap; }
.rt-type { background: #eef2fb; color: #2c4f9e; border: 1px solid #cdd9f2; }
.rt-type-pregolive { background: #fdf3da; color: #8a5a12; border-color: #eed398; }
.rt-type-postgolive { background: #e9f2e2; color: #2f6f23; border-color: #bcd6aa; }
.rt-type-hypercare { background: #f3e9fb; color: #6b3fa0; border-color: #ddc7f0; }
.rt-type-endofproject { background: #fbe9e3; color: #b2541f; border-color: #f0c9b3; }
.rt-status { background: var(--nav-2); color: var(--muted); border: 1px solid var(--line); }
.rt-st-approved, .rt-st-closed { background: #e9f2e2; color: #2f6f23; border-color: #bcd6aa; }
.rt-st-draft { background: var(--nav-2); color: var(--muted); }
.rt-st-review, .rt-st-teamapproval, .rt-st-pmapproval { background: #fdf3da; color: #8a5a12; border-color: #eed398; }

/* board */
.rt-board-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 16px; flex-wrap: wrap; padding: 14px 18px; }
.rt-bh-l { display: flex; gap: 12px; align-items: flex-start; }
.rt-bh-title { font-family: var(--fh); font-weight: 700; font-size: 17px; }
.rt-bh-meta { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; margin-top: 5px; font-size: 12px; }
.rt-bh-r { display: flex; flex-direction: column; gap: 8px; align-items: flex-end; }
.rt-bh-actions { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; }
.rt-status-sel { font: inherit; font-size: 12.5px; font-weight: 700; border: 1px solid var(--line-2); border-radius: 999px; padding: 5px 11px; background: var(--card); }
.rt-wf { display: flex; gap: 4px; flex-wrap: wrap; }
.rt-wf-step { font-size: 9.5px; font-weight: 700; color: var(--muted); background: var(--nav-2); border: 1px solid var(--line); border-radius: 999px; padding: 2px 8px; }
.rt-wf-step.done { color: #fff; background: var(--leaf); border-color: var(--leaf); }
.rt-chip { font-size: 11px; background: var(--nav-2); border: 1px solid var(--line); border-radius: 999px; padding: 2px 9px; }

.rt-cols { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; align-items: start; }
.rt-col { background: var(--bg); border: 1px solid var(--line); border-radius: var(--radius); border-top: 4px solid var(--line-2); display: flex; flex-direction: column; min-height: 140px; }
.rt-col-stop { border-top-color: #cf3c2e; }
.rt-col-continue { border-top-color: #4f8f3f; }
.rt-col-start { border-top-color: #2563eb; }
.rt-col.rt-drop { background: rgba(191,85,15,.06); box-shadow: inset 0 0 0 2px var(--brand-2); }
.rt-col-h { display: flex; align-items: center; justify-content: space-between; gap: 8px; padding: 10px 14px; border-bottom: 1px solid var(--line); }
.rt-col-name { display: flex; flex-direction: column; }
.rt-col-name > span:first-child { font-family: var(--fh); font-weight: 700; font-size: 13.5px; }
.rt-col-hint { font-size: 10.5px; color: var(--muted); }
.rt-col-n { font-size: 12px; color: var(--muted); background: var(--card); border: 1px solid var(--line); border-radius: 999px; padding: 1px 9px; }
.rt-col-body { display: flex; flex-direction: column; gap: 8px; padding: 10px; min-height: 50px; }

.rt-item { background: var(--card); border: 1px solid var(--line-2); border-left: 3px solid var(--grey); border-radius: 10px; padding: 10px 12px; cursor: pointer; box-shadow: var(--shadow-sm); transition: border-color .12s, box-shadow .12s, transform .1s; }
.rt-item:hover { border-color: var(--brand-2); box-shadow: var(--shadow-md); }
.rt-item.rt-dragging { opacity: .45; }
.rt-item-stop { border-left-color: #cf3c2e; }
.rt-item-continue { border-left-color: #4f8f3f; }
.rt-item-start { border-left-color: #2563eb; }
.rt-item-done { opacity: .65; }
.rt-item-top { display: flex; align-items: center; gap: 6px; flex-wrap: wrap; margin-bottom: 5px; }
.rt-item-id { font-size: 10px; }
.rt-item-title { font-size: 13.5px; font-weight: 600; line-height: 1.35; color: var(--ink); }
.rt-item-desc { font-size: 11.5px; color: var(--muted); margin-top: 3px; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.rt-item-foot { display: flex; align-items: center; gap: 6px; flex-wrap: wrap; margin-top: 8px; }
.rt-chip-sm { font-size: 10px; color: var(--muted); background: var(--nav-2); border: 1px solid var(--line); border-radius: 999px; padding: 1px 8px; }
.rt-addcard { border: 1px dashed var(--line-2); background: none; color: var(--muted); border-radius: 9px; padding: 9px; font: inherit; font-size: 12.5px; font-weight: 600; cursor: pointer; }
.rt-addcard:hover { border-color: var(--brand); color: var(--brand); background: #fdf2e4; }

/* severity / priority */
.rt-sev { font-size: 9.5px; font-weight: 700; border-radius: 999px; padding: 1px 8px; }
.rt-sev-critical { background: #fde0dd; color: #cf3c2e; }
.rt-sev-high { background: #fdeae0; color: #c05621; }
.rt-sev-medium { background: #e8effc; color: #2563eb; }
.rt-sev-low { background: #e8f0e3; color: #4f8f3f; }
.rt-prio { font-size: 9.5px; font-weight: 700; color: var(--muted); border: 1px solid var(--line-2); border-radius: 999px; padding: 1px 8px; }
.rt-col-tag { font-size: 10px; font-weight: 700; border-radius: 999px; padding: 1px 9px; color: #fff; }
.rt-col-tag.rt-col-stop { background: #cf3c2e; }
.rt-col-tag.rt-col-continue { background: #4f8f3f; }
.rt-col-tag.rt-col-start { background: #2563eb; }

/* editor + modals */
.rt-editor { max-width: 760px; }
.rt-ed-head { display: flex; align-items: center; gap: 10px; margin-bottom: 12px; }
.rt-edit-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 10px 12px; }
.rt-span2 { grid-column: 1 / -1; }
.rt-f { display: flex; flex-direction: column; gap: 3px; }
.rt-fl { font-size: 11px; font-weight: 600; color: var(--muted); }
.rt-modal { max-width: 560px; } .rt-modal h3 { font-family: var(--fh); margin: 0 0 4px; }
.rt-grid2 { display: grid; grid-template-columns: 1fr 1fr; gap: 10px 12px; }
.rt-sec { font-family: var(--fh); font-size: 15px; margin: 8px 2px 2px; }

/* actions sub-section */
.rt-actions { display: flex; flex-direction: column; gap: 7px; }
.rt-action { display: grid; grid-template-columns: auto 1.6fr 1fr 130px 120px 70px auto auto; gap: 6px; align-items: center; }
.rt-action.rt-action-late { background: rgba(207,60,46,.05); border-radius: 8px; padding: 3px; }
.rt-aid { font-size: 10px; }
.rt-addaction { align-self: flex-start; margin-top: 4px; }

/* participants */
.rt-parts { display: flex; flex-direction: column; gap: 7px; }
.rt-part-row { display: grid; grid-template-columns: 1.4fr 1fr 1fr auto; gap: 7px; align-items: center; }

/* repository */
.rt-repo td { vertical-align: top; }
.rt-repo tr, .rt-repo tbody tr { cursor: pointer; }
.rt-repo tbody tr:hover { background: #fbf7ef; }
.rt-repo-desc { font-size: 11px; margin-top: 2px; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; max-width: 420px; }

/* insights */
.rt-insights { padding: 14px 16px; display: flex; flex-direction: column; gap: 8px; }
.rt-insight { display: flex; gap: 10px; align-items: flex-start; font-size: 13px; line-height: 1.5; padding: 9px 11px; background: var(--nav-2); border: 1px solid var(--line); border-radius: 10px; }
.rt-insight-ico { flex: none; }

@media (max-width: 1100px) { .rt-kpis { grid-template-columns: repeat(4, 1fr); } .rt-dash-grid { grid-template-columns: 1fr 1fr; } }
@media (max-width: 760px) {
  .rt-kpis { grid-template-columns: repeat(2, 1fr); }
  .rt-dash-grid, .rt-cols { grid-template-columns: 1fr; }
  .rt-edit-grid, .rt-grid2 { grid-template-columns: 1fr; }
  .rt-action { grid-template-columns: 1fr 1fr; }
  .rt-part-row { grid-template-columns: 1fr 1fr; }
}
