/* Internes Tool (Shop Admin): Rahmen, Blatt, Sidebar, Login und Grundbausteine.
   Baut auf brand.css auf (Tokens, Schrift, .btn, .pill, .field, .link). */

/* ── Variablen des Tools ───────────────────────────────── */
:root {
  --gray-300: #d9cfcc;  /* vom Shell-Skript gesetzte Randfarbe */
  /* Schatten nur für Schwebendes (Menüs, Dialoge, Toasts). */
  --shadow: 0 8px 24px rgba(11, 11, 11, .12);
  --shadow-lg: 0 24px 64px rgba(11, 11, 11, .18);

  --sidebar-width: 236px;
  --line: #e2d9d6;      /* Feldrand, einen Schritt kräftiger als --edge */
  --rule: #f4efed;      /* Zeilenlinie in Tabellen */
  --hover: #fcfaf9;     /* Zeile unter dem Zeiger */
}

/* ── Grundlage ─────────────────────────────────────────── */
*, *::before, *::after { margin: 0; padding: 0; }

html { -webkit-text-size-adjust: 100%; }
body {
  background: var(--frame);
  font-size: 15px;
  line-height: 1.45;
  min-height: 100dvh;
  -webkit-font-smoothing: antialiased;
}
button, input, select, textarea { font: inherit; color: inherit; }
img { max-width: 100%; }
h1, h2, h3 { font-weight: 650; letter-spacing: -.03em; line-height: 1.15; }

/* ── Rahmen und Blatt ──────────────────────────────────── */
.app-shell {
  display: grid;
  grid-template-columns: var(--sidebar-width) minmax(0, 1fr);
  min-height: 100dvh;
  background: var(--frame);
}
.main-col {
  display: flex;
  flex-direction: column;
  min-width: 0;
  min-height: 100dvh;
}

