/* HUB Flow Monitor - style panelu. Podstawa: makieta docs/panel-mockup/styles.css w repo HUB (sekcje do "Stany specjalne"), niżej dodatki panelu. */

:root {
  --bg: #0B0F17;
  --bg-top: #0D121C;
  --panel: #111827;
  --panel-deep: #0F1520;
  --line: #1F2937;
  --line-soft: #172031;
  --line-input: #2A3647;
  --text: #E5E9F0;
  --text-2: #C9D1DC;
  --muted: #8B95A7;
  --accent: #38D6E8;
  --accent-line: #1E4E58;
  --in: #7FB8FF;
  --amber: #F5B841;
  --amber-line: #5C4A1A;

  /* Kolory wyników - spójne na wszystkich ekranach. */
  --ok: #3DD68C;
  --retry: #F5B841;
  --rejected: #FF8A3D;
  --error: #FF5C5C;
  --skipped: #9AA3B2;
  --requeued: #B79CFF;

  --sans: 'IBM Plex Sans', system-ui, sans-serif;
  --mono: 'IBM Plex Mono', ui-monospace, monospace;
}

* { box-sizing: border-box; }

body {
  margin: 0;
  min-height: 100vh;
  background: var(--bg);
  color: var(--text);
  font-family: var(--sans);
  font-size: 14px;
}

a { color: var(--accent); }
a:hover { color: #7FE6F2; }

button, input, select { font: inherit; color: inherit; }

.mono { font-family: var(--mono); }
.muted { color: var(--muted); }
.text-2 { color: var(--text-2); }
.right { text-align: right; }
.nowrap { white-space: nowrap; }

.label {
  font-size: 11px;
  letter-spacing: .16em;
  color: var(--muted);
  text-transform: uppercase;
}

.panel {
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: 6px;
}

/* ---------- Górny pasek ---------- */

.topbar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 14px 24px;
  border-bottom: 1px solid var(--line);
  background: var(--bg-top);
}

.topbar__group { display: flex; flex-wrap: wrap; align-items: center; gap: 14px; }

.brand { font-family: var(--mono); font-weight: 600; letter-spacing: .22em; font-size: 15px; }
.brand-sub { font-size: 11px; letter-spacing: .14em; color: var(--muted); text-transform: uppercase; }

.crumbs { display: flex; flex-wrap: wrap; align-items: center; gap: 12px; font-size: 13px; }
.crumbs a { text-decoration: none; }
.crumbs .sep { color: var(--line-input); }

.clock { display: flex; flex-direction: column; align-items: flex-end; }
.clock__time { font-family: var(--mono); font-size: 18px; font-weight: 500; letter-spacing: .06em; }
.clock__date { font-size: 11px; color: var(--muted); letter-spacing: .12em; }

.live {
  display: flex;
  align-items: center;
  gap: 8px;
  min-height: 36px;
  padding: 0 14px;
  border-radius: 4px;
  border: 1px solid var(--accent-line);
  background: transparent;
  color: var(--accent);
  font-family: var(--mono);
  font-size: 12px;
  font-weight: 600;
  letter-spacing: .16em;
  cursor: pointer;
}
.live__dot { width: 8px; height: 8px; border-radius: 50%; background: currentColor; animation: pulse 1.8s infinite; }
.live[aria-pressed="true"] { color: var(--amber); border-color: var(--amber-line); }
.live[aria-pressed="true"] .live__dot { animation: none; }

@keyframes pulse {
  0% { box-shadow: 0 0 0 0 rgba(56, 214, 232, .6); }
  70% { box-shadow: 0 0 0 8px rgba(56, 214, 232, 0); }
  100% { box-shadow: 0 0 0 0 rgba(56, 214, 232, 0); }
}

/* ---------- Wyniki (pigułki) ---------- */

.pill {
  --c: var(--skipped);
  display: inline-flex;
  align-items: center;
  padding: 2px 9px;
  border-radius: 3px;
  font-family: var(--mono);
  font-size: 12px;
  font-weight: 500;
  color: var(--c);
  background: color-mix(in srgb, var(--c) 12%, transparent);
  border: 1px solid color-mix(in srgb, var(--c) 33%, transparent);
}
.pill--sm { font-size: 11px; padding: 1px 7px; }

