/* ============================================================
   LISTA — production pipeline view
   ============================================================ */

.li-page { display: flex; flex-direction: column; gap: 24px; padding-bottom: 48px; }

/* Height of the top bar (.li-top), used to pin the filters+headers band just
   below it. Approximate — if it's a few px off, only a sliver of the band's
   top padding hides behind .li-top, which is harmless. The column header no
   longer needs its own offset (it bottom-stacks inside .li-stickyhead). */
:root {
  --li-top-h: 56px;
}

.li-top {
  position: sticky;
  top: 0;
  z-index: 40;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px 32px 14px;
  border-bottom: 1px solid var(--hairline);
  background: var(--bg);
}
.li-top-title { font-size: 18px; font-weight: 500; letter-spacing: -0.015em; color: var(--text); }
.li-search {
  display: inline-flex; align-items: center; gap: 7px;
  padding: 6px 10px;
  border: 1px solid var(--hairline);
  border-radius: 7px;
  background: var(--bg-elevated);
  color: var(--text-muted);
  min-width: 280px;
}
.li-search input {
  flex: 1; font-size: 12.5px; color: var(--text); border: 0; background: transparent;
}
.li-search input::placeholder { color: var(--text-faint); }
.li-search input:focus { outline: none; }

/* ── STAGE TOTALS ───────────────────────────────────────── */
.li-totals { display: flex; flex-direction: column; gap: 10px; padding-top: 8px; }
.li-totals-row {
  display: grid;
  grid-template-columns: repeat(8, minmax(0, 1fr));
  gap: 1px;
  background: var(--hairline);
  border: 1px solid var(--hairline);
  border-radius: 8px;
  overflow: hidden;
}
.li-total {
  background: var(--bg-elevated);
  display: flex;
  flex-direction: column;
  gap: 5px;
  padding: 12px 14px;
  text-align: left;
  cursor: pointer;
  transition: background 100ms;
}
.li-total:hover { background: var(--surface); }
.li-total.is-active { background: var(--text); color: var(--bg); }
.li-total-k {
  font-size: 10px;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--text-muted);
}
.li-total.is-active .li-total-k { color: oklch(1 0 0 / 0.6); }
.dark .li-total.is-active .li-total-k { color: oklch(0 0 0 / 0.6); }
.li-total-v {
  font-size: 22px;
  font-weight: 500;
  letter-spacing: -0.02em;
  line-height: 1;
  color: var(--text);
}
.li-total.is-active .li-total-v { color: var(--bg); }
.li-total-of {
  font-size: 12px;
  font-weight: 400;
  color: var(--text-muted);
  margin-left: 2px;
}
.li-total.is-active .li-total-of { color: oklch(1 0 0 / 0.5); }
.dark .li-total.is-active .li-total-of { color: oklch(0 0 0 / 0.5); }
.li-total-bar {
  height: 3px;
  background: var(--hairline);
  border-radius: 2px;
  overflow: hidden;
  margin-top: 2px;
}
.li-total.is-active .li-total-bar { background: oklch(1 0 0 / 0.2); }
.dark .li-total.is-active .li-total-bar { background: oklch(0 0 0 / 0.2); }
.li-total-bar-fill {
  height: 100%;
  background: var(--text);
  border-radius: 2px;
  transition: width 600ms cubic-bezier(0.22, 1, 0.36, 1);
}
.li-total.is-active .li-total-bar-fill { background: var(--bg); }

.li-stage-filter {
  display: flex; align-items: center; gap: 10px;
  font-size: 12px;
  color: var(--text-muted);
  padding: 8px 4px 0;
}
.li-stage-filter strong { color: var(--text); font-weight: 500; }
.li-stage-toggle {
  display: inline-flex;
  background: var(--bg-elevated);
  border: 1px solid var(--hairline);
  border-radius: 6px;
  padding: 2px;
  gap: 1px;
}
.li-stage-toggle button {
  padding: 3px 9px;
  font-size: 11.5px;
  color: var(--text-muted);
  border-radius: 4px;
}
.li-stage-toggle button.is-on { background: var(--text); color: var(--bg); }
.li-stage-clear { font-size: 11.5px; color: var(--text-muted); padding: 3px 8px; border-radius: 4px; }
.li-stage-clear:hover { background: var(--hairline); color: var(--text); }

/* ── STICKY HEAD (filters + column headers) ─────────────── */
/* One sticky band holds both the filter controls and the column-header row.
   Because they live in normal flow inside this pinned wrapper, the header
   always sits directly under the filters — there is no second offset to keep
   in sync with the bars' real heights (the old --li-filters-h magic number). */
.li-stickyhead {
  position: sticky;
  top: var(--li-top-h);
  z-index: 30;
  background: var(--bg);
  display: flex;
  flex-direction: column;
  gap: 22px;               /* preserve the spacing the flex gap used to give */
  padding-top: 22px;       /* mirror .fc-page padding-top so there's no gap above */
  margin-top: -22px;       /* cancel .fc-page's own top padding (sticky element provides it) */
}

/* ── FILTERS ────────────────────────────────────────────── */
.li-filters {
  padding-bottom: 12px;
}
.li-filter-group { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; }
.li-segment {
  display: inline-flex;
  gap: 0;
  padding: 2px;
  background: var(--bg-elevated);
  border: 1px solid var(--hairline);
  border-radius: 7px;
}
.li-seg {
  padding: 6px 14px;
  font-size: 12.5px;
  font-weight: 500;
  color: var(--text-muted);
  border-radius: 5px;
  transition: background 100ms, color 100ms;
}
.li-seg:hover { color: var(--text); }
.li-seg.is-on { background: var(--text); color: var(--bg); }
.li-select {
  appearance: none;
  padding: 6px 30px 6px 14px;
  border: 1px solid var(--hairline);
  border-radius: 7px;
  background: var(--bg-elevated);
  color: var(--text);
  font-size: 12.5px;
  font-weight: 500;
  line-height: 18px;
  cursor: pointer;
  transition: border-color 120ms, background 120ms;
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='10' height='10' viewBox='0 0 24 24' fill='none' stroke='%23999' stroke-width='2'><path d='M6 9l6 6 6-6'/></svg>");
  background-repeat: no-repeat;
  background-position: right 10px center;
}
.li-select:hover {
  border-color: var(--hairline-strong);
  background: var(--surface);
}
.li-select:focus {
  outline: none;
  border-color: var(--text-muted);
}
.li-count {
  font-size: 12px;
  color: var(--text-muted);
  margin-left: auto;
}
.li-clear {
  font-size: 12px;
  color: var(--text-muted);
  padding: 5px 10px;
  border-radius: 6px;
}
.li-clear:hover { background: var(--hairline); color: var(--text); }
.li-newhold {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  font-size: 12px;
  font-weight: 500;
  color: var(--text-muted);
  padding: 6px 11px;
  border-radius: 7px;
  border: 1px solid var(--hairline);
  background: var(--bg-elevated);
  transition: background 120ms, color 120ms, border-color 120ms;
}
.li-newhold:hover { border-color: var(--hairline-strong); color: var(--text); background: var(--surface); }
.li-stangt-toggle {
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.04em;
  padding: 6px 11px;
  border-radius: 7px;
  border: 1px solid var(--hairline);
  background: var(--bg-elevated);
  color: var(--text-faint);
  transition: background 120ms, color 120ms, border-color 120ms;
}
.li-stangt-toggle:hover { border-color: var(--hairline-strong); color: var(--text-muted); }
.li-stangt-toggle.is-on { background: var(--text); color: var(--bg); border-color: var(--text); }

/* ── GROUPS ─────────────────────────────────────────────── */
.li-groups { display: flex; flex-direction: column; gap: 36px; }
.li-group { display: flex; flex-direction: column; gap: 0; }
.li-group-head {
  display: flex;
  align-items: baseline;
  gap: 12px;
  padding: 0 0 10px;
  border-bottom: 1px solid var(--hairline);
  margin-bottom: 4px;
}
.li-group-wk {
  font-size: 18px;
  font-weight: 500;
  color: var(--text);
  letter-spacing: -0.015em;
  text-transform: capitalize;
}
.li-group-range {
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--text-muted);
}
.li-group-count {
  margin-left: auto;
  font-size: 11px;
  color: var(--text-muted);
}

/* ── COLUMN HEADERS ──────────────────────────────────── */
.li-header-row {
  background: var(--bg);
  display: grid;
  grid-template-columns: 40px minmax(0, 1.4fr) 28px minmax(0, 2.4fr) 104px 80px 28px;
  gap: 18px;
  align-items: center;
  padding: 10px 0 10px;
  border-bottom: 1px solid var(--hairline-strong);
  font-size: 10.5px;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--text-muted);
}
.li-header-cell {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  cursor: pointer;
  user-select: none;
  transition: color 100ms;
}
.li-header-cell:hover { color: var(--text); }
.li-header-cell-num { justify-content: flex-end; }
/* Sub-grid that mirrors .li-row-pipe so "Pipeline" sits centered above
   the first (Release) tile rather than the whole pipeline column. */
.li-header-cell-pipe {
  display: grid;
  grid-template-columns: 1.4fr repeat(8, minmax(0, 1fr));
  gap: 4px;
  user-select: none;
  align-items: center;
  width: 100%;
}
.li-header-cell-pipe-label {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 4px;
  transition: color 100ms;
}
/* Release column header doubles as the release sort control. */
.li-header-pipe-sort { cursor: pointer; }
.li-header-pipe-sort:hover { color: var(--text); }
/* Per-stage headers above each pipeline tile column. They double as
   "Saknar" filters: click to show only dates missing that stage. Sized to
   match the tile labels (.li-stage-label) so each sits centered over its tile. */