.topbar {
  flex: none;
  height: 48px;
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 0 16px 0 8px;
  font-size: 15px;
  color: var(--soft);
  min-width: 0;
}
.topbar-crumb {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.topbar-crumb b { color: var(--ink); font-weight: 600; }

.menu-btn, .sidebar-close {
  display: none;
  flex: none;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  border: 0;
  border-radius: 999px;
  background: none;
  color: var(--ink);
  cursor: pointer;
}
.menu-btn:hover, .sidebar-close:hover { background: rgba(11, 11, 11, .05); }
.menu-btn-lines, .menu-btn-lines::before, .menu-btn-lines::after {
  display: block;
  width: 18px;
  height: 2px;
  border-radius: 2px;
  background: currentColor;
}
.menu-btn-lines { position: relative; }
.menu-btn-lines::before, .menu-btn-lines::after { content: ""; position: absolute; left: 0; }
.menu-btn-lines::before { top: -6px; }
.menu-btn-lines::after { top: 6px; }
.sidebar-close-x { position: relative; display: block; width: 18px; height: 18px; }
.sidebar-close-x::before, .sidebar-close-x::after {
  content: "";
  position: absolute;
  left: 0;
  top: 8px;
  width: 18px;
  height: 2px;
  border-radius: 2px;
  background: currentColor;
  transform: rotate(45deg);
}
.sidebar-close-x::after { transform: rotate(-45deg); }

.sheet {
  flex: 1;
  min-width: 0;
  background: var(--ground);
  border: 1px solid var(--edge);
  border-radius: 16px;
  margin: 0 8px 8px 0;
  padding: 28px 32px 48px;
}
.sheet:focus { outline: none; }

/* ── Sidebar ───────────────────────────────────────────── */
.sidebar {
  position: sticky;
  top: 0;
  height: 100dvh;
  display: flex;
  flex-direction: column;
  min-width: 0;
  padding: 16px 12px 12px;
  background: var(--frame);
}
.sidebar-head { display: flex; align-items: center; justify-content: space-between; gap: 8px; }
.sidebar-logo {
  display: flex;
  align-items: flex-end;
  gap: 10px;
  padding: 6px 10px 18px;
}
.sidebar-mark { display: block; height: 24px; width: auto; }
/* Grundlinie der Wortmarke liegt etwa 5 px über der Bildunterkante. */
.sidebar-product { padding-bottom: 3px; font-size: 14px; line-height: 1; color: var(--soft); white-space: nowrap; }
.sidebar-staging { align-self: center; background: var(--warn); color: #fff; letter-spacing: .02em; }
/* Auf dem Handy ist die Sidebar eingeklappt: dort zeigt die Kopfleiste das Abzeichen. */
.topbar-staging { display: none; flex: none; margin-left: auto; }

.sidebar-nav {
  flex: 1;
  min-height: 0;
  overflow-y: auto;
  margin: 0 -4px;
  padding: 0 4px 12px;
}
.sidebar-group {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  width: 100%;
  padding: 14px 10px 4px;
  border: 0;
  border-radius: 8px;
  background: none;
  font-size: 13px;
  font-weight: 400;
  color: var(--soft);
  text-align: left;
  cursor: pointer;
}
.sidebar-group:hover { color: var(--ink); }
.sidebar-group--sub { padding-top: 8px; font-weight: 600; }
/* Chevron als CSS-Winkel, zeigt nach unten, eingeklappt nach rechts. */
.sidebar-section-chevron {
  flex: none;
  width: 7px;
  height: 7px;
  margin-right: 3px;
  border-right: 1.5px solid currentColor;
  border-bottom: 1.5px solid currentColor;
  transform: translateY(-2px) rotate(45deg);
  transition: transform .18s ease;
}
.sidebar-group.collapsed .sidebar-section-chevron { transform: rotate(-45deg); }

.sidebar-nav-item {
  display: flex;
  align-items: center;
  width: 100%;
  min-height: 34px;
  padding: 6px 10px;
  margin-bottom: 1px;
  border: 0;
  border-radius: 8px;
  background: none;
  font-size: 15px;
  font-weight: 400;
  line-height: 1.3;
  color: #2a2726;
  text-align: left;
  cursor: pointer;
}
.sidebar-nav-item:hover { background: rgba(11, 11, 11, .04); color: var(--ink); }
.sidebar-nav-item.active { background: var(--ground); color: var(--ink); font-weight: 600; }

.sidebar-footer { flex: none; padding-top: 8px; }
.sidebar-logout { color: var(--soft); }

.sidebar-backdrop { display: none; }

/* ── Login ─────────────────────────────────────────────── */
.login-overlay {
  min-height: 100dvh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px 16px;
  background: var(--peach);
}
.login-wrap { width: 100%; max-width: 420px; }
.login-brand { display: flex; justify-content: center; margin-bottom: 28px; }
.login-mark { display: block; height: 40px; width: auto; }
.card.login-card { background: var(--ground); padding: 32px; }
.login-card .btn-row { margin-top: 8px; }

/* ── Seitenkopf ────────────────────────────────────────── */
.page-head {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 16px 24px;
  flex-wrap: wrap;
  margin-bottom: 24px;
}
.page-head h1 {
  font-size: 30px;
  font-weight: 650;
  letter-spacing: -.035em;
  line-height: 1.1;
  color: var(--ink);
  overflow-wrap: anywhere;
}
.page-sub { margin-top: 6px; font-size: 15px; color: var(--ink); }
.page-sub b { font-weight: 600; }

/* Ältere Seitenhüllen: das Blatt gibt den Innenabstand vor. */
.page { padding: 0; }
.page-inner { max-width: 1200px; }
.content-inner { max-width: 680px; padding: 0; }

/* ── Tabs ──────────────────────────────────────────────── */
.tabs {
  display: flex;
  gap: 24px;
  margin: 0 0 24px;
  border-bottom: 1px solid var(--edge); /* taste-skill-ignore: Unterstrich-Tabs stehen auf einer Linie */
  overflow-x: auto;
  scrollbar-width: none;
}
.tabs::-webkit-scrollbar { display: none; }
.tab {
  flex: none;
  margin-bottom: -1px;
  padding: 10px 0 8px;
  border: 0;
  border-bottom: 2px solid transparent;
  background: none;
  font-size: 15px;
  color: var(--soft);
  white-space: nowrap;
  cursor: pointer;
}
.tab:hover { color: var(--ink); }
.tab.active, .tab[aria-selected="true"] { color: var(--ink); font-weight: 600; border-bottom-color: var(--blue); }

/* ── Einstellungs-Zeile und Panel ──────────────────────── */
.setrow {
  display: grid;
  grid-template-columns: 300px minmax(0, 1fr);
  gap: 32px;
  margin-bottom: 32px;
}
.setrow h2 { font-size: 16px; font-weight: 600; letter-spacing: -.01em; }
.setrow-desc { margin-top: 4px; max-width: 36ch; font-size: 15px; color: var(--soft); }
.panel {
  background: var(--panel);
  border-radius: 16px;
  padding: 20px;
  min-width: 0;
}

/* ── Karten (ältere Views): ein Panel auf dem Blatt ────── */
.card {
  background: var(--panel);
  border-radius: 16px;
  padding: 28px;
  min-width: 0;
}
.card-title {
  font-size: 22px;
  font-weight: 650;
  letter-spacing: -.03em;
  line-height: 1.15;
  color: var(--ink);
  margin-bottom: 6px;
}
.card-subtitle { font-size: 15px; color: var(--soft); margin-bottom: 24px; }

/* ── Formulare ─────────────────────────────────────────── */
.form-group { margin-bottom: 18px; }
.form-label {
  display: block;
  margin-bottom: 6px;
  font-size: 14px;
  font-weight: 600;
  color: var(--ink);
}
.form-input {
  display: block;
  width: 100%;
  min-height: 40px;
  padding: 8px 12px;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: var(--ground);
  font-family: var(--font);
  font-size: 15px;
  color: var(--ink);
}
.form-input::placeholder { color: var(--placeholder); }
.form-input:focus { outline: 2px solid var(--blue); outline-offset: -1px; border-color: var(--blue); }
.form-input:disabled { background: var(--panel); color: var(--soft); }
.form-input.error { border-color: var(--error); }
select.form-input { padding-right: 8px; }
textarea.form-input { min-height: 88px; }
.form-hint { margin-top: 6px; font-size: 15px; color: var(--soft); }
.form-label .form-hint { display: inline; margin: 0; font-weight: 400; }
.form-error {
  display: flex;
  align-items: center;
  gap: 4px;
  margin-top: 6px;
  font-size: 15px;
  color: var(--error);
}
input[type="checkbox"], input[type="radio"] { accent-color: var(--ink); }

/* ── Filterzeile über Listen (Suche, Auswahl, Aktionen) ── */
.toolbar { display: flex; flex-wrap: wrap; align-items: center; gap: 10px; }
/* Felder nehmen ihre eigene oder die Inline-Breite, nie die ganze Zeile. */
.toolbar .form-input { width: auto; max-width: 100%; }

/* ── Buttons (ältere Klassen auf die gradoo-Pills) ─────── */
.btn {
  height: auto;
  min-height: 38px;
  padding: 6px 18px;
  line-height: 1.2;
  text-align: center;
  white-space: normal;
}
.btn.btn--small { min-height: 30px; padding: 4px 12px; }
.btn-primary { background: var(--blue); color: #fff; }
.btn-primary:hover { background: var(--blue-press); }
.btn.btn-outline { background: var(--ground); color: var(--ink); border: 1px solid var(--line); }
.btn.btn-outline:hover { background: var(--panel); border-color: #cfc5c2; }
/* Auch ohne .btn nutzbar (z. B. „Banner entfernen"). */
.btn-ghost {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  min-height: 32px;
  padding: 4px 12px;
  border: 0;
  border-radius: 999px;
  background: transparent;
  font-family: var(--font);
  font-size: 15px;
  color: var(--ink);
  cursor: pointer;
}
.btn-ghost:hover { background: var(--muted-pale); }
.btn-full { width: 100%; }
.btn-row { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 24px; }
.btn-row .btn { flex: 1; }

/* ── Tabellen ──────────────────────────────────────────── */
.table {
  width: 100%;
  border-collapse: collapse;
  font-size: 15px;
}
.table th {
  padding: 8px 12px;
  border-bottom: 1px solid var(--edge);
  font-size: 13px;
  font-weight: 500;
  color: var(--soft);
  text-align: left;
  white-space: nowrap;
}
.table td {
  height: 52px;
  padding: 8px 12px;
  border-bottom: 1px solid var(--rule);
  color: var(--ink);
  vertical-align: middle;
}
.table tbody tr:hover td { background: var(--hover); }
.table .u-num {
  text-align: right;
  font-variant-numeric: tabular-nums;
}
.th-sort { cursor: pointer; user-select: none; }
.cell-link { font-weight: 600; color: var(--ink); text-decoration: none; }
.cell-link:hover { color: var(--blue); text-decoration: underline; text-underline-offset: 3px; }

/* Eine breite Tabelle scrollt in ihrem Rahmen, nie die Seite. */
.table-scroll { overflow-x: auto; }

/* Unter 700 px: jede Zeile ein Block, das Label kommt aus data-label. */
@media (max-width: 699px) {
  .table thead { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }
  .table, .table tbody, .table tr, .table td { display: block; width: 100%; }
  .table tr { padding: 12px 0; border-bottom: 1px solid var(--edge); }
  .table td {
    display: flex;
    justify-content: space-between;
    align-items: baseline;
    gap: 16px;
    height: auto;
    padding: 3px 0;
    border: 0;
    text-align: right;
    overflow-wrap: anywhere;
  }
  .table td[data-label]::before {
    content: attr(data-label);
    flex: none;
    font-size: 14px;
    font-weight: 400;
    color: var(--soft);
    text-align: left;
  }
  .table td:not([data-label]) { display: block; text-align: left; }
  .table tbody tr:hover td { background: none; }
}

/* ── Status-Pills (ältere Namen) ───────────────────────── */
.pill { flex: none; }
.pill-green { background: var(--ok-pale); color: var(--ok); }
.pill-yellow { background: var(--warn-pale); color: var(--warn); }
.pill-gray { background: var(--muted-pale); color: var(--muted); }
.pill-red { background: var(--error-pale); color: var(--error); }
.weclapp-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  height: 24px;
  margin-bottom: 16px;
  padding: 0 10px;
  border-radius: 999px;
  background: var(--muted-pale);
  color: var(--muted);
  font-size: 14px;
  font-weight: 600;
}

/* ── Leere, Lade- und Fehlerzustände ───────────────────── */
.empty {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 32px 20px;
  border: 1px dashed var(--line);
  border-radius: 16px;
  color: var(--soft);
  font-size: 15px;
  text-align: center;
}
.empty-title { font-size: 16px; font-weight: 600; color: var(--ink); }
.list-state { padding: 48px 0; text-align: center; color: var(--soft); }
.list-spinner, .spinner {
  border-radius: 50%;
  border: 3px solid var(--edge);
  border-top-color: var(--ink);
  animation: spin .8s linear infinite;
}
.list-spinner { width: 28px; height: 28px; margin: 0 auto 12px; }
.spinner { width: 44px; height: 44px; margin: 0 auto 20px; }
@keyframes spin { to { transform: rotate(360deg); } }
.error-box {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  margin-bottom: 20px;
  padding: 12px 14px;
  border-radius: 12px;
  background: var(--error-pale);
  color: var(--error);
  font-size: 15px;
}
.text-muted { font-size: 15px; color: var(--soft); }
.mt-2 { margin-top: 8px; }
.divider { height: 1px; margin: 20px 0; background: var(--edge); } /* taste-skill-ignore: Trenner in Formularen älterer Views */

/* ── Dialog (schwebt, daher mit Schatten) ──────────────── */
.modal-overlay {
  position: fixed;
  inset: 0;
  z-index: 500;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 16px;
  background: rgba(11, 11, 11, .4);
}
.modal {
  width: 100%;
  max-width: 560px;
  max-height: calc(100dvh - 32px);
  overflow-y: auto;
  padding: 28px;
  border-radius: 16px;
  background: var(--ground);
  box-shadow: var(--shadow-lg); /* taste-skill-ignore: Dialog schwebt */
}
.modal h2 { font-size: 20px; margin-bottom: 8px; }

/* ── Hilfsklassen ──────────────────────────────────────── */
.u-num { text-align: right; font-variant-numeric: tabular-nums; }
.u-soft { color: var(--soft); }
.cluster { display: flex; flex-wrap: wrap; align-items: center; }
.stack-8 > * + * { margin-top: 8px; }
.stack-12 > * + * { margin-top: 12px; }
.stack-16 > * + * { margin-top: 16px; }
.stack-24 > * + * { margin-top: 24px; }
.gap-4 { gap: 4px; }
.gap-8 { gap: 8px; }
.gap-12 { gap: 12px; }
.gap-16 { gap: 16px; }

/* ════════════════════════════════════════════════════════
   Bausteine einzelner Views.
   ════════════════════════════════════════════════════════ */

/* ── Fortschritt im Assistenten ────────────────────────── */
.progress-wrap { padding: 0 0 28px; }
.progress-steps { display: flex; align-items: center; max-width: 680px; }
.progress-step { position: relative; display: flex; align-items: center; gap: 8px; flex: 1; }
.progress-step:not(:last-child)::after {
  content: "";
  position: absolute;
  left: calc(50% + 16px);
  right: calc(-50% + 16px);
  top: 13px;
  z-index: 0;
  height: 2px;
  background: var(--edge);
}
.progress-step.done:not(:last-child)::after { background: var(--ink); }
.progress-step-inner { display: flex; flex-direction: column; align-items: center; gap: 4px; flex: 1; }
.progress-circle {
  position: relative;
  z-index: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 26px;
  height: 26px;
  border: 2px solid var(--edge);
  border-radius: 50%;
  background: var(--ground);
  color: var(--soft);
  font-size: 13px;
  font-weight: 650;
  font-variant-numeric: tabular-nums;
}
/* Drei Zustände auf einen Blick: erledigt = schwarz gefüllt mit Haken (statt der Zahl),
   aktuell = schwarzer Ring mit Zahl, kommend = heller Ring mit grauer Zahl. */
.progress-step.active .progress-circle { border-color: var(--ink); color: var(--ink); }
.progress-step.done .progress-circle { border-color: var(--ink); background: var(--ink); color: transparent; }
.progress-step.done .progress-circle::after {
  content: "";
  position: absolute;
  left: 50%;
  top: 50%;
  width: 5px;
  height: 10px;
  border-right: 2px solid #fff;
  border-bottom: 2px solid #fff;
  transform: translate(-50%, -62%) rotate(45deg);
}
.progress-label { font-size: 14px; color: var(--soft); white-space: nowrap; }
.progress-step.active .progress-label { color: var(--ink); font-weight: 600; }
.progress-step.done .progress-label { color: var(--ink); }

/* ── Auswahlkarten ─────────────────────────────────────── */
.mode-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; margin-bottom: 24px; }
.mode-card {
  padding: 18px 16px;
  border: 1px solid var(--line);
  border-radius: 16px;
  background: var(--ground);
  text-align: center;
  cursor: pointer;
}
.mode-card:hover { border-color: #cfc5c2; }
.mode-card.selected { border-color: var(--ink); outline: 1px solid var(--ink); outline-offset: -2px; }
.mode-title { margin-bottom: 2px; font-size: 15px; font-weight: 650; color: var(--ink); }
.mode-desc { font-size: 14px; color: var(--soft); }

/* ── Textilauswahl: Links ──────────────────────────────── */
.sel-new { display: grid; grid-template-columns: minmax(0, 220px) minmax(0, 1fr) auto; gap: 16px; align-items: end; }
.sel-new > .sel-note { grid-column: 1 / -1; margin: 0; }
.seg { display: flex; gap: 3px; padding: 3px; border-radius: 10px; background: var(--tone); }
.seg-opt {
  position: relative;
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 40px;
  padding: 4px 10px;
  border-radius: 8px;
  font-size: 15px;
  line-height: 1.2;
  text-align: center;
  color: var(--soft);
  cursor: pointer;
}
.seg-opt input { position: absolute; inset: 0; width: 100%; height: 100%; margin: 0; opacity: 0; cursor: pointer; }
.seg-opt.selected { background: var(--ground); color: var(--ink); font-weight: 600; }
.seg-opt:focus-within { outline: 2px solid var(--blue); outline-offset: 1px; }
.sel-lookup { height: auto; min-height: 22px; padding-top: 2px; padding-bottom: 2px; white-space: normal; }
.link-row { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; }
.link-row .form-input { flex: 1; min-width: 200px; width: auto; }
.sel-after { margin-top: 6px; }
.detail-title { font-size: 22px; font-weight: 650; letter-spacing: -.03em; line-height: 1.15; overflow-wrap: anywhere; }
.panel-title { margin-bottom: 8px; font-size: 16px; font-weight: 600; letter-spacing: -.01em; }
.panel-count { font-weight: 400; }
.panel .table td { border-bottom-color: var(--edge); }
.panel .table tbody tr:hover td { background: var(--ground); }
.cell-strong { font-weight: 600; overflow-wrap: anywhere; }
.nowrap { white-space: nowrap; }
.between { justify-content: space-between; }
.row-acts { text-align: right; white-space: nowrap; }
.row-acts .link { margin-left: 14px; font-size: 15px; }
.row-url { margin-top: 4px; font-size: 13px; text-align: left; user-select: all; overflow-wrap: anywhere; white-space: normal; }
.pill--faint { background: #f4f1f0; color: var(--soft); font-weight: 500; }

/* ── Textilauswahl: Katalog ────────────────────────────── */
.cm-note { margin-bottom: 16px; }
.cm-staging { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 12px; }
.cm-staging-text { flex: 1 1 240px; font-size: 14px; }
.cm-toolbar { display: flex; flex-wrap: wrap; align-items: center; gap: 12px; margin-bottom: 20px; }
.cm-season { width: auto; min-width: 100px; }
.cm-check { display: inline-flex; align-items: center; gap: 8px; }
.cm-top-acts { display: flex; flex-wrap: wrap; gap: 8px; margin-left: auto; }
.cm-empty-more { display: flex; flex-direction: column; align-items: center; gap: 12px; }
.cm-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 16px; }
.cm-card {
  display: flex;
  flex-direction: column;
  gap: 12px;
  min-width: 0;
  padding: 12px;
  border-radius: 16px;
  background: var(--panel);
  transition: background .2s ease;
}
.cm-card.drag { background: var(--blush); }
.cm-card.drag .cm-img { background: var(--peach); }
.cm-img {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  height: 150px;
  background: var(--blush);
  color: var(--soft);
  font-size: 15px;
  text-align: center;
}
.cm-img img { display: block; width: 100%; height: 100%; object-fit: cover; object-position: 50% 12%; mix-blend-mode: multiply; }
.cm-badges { position: absolute; top: 8px; left: 8px; right: 8px; display: flex; flex-wrap: wrap; gap: 4px; }
.cm-body { display: flex; flex: 1; flex-direction: column; gap: 6px; min-width: 0; }
.cm-title { font-size: 16px; font-weight: 650; letter-spacing: -.01em; overflow-wrap: anywhere; }
.cm-meta, .cm-chart { font-size: 14px; color: var(--soft); overflow-wrap: anywhere; }
.cm-price { font-weight: 650; font-variant-numeric: tabular-nums; }
.cm-own { font-weight: 600; color: var(--ok); }
.cm-acts { display: flex; flex-direction: column; gap: 10px; margin-top: auto; padding-top: 6px; }
.cm-acts-main { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.cm-acts-files { display: flex; flex-wrap: wrap; align-items: baseline; gap: 4px 14px; }
.cm-acts .link { font-size: 14px; }
.cm-acts .link:disabled { opacity: .5; cursor: not-allowed; }
.link--danger, .link--danger:hover { color: var(--error); }
.cm-progress { font-size: 15px; color: var(--blue); }
.cm-err { font-size: 15px; color: var(--error); overflow-wrap: anywhere; }

/* Dialoge des Katalogs */
.cm-modal { max-width: 640px; }
.cm-modal--add { max-width: 1040px; }
.cm-modal .tabs.cm-dtabs { margin: 12px 0 16px; }
.cm-two { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 16px; align-items: start; }
.cm-step { margin-bottom: 10px; font-weight: 650; }
.cm-hint { display: block; margin-top: 4px; font-size: 14px; font-weight: 400; color: var(--soft); }
.cm-warn-text { color: var(--warn); }
.cm-gap { margin-top: 8px; }
.cm-gap-t { margin-top: 16px; }
.cm-gap-b { margin-bottom: 12px; }
.cm-search { display: flex; gap: 8px; }
.cm-search .form-input { flex: 1 1 auto; width: auto; min-width: 0; }
.cm-search .cm-other-season { flex: none; width: auto; }
.cm-search .btn { flex: none; height: auto; min-height: 0; align-self: stretch; }
.cm-results { display: flex; flex-direction: column; gap: 8px; margin-top: 12px; max-height: 440px; overflow-y: auto; }
.cm-res {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 2px 12px;
  width: 100%;
  padding: 10px 12px;
  border: 0;
  border-radius: 12px;
  background: var(--ground);
  color: var(--ink);
  font: inherit;
  text-align: left;
  cursor: pointer;
  transition: background-color var(--t-hover) ease;
}
.cm-res:hover { background: var(--tone); }
.cm-res.on { outline: 2px solid var(--blue); outline-offset: -2px; background: var(--ground); }
.cm-res:disabled { opacity: .5; cursor: default; }
.cm-res:disabled:hover { background: var(--ground); }
.cm-res-title { font-weight: 650; overflow-wrap: anywhere; }
.cm-res-price { font-weight: 650; font-variant-numeric: tabular-nums; white-space: nowrap; }
.cm-res-meta { grid-column: 1 / -1; font-size: 14px; color: var(--soft); overflow-wrap: anywhere; }
.cm-dots { grid-column: 1 / -1; display: flex; flex-wrap: wrap; align-items: center; gap: 4px; margin-top: 6px; }
.cm-dot { width: 14px; height: 14px; border: 1px solid rgba(11, 11, 11, .15); border-radius: 50%; }
.cm-dots-more { font-size: 13px; color: var(--soft); }
.cm-form { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 14px 16px; }
.cm-field { display: block; min-width: 0; }
.cm-field .form-label { margin-bottom: 5px; }
.cm-full { grid-column: 1 / -1; }
.cm-files { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 8px 16px; padding: 12px 14px; border-radius: 12px; background: var(--tone); }
.cm-files-text { display: flex; flex-direction: column; min-width: 0; }
.cm-files-acts { display: flex; flex-wrap: wrap; gap: 6px 16px; min-width: 0; }
.cm-files-acts .link { font-size: 14px; text-align: left; overflow-wrap: anywhere; }
.cm-callout { padding: 10px 14px; border-radius: 12px; background: var(--warn-pale); color: var(--warn); font-size: 14px; }
.cm-dlg-error { margin-bottom: 0; }
.cm-modal .modal-actions, .modal .cm-full.modal-actions { margin-top: 8px; }
.cm-col-season { max-width: 200px; }
.cm-choice {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  padding: 12px 14px;
  border-radius: 12px;
  background: var(--panel);
  cursor: pointer;
}
.cm-choice.selected { outline: 2px solid var(--blue); outline-offset: -2px; background: var(--ground); }
.cm-choice input[type="radio"] { margin-top: 5px; accent-color: var(--blue); }
.cm-choice-text { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.cm-choice-head { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; }
.cm-inline-select { width: auto; min-height: 34px; padding: 4px 8px; }

@media (max-width: 899px) {
  .cm-two { grid-template-columns: minmax(0, 1fr); }
  .cm-top-acts { width: 100%; margin-left: 0; }
}
@media (max-width: 640px) {
  .cm-form { grid-template-columns: minmax(0, 1fr); }
  .cm-modal--add .panel { padding: 14px; }
}

/* ── Listenauswahl ─────────────────────────────────────── */
.select-list { display: flex; flex-direction: column; gap: 8px; max-height: 320px; margin-bottom: 20px; overflow-y: auto; }
.select-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 14px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: var(--ground);
  cursor: pointer;
}
.select-item:hover { border-color: #cfc5c2; }
.select-item.selected { border-color: var(--ink); outline: 1px solid var(--ink); outline-offset: -2px; }
.select-checkbox {
  display: flex;
  flex-shrink: 0;
  align-items: center;
  justify-content: center;
  width: 20px;
  height: 20px;
  border: 2px solid var(--gray-300);
  border-radius: 6px;
  font-size: 13px;
}
.select-item.selected .select-checkbox { border-color: var(--ink); background: var(--ink); color: #fff; }
.select-item-name { flex: 1; min-width: 0; font-size: 15px; font-weight: 500; overflow-wrap: anywhere; }
.select-item-price { font-size: 15px; color: var(--soft); font-variant-numeric: tabular-nums; }

/* ── Farbfelder ────────────────────────────────────────── */
.color-grid { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 20px; }
.color-swatch {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
  min-width: 72px;
  padding: 10px 12px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: var(--ground);
  cursor: pointer;
}
.color-swatch:hover { border-color: #cfc5c2; }
.color-swatch.selected { border-color: var(--ink); outline: 1px solid var(--ink); outline-offset: -2px; }
.color-swatch.disabled { opacity: .4; cursor: not-allowed; }
.color-swatch.disabled:hover { border-color: var(--line); }
.swatch-dot { width: 36px; height: 36px; border: 1px solid rgba(11, 11, 11, .14); border-radius: 50%; }
/* Kein hinterlegter Farbwert: rot getönter Kreis mit X, nicht mit Grau zu verwechseln. */
.swatch-dot.missing { position: relative; background: var(--error-pale); border-color: var(--error); }
.swatch-dot.missing::after {
  content: "";
  position: absolute;
  inset: 0;
  background-color: var(--error);
  -webkit-mask: no-repeat center / 46% url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='3' stroke-linecap='round'%3E%3Cpath d='M7 7l10 10M17 7L7 17'/%3E%3C/svg%3E");
          mask: no-repeat center / 46% url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='3' stroke-linecap='round'%3E%3Cpath d='M7 7l10 10M17 7L7 17'/%3E%3C/svg%3E");
}
.swatch-label { font-size: 14px; color: var(--ink); white-space: nowrap; }

/* ── Motiv-Zuordnung (hell/dunkel je Farbe) ────────────── */
.motif-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(268px, 100%), 1fr)); gap: 8px; }
.motif-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding: 8px 10px;
  border: 1px solid var(--edge);
  border-radius: 12px;
  background: var(--ground);
}
.motif-row-color { display: flex; align-items: center; gap: 9px; min-width: 0; }
.motif-row-color .swatch-dot { flex: none; width: 26px; height: 26px; }
.motif-row-name { overflow: hidden; font-size: 15px; color: var(--ink); text-overflow: ellipsis; white-space: nowrap; }
.motif-seg { display: inline-flex; flex: none; gap: 3px; padding: 3px; border-radius: 999px; background: var(--muted-pale); }
.motif-seg button {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 4px 10px;
  border: 0;
  border-radius: 999px;
  background: transparent;
  font-size: 13px;
  font-weight: 600;
  line-height: 1;
  color: var(--soft);
  cursor: pointer;
}
.motif-seg button:hover { color: var(--ink); }
.motif-seg button.on-light { background: var(--ground); color: var(--ink); }
.motif-seg button.on-dark { background: var(--ink); color: #fff; }
.motif-status { flex: none; font-size: 13px; font-weight: 600; }
.motif-status.st-auto { color: var(--soft); }
.motif-status.st-manual { color: var(--ink); }
.motif-status.st-check { color: var(--warn); }

/* ── Ablageflächen und Bildvorschau ────────────────────── */
.dropzone {
  display: block;
  margin-bottom: 16px;
  padding: 28px 20px;
  border-radius: 16px;
  background: var(--tone);
  text-align: center;
  cursor: pointer;
}
.dropzone:hover, .dropzone.drag-over { background: var(--blush); }
.dropzone:focus-within { outline: 2px solid var(--blue); outline-offset: 2px; }
.dropzone--md { margin-bottom: 0; padding: 20px; }
.dropzone--sm { margin: 0; padding: 14px; }
.dropzone-title { margin-bottom: 4px; font-size: 15px; font-weight: 600; color: var(--ink); }
.dropzone-hint { font-size: 15px; color: var(--soft); }
.dropzone-hint span { font-weight: 600; color: var(--ink); text-decoration: underline; text-underline-offset: 3px; }
.image-previews { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 16px; }
.image-preview { position: relative; width: 80px; height: 80px; overflow: hidden; border: 1px solid var(--edge); }
.image-preview img { width: 100%; height: 100%; object-fit: cover; }
.image-preview-remove {
  position: absolute;
  top: 4px;
  right: 4px;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 22px;
  height: 22px;
  border: 0;
  border-radius: 50%;
  background: rgba(11, 11, 11, .7);
  color: #fff;
  font-size: 12px;
  line-height: 1;
  cursor: pointer;
}
.image-preview-remove:hover { background: var(--error); }
.url-input-row { display: flex; flex-wrap: wrap; gap: 8px; }
.url-input-row .form-input { flex: 1 1 200px; }
.url-input-row .btn { flex-shrink: 0; }
.upload-loading { display: flex; align-items: center; gap: 8px; font-size: 15px; color: var(--soft); }

/* ── Artikelübersicht ──────────────────────────────────── */
.article-list { display: flex; flex-direction: column; gap: 8px; margin-bottom: 24px; }
.article-item {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 12px 14px;
  border: 1px solid var(--edge);
  border-radius: 12px;
  background: var(--ground);
}
.article-item-icon {
  display: flex;
  flex-shrink: 0;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  overflow: hidden;
  background: var(--blush);
  font-size: 0; /* Emoji-Platzhalter ausblenden, Bilder bleiben */
}
.article-item-info { flex: 1; min-width: 0; }
.article-item-name { font-size: 15px; font-weight: 600; overflow-wrap: anywhere; }
.article-item-meta { font-size: 14px; color: var(--soft); }
.article-item-price { font-size: 15px; font-weight: 650; font-variant-numeric: tabular-nums; }

/* ── Zusammenfassung vor dem Anlegen ───────────────────── */
.confirm-section { margin-bottom: 20px; }
.confirm-label { margin-bottom: 6px; font-size: 14px; font-weight: 600; color: var(--soft); }
.confirm-value { font-size: 15px; font-weight: 500; color: var(--ink); overflow-wrap: anywhere; }
.confirm-handle { font-size: 15px; color: var(--soft); overflow-wrap: anywhere; }

/* ── Verarbeitung ──────────────────────────────────────── */
.processing-wrap { padding: 20px 0; text-align: center; }
.processing-title { margin-bottom: 8px; font-size: 20px; font-weight: 650; letter-spacing: -.02em; }
.processing-message { font-size: 15px; color: var(--soft); }
.progress-log { margin-top: 20px; text-align: left; }
.progress-log-item { display: flex; align-items: center; gap: 8px; padding: 4px 0; font-size: 15px; color: var(--soft); }
.progress-log-item::before { content: "→"; color: var(--ink); }

/* ── Ergebnis ──────────────────────────────────────────── */
.result-hero { padding: 4px 0 24px; text-align: center; }
.result-title { margin-bottom: 6px; font-size: 24px; font-weight: 650; letter-spacing: -.03em; }
.result-subtitle { font-size: 15px; color: var(--soft); }
.result-section { margin-bottom: 20px; }
.result-section-title { margin-bottom: 10px; font-size: 16px; font-weight: 600; color: var(--ink); }
.result-link-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 6px;
  padding: 10px 14px;
  border: 1px solid var(--edge);
  border-radius: 12px;
  background: var(--ground);
}
.result-link-name { flex: 1; min-width: 0; overflow: hidden; font-size: 15px; font-weight: 500; text-overflow: ellipsis; white-space: nowrap; }
.result-link-btns { display: flex; flex-shrink: 0; gap: 6px; }
.result-link-btn {
  display: inline-flex;
  align-items: center;
  height: 30px;
  padding: 0 12px;
  border-radius: 999px;
  background: var(--muted-pale);
  color: var(--ink);
  font-size: 14px;
  font-weight: 600;
  text-decoration: none;
}
.result-link-btn:hover { background: #e7e2e0; }
.result-link-btn-front { background: var(--blue); color: #fff; }
.result-link-btn-front:hover { background: var(--blue-press); }

/* ── Sammelshop-Views (Anlegen, Bestellungen, Shops, Links, Bearbeiten) ── */
.grow { flex: 1 1 200px; min-width: 0; }
.rel { position: relative; }
.nowrap-row { flex-wrap: nowrap; }
.input-search { width: 220px; }
.input-gap { margin-top: 8px; }
.btn-gap { margin-top: 12px; }
.btn-fixed { flex: none; white-space: nowrap; }
.hint-gap { margin-bottom: 12px; }
.hint-gap-top { margin-top: 12px; }
.chips { margin-top: 6px; }
.cell-small { font-size: 14px; }
.check-row { display: flex; align-items: center; gap: 8px; cursor: pointer; }
.check-label { margin: 0; }
.form-group--after { margin-top: 16px; }
.card--gap { margin-bottom: 20px; }
.bare-fieldset { border: 0; padding: 0; min-width: 0; }
.back-link { margin: 0 0 8px -12px; }
.foreign-link { margin-left: 6px; }
.spinner--small { width: 18px; height: 18px; margin: 0; border-width: 2px; }
.modal-actions { justify-content: flex-end; margin-top: 24px; }
.modal--wide { max-width: 600px; }
.tag {
  display: inline-block;
  margin: 1px 2px 1px 0;
  padding: 1px 8px;
  border-radius: 999px;
  background: var(--muted-pale);
  font-size: 13px;
}
.select-item-meta { margin-top: 2px; font-size: 14px; }
.select-item.selected .select-checkbox::after {
  content: "";
  width: 10px;
  height: 5px;
  margin-top: -2px;
  border-left: 2px solid currentColor;
  border-bottom: 2px solid currentColor;
  transform: rotate(-45deg);
}
.suggest-list {
  position: absolute;
  z-index: 20;
  left: 0;
  right: 0;
  top: 100%;
  max-height: 260px;
  margin: 4px 0 0;
  padding: 4px;
  background: var(--ground);
  border: 1px solid var(--line);
  border-radius: 12px;
  box-shadow: var(--shadow); /* taste-skill-ignore: Vorschlagsmenü schwebt */
}

/* Meldung nach einer Aktion (mit Schließen-Knopf) */
.notice {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 20px;
  padding: 10px 14px;
  border-radius: 12px;
  font-size: 15px;
  overflow-wrap: anywhere;
}
.notice--ok { background: var(--ok-pale); color: var(--ok); }
.notice--error { background: var(--error-pale); color: var(--error); }
.notice .btn-ghost { flex: none; color: inherit; }
.notice .link { color: inherit; }

/* Combobox Schule (Bestellungen) */
.combo { position: relative; }
.combo-input { width: 240px; padding-right: 36px; }
.combo-clear {
  position: absolute;
  top: 50%;
  right: 4px;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 32px;
  height: 32px;
  border: 0;
  border-radius: 999px;
  background: none;
  font-size: 18px;
  line-height: 1;
  color: var(--soft);
  cursor: pointer;
  transform: translateY(-50%);
}
.combo-clear:hover { color: var(--ink); background: var(--muted-pale); }
.combo-menu {
  position: absolute;
  top: calc(100% + 4px);
  left: 0;
  z-index: 200;
  min-width: 100%;
  max-width: min(420px, 90vw);
  max-height: 260px;
  overflow-y: auto;
  padding: 4px;
  background: var(--ground);
  border: 1px solid var(--line);
  border-radius: 12px;
  box-shadow: var(--shadow); /* taste-skill-ignore: Menü schwebt */
}
.combo-item { padding: 8px 12px; border-radius: 8px; font-size: 15px; cursor: pointer; overflow-wrap: anywhere; }
.combo-item:hover { background: var(--panel); }
.combo-item.selected { background: var(--blush); font-weight: 600; }
.combo-item--all { color: var(--soft); }

/* Bestelltabelle */
.order-name { font-weight: 650; }
.orders-table th, .orders-table td { padding-left: 8px; padding-right: 8px; }
.cell-customer { overflow-wrap: anywhere; }
.vendor-name { display: block; font-size: 14px; color: var(--soft); overflow-wrap: break-word; }
.vendor-name + .vendor-name { margin-top: 4px; }
/* Breiten nur in der echten Tabelle; gestapelt füllen die Zellen die Zeile. */
@media (min-width: 700px) {
  .cell-customer { min-width: 140px; max-width: 210px; }
  .cell-vendors { min-width: 130px; max-width: 170px; }
  .cell-articles { min-width: 180px; max-width: 240px; }
}
.u-num .pill { display: inline-flex; margin: 4px 0 0; }

/* Erfüllen-Dialog und Änderungsliste */
.fulfill-list {
  max-height: 200px;
  margin-bottom: 16px;
  overflow-y: auto;
  border: 1px solid var(--edge);
  border-radius: 12px;
}
.fulfill-row {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 4px 12px;
  padding: 8px 12px;
  border-bottom: 1px solid var(--rule); /* taste-skill-ignore: Tabellenzeile in der Erfüllen-Liste (App-Liste mit Linien, wie .table) */
  font-size: 15px;
}
.fulfill-row:last-child { border-bottom: 0; }
.fulfill-name { font-weight: 650; }
.code-cap { margin-bottom: 6px; font-size: 14px; font-weight: 600; color: var(--soft); }
.code-block {
  margin: 0;
  padding: 10px 12px;
  overflow-x: auto;
  border: 1px solid var(--edge);
  border-radius: 10px;
  background: var(--panel);
  font-family: ui-monospace, "SFMono-Regular", Menlo, Consolas, monospace;
  font-size: 13px;
}
.code-block--list { max-height: 200px; margin-bottom: 16px; overflow-y: auto; }
.code-group { margin-bottom: 12px; }
.code-id { margin-bottom: 4px; word-break: break-all; }
.code-line { padding-left: 12px; }
.change-list { margin: 0 0 8px; padding: 0; list-style: none; font-size: 15px; }
.change-list li { padding: 8px 0; border-bottom: 1px solid var(--rule); overflow-wrap: anywhere; } /* taste-skill-ignore: Zeilen der Änderungsliste im Dialog (App-Liste mit Linien, wie .table) */
.change-list li:last-child { border-bottom: 0; }
.change-list li.is-skipped { color: var(--soft); }
.change-list li.is-blocking { color: var(--error); }
.change-list .change-note, .form-hint.change-note { color: var(--warn); }
.change-list--log { margin-bottom: 0; }
.change-list--log li { padding: 4px 0; border: 0; }
.change-list--log .pill { margin-right: 6px; }
.after-log { margin-top: 12px; }

/* Shop bearbeiten */
.article-item.removed { opacity: .5; }
.article-item.removed .article-item-name,
.article-item.removed .article-item-meta { text-decoration: line-through; }
.article-item-icon { position: relative; }
.article-item-icon img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; background: var(--blush); }
.article-item > .btn { flex: none; }
.article-item .article-item-price { margin-left: auto; }
.article-edit { padding: 16px 4px 8px; }
.shop-flags { display: flex; flex-wrap: wrap; gap: 8px 20px; margin-bottom: 12px; }
.article-flags { display: flex; flex-wrap: wrap; gap: 4px 18px; margin-top: 6px; font-size: 14px; }
.article-flags .check-row { gap: 6px; }

/* Dialog mit Kopfzeile und Schließen-Knopf; auf dem Handy ein Vollbild-Blatt */
.modal-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 12px; }
.modal-head h2 { margin-bottom: 8px; }
.modal-x {
  display: inline-flex;
  flex: none;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  margin: -8px -10px 0 0;
  border: 0;
  border-radius: 999px;
  background: none;
  color: var(--ink);
  cursor: pointer;
}
.modal-x:hover { background: rgba(11, 11, 11, .05); }
.unlock-options { margin-top: 16px; }
.unlock-option { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 10px 16px; padding: 14px; border-radius: 12px; background: var(--panel); }
.unlock-option-text { flex: 1 1 200px; min-width: 0; font-size: 15px; }
.unlock-option > .btn { flex: none; }
.unlock-option-date { display: flex; flex-wrap: wrap; gap: 8px; flex: 1 1 100%; }
.unlock-option-date .form-input { flex: 1 1 160px; width: auto; min-width: 0; }
.unlock-option-date .btn { flex: none; }
@media (max-width: 640px) {
  .modal-overlay--sheet { padding: 0; align-items: stretch; }
  .modal-overlay--sheet .modal { max-width: none; max-height: none; height: 100dvh; border-radius: 0; box-shadow: none; }
  .unlock-option > .btn, .unlock-option-date .btn { flex: 1 1 100%; }
}
.color-image { display: flex; flex-direction: column; align-items: center; gap: 4px; }

/* Platzhalter für Artikel ohne Bild: T-Shirt-Symbol auf Blush */
.shirt-ph {
  width: 60%;
  height: 60%;
  background-color: var(--soft);
  -webkit-mask: no-repeat center / contain url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M8 3 3 6l2 4 2-1v12h10V9l2 1 2-4-5-3c-.5 1.5-2 2.5-4 2.5S8.5 4.5 8 3Z'/%3E%3C/svg%3E");
          mask: no-repeat center / contain url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M8 3 3 6l2 4 2-1v12h10V9l2 1 2-4-5-3c-.5 1.5-2 2.5-4 2.5S8.5 4.5 8 3Z'/%3E%3C/svg%3E");
}
.link-cell { flex-wrap: nowrap; min-width: 0; }
.link-url { min-width: 0; max-width: 260px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: 14px; }
.row-acts .btn { margin-left: 6px; }

/* ── Video-Tool ────────────────────────────────────────── */
.vt-root { position: relative; max-width: 720px; }
.vt-steps { display: flex; align-items: center; max-width: 420px; margin: 0 0 28px; }
/* Ablagefläche: ein echter Button, damit sie per Tastatur erreichbar ist. */
.vt-drop {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
  width: 100%;
  padding: 56px 24px;
  border: 0;
  border-radius: 16px;
  background: var(--tone);
  font-family: var(--font);
  cursor: pointer;
}
.vt-drop:hover { background: var(--blush); }
.vt-drop:focus-visible { outline: 2px solid var(--blue); outline-offset: 2px; }
.vt-drop-badge {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 72px;
  height: 72px;
  border-radius: 50%;
  background: var(--ground);
  color: var(--ink);
  transition: transform .18s ease;
}
.vt-drop:hover .vt-drop-badge { transform: translateY(-2px); }
.vt-drop-title { font-size: 18px; font-weight: 650; color: var(--ink); }
.vt-drop-sub { font-size: 15px; color: var(--soft); }
.vt-drop-sub span { font-weight: 600; color: var(--ink); text-decoration: underline; text-underline-offset: 3px; }
.vt-drop-formats { margin-top: 2px; font-size: 14px; color: var(--soft); }
/* Beim Ziehen wird die ganze Spalte zur Ablagefläche. */
.vt-overlay {
  position: absolute;
  inset: -10px;
  z-index: 30;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 6px;
  border: 2px solid var(--blue);
  border-radius: 16px;
  background: var(--blush);
  pointer-events: none;
}
.vt-overlay-title { font-size: 20px; font-weight: 650; color: var(--ink); }
.vt-overlay-sub { font-size: 15px; color: var(--ink); }
.vt-card { padding: 24px; border-radius: 16px; background: var(--panel); }
.vt-filename { display: flex; align-items: center; gap: 10px; font-size: 15px; font-weight: 650; color: var(--ink); word-break: break-all; }
.vt-meta { margin-top: 6px; font-size: 15px; color: var(--soft); }
.vt-chips { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 14px; }
.vt-chip {
  display: inline-flex;
  align-items: center;
  height: 24px;
  padding: 0 10px;
  border-radius: 999px;
  background: var(--muted-pale);
  color: var(--muted);
  font-size: 13px;
  font-weight: 600;
  white-space: nowrap;
}
.vt-chip-ok { background: var(--ok-pale); color: var(--ok); }
.vt-warn {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  margin-top: 14px;
  padding: 12px 14px;
  border-radius: 12px;
  background: var(--warn-pale);
  color: var(--warn);
  font-size: 15px;
}
.vt-bar-head { display: flex; align-items: baseline; justify-content: space-between; gap: 12px; margin-bottom: 10px; }
.vt-bar-label { font-size: 15px; font-weight: 650; }
.vt-bar-value { font-size: 15px; font-weight: 650; font-variant-numeric: tabular-nums; }
.vt-bar { height: 6px; overflow: hidden; border-radius: 999px; background: var(--tone); }
.vt-bar-fill { height: 100%; border-radius: 999px; background: var(--blue); }
.vt-bar-hint { margin-top: 12px; font-size: 15px; color: var(--soft); }
.vt-result { display: flex; flex-wrap: wrap; align-items: baseline; gap: 12px; }
.vt-size-new { font-size: 26px; font-weight: 650; letter-spacing: -.03em; color: var(--ink); font-variant-numeric: tabular-nums; }
.vt-size-old { font-size: 15px; color: var(--soft); text-decoration: line-through; }
.vt-done-note { margin-top: 4px; font-size: 15px; color: var(--soft); }
.vt-actions { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 20px; }

/* ── POD-Shop, Verwaltung, Tools, Einstellungen ───────── */
.input-days { width: 120px; }
.toolbar--gap { margin-bottom: 20px; }
.tnum { font-variant-numeric: tabular-nums; }
.count-line { margin-top: 12px; font-size: 15px; }
.row-click { cursor: pointer; }
.chevron { display: inline-block; width: 14px; color: var(--soft); }
.akd-positions { background: var(--panel); }
.akd-pos { padding: 2px 0; font-size: 15px; }
.akd-pos-qty { display: inline-block; min-width: 36px; }
code { font-family: ui-monospace, "SFMono-Regular", Menlo, Consolas, monospace; font-size: 14px; }
.form-group--flush { margin-bottom: 0; }
.card--stack { margin-top: 16px; }
.step-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 12px; margin-bottom: 24px; }
.step-head .card-title { margin: 0; font-size: 18px; }
.step-head .card-subtitle { margin: 2px 0 0; overflow-wrap: anywhere; }
.card-title--step { margin-bottom: 16px; font-size: 18px; }
.grid-2 { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 0 16px; }
.grid-2--wide { gap: 16px 20px; }
.grid-2--tight { gap: 10px; }
.grid-stack { display: grid; gap: 10px; }
.color-grid--flush { margin-bottom: 0; }
.u-accent { color: var(--blue); }
.row-between { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 8px 12px; margin-bottom: 12px; }
.row-between--tight { margin-bottom: 6px; }
.mb-6 { margin-bottom: 6px; }
.color-block { margin-bottom: 14px; }
.image-previews--center { justify-content: center; margin: 0; }
.motif-ctl { display: flex; flex: none; align-items: center; gap: 8px; }

/* ── Rückmeldung unter der Hand ────────────────────────
   Farbwechsel weich (180 ms), Drücken gibt kurz nach (150 ms, nur transform).
   Fokus zeigt überall der blaue Ring aus brand.css (:focus-visible). */
.menu-btn, .sidebar-close, .sidebar-group, .sidebar-nav-item, .tab, .btn-ghost, .cell-link,
.mode-card, .select-item, .color-swatch, .motif-seg button, .dropzone, .image-preview-remove,
.result-link-btn, .combo-clear, .combo-item, .vt-drop, .seg-opt, .th-sort,
.table td {
  transition: background-color var(--t-hover) ease, color var(--t-hover) ease, border-color var(--t-hover) ease, transform var(--t-press) var(--ease-out);
}
.menu-btn:active, .sidebar-close:active, .btn-ghost:active, .image-preview-remove:active,
.result-link-btn:active, .motif-seg button:active, .seg-opt:active { transform: scale(.96); }
.mode-card:active, .select-item:active, .color-swatch:not(.disabled):active, .dropzone:active, .vt-drop:active { transform: scale(.985); }
.sidebar-nav-item:active { background: rgba(11, 11, 11, .07); }
.tab:active { color: var(--ink); }

/* Dialoge erscheinen aus der Mitte: Fläche blendet ein, der Dialog steigt leicht auf. */
@keyframes dialog-in {
  from { opacity: 0; transform: translateY(8px) scale(.97); }
  to { opacity: 1; transform: none; }
}
.modal-overlay { animation: rise-fade 200ms ease-out backwards; }
.modal { animation: dialog-in 240ms var(--ease-out) backwards; }

/* ════════════════════════════════════════════════════════
   Handy und Tablet (< 900 px): kein Rahmen, das Blatt ist der Bildschirm,
   die Sidebar öffnet als Ebene über dem Inhalt.
   ════════════════════════════════════════════════════════ */
@media (max-width: 899px) {
  .app-shell { grid-template-columns: minmax(0, 1fr); }
  .topbar { position: sticky; top: 0; z-index: 40; padding: 0 12px 0 4px; background: var(--frame); }
  .menu-btn, .sidebar-close { display: inline-flex; }
  .topbar-staging { display: inline-flex; }
  .sheet { margin: 0; border: 0; border-radius: 0; padding: 20px 16px 40px; }

  .sidebar {
    position: fixed;
    top: 0;
    bottom: 0;
    left: 0;
    z-index: 60;
    width: min(300px, 86vw);
    height: auto;
    padding-top: 6px;
    box-shadow: var(--shadow-lg); /* taste-skill-ignore: Ebene über dem Inhalt */
    visibility: hidden;
    transform: translateX(-100%);
    transition: transform .25s cubic-bezier(.2, .7, .2, 1), visibility 0s linear .25s;
  }
  .sidebar-logo { padding-top: 14px; }
  .app-shell.menu-open .sidebar {
    visibility: visible;
    transform: none;
    transition: transform .25s cubic-bezier(.2, .7, .2, 1);
  }
  .sidebar-nav-item { min-height: 44px; }
  .sidebar-backdrop {
    position: fixed;
    inset: 0;
    z-index: 55;
    display: block;
    background: rgba(11, 11, 11, .35);
    opacity: 0;
    visibility: hidden;
    transition: opacity .25s ease, visibility 0s linear .25s;
  }
  .app-shell.menu-open .sidebar-backdrop { opacity: 1; visibility: visible; transition: opacity .25s ease; }

  .btn { min-height: 44px; }
  .btn.btn--small { min-height: 36px; }
  .form-input { min-height: 44px; font-size: 16px; }
  .page-head h1 { font-size: 24px; }

  .setrow { grid-template-columns: minmax(0, 1fr); gap: 12px; }
  .card, .vt-card { padding: 20px 16px; }
  .modal { padding: 22px 18px; }
}

@media (max-width: 899px) {
  .sel-new { grid-template-columns: minmax(0, 1fr); gap: 12px; }
  .row-acts { text-align: left; }
  .row-acts .btn { margin: 0 6px 0 0; }
  .row-acts .link { margin: 0 14px 0 0; }
}

@media (max-width: 640px) {
  .grid-2:not(.grid-2--tight) { grid-template-columns: minmax(0, 1fr); }
  .article-item { flex-wrap: wrap; }
  .article-item-info { flex: 1 1 calc(100% - 60px); }
  .article-item .article-item-price { margin-left: 0; }
  .combo, .combo-input, .input-search { width: 100%; }
  .mode-grid { grid-template-columns: minmax(0, 1fr); }
  .vt-drop { padding: 40px 16px; }
  .progress-label { white-space: normal; text-align: center; }
}

/* Weniger Bewegung: nichts wandert oder wird gedrückt; Farbwechsel und
   reines Einblenden (opacity) bleiben. */
@media (prefers-reduced-motion: reduce) {
  .sidebar, .app-shell.menu-open .sidebar,
  .sidebar-section-chevron, .vt-drop-badge, .cm-card { transition: none; }
  .vt-drop:hover .vt-drop-badge { transform: none; }
  .menu-btn:active, .sidebar-close:active, .btn-ghost:active, .image-preview-remove:active,
  .result-link-btn:active, .motif-seg button:active, .seg-opt:active,
  .mode-card:active, .select-item:active, .color-swatch:not(.disabled):active, .dropzone:active, .vt-drop:active { transform: none; }
  .modal { animation: rise-fade 200ms ease-out backwards; }
  .list-spinner, .spinner { animation-duration: 2.4s; }
}