.o-ok, .o-delivered, .o-published, .o-created, .o-updated { --c: var(--ok); }
.o-retry { --c: var(--retry); }
.o-rejected { --c: var(--rejected); }
.o-error, .o-dead { --c: var(--error); }
.o-skipped, .o-unchanged { --c: var(--skipped); }
.o-requeued { --c: var(--requeued); }

/* ---------- Kafelki telemetrii ---------- */

.tiles {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 1px;
  background: var(--line);
  border-bottom: 1px solid var(--line);
}
.tile { background: var(--panel-deep); padding: 14px 20px; display: flex; flex-direction: column; gap: 6px; }
.tile__row { display: flex; align-items: flex-end; justify-content: space-between; gap: 12px; }
.tile__value { font-family: var(--mono); font-size: 28px; font-weight: 500; line-height: 1; color: var(--c, var(--text)); }
.tile__sub { font-family: var(--mono); font-size: 11px; color: var(--muted); }
.tile svg polyline { stroke: var(--c, var(--text)); }

.systems {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 12px;
  padding: 16px 24px 0;
}
.sys { --c: var(--ok); padding: 14px 16px; }
.sys--alert {
  --c: var(--error);
  border-color: #7A2A2A;
  box-shadow: inset 0 0 0 1px rgba(255, 92, 92, .25), 0 0 24px rgba(255, 92, 92, .08);
}
.sys__head { display: flex; align-items: center; justify-content: space-between; }
.sys__name { display: flex; align-items: center; gap: 10px; font-family: var(--mono); font-weight: 600; font-size: 15px; }
.sys__dot { width: 10px; height: 10px; border-radius: 50%; background: var(--c); box-shadow: 0 0 10px var(--c); }
.sys__state {
  font-family: var(--mono);
  font-size: 11px;
  letter-spacing: .12em;
  padding: 3px 8px;
  border-radius: 3px;
  color: var(--c);
  background: color-mix(in srgb, var(--c) 12%, transparent);
}
.sys__stats { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; margin-top: 12px; }
.sys__stats div { display: flex; flex-direction: column; gap: 2px; }
.sys__stats span:first-child { font-size: 10px; letter-spacing: .14em; color: var(--muted); }
.sys__stats span:last-child { font-family: var(--mono); font-size: 16px; }
.sys--alert .sys__err { color: var(--error); }

/* ---------- Układ strumienia ---------- */

.layout { display: flex; flex-wrap: wrap; gap: 16px; padding: 16px 24px 24px; align-items: flex-start; }

.sidebar { flex: 1 1 250px; max-width: 300px; padding: 16px; display: flex; flex-direction: column; gap: 18px; }
.sidebar__group { display: flex; flex-direction: column; gap: 8px; }
.sidebar__group--split { border-top: 1px solid var(--line); padding-top: 16px; gap: 10px; }

.content { flex: 999 1 560px; min-width: 0; display: flex; flex-direction: column; }
.content__bar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 12px 16px;
  border-bottom: 1px solid var(--line);
}
.content__foot {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 8px;
  padding: 12px 16px;
  border-top: 1px solid var(--line);
  font-size: 12px;
  color: var(--muted);
}