.li-pipe-head-btn {
  justify-self: stretch;
  text-align: center;
  font-size: 9.5px;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--text-faint);
  padding: 4px 2px;
  border-radius: 6px;
  transition: background 120ms, color 120ms;
}
.li-pipe-head-btn:hover { background: var(--hairline); color: var(--text); }
.li-pipe-head-btn.is-on { background: var(--text); color: var(--bg); }

.li-rows { display: flex; flex-direction: column; }

/* Empty-date placeholder row (full-calendar view) — thin + faint, click to add a hold. */
.li-row-empty {
  padding: 5px 0;
  opacity: 0.45;
  transition: opacity 120ms, background 120ms;
}
.li-row-empty:hover { opacity: 1; background: var(--bg-sunken); }
.li-row-empty .li-row-date { opacity: 0.8; }
.li-row-empty-label {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  font-size: 11px;
  color: var(--text-faint);
}
.li-row-empty:hover .li-row-empty-label { color: var(--text-muted); }

/* ── ROW ────────────────────────────────────────────────── */
.li-row {
  display: grid;
  grid-template-columns: 40px minmax(0, 1.4fr) 28px minmax(0, 2.4fr) 104px 80px 28px;
  gap: 18px;
  align-items: center;
  padding: 16px 0;
  border-bottom: 1px solid var(--hairline);
  position: relative;
}
.li-row.is-hold .li-row-artist { color: var(--text-muted); font-style: italic; }
/* Closed-date row — matches Kalender's faint "STÄNGT" marker; no pipeline. */
.li-row-stangt .li-row-head { display: flex; align-items: baseline; gap: 8px; }
.li-row-stangt-tag {
  font-size: 11px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: var(--text-faint);
}
.li-row-stangt-note { font-size: 13px; color: var(--text-muted); font-style: italic; }
.li-row.is-row-clickable { cursor: pointer; }
.li-row.is-row-clickable:hover { background: color-mix(in oklch, var(--text) 3%, transparent); }
/* Stage tiles inside the pipe own their own click target; reset cursor for
   non-clickable stages so the row's pointer affordance doesn't leak in. */
.li-row.is-row-clickable .li-stage:not(.is-clickable) { cursor: default; }
.li-row-date {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 2px;
  min-width: 40px;
}
.li-row-day {
  font-size: 24px;
  font-weight: 500;
  letter-spacing: -0.02em;
  color: var(--text);
  line-height: 1;
  text-align: center;
}
.li-row-month {
  font-size: 10.5px;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--text-muted);
  text-align: center;
}
.li-row-year {
  font-size: 10px;
  font-weight: 400;
  letter-spacing: 0.04em;
  color: var(--text-muted);
  opacity: 0.7;
  text-align: center;
  line-height: 1;
}
.li-row-mo {
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--text-muted);
}

.li-row-main { display: flex; flex-direction: column; gap: 4px; min-width: 0; }
.li-row-head { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.li-row-artist {
  font-size: 15px;
  font-weight: 500;
  letter-spacing: -0.01em;
  color: var(--text);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.li-row-chip {
  display: inline-flex;
  padding: 2px 7px;
  border-radius: 4px;
  font-size: 10px;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  background: var(--hairline);
  color: var(--text);
}
.li-row-chip-quiet { background: transparent; border: 1px solid var(--hairline); color: var(--text-muted); }
.li-row-chip-hold { background: oklch(0.62 0.14 50 / 0.14); color: oklch(0.5 0.14 50); }
.dark .li-row-chip-hold { color: oklch(0.78 0.15 60); }
.li-row-chip-d { color: var(--text-faint); font-weight: 400; text-transform: lowercase; letter-spacing: 0; }
.li-row-meta {
  display: flex;
  gap: 6px;
  font-size: 11.5px;
  color: var(--text-muted);
}
.li-row-sep { color: var(--text-faint); }

.li-row-pipe {
  display: grid;
  grid-template-columns: 1.4fr repeat(8, minmax(0, 1fr));
  gap: 4px;
}
.li-stage-release { align-items: center; padding: 8px 6px; gap: 5px; }
.li-stage-release .li-stage-sub { display: flex; align-items: center; height: 9px; }
.li-stage-release .li-stage-label { font-size: 9.5px; color: var(--text-faint); }
.li-stage-release.is-done .li-stage-label { color: var(--text); }
.li-stage-sub {
  font-size: 11px;
  color: var(--text);
  font-weight: 500;
  letter-spacing: -0.005em;
  text-transform: none;
  line-height: 1;
}
.li-stage-release.is-empty .li-stage-sub { color: var(--text-muted); font-weight: 400; }
.li-stage {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 5px;
  padding: 8px 4px;
  border-radius: 7px;
  position: relative;
  transition: background 120ms var(--ease), color 120ms var(--ease);
  cursor: default;
}
.li-stage:hover {
  background: var(--hairline);
}
.li-stage:hover .li-stage-label {
  color: var(--text);
}
.li-stage-dot-wrap { display: inline-flex; }
.li-stage-dots { display: inline-flex; gap: 3px; }
.li-stage-dot {
  width: 9px;
  height: 9px;
  border-radius: 50%;
  border: 1.5px solid var(--hairline-strong);
  background: transparent;
  display: inline-block;
}
.li-stage.is-done .li-stage-dot {
  background: var(--text);
  border-color: var(--text);
}
/* Partial: some required artworks submitted but not all — black border, no fill */
.li-stage.is-partial .li-stage-dot {
  background: transparent;
  border-color: var(--text);
  border-width: 2.25px;
}
.li-stage.is-partial .li-stage-label,
.li-stage-label.is-partial { color: var(--text); }
.li-stage-release.is-approved {
  background: color-mix(in oklch, var(--h-strong) 10%, transparent);
  position: relative;
}
.li-stage-release.is-approved .li-stage-sub,
.li-stage-release.is-approved .li-stage-label,
/* Higher-specificity overrides for the case where a tile is BOTH
   `.is-done` (past release) AND `.is-approved`. Without these, the
   later-defined `.li-stage.is-done .li-stage-label` rule wins and we
   lose the green text on already-released shows. */
.li-stage-release.is-approved.is-done .li-stage-label,
.li-stage-release.is-approved.is-done .li-stage-sub {
  color: var(--h-strong);
}
.li-stage-release.is-approved:hover {
  background: color-mix(in oklch, var(--h-strong) 16%, transparent);
}
/* Scheduled but not-yet-approved: same shape/feel as .is-approved, neutral
   grey colour. Communicates "release is in the pipeline" without the
   "ready to go live" affordance of the green state. */
.li-stage-release.is-scheduled {
  background: color-mix(in oklch, var(--text) 6%, transparent);
  position: relative;
}
.li-stage-release.is-scheduled .li-stage-sub,
.li-stage-release.is-scheduled .li-stage-label {
  color: var(--text);
}
.li-stage-release.is-scheduled:hover {
  background: color-mix(in oklch, var(--text) 10%, transparent);
}
/* Per-platform publish badges on the Release tile. Each appears only once the
   platform is live (see Lista.tsx `pub`), pinned to its own corner so the
   operator can read publish state at a glance without opening the popover:
   Nortic top-left · FB-event top-right · WordPress + Bandsintown mid-edges. */
.li-rel-badge {
  position: absolute;
  width: 12px;
  height: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 8px;
  font-weight: 700;
  line-height: 1;
  letter-spacing: 0;
  border-radius: 999px;
  background: var(--text);
  color: var(--bg);
  z-index: 2;
}
/* One badge per corner of the release tile. */
.li-rel-badge.is-nortic { top: 3px; left: 3px; }       /* top-left */
.li-rel-badge.is-fb { top: 3px; right: 3px; }          /* top-right */
.li-rel-badge.is-wp { bottom: 3px; left: 3px; }        /* bottom-left */
.li-rel-badge.is-bit { bottom: 3px; right: 3px; }      /* bottom-right */
.li-stage-dots .li-stage-dot.is-done {
  background: var(--text);
  border-color: var(--text);
}
.li-stage-label {
  font-size: 9.5px;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--text-faint);
}
.li-stage.is-done .li-stage-label { color: var(--text); }
.li-stage-label.is-done { color: var(--text); }
.li-stage-num {
  position: absolute;
  top: -3px;
  right: 2px;
  font-size: 9px;
  font-weight: 600;
  color: var(--text);
  background: var(--bg);
  border-radius: 999px;
  padding: 0 3px;
  line-height: 1.4;
}

.li-row-tickets {
  text-align: right;
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 1px;
}
.li-row-sold {
  font-size: 18px;
  font-weight: 500;
  letter-spacing: -0.015em;
  color: var(--text);
}
.li-row-sold-k {
  font-size: 10px;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--text-muted);
}
.li-row-sold-empty { color: var(--text-faint); font-size: 14px; }

.li-row-prog {
  text-align: right;
  font-size: 11px;
  color: var(--text-muted);
}
.li-row-prog-num {
  font-size: 14px;
  font-weight: 500;
  color: var(--text);
  letter-spacing: -0.01em;
}
.li-row-prog-of { color: var(--text-muted); font-weight: 400; font-size: 11px; }

/* ── Prognos column · sparkline cell + tabbed ML popover ──────────────────
   Design ported from Fasching App (10).zip → lista-kallkod (li-fc* / li-mlp*).
   Data is the real observe-only shadow forecast — see ForecastRangeCell /
   ForecastPopover in Lista.tsx. Fasching tokens only; no new colors. */
