/* ============================================================
   URBINO · STATUS TIMELINE
   Molecule. Lifecycle progression for an issue.
   Vertical (default, citizen detail view) + horizontal (manager).

   4 lifecycle steps: Új → Jóváhagyva → Folyamatban → Megoldódott
   (Elutasítva is manager-only and replaces the active step, never
   shown to citizens — see chip.md.)
   ============================================================ */

.u-timeline {
  display: flex;
  flex-direction: column;
  list-style: none;
  margin: 0;
  padding: 0;
}

/* ---------- STEP ---------- */
.u-timeline-step {
  display: flex;
  gap: 14px;
  padding-bottom: 20px;
  position: relative;
}
.u-timeline-step:last-child { padding-bottom: 0; }

/* Connector — vertical line between this step and the next */
.u-timeline-step:not(:last-child)::before {
  content: "";
  position: absolute;
  left: 13px;
  top: 28px;
  bottom: 0;
  width: 2px;
  background: var(--u-slate-200);
}

/* ---------- INDICATOR ---------- */
.u-timeline-step__indicator {
  flex-shrink: 0;
  width: 28px; height: 28px;
  border-radius: 50%;
  background: var(--u-surface);
  border: var(--u-border-w-thick) solid var(--u-border-strong);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  position: relative;
  z-index: 1;
  box-sizing: border-box;
  transition: background var(--u-dur-base) var(--u-ease-out), border-color var(--u-dur-base) var(--u-ease-out);
}

/* ---------- BODY (title + time + optional note) ---------- */
.u-timeline-step__body {
  flex: 1;
  min-width: 0;
  padding-top: 4px;
}
.u-timeline-step__title {
  font-family: var(--u-font-sans);
  font-size: 15px;
  font-weight: 600;
  color: var(--u-fg-3);
  line-height: 1.3;
  margin: 0;
}
.u-timeline-step__time {
  font-size: 13px;
  color: var(--u-fg-3);
  margin-top: 2px;
  font-variant-numeric: tabular-nums;
}
.u-timeline-step__note {
  font-size: 13px;
  color: var(--u-fg-2);
  margin-top: var(--u-space-1);
  line-height: 1.5;
}

/* ============================================================
   STATES — future (default) · current · done · rejected
   ============================================================ */

/* DONE (completed) — filled brand circle with white check */
.u-timeline-step--done .u-timeline-step__indicator {
  background: var(--u-primary);
  border-color: var(--u-primary);
}
.u-timeline-step--done .u-timeline-step__indicator::after {
  content: "";
  display: block;
  width: 6px; height: 11px;
  border-right: 2px solid var(--u-fg-inv);
  border-bottom: 2px solid var(--u-fg-inv);
  transform: rotate(45deg) translate(-1px, -1px);
}
.u-timeline-step--done .u-timeline-step__title { color: var(--u-fg-1); }
.u-timeline-step--done:not(:last-child)::before { background: var(--u-primary); }

/* CURRENT (active) — filled brand with white inner dot, soft halo */
.u-timeline-step--current .u-timeline-step__indicator {
  background: var(--u-primary);
  border-color: var(--u-primary);
  box-shadow: 0 0 0 4px var(--u-blue-100);
}
.u-timeline-step--current .u-timeline-step__indicator::after {
  content: "";
  display: block;
  width: 8px; height: 8px;
  border-radius: 50%;
  background: var(--u-fg-inv);
}
.u-timeline-step--current .u-timeline-step__title {
  color: var(--u-fg-1);
  font-weight: 700;
}

/* REJECTED — replaces the current step on manager-side only */
.u-timeline-step--rejected .u-timeline-step__indicator {
  background: var(--u-red-500);
  border-color: var(--u-red-500);
}
.u-timeline-step--rejected .u-timeline-step__indicator::after {
  content: "×";
  color: var(--u-fg-inv);
  font-size: 18px;
  font-weight: 700;
  line-height: 1;
}
.u-timeline-step--rejected .u-timeline-step__title {
  color: var(--u-red-700);
  font-weight: 700;
}

/* FUTURE (not started) — default visual; no extra rules needed */


/* ============================================================
   CITIZEN size — larger indicator + body for mobile
   ============================================================ */

.u-timeline--cit .u-timeline-step { gap: 16px; padding-bottom: 24px; }
.u-timeline--cit .u-timeline-step__indicator { width: 32px; height: 32px; }
.u-timeline--cit .u-timeline-step:not(:last-child)::before {
  left: 15px;
  top: 32px;
}
.u-timeline--cit .u-timeline-step__title { font-size: 16px; }
.u-timeline--cit .u-timeline-step__time { font-size: 14px; }
.u-timeline--cit .u-timeline-step__note { font-size: 14px; }
.u-timeline--cit .u-timeline-step--current .u-timeline-step__indicator::after { width: 10px; height: 10px; }


/* ============================================================
   HORIZONTAL — manager detail-view header bar
   Steps spread evenly, connector lines run between indicators.
   ============================================================ */

.u-timeline--horizontal {
  flex-direction: row;
  align-items: flex-start;
}
.u-timeline--horizontal .u-timeline-step {
  flex: 1;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  padding-bottom: 0;
  padding-top: 0;
  text-align: center;
}
.u-timeline--horizontal .u-timeline-step:not(:last-child)::before {
  left: calc(50% + 16px);
  top: 13px;
  bottom: auto;
  right: -50%;
  width: auto;
  height: 2px;
}
.u-timeline--horizontal .u-timeline-step__body { padding-top: 0; }
.u-timeline--horizontal .u-timeline-step__title { font-size: 13px; }
.u-timeline--horizontal .u-timeline-step__time { font-size: 12px; margin-top: 4px; }
.u-timeline--horizontal .u-timeline-step__note { display: none; }


/* ============================================================
   COMPACT — vertical, dense (manager activity log)
   ============================================================ */

.u-timeline--compact .u-timeline-step { gap: 10px; padding-bottom: 12px; }
.u-timeline--compact .u-timeline-step__indicator { width: 20px; height: 20px; border-width: var(--u-border-w-thin); }
.u-timeline--compact .u-timeline-step:not(:last-child)::before {
  left: 9px;
  top: 20px;
  width: 1.5px;
}
.u-timeline--compact .u-timeline-step__title { font-size: 13px; font-weight: 500; }
.u-timeline--compact .u-timeline-step__time { font-size: 11px; margin-top: 1px; }
.u-timeline--compact .u-timeline-step--done .u-timeline-step__indicator::after { width: 4px; height: 8px; }
.u-timeline--compact .u-timeline-step--current .u-timeline-step__indicator::after { width: 6px; height: 6px; }