.btn {
  min-height: 36px;
  padding: 0 12px;
  border-radius: 4px;
  border: 1px solid var(--line);
  background: transparent;
  color: var(--text-2);
  text-align: left;
  cursor: pointer;
}
.btn--accent { border-color: var(--accent); background: rgba(56, 214, 232, .1); color: var(--text); }
.btn--lg { min-height: 44px; padding: 0 18px; text-align: center; }
.btn--danger { border-color: var(--error); color: #FF8080; }

.input {
  min-height: 36px;
  background: var(--bg);
  border: 1px solid var(--line-input);
  border-radius: 4px;
  padding: 0 10px;
  color: var(--text);
}
.input--mono { font-family: var(--mono); font-size: 12px; }
.input--lg { min-height: 44px; }
.field-label { font-size: 12px; color: var(--text-2); }

.segmented { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); border: 1px solid var(--line-input); border-radius: 4px; overflow: hidden; }
.segmented button { min-height: 34px; border: 0; background: transparent; color: var(--text-2); font-size: 12px; cursor: pointer; }
.segmented button + button { border-left: 1px solid var(--line-input); }
.segmented button[aria-pressed="true"] { background: #1B2638; color: var(--text); }

.check { display: flex; align-items: center; gap: 8px; font-size: 13px; }

.chips { display: flex; flex-wrap: wrap; gap: 6px; }
.chip {
  --c: var(--muted);
  padding: 3px 8px;
  border-radius: 3px;
  font-family: var(--mono);
  font-size: 11px;
  cursor: pointer;
  color: var(--muted);
  border: 1px solid var(--line-input);
  background: transparent;
}
.chip[aria-pressed="true"] {
  color: var(--c);
  border-color: color-mix(in srgb, var(--c) 53%, transparent);
  background: color-mix(in srgb, var(--c) 10%, transparent);
}

.resume {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  min-height: 40px;
  border: 0;
  border-bottom: 1px solid var(--amber-line);
  background: rgba(245, 184, 65, .12);
  color: var(--amber);
  font-size: 13px;
  cursor: pointer;
}
.resume[hidden] { display: none; }

/* ---------- Tabela strumienia ---------- */

.table-wrap { overflow-x: auto; }

.stream { width: 100%; min-width: 1040px; border-collapse: collapse; font-size: 13px; }
.stream th {
  padding: 10px 8px;
  font-weight: 500;
  font-size: 11px;
  letter-spacing: .14em;
  color: var(--muted);
  text-align: left;
  border-bottom: 1px solid var(--line);
}
.stream td { padding: 9px 8px; border-bottom: 1px solid var(--line-soft); }
.stream th:first-child, .stream td:first-child { padding-left: 16px; }
.stream th:last-child, .stream td:last-child { padding-right: 16px; }
.stream tbody tr { cursor: pointer; }
.stream tbody tr:hover { background: #151D2B; }
.stream td.mono { font-size: 12px; }
.stream td.time { font-size: 13px; color: var(--text-2); white-space: nowrap; }

.dir { font-family: var(--mono); font-size: 12px; font-weight: 600; white-space: nowrap; }
.dir--in { color: var(--in); }
.dir--out { color: var(--accent); }

.row-new { animation: flash 2.4s ease-out; }
@keyframes flash { from { background: rgba(56, 214, 232, .14); } to { background: transparent; } }

.row-selected { background: #1B2638; outline: 1px solid var(--accent); }

/* ---------- Szczegóły wpisu ---------- */

.split { display: flex; flex-wrap: wrap; flex: 1; }
.split__bg { flex: 999 1 520px; min-width: 0; padding: 24px; opacity: .38; }

.drawer {
  flex: 1 1 480px;
  max-width: 560px;
  background: var(--panel-deep);
  border-left: 1px solid var(--line-input);
  box-shadow: -24px 0 48px rgba(0, 0, 0, .45);
  display: flex;
  flex-direction: column;
}
.drawer__section { padding: 20px 24px; border-bottom: 1px solid var(--line); display: flex; flex-direction: column; gap: 8px; }
.drawer__head { flex-direction: row; align-items: flex-start; justify-content: space-between; gap: 12px; }

.icon-btn {
  width: 44px;
  height: 44px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: transparent;
  border: 1px solid var(--line-input);
  border-radius: 4px;
  color: var(--text-2);
  cursor: pointer;
}
.icon-btn--sm { width: 32px; height: 32px; color: var(--muted); }

.kv { display: grid; grid-template-columns: 140px minmax(0, 1fr) 44px; align-items: center; gap: 8px; min-height: 34px; border-bottom: 1px dashed #1A2333; }
.kv dt { font-size: 12px; color: var(--muted); }
.kv dd { margin: 0; font-family: var(--mono); font-size: 13px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

.record-row {
  display: grid;
  grid-template-columns: 110px minmax(0, 1fr) 90px;
  gap: 8px;
  align-items: center;
  padding: 10px 12px;
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: 4px;
  font-family: var(--mono);
  font-size: 12px;
}

.nav-link {
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 44px;
  padding: 0 14px;
  border: 1px solid var(--accent-line);
  border-radius: 4px;
  text-decoration: none;
  background: rgba(56, 214, 232, .06);
}
.nav-link span { font-family: var(--mono); font-size: 12px; }
.nav-link--disabled { border-color: var(--line-input); background: transparent; color: var(--muted); pointer-events: none; }

.notice {
  margin: auto 24px 24px;
  padding: 12px 14px;
  border: 1px solid var(--line-input);
  border-radius: 4px;
  display: flex;
  gap: 10px;
  align-items: flex-start;
  font-size: 12px;
  color: var(--text-2);
}

/* ---------- Ścieżka przepływu ---------- */

.grid-bg {
  background-image: linear-gradient(#121A27 1px, transparent 1px), linear-gradient(90deg, #121A27 1px, transparent 1px);
  background-size: 40px 40px;
}

.page { padding: 24px; display: flex; flex-direction: column; gap: 20px; width: 100%; max-width: 1440px; }
.page--narrow { max-width: 1120px; }

.page-head { display: flex; flex-wrap: wrap; align-items: flex-end; justify-content: space-between; gap: 16px; }

.stats { display: grid; grid-template-columns: repeat(4, minmax(120px, 1fr)); gap: 1px; background: var(--line); border: 1px solid var(--line); border-radius: 6px; overflow: hidden; }
.stat { background: var(--panel); padding: 10px 16px; display: flex; flex-direction: column; gap: 4px; }
.stat span:first-child { font-size: 10px; letter-spacing: .16em; color: var(--muted); }
.stat span:last-child { font-family: var(--mono); font-size: 15px; }

.trace { background: rgba(17, 24, 39, .92); padding: 24px; overflow-x: auto; }
.trace__inner { min-width: 1180px; display: flex; flex-direction: column; gap: 28px; }
.trace__axis { display: flex; justify-content: space-between; border-bottom: 1px solid var(--line-input); padding-bottom: 8px; font-family: var(--mono); font-size: 11px; color: var(--muted); }
.trace__flow { display: flex; align-items: center; }

.node {
  width: 230px;
  flex: none;
  background: var(--panel-deep);
  border: 1px solid var(--accent-line);
  border-radius: 6px;
  padding: 14px;
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.node--in { border-color: #2B4A7A; }
.node__head { display: flex; justify-content: space-between; align-items: center; }
.node__kind { font-size: 10px; letter-spacing: .16em; color: var(--accent); }
.node--in .node__kind { color: var(--in); }
.node__title { font-family: var(--mono); font-size: 15px; font-weight: 600; }
.node__meta { font-family: var(--mono); font-size: 11px; color: var(--muted); }

.wire { height: 1px; background: var(--accent); flex: none; }

.lanes { flex: 1; display: flex; flex-direction: column; gap: 20px; border-left: 1px solid var(--accent); padding: 6px 0; }
.lane { display: flex; align-items: center; }
.lane__label { width: 120px; flex: none; display: flex; flex-direction: column; gap: 2px; padding: 0 12px; }
.lane__label span:first-child { font-size: 10px; letter-spacing: .16em; color: var(--muted); }
.lane__label span:last-child { font-family: var(--mono); font-size: 14px; font-weight: 600; }

.attempt {
  width: 190px;
  flex: none;
  background: var(--panel-deep);
  border: 1px solid color-mix(in srgb, var(--c) 40%, transparent);
  border-radius: 6px;
  padding: 12px;
  display: flex;
  flex-direction: column;
  gap: 6px;
  font-family: var(--mono);
}
.attempt.o-delivered { box-shadow: 0 0 18px rgba(61, 214, 140, .12); }
.attempt__head { display: flex; justify-content: space-between; align-items: center; gap: 8px; }
.attempt__head span:first-child { font-family: var(--sans); font-size: 10px; letter-spacing: .14em; color: var(--muted); }
.attempt__http { font-size: 13px; }
.attempt__msg { font-size: 11px; color: var(--text-2); }
.attempt__time { font-size: 11px; color: var(--muted); }

.backoff { display: flex; flex-direction: column; align-items: center; gap: 4px; flex: none; }
.backoff span { font-family: var(--mono); font-size: 10px; color: var(--amber); letter-spacing: .08em; }
.backoff div { width: 96px; border-top: 1px dashed var(--amber-line); }

.legend { display: flex; flex-wrap: wrap; gap: 16px; font-size: 12px; color: var(--text-2); }
.legend > span { display: flex; align-items: center; gap: 8px; }

/* ---------- Historia rekordu ---------- */

.search { display: flex; flex-wrap: wrap; gap: 10px; align-items: flex-end; padding: 16px; }
.search__field { display: flex; flex-direction: column; gap: 6px; }

.counters { display: flex; flex-wrap: wrap; gap: 12px; }
.counter { flex: 1 1 160px; padding: 12px 16px; display: flex; flex-direction: column; gap: 4px; }
.counter span:first-child { font-size: 10px; letter-spacing: .16em; color: var(--muted); }
.counter span:last-child { font-family: var(--mono); font-size: 22px; }

.timeline { list-style: none; margin: 0; padding: 8px 0; }
.timeline li { display: grid; grid-template-columns: 150px 28px minmax(0, 1fr); gap: 0 12px; padding: 0 20px; }
.timeline__when { display: flex; flex-direction: column; gap: 2px; padding: 14px 0; text-align: right; font-family: var(--mono); }
.timeline__when span:first-child { font-size: 13px; }
.timeline__when span:last-child { font-size: 11px; color: var(--muted); }
.timeline__rail { display: flex; flex-direction: column; align-items: center; }
.timeline__rail::before { content: ''; width: 1px; height: 18px; background: var(--line-input); }
.timeline__rail::after { content: ''; width: 1px; flex: 1; background: var(--line-input); }
.timeline__dot { width: 11px; height: 11px; border-radius: 50%; flex: none; border: 2px solid var(--c); background: var(--bg); box-shadow: 0 0 8px color-mix(in srgb, var(--c) 40%, transparent); }
.timeline__body { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 8px 16px; padding: 12px 0; border-bottom: 1px solid var(--line-soft); }
.timeline__what { display: flex; flex-wrap: wrap; align-items: center; gap: 10px; }
.timeline__note { font-size: 12px; color: var(--muted); }

/* ---------- Stany specjalne ---------- */

.states { display: grid; grid-template-columns: repeat(auto-fit, minmax(520px, 1fr)); gap: 24px; padding: 40px; }
.states__full { grid-column: 1 / -1; }
.state { display: flex; flex-direction: column; gap: 10px; }

.alert {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 14px 20px;
  border: 1px solid #7A2A2A;
  border-radius: 6px;
  background: rgba(255, 92, 92, .08);
}
.alert__title { font-weight: 600; color: #FF8080; letter-spacing: .06em; }

.stale { opacity: .45; }

.empty { flex: 1; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 14px; padding: 40px; text-align: center; }
.filter-tag { padding: 4px 10px; border-radius: 3px; border: 1px solid var(--line-input); font-family: var(--mono); font-size: 12px; }

.mini-row { display: grid; grid-template-columns: 110px 100px minmax(0, 1fr) 90px; gap: 10px; align-items: center; padding: 10px 16px; border-bottom: 1px solid var(--line-soft); font-family: var(--mono); font-size: 12px; }
.mini-row .pill { justify-self: end; }

/* =====================================================================
   Dodatki panelu (poza makietą): nawigacja, logowanie, konto, panel
   szczegółów jako nakładka, toast. Te same tokeny kolorów co wyżej.
   ===================================================================== */

[hidden] { display: none !important; }

.small { font-size: 12px; }
.ellipsis { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.inline-fields { display: flex; gap: 6px; align-items: center; }
.inline-fields .input { min-width: 0; }
.inline-fields input.input { flex: 1; }

.brand-link { display: flex; align-items: center; gap: 12px; color: inherit; text-decoration: none; }
.brand-link > span { display: flex; flex-direction: column; }
.topbar__hint { font-size: 12px; }

.nav { display: flex; gap: 4px; margin-left: 12px; }
.nav a {
  padding: 6px 10px;
  border-radius: 4px;
  font-size: 13px;
  color: var(--text-2);
  text-decoration: none;
}
.nav a:hover { color: var(--text); background: #151D2B; }
.nav a[aria-current="page"] { color: var(--accent); background: rgba(56, 214, 232, .08); }

.user-chip { display: flex; align-items: center; gap: 10px; padding-left: 14px; border-left: 1px solid var(--line); }
.user-chip__name { font-size: 13px; color: var(--text-2); }

.app-foot { padding: 0 24px 24px; font-size: 11px; letter-spacing: .08em; }

.loading { padding: 24px 16px; font-size: 12px; }

.alert--banner { margin: 16px 24px 0; }
.alert--sm { padding: 10px 14px; font-size: 13px; color: #FF8080; }
.alert__body { display: flex; flex-direction: column; gap: 2px; }

.notice--inline { margin: 12px 16px; color: #FF8080; border-color: #7A2A2A; }
.page > .notice--inline, .page--narrow > .notice--inline { margin: 0; }

.filter-tags { padding: 10px 16px; border-bottom: 1px solid var(--line); }
.filter-tags .filter-tag { background: transparent; color: var(--text-2); cursor: pointer; }
.filter-tags .filter-tag:hover { border-color: var(--accent-line); color: var(--text); }

.empty__title { letter-spacing: .16em; font-size: 13px; }
.empty__text { max-width: 380px; font-size: 13px; }

.stream tbody tr.row-static { cursor: default; }

/* Panel szczegółów wpisu jako nakładka z prawej (makieta detail.html). */
.drawer--overlay {
  position: fixed;
  top: 0;
  right: 0;
  bottom: 0;
  width: min(560px, 100%);
  max-width: none;
  overflow-y: auto;
  z-index: 20;
}
.drawer-backdrop { position: fixed; inset: 0; background: rgba(5, 8, 13, .55); z-index: 19; }
.drawer__title { display: flex; flex-direction: column; gap: 8px; min-width: 0; }
.drawer__route { font-size: 15px; word-break: break-all; }

/* Ścieżka przepływu: kilka zdarzeń jednego requestu jeden pod drugim. */
.trace__events { flex: 1; display: flex; flex-direction: column; gap: 24px; border-left: 1px solid var(--accent); padding-left: 0; }
.trace__events > .trace__flow::before { content: ''; width: 24px; height: 1px; background: var(--accent); flex: none; }
.trace__note { padding: 0 16px; }
.legend__line { width: 24px; height: 1px; background: var(--accent); }
.legend__dash { width: 24px; border-top: 1px dashed var(--amber); }

.page-head__title { display: flex; flex-direction: column; gap: 6px; }
.page-title { font-size: 20px; letter-spacing: .04em; }
.stats--3 { grid-template-columns: repeat(3, minmax(140px, 1fr)); }
.counter__list { font-size: 14px !important; padding-top: 6px; }

/* Logowanie i kod 2FA. */
.auth-page { display: flex; align-items: center; justify-content: center; padding: 24px; }
.auth { width: min(420px, 100%); padding: 28px; display: flex; flex-direction: column; gap: 20px; }
.auth__head { display: flex; flex-direction: column; gap: 4px; }
.auth__form { display: flex; flex-direction: column; gap: 10px; }
.auth__form .btn { margin-top: 8px; }
.auth__note { margin: 0; font-size: 12px; line-height: 1.5; }
.auth__link { display: flex; align-items: center; justify-content: center; text-decoration: none; }
.input--code { font-size: 18px; letter-spacing: .3em; }

/* Konto. */
.account-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); gap: 16px; align-items: start; }
.card { padding: 16px 18px; display: flex; flex-direction: column; gap: 12px; }
.card__text { margin: 0; font-size: 13px; line-height: 1.5; }
.card__note { font-size: 12px; }
.form { display: flex; flex-direction: column; gap: 6px; }
.form .btn { margin-top: 8px; align-self: flex-start; }
.field-error { min-height: 0; font-size: 12px; color: #FF8080; }
.field-error:empty { display: none; }
.textarea { min-height: 110px; padding: 8px 10px; resize: vertical; }
.qr { align-self: flex-start; border-radius: 4px; background: #fff; padding: 6px; }
.secret { padding: 8px 10px; border: 1px solid var(--line-input); border-radius: 4px; font-size: 12px; word-break: break-all; }

.toast {
  position: fixed;
  right: 24px;
  bottom: 24px;
  z-index: 30;
  max-width: 420px;
  padding: 12px 16px;
  border-radius: 4px;
  border: 1px solid var(--accent-line);
  background: var(--panel);
  color: var(--text);
  font-size: 13px;
  box-shadow: 0 12px 32px rgba(0, 0, 0, .45);
}
.toast[data-tone="error"] { border-color: #7A2A2A; color: #FF8080; }

/* Kolor chipa filtra wyniku: .chip ustawia --c: muted później niż klasy
   .o-*, więc w makiecie zaznaczone chipy też wychodziły szare. */
.chip.o-ok, .chip.o-delivered, .chip.o-published { --c: var(--ok); }
.chip.o-retry { --c: var(--retry); }
.chip.o-rejected { --c: var(--rejected); }
.chip.o-error, .chip.o-dead { --c: var(--error); }
.chip.o-skipped { --c: var(--skipped); }
.chip.o-requeued { --c: var(--requeued); }