.li-fc {
  display: flex; flex-direction: column; justify-content: center; gap: 4px;
  min-width: 0;
  position: relative;
  --fc: var(--text);
}
.li-fc.is-clickable { cursor: pointer; }
.li-fc.is-clickable:hover .li-fc-n { text-decoration: underline; text-underline-offset: 2px; text-decoration-thickness: 1px; }
.li-fc.tone-strong  { --fc: var(--h-strong); }
.li-fc.tone-healthy { --fc: var(--text); }
.li-fc.tone-watch   { --fc: var(--h-low); }
.li-fc.tone-risk    { --fc: var(--h-critical); }
.li-fc-top { display: flex; align-items: baseline; gap: 6px; }
.li-fc-n {
  font-size: 16px; font-weight: 500; letter-spacing: -0.015em;
  color: var(--text);
  font-variant-numeric: tabular-nums; line-height: 1;
}
.li-fc-d { font-size: 9.5px; font-weight: 600; color: var(--fc); white-space: nowrap; }
.li-fc.tone-healthy .li-fc-d { color: var(--text-muted); }
.li-fc-spark { width: 100%; height: 26px; display: block; overflow: visible; }
.li-fc-target { stroke: var(--hairline-strong); stroke-width: 1; stroke-dasharray: 2 2.5; }
.li-fc-g0 { stop-color: var(--fc); stop-opacity: 0.16; }
.li-fc-g1 { stop-color: var(--fc); stop-opacity: 0; }
.li-fc-area { stroke: none; }
.li-fc-line { fill: none; stroke: var(--text); stroke-width: 1.5; stroke-linecap: round; stroke-linejoin: round; }
.li-fc-proj { fill: none; stroke: var(--fc); stroke-width: 1.5; stroke-linecap: round; stroke-linejoin: round; stroke-dasharray: 3 2.5; }
.li-fc-end { fill: var(--fc); }
.li-fc.is-empty { align-items: center; justify-content: center; }
.li-fc-dash { color: var(--text-faint); font-size: 14px; }

/* ── ML forecast popover (anchored to the cell, right-aligned) ── */
.li-pop.li-pop-ml {
  left: auto; right: 0; transform: none;
  width: 404px; max-height: 540px;
  animation: li-pop-ml-in 200ms cubic-bezier(0.22, 1, 0.36, 1);
  --fc: var(--text);
}
.li-pop-ml.tone-strong  { --fc: var(--h-strong); }
.li-pop-ml.tone-watch   { --fc: var(--h-low); }
.li-pop-ml.tone-risk    { --fc: var(--h-critical); }
@keyframes li-pop-ml-in { from { opacity: 0; transform: translateY(-4px); } to { opacity: 1; transform: translateY(0); } }

.li-mlp-stats { padding: 18px 20px 6px; display: flex; gap: 18px; align-items: flex-start; }
.li-mlp-hero { display: flex; flex-direction: column; gap: 2px; flex-shrink: 0; }
.li-mlp-hero-n { font-weight: 600; letter-spacing: -0.015em; font-size: 30px; line-height: 0.9; color: var(--fc); font-variant-numeric: tabular-nums; }
.li-mlp-hero-l { font-size: 9px; text-transform: uppercase; letter-spacing: 0.06em; color: var(--text-faint); }
.li-mlp-statgrid { display: flex; flex-direction: column; gap: 7px; flex: 1; padding-top: 3px; }
.li-mlp-stat { display: flex; justify-content: space-between; align-items: baseline; gap: 10px; }
.li-mlp-k { font-size: 10.5px; color: var(--text-muted); }
.li-mlp-v { font-size: 12px; font-weight: 600; color: var(--text); font-variant-numeric: tabular-nums; }

.li-mlp-chart { padding: 10px 20px 6px; }
.li-mlp-svg { display: block; width: 100%; height: 138px; overflow: visible; }
.li-mlp-cap { stroke: var(--hairline-strong); stroke-width: 1; stroke-dasharray: 2 3; }
.li-mlp-today { stroke: var(--hairline-strong); stroke-width: 1; }
.li-mlp-axislbl { fill: var(--text-faint); font-size: 8px; text-transform: uppercase; letter-spacing: 0.04em; }
.li-mlp-g0 { stop-color: var(--fc); stop-opacity: 0.22; }
.li-mlp-g1 { stop-color: var(--fc); stop-opacity: 0.04; }
.li-mlp-bandfill { stroke: none; }
.li-mlp-obs { fill: none; stroke: var(--text); stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.li-mlp-med { fill: none; stroke: var(--fc); stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; stroke-dasharray: 3 2.5; }
.li-mlp-end { fill: var(--fc); }
.li-mlp-legend { display: flex; gap: 13px; margin-top: 4px; }
.li-mlp-lg { display: inline-flex; align-items: center; gap: 5px; font-size: 9.5px; color: var(--text-muted); }
.li-mlp-lg .sw { width: 12px; height: 3px; border-radius: 2px; }
.li-mlp-lg .sw.obs { background: var(--text); }
.li-mlp-lg .sw.med { background: var(--fc); }
.li-mlp-lg .sw.band { background: var(--fc); opacity: 0.3; height: 9px; border-radius: 2px; }

.li-mlp-drivers { padding: 4px 20px 16px; display: flex; flex-direction: column; gap: 9px; }
.li-mlp-driver { display: grid; grid-template-columns: 132px 1fr auto; align-items: center; gap: 10px; }
.li-mlp-dk { font-size: 10.5px; color: var(--text-muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.li-mlp-dbar { height: 4px; border-radius: 999px; background: var(--hairline); overflow: hidden; }
.li-mlp-dbf { height: 100%; border-radius: 999px; background: var(--text); transform-origin: left center; animation: mlp-grow-x 520ms cubic-bezier(0.22, 1, 0.36, 1) both; }
.li-mlp-dbf.pos { background: var(--h-strong); }
.li-mlp-dbf.neg { background: var(--h-critical); }
.li-mlp-dv { font-size: 10.5px; font-weight: 600; color: var(--text); font-variant-numeric: tabular-nums; min-width: 34px; text-align: right; }
.li-mlp-dv.pos { color: var(--h-strong); }
.li-mlp-dv.neg { color: var(--h-critical); }

/* ── tabbed ML popover ──────────────────────────────────────── */
.li-mlp-tabs { display: flex; gap: 3px; padding: 8px 12px 0; position: relative; }
.li-mlp-tab-ind {
  position: absolute; border-radius: 8px; background: var(--text); z-index: 0;
  transition: left 340ms cubic-bezier(0.5, 0.05, 0.1, 1), width 340ms cubic-bezier(0.5, 0.05, 0.1, 1);
}
.li-mlp-tabs button {
  position: relative; z-index: 1;
  flex: 1; font-size: 11.5px; font-weight: 600; color: var(--text-muted);
  padding: 7px 8px; border-radius: 8px; border: 0; background: transparent; cursor: pointer;
  transition: color 240ms var(--ease);
}
.li-mlp-tabs button:hover { color: var(--text); }
.li-mlp-tabs button.is-on { color: var(--bg); }
.li-mlp-tabbody { display: flex; flex-direction: column; animation: mlp-fade-up 320ms cubic-bezier(0.22, 1, 0.36, 1) both; }
@keyframes mlp-fade-up { from { opacity: 0; transform: translateY(7px); } to { opacity: 1; transform: translateY(0); } }

/* action tab */
.li-mlp-verdict { padding: 14px 18px 10px; display: flex; align-items: flex-start; gap: 11px; }
.li-mlp-badge { font-size: 11px; font-weight: 700; letter-spacing: 0.02em; padding: 5px 11px; border-radius: 999px; white-space: nowrap; flex-shrink: 0; }
.li-mlp-badge.good { background: var(--h-strong-bg); color: var(--h-strong); }
.li-mlp-badge.watch { background: var(--h-low-bg); color: var(--h-low); }
.li-mlp-badge.risk { background: var(--h-critical-bg); color: var(--h-critical); }
.li-mlp-verdict-tx { font-size: 11.5px; color: var(--text); line-height: 1.45; }
.li-mlp-verdict-tx b { font-weight: 600; }
.li-mlp-levers { padding: 2px 20px 16px; display: flex; flex-direction: column; gap: 8px; }
.li-mlp-levers-h { font-size: 9.5px; font-weight: 700; text-transform: uppercase; letter-spacing: 0.08em; color: var(--text-faint); margin-bottom: 2px; }

/* forecast tab honest note strip (replaces the zip's fabricated "±6%" claim) */
.li-mlp-acc { margin: 4px 18px 14px; padding: 9px 12px; background: var(--bg-elevated); border: 1px solid var(--hairline); border-radius: 9px; font-size: 10.5px; color: var(--text-muted); line-height: 1.45; }

/* drivers tab */
.li-mlp-drivers-top { padding: 14px 18px 8px; display: flex; align-items: baseline; justify-content: space-between; }
.li-mlp-dtop-n { font-weight: 600; letter-spacing: -0.02em; font-size: 30px; color: var(--fc); font-variant-numeric: tabular-nums; }
.li-mlp-dtop-l { font-size: 10px; text-transform: uppercase; letter-spacing: 0.06em; color: var(--text-faint); }
.li-mlp-conf { font-size: 10px; color: var(--text-muted); }
.li-mlp-conf b { color: var(--text); font-weight: 600; }

@keyframes mlp-grow-x { from { transform: scaleX(0); } to { transform: scaleX(1); } }
.li-mlp-revealrect { transform: scaleX(0); transform-origin: left center; animation: mlp-grow-x 760ms cubic-bezier(0.33, 0, 0.1, 1) 120ms both; }
.li-mlp-end { animation: mlp-end-in 360ms cubic-bezier(0.22, 1, 0.36, 1) 740ms both; transform-box: fill-box; transform-origin: center; }
@keyframes mlp-end-in { from { opacity: 0; transform: scale(0); } 70% { transform: scale(1.5); } to { opacity: 1; transform: scale(1); } }
@media (prefers-reduced-motion: reduce) {
  .li-mlp-revealrect, .li-mlp-dbf { transform: scaleX(1) !important; animation: none !important; }
  .li-mlp-end, .li-mlp-tabbody { animation: none !important; }
  .li-mlp-tab-ind { transition: none !important; }
}

.li-stage.is-clickable { cursor: pointer; }
.li-stage.is-popping { background: var(--hairline); }

.li-pop {
  position: absolute;
  top: calc(100% + 6px);
  left: 50%;
  transform: translateX(-50%);
  width: 380px;
  max-height: 440px;
  background: var(--surface);
  border-radius: 12px;
  box-shadow: 0 1px 2px oklch(0 0 0 / 0.05), 0 12px 36px oklch(0 0 0 / 0.16);
  z-index: 50;
  display: flex;
  flex-direction: column;
  cursor: default;
  overflow: hidden;
  animation: li-pop-in 200ms cubic-bezier(0.22, 1, 0.36, 1);
}
.li-pop-wide { width: 460px; }
@keyframes li-pop-in { from { opacity: 0; transform: translateX(-50%) translateY(-4px); } to { opacity: 1; transform: translateX(-50%) translateY(0); } }
.li-pop-head {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  padding: 14px 16px 12px;
  border-bottom: 1px solid var(--hairline);
}
.li-pop-eyebrow {
  font-size: 10px;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--text-muted);
}
.li-pop-title {
  font-size: 13.5px;
  font-weight: 500;
  letter-spacing: -0.005em;
  color: var(--text);
  margin-top: 2px;
}
.li-pop-summary {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1px;
  background: var(--hairline);
  border-bottom: 1px solid var(--hairline);
}
.li-pop-stat {
  background: var(--bg-elevated);
  padding: 10px 12px;
}
.li-pop-stat-k {
  font-size: 9.5px;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--text-muted);
}
.li-pop-stat-v {
  font-size: 14px;
  font-weight: 500;
  letter-spacing: -0.01em;
  color: var(--text);
  margin-top: 2px;
}
.li-pop-list {
  flex: 1;
  overflow-y: auto;
  padding: 4px;
}
.li-pop-body {
  flex: 1;
  overflow-y: auto;
  padding: 14px 16px 16px;
  display: flex;
  flex-direction: column;
  gap: 16px;
}
.li-pop-head-actions { display: flex; align-items: center; gap: 6px; }
/* Simple key/value rows used by the FB-event popover. */
.li-pop-row {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 12px;
  padding: 8px 0;
  border-bottom: 1px solid var(--hairline);
  font-size: 12.5px;
}
.li-pop-row:last-of-type { border-bottom: 0; }
.li-pop-k {
  font-size: 10.5px;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--text-muted);
}
.li-pop-v { color: var(--text); }
.li-pop-link {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  font-size: 12px;
  color: var(--text);
  text-decoration: none;
  border-bottom: 1px solid var(--hairline-strong);
  padding-bottom: 2px;
}
.li-pop-link:hover { color: var(--text); border-color: var(--text); }
.li-pop-lang {
  display: inline-flex;
  border: 1px solid var(--hairline);
  border-radius: 5px;
  padding: 1px;
}
.li-pop-lang button {
  padding: 2px 8px;
  font-size: 10.5px;
  font-weight: 500;
  color: var(--text-muted);
  border-radius: 4px;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  letter-spacing: 0.04em;
  background: transparent;
  border: 0;
  cursor: pointer;
}
.li-pop-lang button.is-on { background: var(--text); color: var(--bg); }

.li-pop-foot {
  display: flex;
  justify-content: flex-end;
  align-items: center;
  padding: 10px 14px;
  border-top: 1px solid var(--hairline);
  gap: 10px;
  flex-shrink: 0;
}
.li-pop-foot-meta { font-size: 11px; color: var(--text-muted); }
.li-pop-foot-meta strong { color: var(--text); font-weight: 500; }
.li-pop-cta {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 6px 12px;
  background: var(--text);
  color: var(--bg);
  border-radius: 6px;
  font-size: 11.5px;
  font-weight: 500;
  border: 0;
  cursor: pointer;
}
.li-pop-release {
  width: 420px;
  max-height: min(760px, calc(100vh - 60px));
}

/* ─── Chat / comments per row ─────────────────────────────────────── */
.li-row-chat {
  display: flex;
  justify-content: center;
  align-items: center;
  position: relative;
}
.li-chat-btn {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 26px;
  height: 26px;
  border-radius: 6px;
  border: 0;
  background: transparent;
  color: var(--text-faint);
  cursor: pointer;
  transition: background 120ms, color 120ms;
}
.li-chat-btn:hover { background: var(--hairline); color: var(--text); }
.li-chat-btn.is-popping { background: var(--hairline); color: var(--text); }
.li-chat-btn.has-msgs { color: var(--text); }

/* ── Change-log (history) button + popover ───────────────────────────── */
.li-row-history {
  display: flex;
  justify-content: center;
  align-items: center;
  position: relative;
}
.li-hist-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 26px;
  height: 26px;
  border-radius: 6px;
  border: 0;
  background: transparent;
  color: var(--text-faint);
  cursor: pointer;
  transition: background 120ms, color 120ms;
}
.li-hist-btn:hover { background: var(--hairline); color: var(--text); }
.li-hold-del:hover { background: var(--h-critical-bg); color: var(--h-critical); }
.li-hist-btn.is-popping { background: var(--hairline); color: var(--text); }
/* Anchor under the icon, aligned to the right edge so the wide panel stays
   on-screen (the history icon is the last column in the row). */
.li-hist-pop {
  position: absolute;
  top: calc(100% + 6px);
  right: 0;
  width: 420px;
  max-width: calc(100vw - 32px);
  max-height: 460px;
  background: var(--surface);
  border-radius: 12px;
  box-shadow: 0 1px 2px oklch(0 0 0 / 0.05), 0 12px 36px oklch(0 0 0 / 0.16);
  z-index: 50;
  display: flex;
  flex-direction: column;
  cursor: default;
  overflow: hidden;
  animation: li-pop-in 200ms cubic-bezier(0.22, 1, 0.36, 1);
}
.li-hist-list {
  flex: 1;
  overflow-y: auto;
  padding: 10px 14px;
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.li-hist-empty {
  font-size: 12px;
  color: var(--text-muted);
  padding: 18px 4px;
  text-align: center;
}
.li-hist-item {
  display: flex;
  flex-direction: column;
  gap: 4px;
  padding-bottom: 10px;
  border-bottom: 1px solid var(--hairline);
}
.li-hist-item:last-child { border-bottom: 0; padding-bottom: 0; }
.li-hist-item-top {
  display: flex;
  align-items: baseline;
  gap: 8px;
  flex-wrap: wrap;
}
.li-hist-tag {
  font-size: 9px;
  font-weight: 600;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  padding: 1px 6px;
  border-radius: 999px;
  color: var(--text);
  background: var(--hairline);
}
.li-hist-tag-publish { background: oklch(0.72 0.14 145 / 0.18); }
.li-hist-tag-status { background: oklch(0.72 0.13 250 / 0.18); }
.li-hist-field { font-size: 12px; font-weight: 600; color: var(--text); }
.li-hist-meta { font-size: 11px; color: var(--text-muted); margin-left: auto; white-space: nowrap; }
.li-hist-change {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 12px;
  color: var(--text-muted);
  min-width: 0;
}
.li-hist-old, .li-hist-new {
  max-width: 46%;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.li-hist-old { text-decoration: line-through; opacity: 0.7; }
.li-hist-new { color: var(--text); font-weight: 500; }
/* Global change-log button on the filter bar: pushed to the right edge, with the
   popover anchored beneath it (right-aligned so the panel stays on-screen). */
.li-globallog {
  position: relative;
  margin-left: auto;
  display: flex;
  align-items: center;
}
.li-hist-show {
  font-size: 11px;
  font-weight: 600;
  color: var(--text-muted);
}
/* Match .li-stage-num (nyhetsbrev / meta ads count) — tiny pill at top-right,
   bg-coloured background, dark text. */
.li-chat-badge {
  position: absolute;
  top: -3px;
  right: 2px;
  font-size: 9px;
  font-weight: 600;
  color: var(--text);
  background: var(--bg);
  border-radius: 999px;
  padding: 0 3px;
  line-height: 1.4;
  letter-spacing: 0;
}
/* Anchor the chat popover under the icon. The icon sits in the middle of the
   row (column before release) so center it horizontally. */
.li-chat-pop {
  position: absolute;
  top: calc(100% + 6px);
  left: 50%;
  transform: translateX(-50%);
  width: 380px;
  max-height: 460px;
  background: var(--surface);
  border-radius: 12px;
  box-shadow: 0 1px 2px oklch(0 0 0 / 0.05), 0 12px 36px oklch(0 0 0 / 0.16);
  z-index: 50;
  display: flex;
  flex-direction: column;
  cursor: default;
  overflow: hidden;
  animation: li-pop-in 200ms cubic-bezier(0.22, 1, 0.36, 1);
}
.li-chat-list {
  flex: 1;
  overflow-y: auto;
  padding: 12px 14px;
  display: flex;
  flex-direction: column;
  gap: 12px;
}
.li-chat-empty {
  font-size: 12px;
  color: var(--text-muted);
  padding: 18px 4px;
  text-align: center;
}
.li-chat-msg { display: flex; flex-direction: column; gap: 3px; }
.li-chat-msg-head {
  display: flex;
  align-items: baseline;
  gap: 8px;
  font-size: 11px;
  color: var(--text-muted);
}
.li-chat-msg-who { color: var(--text); font-weight: 500; font-size: 11.5px; }
.li-chat-msg-text {
  font-size: 12.5px;
  line-height: 1.45;
  color: var(--text);
  white-space: pre-wrap;
  word-wrap: break-word;
}
.li-chat-form {
  display: flex;
  gap: 8px;
  align-items: flex-end;
  padding: 10px 12px;
  border-top: 1px solid var(--hairline);
  flex-shrink: 0;
}
.li-chat-input {
  flex: 1;
  min-height: 32px;
  max-height: 110px;
  padding: 7px 10px;
  border-radius: 6px;
  border: 1px solid var(--hairline);
  background: var(--bg-elevated);
  color: var(--text);
  font-size: 12.5px;
  font-family: inherit;
  resize: none;
  line-height: 1.4;
}
.li-chat-input:focus { outline: none; border-color: var(--hairline-strong); }
.li-chat-send {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 32px;
  height: 32px;
  border-radius: 6px;
  border: 0;
  background: var(--text);
  color: var(--bg);
  cursor: pointer;
  flex-shrink: 0;
}
.li-chat-send:disabled { opacity: 0.4; cursor: not-allowed; }

.li-rel-body {
  padding: 14px 16px 12px;
  display: flex;
  flex-direction: column;
  gap: 14px;
  flex: 1;
  min-height: 0;
  overflow-y: auto;
}
.li-rel-status {
  padding: 12px 14px;
  border-radius: 7px;
  background: var(--bg-elevated);
  border: 1px solid var(--hairline);
  display: flex;
  flex-direction: column;
  gap: 2px;
}
.li-rel-status-empty   { background: var(--bg-elevated); }
.li-rel-status-planned { background: var(--bg-elevated); border-color: var(--hairline-strong); }
.li-rel-status-done    { background: color-mix(in oklch, var(--h-strong) 10%, transparent); border-color: color-mix(in oklch, var(--h-strong) 30%, transparent); }
.li-rel-status-late    { background: color-mix(in oklch, var(--h-low) 10%, transparent); border-color: color-mix(in oklch, var(--h-low) 30%, transparent); }
.li-rel-status-hold    { background: color-mix(in oklch, oklch(0.62 0.14 50) 10%, transparent); }
.li-rel-status-k {
  font-size: 10px;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--text-muted);
}
.li-rel-status-v {
  font-size: 16px;
  font-weight: 500;
  letter-spacing: -0.015em;
  color: var(--text);
  margin-top: 2px;
}
.li-rel-status-done .li-rel-status-v { color: var(--h-strong); }
.li-rel-status-late .li-rel-status-v { color: var(--h-low); }
.li-rel-status-sub {
  font-size: 11.5px;
  color: var(--text-muted);
  margin-top: 2px;
}

.li-rel-field { display: flex; flex-direction: column; gap: 4px; }
.li-rel-field-k {
  font-size: 10px;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--text-muted);
}
.li-rel-field-v { font-size: 13px; color: var(--text); font-weight: 500; }
.li-rel-field-hint { font-size: 11px; color: var(--text-muted); }
.li-rel-input {
  width: 100%;
  padding: 8px 12px;
  border: 1px solid var(--hairline);
  border-radius: 7px;
  background: var(--surface);
  color: var(--text);
  font-size: 13px;
  font-family: inherit;
  transition: border-color 120ms;
}
.li-rel-input:hover { border-color: var(--hairline-strong); }
.li-rel-input:focus { outline: none; border-color: var(--text-muted); }

/* Contact (agent / management) rows in the Release Container */
.li-rel-contact { display: flex; flex-direction: column; gap: 6px; }
.li-rel-contact-row { display: flex; align-items: center; gap: 8px; }
.li-rel-contact-tag {
  flex: 0 0 42px;
  font-size: 10px;
  font-weight: 600;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--text-muted);
}
.li-rel-contact-input { flex: 1 1 auto; }
.li-rel-contact-mail {
  flex: 0 0 auto;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 30px;
  height: 30px;
  border: 1px solid var(--hairline);
  border-radius: 7px;
  color: var(--text-muted);
  background: var(--surface);
  transition: color 120ms, border-color 120ms;
}
.li-rel-contact-mail:hover { color: var(--text); border-color: var(--hairline-strong); }

.li-rel-checks {
  display: flex;
  flex-direction: column;
  gap: 8px;
  padding: 12px 14px;
  border: 1px solid var(--hairline);
  border-radius: 7px;
  background: var(--bg-elevated);
}
.li-rel-check {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 12.5px;
  color: var(--text-muted);
}
.li-rel-check-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  border: 1.5px solid var(--hairline-strong);
  background: transparent;
}
.li-rel-check.is-on { color: var(--text); }
.li-rel-check.is-on .li-rel-check-dot { background: var(--text); border-color: var(--text); }
.li-rel-check.is-green { color: var(--h-strong); }
.li-rel-check.is-green .li-rel-check-dot { background: var(--h-strong); border-color: var(--h-strong); }

.li-rel-warn {
  padding: 10px 12px;
  border-radius: 7px;
  background: color-mix(in oklch, var(--h-low) 10%, transparent);
  color: var(--h-low);
  font-size: 11.5px;
  line-height: 1.4;
}
.li-rel-tracker {
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin-top: 6px;
  padding-top: 12px;
  border-top: 1px solid var(--hairline);
}

.li-rel-flow {
  margin-top: 14px;
  padding: 10px 12px 12px;
  border: 1px solid var(--hairline);
  border-radius: 8px;
  background: var(--bg-elevated);
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.li-rel-flow.is-complete { border-color: color-mix(in oklch, var(--h-strong) 40%, var(--hairline)); }
.li-rel-flow-head {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
}
.li-rel-flow-k {
  font-size: 10.5px;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--text-muted);
}
.li-rel-flow-summary { font-size: 11px; color: var(--text-faint); }
.li-rel-flow.is-complete .li-rel-flow-summary { color: var(--h-strong); }
.li-rel-flow-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 6px;
}
.li-rel-flow-row {
  display: grid;
  grid-template-columns: 12px 100px 1fr;
  gap: 8px;
  align-items: start;
  font-size: 11.5px;
  line-height: 1.45;
  color: var(--text-muted);
}
.li-rel-flow-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  border: 1.5px solid var(--hairline-strong);
  background: transparent;
  align-self: start;
  /* Center the dot vertically on the first text line so it stays aligned
     with the label even when the "Saknar: …" column wraps to two lines. */
  margin-top: calc((1.45em - 11px) / 2);
}
.li-rel-flow-label { font-weight: 500; color: var(--text); }
.li-rel-flow-missing {
  font-size: 11px;
  color: var(--text-muted);
  line-height: 1.35;
}
.li-rel-flow-missing.is-done-text { color: var(--h-strong); }
.li-rel-flow-row.is-done .li-rel-flow-dot {
  background: var(--text);
  border-color: var(--text);
}
.li-rel-flow-row.is-failed .li-rel-flow-dot {
  background: var(--h-critical);
  border-color: var(--h-critical);
}
.li-rel-flow-row.is-failed .li-rel-flow-missing { color: var(--h-critical); }
/* Per-platform "Publicera" push button + two-step confirm (Release Container). */
.li-rel-flow-push {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  justify-self: start;
  padding: 2px 8px;
  font-size: 11px;
  font-weight: 600;
  color: var(--h-strong);
  background: color-mix(in oklch, var(--h-strong) 10%, transparent);
  border: 1px solid color-mix(in oklch, var(--h-strong) 35%, var(--hairline));
  border-radius: 6px;
  cursor: pointer;
  transition: background 0.12s ease, border-color 0.12s ease;
}
.li-rel-flow-push:hover:not(:disabled) { background: color-mix(in oklch, var(--h-strong) 18%, transparent); }
.li-rel-flow-push:disabled {
  opacity: 0.45;
  cursor: not-allowed;
  color: var(--text-muted);
  background: transparent;
  border-color: var(--hairline);
}
.li-rel-flow-actions {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 3px;
}
.li-rel-flow-doneflag { font-size: 10.5px; }
.li-rel-flow-ennote {
  font-size: 10.5px;
  color: var(--h-warning, #b8860b);
  cursor: help;
  white-space: nowrap;
}
.li-rel-flow-confirm { display: inline-flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.li-rel-flow-confirm-q { font-size: 11px; color: var(--text); }
.li-rel-flow-cancel,
.li-rel-flow-go {
  padding: 2px 8px;
  font-size: 11px;
  font-weight: 600;
  border-radius: 6px;
  cursor: pointer;
  border: 1px solid var(--hairline);
}
.li-rel-flow-cancel { background: var(--bg-elevated, #eee); color: var(--text); }
.li-rel-flow-go { background: var(--h-strong); color: #fff; border-color: var(--h-strong); }
/* Live release state: at the planned release time a ready platform shows a
   pulsing amber "Publicerar…" until the backend confirms it published. */
.li-rel-flow-publishing {
  font-size: 11px;
  font-weight: 600;
  color: oklch(0.62 0.15 65);
  justify-self: start;
  display: inline-flex;
  align-items: center;
  gap: 8px;
}
/* Indeterminate progress bar shown while a platform is publishing — the
   backend reports no percentage, so an animated sweep honestly conveys
   "in progress" until polling flips the row to Publicerad/Misslyckades. */
.li-rel-flow-bar {
  position: relative;
  display: inline-block;
  width: 72px;
  height: 4px;
  border-radius: 2px;
  background: color-mix(in oklch, oklch(0.72 0.16 65) 22%, transparent);
  overflow: hidden;
  flex-shrink: 0;
}
.li-rel-flow-bar i {
  position: absolute;
  top: 0;
  left: 0;
  height: 100%;
  width: 42%;
  border-radius: 2px;
  background: oklch(0.72 0.16 65);
  animation: li-rel-indeterminate 1.15s ease-in-out infinite;
}
@keyframes li-rel-indeterminate {
  0%   { transform: translateX(-110%); }
  100% { transform: translateX(240%); }
}
@media (prefers-reduced-motion: reduce) {
  .li-rel-flow-bar i { animation: none; width: 100%; opacity: 0.55; }
}
.li-rel-flow-row.is-publishing .li-rel-flow-dot {
  background: oklch(0.72 0.16 65);
  border-color: oklch(0.72 0.16 65);
  animation: li-rel-pulse 1.1s ease-in-out infinite;
}
/* Armed/scheduled state: a WP draft or approval-gated FB event the release
   cron will auto-publish at nortic_release_at. Calm blue, not actionable. */
.li-rel-flow-scheduled {
  font-size: 11px;
  font-weight: 600;
  color: oklch(0.56 0.10 250);
  justify-self: start;
  white-space: nowrap;
}
.li-rel-flow-row.is-scheduled .li-rel-flow-dot {
  background: oklch(0.70 0.10 250);
  border-color: oklch(0.70 0.10 250);
}
.li-rel-flow.is-armed .li-rel-flow-summary {
  color: oklch(0.56 0.10 250);
  font-weight: 600;
}
.li-rel-flow.is-releasing { border-color: oklch(0.72 0.16 65 / 0.55); }
.li-rel-flow.is-releasing .li-rel-flow-summary {
  color: oklch(0.62 0.15 65);
  font-weight: 600;
  display: inline-flex;
  align-items: center;
  gap: 5px;
}
.li-rel-flow-live-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: oklch(0.72 0.16 65);
  animation: li-rel-pulse 1.1s ease-in-out infinite;
}
@keyframes li-rel-pulse {
  0%, 100% { opacity: 1; transform: scale(1); }
  50%      { opacity: 0.4; transform: scale(0.82); }
}
@media (prefers-reduced-motion: reduce) {
  .li-rel-flow-row.is-publishing .li-rel-flow-dot,
  .li-rel-flow-live-dot { animation: none; }
}
.li-rel-tracker-head { display: flex; flex-direction: column; gap: 2px; }
.li-rel-tracker-k {
  font-size: 10.5px;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--text-muted);
}
.li-rel-tracker-hint { font-size: 11px; color: var(--text-faint); line-height: 1.35; }
.li-rel-tracker-btn { align-self: flex-start; }

.li-rel-secondary {
  background: transparent;
  border: 0;
  font-size: 12px;
  color: var(--text-muted);
  padding: 6px 10px;
  border-radius: 6px;
  cursor: pointer;
}
.li-rel-secondary:hover { background: var(--hairline); color: var(--text); }

/* ── Release Container: inline "fix what's missing" (BlockerList / BlockerFix) ── */
.li-rel-flow-fix { display: flex; flex-direction: column; gap: 6px; }
.li-rel-flow-fixchips {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 5px;
}
.li-rel-flow-fix-k { font-size: 11px; color: var(--text-muted); }
.li-rel-fixchip {
  font-size: 11px;
  line-height: 1.3;
  padding: 2px 7px;
  border-radius: 5px;
  border: 1px solid var(--hairline);
  background: transparent;
  color: var(--text-muted);
}
.li-rel-fixchip.is-edit,
.li-rel-fixchip.is-link {
  cursor: pointer;
  color: var(--text);
  border-color: var(--hairline-strong);
  transition: background 0.12s ease, border-color 0.12s ease;
}
.li-rel-fixchip.is-edit:hover,
.li-rel-fixchip.is-link:hover {
  background: var(--hairline);
  border-color: var(--h-strong);
}
.li-rel-fixchip.is-open {
  background: color-mix(in oklch, var(--h-strong) 10%, transparent);
  border-color: color-mix(in oklch, var(--h-strong) 35%, var(--hairline));
  color: var(--h-strong);
}
.li-rel-fixchip.is-muted { cursor: default; opacity: 0.7; border-style: dashed; }

.li-rel-fix {
  display: flex;
  flex-direction: column;
  gap: 6px;
  padding: 8px;
  border: 1px solid var(--hairline);
  border-radius: 7px;
  background: var(--bg, #fff);
}
.li-rel-fix-input,
.li-rel-fix-area,
.li-rel-fix-num {
  width: 100%;
  font: inherit;
  font-size: 12px;
  padding: 5px 7px;
  border: 1px solid var(--hairline-strong);
  border-radius: 6px;
  background: var(--bg, #fff);
  color: var(--text);
  box-sizing: border-box;
}
.li-rel-fix-area { resize: vertical; min-height: 56px; }
.li-rel-fix-prices { display: flex; gap: 8px; }
.li-rel-fix-pricelbl {
  display: flex;
  flex-direction: column;
  gap: 3px;
  font-size: 10.5px;
  color: var(--text-muted);
  flex: 1;
}
.li-rel-fix-actions { display: flex; gap: 6px; justify-content: flex-end; }

/* Sales Tracker gate — disabled until Nortic + artwork prerequisites are met. */
.li-rel-tracker-gate { display: flex; flex-direction: column; gap: 4px; align-items: flex-start; }
.li-rel-secondary:disabled,
.li-rel-tracker-btn:disabled { opacity: 0.45; cursor: not-allowed; }
.li-rel-secondary:disabled:hover { background: transparent; color: var(--text-muted); }
.li-rel-tracker-missing { font-size: 10.5px; color: var(--text-faint); line-height: 1.35; }

.li-pop-item-row {
  display: grid;
  grid-template-columns: 28px 1fr 14px;
  gap: 10px;
  align-items: center;
  text-decoration: none;
  color: inherit;
}
.li-pop-item-icon {
  width: 28px; height: 28px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: var(--hairline);
  color: var(--text);
  border-radius: 6px;
  flex-shrink: 0;
}
.li-pop-item-icon-pdf { background: oklch(0.55 0.18 25 / 0.12); color: oklch(0.55 0.18 25); }
.li-pop-item-icon-image { background: oklch(0.55 0.13 230 / 0.12); color: oklch(0.55 0.13 230); }
.li-pop-item-icon-sheet { background: oklch(0.55 0.13 155 / 0.12); color: oklch(0.55 0.13 155); }
.li-pop-item-icon-folder { background: oklch(0.62 0.14 50 / 0.12); color: oklch(0.62 0.14 50); }
.li-pop-item-stack { display: flex; flex-direction: column; gap: 1px; min-width: 0; }
.li-pop-item-sub { font-size: 11px; color: var(--text-muted); }
.li-pop-item-chips { display: inline-flex; gap: 4px; align-items: center; }
.li-pop-chip {
  font-size: 9px;
  font-weight: 600;
  letter-spacing: 0.08em;
  padding: 2px 5px;
  border-radius: 999px;
  background: var(--hairline);
  color: var(--text);
}
.li-pop-weight { color: oklch(0.6 0.18 60); }
.li-pop-note {
  padding: 8px 14px 12px;
  border-top: 1px solid var(--hairline);
  font-size: 10.5px;
  color: var(--text-faint);
}

.li-assets-body { padding: 14px 16px 12px; display: flex; flex-direction: column; gap: 14px; }
.li-assets-slot {
  display: grid;
  grid-template-columns: 18px 1fr;
  gap: 12px;
  align-items: start;
}
.li-assets-slot-num {
  font-size: 11px;
  color: var(--text-muted);
  letter-spacing: 0.06em;
  padding-top: 8px;
}
.li-assets-slot-fields { display: flex; flex-direction: column; gap: 6px; min-width: 0; }
.li-assets-input {
  width: 100%;
  padding: 8px 10px;
  border: 1px solid var(--hairline);
  border-radius: 6px;
  background: var(--surface);
  color: var(--text);
  font-size: 12.5px;
  font-family: inherit;
  letter-spacing: -0.005em;
  transition: border-color 120ms;
}
.li-assets-input:hover { border-color: var(--hairline-strong); }
.li-assets-input:focus { outline: none; border-color: var(--text-muted); }
.li-assets-label { font-weight: 500; }
.li-assets-url-row { position: relative; display: flex; align-items: center; gap: 4px; }
.li-assets-url { padding-right: 56px; }
.li-assets-open,
.li-assets-clear {
  width: 22px;
  height: 22px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 0;
  background: transparent;
  color: var(--text-muted);
  border-radius: 4px;
  cursor: pointer;
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
}
.li-assets-open { right: 28px; color: var(--text); }
.li-assets-clear { right: 6px; }
.li-assets-open:hover, .li-assets-clear:hover { background: var(--hairline); color: var(--text); }
.li-assets-host {
  font-size: 11px;
  color: var(--text-faint);
  padding-left: 2px;
}
.li-assets-hint {
  font-size: 11px;
  color: var(--text-faint);
  padding-top: 4px;
  border-top: 1px solid var(--hairline);
  margin-top: 4px;
}

/* ── COPY EDITOR ─────────────────────────────────────────── */
.li-edit {
  display: flex;
  flex-direction: column;
  flex: 1;
  background: var(--bg);
  animation: li-edit-in 280ms cubic-bezier(0.22, 1, 0.36, 1);
}
@keyframes li-edit-in { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: translateY(0); } }
.li-edit-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px 32px 14px;
  border-bottom: 1px solid var(--hairline);
}
.li-edit-head-left { display: flex; align-items: center; gap: 8px; font-size: 12.5px; color: var(--text-muted); }
.li-edit-crumb { color: var(--text); font-weight: 500; }
.li-edit-head-right { display: flex; align-items: center; gap: 12px; }
.li-edit-dirty { font-size: 11.5px; color: var(--h-low); }
.li-edit-save {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 8px 16px;
  background: var(--text);
  color: var(--bg);
  border: 0;
  border-radius: 7px;
  font-size: 12.5px;
  font-weight: 500;
  cursor: pointer;
  transition: opacity 120ms;
}
.li-edit-save:hover { opacity: 0.88; }

.li-edit-hero {
  padding: 36px 32px 28px;
  border-bottom: 1px solid var(--hairline);
  background: var(--bg-elevated);
}
.li-edit-hero-eyebrow {
  font-size: 11px;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--text-muted);
}
.li-edit-hero-title {
  margin: 8px 0 0;
  font-size: 36px;
  font-weight: 500;
  letter-spacing: -0.025em;
  line-height: 1.05;
  color: var(--text);
}

.li-edit-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 36px 32px;
  padding: 32px 32px 48px;
  align-items: start;
}
.li-edit-col {
  display: flex;
  flex-direction: column;
  gap: 36px;
}
.li-edit-section-meta { align-self: start; position: sticky; top: 24px; }
.li-edit-section { display: flex; flex-direction: column; gap: 10px; }
.li-edit-section-wide { grid-column: 1 / -1; }
.li-edit-section-head {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  padding-bottom: 10px;
  border-bottom: 1px solid var(--hairline);
}
.li-edit-section-k {
  font-size: 11px;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--text-muted);
}
.li-edit-section-hint { font-size: 11.5px; color: var(--text-faint); margin-top: 2px; }
.li-edit-wc { font-size: 10.5px; color: var(--text-faint); }

.li-edit-lang { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.li-edit-meta { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; align-items: stretch; }
.li-edit-meta-stack { display: flex; flex-direction: column; gap: 10px; }
.li-edit-tags {
  min-height: 80px;
  padding: 8px;
  border: 1px solid var(--hairline);
  border-radius: 7px;
  background: var(--surface);
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  align-content: flex-start;
  transition: border-color 120ms;
}
.li-edit-tags:focus-within { border-color: var(--text-muted); }
.li-edit-tag {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 4px 4px 4px 10px;
  background: var(--bg-elevated);
  border: 1px solid var(--hairline);
  border-radius: 999px;
  font-size: 11.5px;
  font-weight: 500;
  color: var(--text);
}
.li-edit-tag-x {
  width: 16px;
  height: 16px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 0;
  background: transparent;
  color: var(--text-muted);
  border-radius: 50%;
  cursor: pointer;
}
.li-edit-tag-x:hover { background: var(--hairline); color: var(--text); }
.li-edit-tag-input {
  flex: 1;
  min-width: 120px;
  padding: 4px 4px;
  border: 0;
  background: transparent;
  font-size: 12.5px;
  color: var(--text);
  font-family: inherit;
}
.li-edit-tag-input::placeholder { color: var(--text-faint); }
.li-edit-tag-input:focus { outline: none; }
.li-edit-hint { font-size: 11px; color: var(--text-faint); margin-top: 4px; }
.li-edit-warn {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  font-size: 11px;
  color: oklch(0.55 0.18 50);
  background: oklch(0.97 0.04 75);
  padding: 4px 8px;
  border-radius: 5px;
  margin: 4px 0;
}
.li-edit-tag.is-deprecated { background: oklch(0.97 0.05 75); border-color: oklch(0.55 0.18 50); }
.li-edit-tag-swap {
  font-size: 10px;
  background: transparent;
  border: none;
  color: oklch(0.45 0.14 230);
  cursor: pointer;
  padding: 0 4px;
}
.li-edit-tag-swap:hover { text-decoration: underline; }
.li-edit-interest-search { position: relative; }
.li-edit-interest-list {
  list-style: none;
  margin: 4px 0 0;
  padding: 4px;
  background: var(--surface);
  border: 1px solid var(--hairline);
  border-radius: 7px;
  box-shadow: 0 6px 24px oklch(0 0 0 / 0.08);
  max-height: 220px;
  overflow-y: auto;
}
.li-edit-interest-row {
  display: flex;
  width: 100%;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  padding: 6px 8px;
  background: transparent;
  border: none;
  border-radius: 4px;
  cursor: pointer;
  font-size: 12px;
  color: var(--text);
  text-align: left;
}
.li-edit-interest-row:hover:not(:disabled) { background: var(--bg-elevated); }
.li-edit-interest-row:disabled { opacity: 0.55; cursor: default; }
.li-edit-interest-size { font-size: 10.5px; color: var(--text-faint); }
.li-edit-interest-tick { color: var(--h-strong); font-size: 11px; }

.li-edit-video {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 10px 12px;
  border: 1px solid var(--hairline);
  border-radius: 7px;
  background: var(--surface);
  font-size: 12px;
}
.li-edit-video-meta { display: flex; gap: 10px; align-items: baseline; }
.li-edit-video-name { color: var(--text); font-weight: 500; }
.li-edit-video-size { font-size: 11px; color: var(--text-faint); }
.li-edit-video-clear {
  background: transparent;
  border: none;
  color: var(--text-muted);
  font-size: 11px;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 4px;
}
.li-edit-video-clear:hover { color: var(--text); }
.li-edit-video-pick {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 10px 12px;
  border: 1px dashed var(--hairline-strong);
  border-radius: 7px;
  cursor: pointer;
  font-size: 12px;
  color: var(--text-muted);
}
.li-edit-video-pick:hover { background: var(--bg-elevated); color: var(--text); }
.li-edit-video-pick.is-busy { opacity: 0.6; cursor: progress; }

.li-edit-promo-list {
  list-style: none;
  margin: 0 0 8px;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 4px;
}
.li-edit-promo-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  padding: 8px 10px;
  border: 1px solid var(--hairline);
  border-radius: 6px;
  background: var(--surface);
  font-size: 12px;
}
.li-edit-promo-url {
  color: var(--text);
  text-decoration: none;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  flex: 1;
  min-width: 0;
}
.li-edit-promo-url:hover { text-decoration: underline; }
.li-edit-promo-x {
  background: transparent;
  border: none;
  color: var(--text-muted);
  cursor: pointer;
  padding: 2px 4px;
}
.li-edit-promo-x:hover { color: var(--text); }
.li-edit-promo-add { display: flex; gap: 8px; align-items: stretch; }
.li-edit-promo-add .li-edit-input { flex: 1; }
.li-edit-promo-add-btn {
  padding: 0 14px;
  border-radius: 7px;
  border: 1px solid var(--hairline);
  background: var(--text);
  color: var(--bg);
  font-size: 12px;
  font-weight: 500;
  cursor: pointer;
}
.li-edit-promo-add-btn:disabled { opacity: 0.4; cursor: default; background: var(--hairline); color: var(--text-muted); }
.li-edit-lang-cell { display: flex; flex-direction: column; gap: 4px; }
.li-edit-lang-head { display: flex; justify-content: space-between; align-items: baseline; }
.li-edit-lang-tag {
  font-size: 9.5px;
  font-weight: 600;
  letter-spacing: 0.1em;
  background: var(--hairline);
  padding: 2px 6px;
  border-radius: 3px;
  color: var(--text);
}
.li-edit-input {
  width: 100%;
  padding: 10px 12px;
  border: 1px solid var(--hairline);
  border-radius: 7px;
  background: var(--surface);
  color: var(--text);
  font-size: 13.5px;
  line-height: 1.5;
  letter-spacing: -0.005em;
  font-family: inherit;
  resize: vertical;
  transition: border-color 120ms;
}
.li-edit-input:hover { border-color: var(--hairline-strong); }
.li-edit-input:focus { outline: none; border-color: var(--text-muted); }

.li-edit-preview {
  padding: 24px 28px;
  background: var(--surface);
  border: 1px solid var(--hairline);
  border-radius: 8px;
}
.li-edit-preview-date {
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--text-muted);
}
.li-edit-preview-artist {
  margin: 4px 0 12px;
  font-size: 28px;
  font-weight: 500;
  letter-spacing: -0.02em;
  color: var(--text);
}
.li-edit-preview-hook {
  margin: 0 0 12px;
  font-size: 17px;
  font-weight: 500;
  line-height: 1.4;
  letter-spacing: -0.01em;
  color: var(--text);
}
.li-edit-preview-desc {
  margin: 0 0 12px;
  font-size: 14px;
  line-height: 1.55;
  color: var(--text-quiet);
  letter-spacing: -0.005em;
}
.li-edit-preview-lineup {
  margin: 0;
  padding-top: 12px;
  border-top: 1px solid var(--hairline);
  font-size: 12.5px;
  color: var(--text-muted);
}

@media (max-width: 1100px) {
  .li-edit-grid { grid-template-columns: 1fr; }
}

.li-copy-section { display: flex; flex-direction: column; gap: 6px; }
.li-copy-head { display: flex; justify-content: space-between; align-items: baseline; }
.li-copy-k {
  font-size: 10px;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--text-muted);
}
.li-copy-wc { font-size: 10.5px; color: var(--text-faint); }
.li-copy-text {
  margin: 0;
  font-size: 13px;
  line-height: 1.5;
  color: var(--text);
  letter-spacing: -0.005em;
  white-space: pre-wrap;
}
.li-copy-hook { font-size: 15px; font-weight: 500; letter-spacing: -0.01em; }
.li-copy-quiet { color: var(--text-muted); font-size: 12px; }

.li-pop-stat-of { color: var(--text-faint); font-weight: 400; font-size: 11px; margin-left: 1px; }

.li-art-body {
  flex: 1;
  display: block;
  padding: 8px 8px 12px;
  overflow-y: auto;
  position: relative;
}

.li-art-preview-pop {
  position: absolute;
  top: 12px;
  left: calc(100% + 12px);
  z-index: 60;
  pointer-events: none;
  animation: li-art-preview-in 140ms cubic-bezier(0.22, 1, 0.36, 1);
}
@keyframes li-art-preview-in { from { opacity: 0; transform: translateX(-4px); } to { opacity: 1; transform: translateX(0); } }
.li-art-preview-thumb {
  width: 200px;
  max-height: 280px;
  background: var(--text);
  color: var(--bg);
  border-radius: 8px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 12px;
  box-shadow: 0 12px 36px oklch(0 0 0 / 0.18);
}
.li-art-preview-thumb.is-empty {
  background: var(--surface);
  color: var(--text-muted);
  border: 1px dashed var(--hairline-strong);
}
.li-art-preview-glyph { font-size: 40px; line-height: 1; }
.li-art-preview-empty {
  font-size: 11px;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.08em;
}
.li-art-preview-name {
  font-size: 10.5px;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  opacity: 0.75;
}

.li-art-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 0;
}
.li-art-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto auto;
  gap: 10px;
  align-items: center;
  padding: 8px 10px;
  border-radius: 6px;
  transition: background 100ms;
  cursor: default;
}
.li-art-row.is-hover, .li-art-row:hover { background: var(--bg-elevated); }
.li-art-row-name { font-size: 12.5px; font-weight: 500; color: var(--text); }
.li-art-row-size { font-size: 10.5px; color: var(--text-muted); }
.li-art-status {
  font-size: 9.5px;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  padding: 2px 6px;
  border-radius: 999px;
  align-self: flex-start;
}
.li-art-status-empty { background: var(--hairline); color: var(--text-muted); }
.li-art-status-up    { background: var(--hairline); color: var(--text); }
.li-art-status-ok    { background: var(--h-strong-bg); color: var(--h-strong); }
.li-pop-item {
  display: flex;
  flex-direction: column;
  gap: 6px;
  padding: 10px 12px;
  border-radius: 7px;
  cursor: default;
  text-align: left;
  white-space: normal;
}
.li-pop-item:hover { background: var(--bg-elevated); }
.li-pop-item-head { display: flex; justify-content: space-between; align-items: baseline; gap: 8px; }
.li-pop-item-name { font-size: 12.5px; font-weight: 500; color: var(--text); letter-spacing: -0.005em; line-height: 1.3; }
.li-pop-item-ago { font-size: 10.5px; color: var(--text-muted); white-space: nowrap; }
.li-pop-status {
  font-size: 9px;
  font-weight: 600;
  letter-spacing: 0.08em;
  padding: 2px 6px;
  border-radius: 999px;
  white-space: nowrap;
}
.li-pop-status-active { background: var(--h-strong-bg); color: var(--h-strong); }
.li-pop-status-paused { background: var(--hairline); color: var(--text-muted); }
.li-pop-item-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 10px 16px;
  font-size: 11px;
  color: var(--text);
}
.li-pop-item-k {
  font-size: 9.5px;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--text-muted);
  margin-right: 4px;
}
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
  padding: 80px 20px;
  color: var(--text-muted);
}
.li-empty-title { font-size: 14px; font-weight: 500; color: var(--text); }
.li-empty-sub { font-size: 12px; }

@media (max-width: 1100px) {
  .li-totals-row { grid-template-columns: repeat(3, 1fr); }
  .li-row {
    grid-template-columns: 60px 1fr;
    gap: 12px;
  }
  .li-row-pipe, .li-row-tickets, .li-row-prog, .li-fc { grid-column: 1 / -1; }
}

/* ── Artwork popover — real previews + per-slot upload/delete ─────────────
   Renders a 3-col grid of 7 canonical slots. Each tile shows the real
   GCS thumbnail when uploaded, or a "Saknas" placeholder with upload
   button when empty. */
.li-pop-artwork {
  width: 480px;
  max-width: calc(100vw - 32px);
}
.li-art-error {
  margin: 0 16px;
  padding: 8px 10px;
  border-radius: 6px;
  background: rgba(220, 38, 38, 0.08);
  color: var(--text);
  font-size: 11px;
  border: 1px solid rgba(220, 38, 38, 0.25);
}
.li-art-grid-body { padding: 12px 14px 14px; }
.li-art-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 10px;
}
.li-art-slot {
  display: flex;
  flex-direction: column;
  gap: 6px;
}
.li-art-slot-thumb {
  position: relative;
  width: 100%;
  background: var(--surface-2, rgba(0, 0, 0, 0.04));
  border: 1px solid var(--hairline);
  border-radius: 6px;
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: center;
}
.li-art-slot-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}
.li-art-slot.is-empty .li-art-slot-thumb {
  background: transparent;
  border-style: dashed;
}
.li-art-slot-empty {
  font-size: 10px;
  color: var(--text-faint);
  letter-spacing: 0.04em;
  text-transform: uppercase;
  font-weight: 500;
}
.li-art-slot-busy {
  position: absolute;
  inset: 0;
  background: rgba(255, 255, 255, 0.6);
  display: grid;
  place-items: center;
  backdrop-filter: blur(2px);
}
[data-theme="dark"] .li-art-slot-busy {
  background: rgba(0, 0, 0, 0.55);
}
.li-art-spin {
  width: 14px;
  height: 14px;
  border: 2px solid var(--hairline);
  border-top-color: var(--text);
  border-radius: 50%;
  animation: li-art-spin 700ms linear infinite;
}
@keyframes li-art-spin { to { transform: rotate(360deg); } }

.li-art-slot-meta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 6px;
}
.li-art-slot-label {
  font-size: 10.5px;
  color: var(--text-quiet);
  letter-spacing: 0.02em;
}
.li-art-slot-act {
  width: 20px;
  height: 20px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 4px;
  border: 0;
  background: transparent;
  color: var(--text-quiet);
  cursor: pointer;
  transition: background 120ms, color 120ms;
  padding: 0;
}
.li-art-slot-act:hover { background: var(--hairline); color: var(--text); }
.li-art-slot-act:disabled { opacity: 0.4; cursor: default; }
.li-art-slot-upload:hover { color: var(--text); }
.li-art-slot-download:hover { background: var(--hairline); color: var(--text); }
.li-art-slot-delete:hover { background: rgba(220, 38, 38, 0.1); color: rgb(180, 30, 30); }
.li-art-row-acts {
  display: inline-flex;
  align-items: center;
  gap: 2px;
  justify-self: end;
}

/* ── DELETE CONFIRM MODAL ──────────────────────────────────
   Centered confirmation for deleting a hold, in the V2 design
   language (mirrors the artwork-editor confirm overlay). */
.li-confirm {
  position: fixed;
  inset: 0;
  z-index: 100;
  display: grid;
  place-items: center;
  padding: 24px;
  background: oklch(0 0 0 / 0.45);
  -webkit-backdrop-filter: blur(2px);
  backdrop-filter: blur(2px);
  animation: li-confirm-fade 120ms ease-out;
}
.li-confirm-card {
  width: min(380px, 100%);
  padding: 22px 22px 18px;
  border-radius: var(--r-lg);
  border: 1px solid var(--hairline);
  background: var(--bg-elevated);
  color: var(--text);
  box-shadow: var(--shadow-lg);
  animation: li-confirm-rise 140ms cubic-bezier(0.22, 1, 0.36, 1);
}
.li-confirm-title {
  margin: 0 0 8px;
  font-size: 15px;
  font-weight: 600;
  letter-spacing: -0.01em;
  color: var(--text);
}
.li-confirm-body {
  margin: 0 0 20px;
  font-size: 13px;
  line-height: 1.5;
  color: var(--text-muted);
}
.li-confirm-actions {
  display: flex;
  justify-content: flex-end;
  gap: 10px;
}
.li-confirm-cancel,
.li-confirm-danger {
  font-size: 12.5px;
  font-weight: 500;
  padding: 7px 16px;
  border-radius: 8px;
  transition: background 120ms, color 120ms, border-color 120ms, opacity 120ms;
}
.li-confirm-cancel {
  border: 1px solid var(--hairline);
  background: var(--bg);
  color: var(--text-muted);
}
.li-confirm-cancel:hover:not(:disabled) { border-color: var(--hairline-strong); color: var(--text); }
.li-confirm-danger {
  border: 1px solid var(--h-critical);
  background: var(--h-critical);
  color: #fff;
}
.li-confirm-danger:hover:not(:disabled) { opacity: 0.9; }
.li-confirm-cancel:disabled,
.li-confirm-danger:disabled { opacity: 0.5; cursor: default; }

@keyframes li-confirm-fade { from { opacity: 0; } to { opacity: 1; } }
@keyframes li-confirm-rise {
  from { opacity: 0; transform: translateY(8px) scale(0.98); }
  to   { opacity: 1; transform: translateY(0) scale(1); }
}

/* ============================================================
   SUB-VIEW OVERLAY
   ShowOverview / Artwork / Copy Editor render here, above the still-mounted
   list (Lista.tsx). Because the list never unmounts, the browser keeps its
   scroll position — returning lands exactly where you left. The overlay is a
   fixed, full-viewport, opaque layer with its own scroll; the list behind is
   frozen (root overflow is locked while it's open). z-index sits above page
   content and popovers but below the global notification panel (90/91).
   ============================================================ */
.li-overlay {
  position: fixed;
  top: 0;
  right: 0;
  bottom: 0;
  left: var(--fc-rail-w, 224px);   /* start past the sidebar so the nav stays visible */
  z-index: 80;
  background: var(--bg);
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
  overscroll-behavior: contain;
  transition: left 280ms var(--ease, ease);
  animation: li-confirm-fade 160ms var(--ease, ease) both;
}
@media (max-width: 860px) {
  /* Sidebar is an off-canvas drawer here, so the detail fills the screen. */
  .li-overlay { left: 0; }
}
