/* ============================================================
   FelgenOase Panel – Modern Theme
   ============================================================ */

@font-face {
  font-family: 'Inter';
  src: url('fonts/inter-variable.woff2') format('woff2') tech(variations);
  font-weight: 100 900;
  font-style: normal;
  font-display: swap;
}

:root {
  --fo-primary: #4f46e5;
  --fo-primary-dark: #4338ca;
  --fo-primary-soft: #eef2ff;
  --fo-primary-border: #c7d2fe;
  --fo-bg: #f3f4f8;
  --fo-surface: #ffffff;
  --fo-border: #e6e8f0;
  --fo-text: #1f2433;
  --fo-muted: #6b7280;
  --fo-sidebar: #0e1525;
  --fo-radius: .75rem;
  --fo-radius-sm: .55rem;
  --fo-shadow: 0 1px 2px rgba(16, 24, 40, .05), 0 1px 3px rgba(16, 24, 40, .07);
  --fo-shadow-lg: 0 8px 24px rgba(16, 24, 40, .12);
}

body {
  background: var(--fo-bg);
  color: var(--fo-text);
  font-family: 'Inter', system-ui, -apple-system, 'Segoe UI', sans-serif;
  font-size: .925rem;
}

h1, h2, h3, h4, h5, .h1, .h2, .h3, .h4, .h5 { font-weight: 700; letter-spacing: -.01em; }

a { color: var(--fo-primary); }
a:hover { color: var(--fo-primary-dark); }

main { min-width: 0; }

/* ---------- Sidebar & Topbar ---------- */

.sidebar {
  width: 248px;
  min-height: 100vh;
  flex-shrink: 0;
  background: linear-gradient(180deg, #111a2e 0%, var(--fo-sidebar) 100%);
  color: #cbd2e0;
}
@media (max-width: 991.98px) {
  .sidebar { min-height: auto; background: var(--fo-sidebar); }
}

.fo-brand {
  display: flex;
  align-items: center;
  gap: .6rem;
  margin: .25rem 0 1.25rem;
  font-size: 1.05rem;
  font-weight: 700;
  color: #fff;
  text-decoration: none;
  letter-spacing: -.01em;
}
.fo-brand:hover { color: #fff; }
.fo-brand em { color: #FF6B1A; font-style: normal; }

.fo-brand-topbar {
  display: flex;
  align-items: center;
  gap: .5rem;
  font-size: .95rem;
  font-weight: 700;
  color: #fff;
  text-decoration: none;
  letter-spacing: -.01em;
}
.fo-brand-topbar:hover { color: #fff; }
.fo-brand-topbar em { color: #FF6B1A; font-style: normal; }

.fo-brand-mark {
  width: 34px;
  height: 34px;
  flex-shrink: 0;
  display: inline-grid;
  place-items: center;
  border-radius: .6rem;
  background: linear-gradient(135deg, #6366f1, #4338ca);
  color: #fff;
  font-size: 1.05rem;
  box-shadow: 0 4px 10px rgba(79, 70, 229, .4);
}

.fo-nav-label {
  font-size: .68rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: .09em;
  color: #64748b;
  margin: 0 .35rem .45rem;
}

/* ---------- Omni-Search ---------- */

.fo-omnisearch-wrap { position: relative; }

.fo-omnisearch-inner {
  display: flex;
  align-items: center;
  background: rgba(255,255,255,.07);
  border: 1px solid rgba(255,255,255,.12);
  border-radius: .55rem;
  padding: 0 .6rem;
  gap: .45rem;
  transition: border-color .15s, background .15s;
}
.fo-omnisearch-inner:focus-within {
  background: rgba(255,255,255,.12);
  border-color: rgba(255,255,255,.28);
}
.fo-omnisearch-icon { color: #94a3b8; font-size: .85rem; flex-shrink: 0; }
.fo-omnisearch-input {
  flex: 1; background: transparent; border: none; outline: none;
  color: #e2e8f0; font-size: .82rem; padding: .42rem 0; width: 100%;
}
.fo-omnisearch-input::placeholder { color: #64748b; }
.fo-omnisearch-input::-webkit-search-cancel-button { display: none; }
.fo-omnisearch-kbd {
  background: rgba(255,255,255,.08); border: 1px solid rgba(255,255,255,.14);
  border-radius: .3rem; color: #94a3b8; font-size: .65rem;
  padding: .1rem .35rem; white-space: nowrap; flex-shrink: 0;
}
.fo-omnisearch-dropdown {
  position: absolute; top: calc(100% + .35rem); left: 0;
  width: 520px;
  background: #1e293b; border: 1px solid rgba(255,255,255,.1);
  border-radius: .6rem; list-style: none; margin: 0; padding: .25rem 0;
  z-index: 9999; box-shadow: 0 12px 32px rgba(0,0,0,.5);
  max-height: 360px; overflow-y: auto;
}
@media (max-width: 991.98px) {
  .fo-omnisearch-dropdown { width: 100%; }
}
.fo-omni-item {
  display: flex; align-items: flex-start; gap: .6rem;
  padding: .5rem .75rem; color: #cbd2e0; text-decoration: none;
  font-size: .82rem; transition: background .1s;
}
.fo-omni-item:hover, li.active .fo-omni-item { background: rgba(255,255,255,.07); color: #fff; }
.fo-omni-icon { font-size: 1rem; color: #4f46e5; flex-shrink: 0; width: 1.2rem; text-align: center; }
.fo-omni-text { display: flex; flex-direction: column; min-width: 0; }
.fo-omni-titel { font-weight: 500; white-space: normal; word-break: break-word; }
.fo-omni-sub { font-size: .73rem; color: #64748b; }
.fo-omni-empty { padding: .6rem .75rem; color: #64748b; font-size: .82rem; }

/* Farbakzent je Ergebnistyp */
li[data-typ] .fo-omni-item { border-left: 3px solid transparent; padding-left: calc(.75rem - 3px); }
li[data-typ="aktiv"]  .fo-omni-item { border-left-color: #22c55e; }
li[data-typ="aktiv"]  .fo-omni-icon  { color: #22c55e; }
li[data-typ="felge"]  .fo-omni-item { border-left-color: #e2e8f0; }
li[data-typ="felge"]  .fo-omni-icon  { color: #e2e8f0; }
li[data-typ="reifen"] .fo-omni-item { border-left-color: #475569; }
li[data-typ="reifen"] .fo-omni-icon  { color: #94a3b8; }

/* ---------- Nav Links ---------- */

.fo-nav-link {
  display: flex;
  align-items: center;
  gap: .65rem;
  padding: .55rem .75rem;
  border-radius: var(--fo-radius-sm);
  color: #aab3c5;
  text-decoration: none;
  font-weight: 500;
  transition: background .12s ease, color .12s ease;
}
.fo-nav-link .bi { font-size: 1.02rem; width: 1.2rem; text-align: center; }
.fo-nav-link:hover { background: rgba(255, 255, 255, .07); color: #fff; }
.fo-nav-link.active {
  background: linear-gradient(90deg, #4f46e5, #5b54f0);
  color: #fff;
  box-shadow: 0 4px 12px rgba(79, 70, 229, .35);
}
.fo-order-badge { font-size: .65rem; padding: .2em .4em; min-width: 1.3em; line-height: 1.3; }

.fo-version-btn {
  background: none; border: none; padding: 0;
  font-size: .68rem; color: #9ca3af; cursor: pointer;
  letter-spacing: .03em; transition: color .15s;
}
.fo-version-btn:hover { color: #6b7280; }
[data-bs-theme="dark"] .fo-version-btn { color: #4b5563; }
[data-bs-theme="dark"] .fo-version-btn:hover { color: #9ca3af; }

.fo-about-logo-link { display: block; opacity: .85; transition: opacity .15s; }
.fo-about-logo-link:hover { opacity: 1; }
.fo-about-logo { height: 36px; width: auto; max-width: 110px; object-fit: contain; }

.fo-sidebar-user {
  display: flex;
  align-items: center;
  gap: .6rem;
  padding-top: .9rem;
  border-top: 1px solid rgba(255, 255, 255, .08);
  font-size: .85rem;
}
.fo-sidebar-user > .bi { font-size: 1.5rem; color: #8b96ab; }
.fo-sidebar-username { font-weight: 600; color: #e3e7ef; }
.fo-sidebar-user a { color: #8b96ab; text-decoration: none; font-size: .8rem; }
.fo-sidebar-user a:hover { color: #fff; }

.fo-topbar {
  background: var(--fo-sidebar);
}
.fo-topbar .navbar-brand { color: #fff; font-weight: 700; display: flex; align-items: center; gap: .5rem; }
.fo-topbar .navbar-toggler { border-color: rgba(255, 255, 255, .2); color: #fff; }
.fo-topbar .navbar-toggler-icon {
  background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 30 30'%3e%3cpath stroke='rgba(255,255,255,.85)' stroke-linecap='round' stroke-miterlimit='10' stroke-width='2' d='M4 7h22M4 15h22M4 23h22'/%3e%3c/svg%3e");
}
.fo-topbar-link { color: #cbd2e0; font-size: 1.2rem; text-decoration: none; }
.fo-topbar-link:hover { color: #fff; }

/* Offcanvas (mobiles Menü) dunkel halten */
@media (max-width: 991.98px) {
  .offcanvas-lg.sidebar { background: var(--fo-sidebar); }
}

/* ---------- Karten ---------- */

.card {
  border: 1px solid var(--fo-border);
  border-radius: var(--fo-radius);
  box-shadow: var(--fo-shadow);
}
.card.shadow-sm { box-shadow: var(--fo-shadow) !important; }

.card > .card-header {
  background: transparent;
  font-weight: 600;
  border-bottom: 1px solid var(--fo-border);
  padding: .8rem 1rem;
}
.card > .card-header .bi { color: var(--fo-primary); }

/* ---------- Buttons & Formulare ---------- */

.btn { border-radius: var(--fo-radius-sm); font-weight: 500; }
.btn-lg { border-radius: .65rem; }

.btn-primary {
  --bs-btn-bg: var(--fo-primary);
  --bs-btn-border-color: var(--fo-primary);
  --bs-btn-hover-bg: var(--fo-primary-dark);
  --bs-btn-hover-border-color: var(--fo-primary-dark);
  --bs-btn-active-bg: var(--fo-primary-dark);
  --bs-btn-active-border-color: var(--fo-primary-dark);
  --bs-btn-disabled-bg: var(--fo-primary);
  --bs-btn-disabled-border-color: var(--fo-primary);
  box-shadow: 0 2px 6px rgba(79, 70, 229, .3);
}

.btn-outline-primary {
  --bs-btn-color: var(--fo-primary);
  --bs-btn-border-color: var(--fo-primary-border);
  --bs-btn-hover-bg: var(--fo-primary);
  --bs-btn-hover-border-color: var(--fo-primary);
  --bs-btn-active-bg: var(--fo-primary);
  --bs-btn-active-border-color: var(--fo-primary);
}

.btn-check:checked + .btn-outline-primary {
  background: var(--fo-primary);
  border-color: var(--fo-primary);
  color: #fff;
  box-shadow: 0 2px 6px rgba(79, 70, 229, .3);
}

.form-control, .form-select {
  border-radius: var(--fo-radius-sm);
  border-color: var(--fo-border);
}
.form-control:focus, .form-select:focus {
  border-color: #a5b4fc;
  box-shadow: 0 0 0 .22rem rgba(79, 70, 229, .14);
}
.form-check-input:checked { background-color: var(--fo-primary); border-color: var(--fo-primary); }
.form-check-input:focus { box-shadow: 0 0 0 .2rem rgba(79, 70, 229, .14); }

.form-label { font-weight: 500; margin-bottom: .3rem; }
.form-text { color: var(--fo-muted); }

input[type=number] { max-width: 10rem; }

.dropdown-menu {
  border-radius: var(--fo-radius-sm);
  border-color: var(--fo-border);
  box-shadow: var(--fo-shadow-lg);
}

.nav-tabs .nav-link { color: var(--fo-muted); font-weight: 500; }
.nav-tabs .nav-link.active { color: var(--fo-primary); font-weight: 600; }

.pagination {
  --bs-pagination-color: var(--fo-primary);
  --bs-pagination-active-bg: var(--fo-primary);
  --bs-pagination-active-border-color: var(--fo-primary);
  --bs-pagination-hover-color: var(--fo-primary-dark);
}

/* ---------- Tabellen ---------- */

.table-responsive {
  background: var(--fo-surface);
  border: 1px solid var(--fo-border);
  border-radius: var(--fo-radius);
  box-shadow: var(--fo-shadow);
}

.table { --bs-table-hover-bg: #f7f8ff; }
.table > thead th {
  font-size: .76rem;
  text-transform: uppercase;
  letter-spacing: .05em;
  color: var(--fo-muted);
  background: #f9fafc;
  border-bottom: 1px solid var(--fo-border);
  padding: .6rem .75rem;
  white-space: nowrap;
}
.table > tbody td, .table > tbody th { padding: .55rem .75rem; }
.table > tbody tr.fo-order-unread > td {
  background: #fff7ed !important;
  border-bottom-color: rgba(234, 88, 12, .2);
}
.table > tbody tr.fo-order-unread:hover > td { background: #ffedd5 !important; }
.table > tbody tr.fo-order-unread > td:first-child {
  box-shadow: inset 4px 0 0 #f97316;
}
/* Offener Storno/Widerruf: rote Hervorhebung (hat Vorrang vor „ungelesen") */
.table > tbody tr.fo-order-storno > td {
  background: #fef2f2 !important;
  border-bottom-color: rgba(220, 38, 38, .2);
}
.table > tbody tr.fo-order-storno:hover > td { background: #fee2e2 !important; }
.table > tbody tr.fo-order-storno > td:first-child {
  box-shadow: inset 4px 0 0 #dc2626;
}
/* Neu eingegangene Bestellung/Storno live hervorheben (kurzes Aufleuchten) */
.table > tbody tr.fo-order-new > td {
  animation: fo-order-flash 4s ease-out 1;
}
@keyframes fo-order-flash {
  0%, 35% { box-shadow: inset 0 0 0 9999px rgba(34, 197, 94, .26); }
  100%    { box-shadow: inset 0 0 0 9999px rgba(34, 197, 94, 0); }
}

/* ---------- Manuelle Bestellung: Positionserfassung ---------- */

.fo-manual-search,
.fo-manual-lines,
.fo-manual-lines * {
  min-width: 0;
}

.fo-manual-lines-wrap {
  overflow: visible;
}

.fo-manual-lines {
  table-layout: fixed;
  margin-bottom: 0;
}

.fo-manual-lines th:nth-child(1) { width: 36%; }
.fo-manual-lines th:nth-child(2) { width: 9%; }
.fo-manual-lines th:nth-child(3) { width: 12%; }
.fo-manual-lines th:nth-child(4) { width: 11%; }
.fo-manual-lines th:nth-child(5) { width: 13%; }
.fo-manual-lines th:nth-child(6) { width: 13%; }
.fo-manual-lines th:nth-child(7) { width: 6%; }

.fo-manual-lines .form-control,
.fo-manual-lines .form-select {
  width: 100%;
}

.fo-manual-lines .fo-manual-pos input {
  text-overflow: ellipsis;
}

.fo-manual-lines .fo-manual-sum {
  overflow-wrap: normal;
  white-space: nowrap;
}

@media (max-width: 1599.98px) {
  .fo-manual-lines-wrap {
    overflow: visible !important;
    border: 0;
    box-shadow: none;
    background: transparent;
  }

  .fo-manual-lines,
  .fo-manual-lines tbody,
  .fo-manual-lines tfoot {
    display: block;
    width: 100%;
  }

  .fo-manual-lines thead {
    display: none;
  }

  .fo-manual-lines tbody tr {
    position: relative;
    display: grid;
    grid-template-columns: repeat(5, minmax(6.4rem, 1fr)) 2.35rem;
    gap: .55rem;
    align-items: end;
    padding: .75rem;
    margin-bottom: .7rem;
    border: 1px solid var(--fo-border);
    border-radius: var(--fo-radius-sm);
    background: var(--fo-surface);
    box-shadow: var(--fo-shadow);
  }

  .fo-manual-lines tbody td {
    display: block;
    padding: 0 !important;
    border: 0 !important;
  }

  .fo-manual-lines tbody td[data-label]::before {
    content: attr(data-label);
    display: block;
    margin-bottom: .22rem;
    color: var(--fo-muted);
    font-size: .66rem;
    font-weight: 700;
    line-height: 1.2;
    letter-spacing: .05em;
    text-transform: uppercase;
  }

  .fo-manual-lines tbody .fo-manual-pos::before,
  .fo-manual-lines tbody .fo-manual-action::before {
    display: none;
  }

  .fo-manual-lines .fo-manual-action {
    align-self: center;
  }

  .fo-manual-lines .fo-manual-pos {
    grid-column: 1 / -2;
  }

  .fo-manual-lines .fo-manual-action {
    grid-column: -2 / -1;
    grid-row: 1;
    justify-self: end;
  }

  .fo-manual-lines .fo-manual-action .btn {
    width: 2.35rem;
    height: 2.35rem;
    display: inline-grid;
    place-items: center;
    padding: 0;
  }

  .fo-manual-lines tfoot tr {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(8.5rem, 12rem);
    gap: .75rem;
    align-items: center;
    padding: .55rem .75rem;
    border-top: 1px solid var(--fo-border);
  }

  .fo-manual-lines tfoot td {
    display: block;
    padding: 0 !important;
    border: 0 !important;
    white-space: nowrap;
  }

  .fo-manual-lines tfoot td[colspan] {
    text-align: right !important;
  }

  .fo-manual-lines tfoot td:last-child:empty {
    display: none;
  }
}

@media (max-width: 575.98px) {
  .fo-manual-search .input-group {
    display: grid;
    grid-template-columns: auto minmax(0, 1fr);
  }

  .fo-manual-search .input-group-text {
    border-radius: var(--fo-radius-sm) 0 0 var(--fo-radius-sm) !important;
  }

  .fo-manual-search .form-control {
    border-radius: 0 var(--fo-radius-sm) var(--fo-radius-sm) 0 !important;
    font-size: 1rem;
  }

  .fo-manual-search .btn {
    grid-column: 1 / -1;
    width: 100%;
    margin-top: .5rem;
    border-radius: var(--fo-radius-sm) !important;
  }

  .fo-manual-lines tbody tr {
    grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
    gap: .65rem .55rem;
    padding: .7rem 3.65rem .7rem .7rem;
  }

  .fo-manual-lines .fo-manual-pos {
    grid-column: 1 / -1;
  }

  .fo-manual-lines .fo-manual-action {
    position: absolute;
    top: .7rem;
    right: .7rem;
  }

  .fo-manual-lines .fo-manual-sum {
    align-self: end;
    text-align: right !important;
  }

  .fo-manual-lines tfoot tr {
    grid-template-columns: minmax(0, 1fr) minmax(9.25rem, 50%);
    padding-inline: .15rem;
  }

  .fo-manual-lines tfoot .fs-5 {
    font-size: 1rem !important;
  }
}

/* ---------- Badges (weiche, moderne Töne) ---------- */

.badge { font-weight: 600; border-radius: .45rem; padding: .34em .6em; }

.badge.text-bg-success   { background: #dcfce7 !important; color: #15803d !important; }
.badge.text-bg-secondary { background: #eef0f4 !important; color: #4b5563 !important; }
.badge.text-bg-info      { background: #e0f2fe !important; color: #0369a1 !important; }
.badge.text-bg-warning   { background: #fef3c7 !important; color: #b45309 !important; }
.badge.text-bg-danger    { background: #fee2e2 !important; color: #b91c1c !important; }
.badge.text-bg-dark      { background: #e5e7eb !important; color: #374151 !important; }

.fo-badge-primary { background: var(--fo-primary-soft); color: var(--fo-primary); }

/* ---------- Flash-Meldungen ---------- */

.alert { border-radius: var(--fo-radius-sm); }

/* ---------- Karten-Ansicht für Artikel auf kleinen Bildschirmen ---------- */

.fo-card-list .card + .card { margin-top: .75rem; }

/* ---------- KPI-Kacheln ---------- */

.fo-live-card {
  overflow: hidden;
}
.fo-live-card .card-header {
  background: var(--fo-surface);
}
.fo-live-pulse {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: #22c55e;
  box-shadow: 0 0 0 5px rgba(34, 197, 94, .14);
  flex: 0 0 auto;
}
.fo-live-header { position: relative; }
.fo-live-empty {
  position: absolute;
  left: 50%;
  top: 50%;
  transform: translate(-50%, -50%);
  display: inline-flex;
  align-items: center;
  gap: .35rem;
  color: var(--fo-muted);
  font-size: .8rem;
  font-weight: 500;
  line-height: 1;
  white-space: nowrap;
  pointer-events: none;
}
@media (max-width: 575.98px) {
  .fo-live-empty { position: static; transform: none; }
}
.fo-live-empty i {
  font-size: 1rem;
  line-height: 1;
  color: #22c55e;
}
.fo-live-feed {
  display: grid;
}
.fo-live-item {
  display: grid;
  grid-template-columns: 42px minmax(0, 1fr) auto;
  gap: .8rem;
  align-items: center;
  padding: .8rem .95rem;
  color: inherit;
  text-decoration: none;
  border-top: 1px solid var(--fo-border);
  background: var(--fo-surface);
  transition: background .16s ease, transform .16s ease, box-shadow .16s ease;
}
.fo-live-item:hover {
  background: #f8fafc;
  transform: translateY(-1px);
}
.fo-live-item.is-new {
  animation: foLiveIn .75s ease both;
}
.fo-live-icon {
  width: 38px;
  height: 38px;
  display: inline-grid;
  place-items: center;
  border-radius: .7rem;
  font-size: 1.05rem;
}
.fo-live-icon-info { color: #0369a1; background: #e0f2fe; }
.fo-live-icon-warning { color: #b45309; background: #fef3c7; }
.fo-live-icon-danger { color: #b91c1c; background: #fee2e2; }
.fo-live-main {
  min-width: 0;
  display: grid;
  gap: .12rem;
}
.fo-live-top {
  display: flex;
  align-items: center;
  gap: .45rem;
  min-width: 0;
}
.fo-live-title {
  font-weight: 800;
  line-height: 1.2;
}
.fo-live-text,
.fo-live-meta {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.fo-live-text {
  font-weight: 650;
}
.fo-live-meta {
  color: var(--fo-muted);
  font-size: .82rem;
}
.fo-live-side {
  display: grid;
  justify-items: end;
  gap: .12rem;
  min-width: 6.5rem;
}
.fo-live-sum {
  font-weight: 800;
  white-space: nowrap;
}
.fo-live-time {
  color: var(--fo-muted);
  font-size: .8rem;
  white-space: nowrap;
}
@keyframes foLiveIn {
  from {
    background: #fff7ed;
    box-shadow: inset 4px 0 0 #f97316;
  }
  to {
    background: var(--fo-surface);
    box-shadow: inset 0 0 0 transparent;
  }
}

.fo-kpi {
  background: var(--fo-surface);
  border: 1px solid var(--fo-border);
  border-radius: var(--fo-radius);
  padding: .6rem .7rem;
  box-shadow: var(--fo-shadow);
  height: 100%;
  gap: .55rem !important;
}
.fo-kpi .fs-3 { font-weight: 800; letter-spacing: -.02em; }

.fo-kpi-icon {
  width: 34px;
  height: 34px;
  flex-shrink: 0;
  display: inline-grid;
  place-items: center;
  border-radius: .55rem;
  font-size: 1rem;
  background: var(--kpi-bg, var(--fo-primary-soft));
  color: var(--kpi-fg, var(--fo-primary));
}
.fo-kpi-label { font-size: .66rem; font-weight: 600; color: var(--fo-muted); text-transform: uppercase; letter-spacing: .03em; line-height: 1.15; }
.fo-kpi-wert { font-size: 1.15rem; font-weight: 800; letter-spacing: -.02em; line-height: 1.2; }
.fo-kpi-grid a { color: inherit; }

@media (max-width: 575.98px) {
  .fo-live-item {
    grid-template-columns: 38px minmax(0, 1fr);
  }
  .fo-live-side {
    grid-column: 2;
    justify-items: start;
    min-width: 0;
  }
  .fo-kpi {
    padding: .55rem .6rem;
    gap: .45rem !important;
    min-height: 4.35rem;
  }
  .fo-kpi-icon {
    width: 30px;
    height: 30px;
    border-radius: .48rem;
    font-size: .92rem;
  }
  .fo-kpi-label {
    font-size: .6rem;
    line-height: 1.18;
    overflow-wrap: anywhere;
  }
  .fo-kpi-wert {
    font-size: 1.08rem;
    margin-top: .08rem;
  }
}

/* ---------- Listen-Politur (Artikel) ---------- */

.min-w-0 { min-width: 0; }

.fo-thumb {
  width: 44px;
  height: 44px;
  border-radius: .5rem;
  object-fit: cover;
  border: 1px solid var(--fo-border);
  background: #f1f3f5;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.fo-thumb-leer { color: #adb5bd; font-size: 1.1rem; }

.fo-sort { color: inherit; text-decoration: none; white-space: nowrap; }
.fo-sort:hover { color: var(--fo-primary); }

.fo-zelle-name {
  max-width: 28rem;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

/* ---------- Sticky-Aktionsleiste im Artikel-Formular ---------- */

.fo-action-bar {
  position: sticky;
  bottom: 0;
  z-index: 1020;
  margin-top: 1rem;
  padding: .65rem .9rem;
  background: rgba(255, 255, 255, .9);
  backdrop-filter: blur(8px);
  border: 1px solid var(--fo-border);
  border-radius: var(--fo-radius);
  box-shadow: 0 -4px 18px rgba(16, 24, 40, .1);
}
/* Kompakte Buttons, damit die Aktionsleiste in eine Reihe passt */
.fo-action-bar .btn {
  padding: .34rem .62rem;
  font-size: .82rem;
}
.fo-action-bar .btn .bi { font-size: .9rem; }
.fo-action-bar .btn.px-4 { padding-left: .8rem !important; padding-right: .8rem !important; }
.fo-action-bar .gap-2 { gap: .4rem !important; }

/* ---------- Bilder-Grid (Artikel-Formular) ---------- */

.fo-dropzone {
  position: relative;
  border: 2px dashed #c0c8d8;
  border-radius: var(--fo-radius);
  background: #f7f9fc;
  padding: 2.25rem 1.5rem;
  text-align: center;
  cursor: pointer;
  overflow: hidden;
  transition: border-color .15s, background .15s, box-shadow .15s;
  user-select: none;
}
.fo-dropzone:hover               { border-color: var(--fo-primary); background: var(--fo-primary-soft); }
.fo-dropzone.is-dragover         { border-color: var(--fo-primary); background: var(--fo-primary-soft); box-shadow: 0 0 0 .25rem rgba(79,70,229,.14); }

.fo-dz-icon {
  font-size: 2.8rem; color: #c0c8d8;
  display: block; transition: color .15s, transform .2s;
}
.fo-dropzone:hover .fo-dz-icon,
.fo-dropzone.is-dragover .fo-dz-icon { color: var(--fo-primary); transform: translateY(-3px); }

.fo-dz-content { position: relative; z-index: 1; pointer-events: none; }
.fo-dz-content button  { pointer-events: auto; }

.fo-dz-compress { position: relative; z-index: 1; pointer-events: none; text-align: center; }
.fo-dz-progress-bar { height: 8px; width: 220px; margin: 0 auto; border-radius: 4px; }

/* ---------- Spaltenfilter (Panel-Listen) ---------- */
.fo-filter-row th { padding: .3rem .4rem; vertical-align: top; }
.fo-filter-row th:empty { padding: 0; }
.fo-filter-row .fo-filter-input { min-width: 4.5rem; font-size: .8rem; }

.fo-dz-overlay {
  position: absolute; inset: 0;
  background: rgba(79,70,229,.08);
  backdrop-filter: blur(3px);
  display: flex; flex-direction: column;
  align-items: center; justify-content: center; gap: .5rem;
  color: var(--fo-primary);
  opacity: 0; transition: opacity .15s; pointer-events: none;
}
.fo-dropzone.is-dragover .fo-dz-overlay { opacity: 1; }

/* Drag-Handle & Tile-Zustände */
.fo-drag-handle {
  display: flex; align-items: center; justify-content: center;
  height: 1.4rem; color: #b0bbc8; cursor: grab; font-size: 1rem;
  margin-bottom: .2rem; transition: color .12s;
}
.fo-drag-handle:hover              { color: var(--fo-primary); }
.fo-image-tile[draggable]          { cursor: default; }
.fo-image-tile.is-dragging         { opacity: .3; outline: 2px dashed #b0bbc8; outline-offset: 2px; }
.fo-image-tile.drag-over           { outline: 2px solid var(--fo-primary); outline-offset: 2px; box-shadow: 0 0 0 4px rgba(79,70,229,.15); }

.fo-image-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(110px, 1fr));
  gap: .75rem;
}

.fo-image-tile {
  border: 1px solid var(--fo-border);
  border-radius: var(--fo-radius-sm);
  background: var(--fo-surface);
  padding: .5rem;
  min-width: 0;
  transition: border-color .15s ease, box-shadow .15s ease, transform .15s ease;
}

.fo-image-tile.is-main {
  border-color: var(--fo-primary);
  box-shadow: 0 0 0 .22rem rgba(79, 70, 229, .18);
}

.fo-image-tile.fo-new-image-tile {
  border-style: dashed;
}

.fo-image-open {
  display: block;
  width: 100%;
  border: 0;
  background: transparent;
  padding: 0;
  cursor: zoom-in;
}

.fo-image-open img,
.fo-image-tile > img {
  width: 100%;
  aspect-ratio: 1;
  object-fit: cover;
  border-radius: .35rem;
  background: #f1f3f5;
}

.fo-main-image-choice {
  margin-top: .55rem;
  padding: .35rem .45rem .35rem 1.85rem;
  border-radius: .35rem;
  background: var(--fo-primary-soft);
  border: 1px solid rgba(79, 70, 229, .35);
}

.fo-image-tile.is-main .fo-main-image-choice {
  background: var(--fo-primary);
  color: #fff;
}

.fo-image-tile .form-check-label,
.fo-image-tile .small {
  overflow-wrap: anywhere;
}

/* ---------- eBay-Vorschau ---------- */

.fo-ebay-preview .card-body {
  display: grid;
  gap: 1rem;
}

.fo-ebay-format-wide { max-width: none; }

.fo-ebay-gallery { min-width: 0; }

.fo-ebay-main-image {
  width: 100%;
  aspect-ratio: 1;
  display: grid;
  place-items: center;
  border: 1px solid var(--fo-border);
  border-radius: var(--fo-radius-sm);
  background: var(--fo-surface);
  overflow: hidden;
}

.fo-ebay-main-image img {
  width: 100%;
  height: 100%;
  object-fit: contain;
}

.fo-preview-placeholder {
  color: var(--fo-muted);
  display: grid;
  gap: .35rem;
  place-items: center;
  font-size: .9rem;
}

.fo-preview-placeholder .bi { font-size: 2rem; }

.fo-ebay-thumbs {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: .4rem;
  margin-top: .55rem;
}

.fo-ebay-thumb {
  border: 1px solid var(--fo-border);
  border-radius: .35rem;
  background: var(--fo-surface);
  padding: .15rem;
  aspect-ratio: 1;
  overflow: hidden;
}

.fo-ebay-thumb.active {
  border-color: var(--fo-primary);
  box-shadow: 0 0 0 .15rem rgba(79, 70, 229, .18);
}

.fo-ebay-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.fo-ebay-body h2 {
  font-size: 1.05rem;
  line-height: 1.25;
  margin: 0 0 .45rem;
  overflow-wrap: anywhere;
}

.fo-ebay-meta {
  display: grid;
  gap: .2rem;
  color: var(--fo-muted);
  font-size: .84rem;
}

.fo-ebay-price {
  font-size: 1.55rem;
  font-weight: 800;
  letter-spacing: -.02em;
  margin: .7rem 0;
}

.fo-ebay-buybox {
  display: grid;
  gap: .5rem;
  margin-bottom: .85rem;
}

.fo-ebay-facts {
  display: grid;
  gap: .45rem;
  margin: 0;
  font-size: .88rem;
}

.fo-ebay-facts div {
  display: grid;
  grid-template-columns: 6rem minmax(0, 1fr);
  gap: .75rem;
}

.fo-ebay-facts dt { color: var(--fo-muted); font-weight: 500; }

.fo-ebay-facts dd { margin: 0; overflow-wrap: anywhere; }

.fo-ebay-description {
  border-top: 1px solid var(--fo-border);
  margin-top: .85rem;
  padding-top: .85rem;
  color: #495057;
  font-size: .9rem;
  white-space: pre-wrap;
  overflow-wrap: anywhere;
}

.fo-ebay-html {
  min-height: 12rem;
  max-height: 22rem;
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, "Liberation Mono", monospace;
  font-size: .78rem;
  line-height: 1.35;
}
.fo-kleinanzeigen-text {
  min-height: 20rem;
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, "Liberation Mono", monospace;
  font-size: .86rem;
  line-height: 1.5;
  white-space: pre-wrap;
  overflow-wrap: anywhere;
}

/* ---------- Bild-Galerie (Modal) ---------- */

.fo-gallery-modal {
  background: #111827;
  color: #f8f9fa;
}

.fo-gallery-modal .modal-header,
.fo-gallery-modal .modal-footer {
  border-color: rgba(255, 255, 255, .12);
}

.fo-gallery-modal .btn-close {
  filter: invert(1) grayscale(100%);
}

.fo-gallery-modal .modal-body {
  position: relative;
  min-height: 60vh;
  display: grid;
  place-items: center;
  padding: 1rem 4.5rem;
}

.fo-gallery-image {
  max-width: 100%;
  max-height: 72vh;
  object-fit: contain;
  border-radius: .5rem;
  background: #fff;
}

.fo-gallery-nav {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  width: 3rem;
  height: 3rem;
  border-radius: 999px;
  display: grid;
  place-items: center;
}

.fo-gallery-prev { left: 1rem; }
.fo-gallery-next { right: 1rem; }

@media (max-width: 575.98px) {
  .fo-gallery-modal .modal-body {
    padding: 1rem 3.25rem;
  }
  .fo-gallery-nav {
    width: 2.5rem;
    height: 2.5rem;
  }
}

/* ---------- Feinheiten ---------- */

::-webkit-scrollbar { width: 10px; height: 10px; }
::-webkit-scrollbar-thumb { background: #cdd2dd; border-radius: 8px; border: 2px solid var(--fo-bg); }
::-webkit-scrollbar-thumb:hover { background: #aab1c0; }

.modal-content { border-radius: var(--fo-radius); border-color: var(--fo-border); }

code { color: var(--fo-primary-dark); background: var(--fo-primary-soft); padding: .1em .35em; border-radius: .3rem; }

/* ---------- Login-Seite ---------- */

.fo-login-bg {
  min-height: 100vh;
  background: linear-gradient(160deg, #101828 0%, #1a2744 55%, #0e1525 100%);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 2rem 1rem;
}

.fo-login-card {
  background: #fff;
  border-radius: 1.25rem;
  box-shadow: 0 24px 64px rgba(0, 0, 0, .45), 0 4px 16px rgba(0, 0, 0, .15);
  padding: 2.5rem 2.25rem 2rem;
  width: 100%;
  max-width: 420px;
  border-top: 4px solid var(--fo-primary);
}

.fo-login-brand {
  display: grid;
  grid-template-columns: auto 1fr;
  align-items: center;
  justify-content: center;
  column-gap: .7rem;
  row-gap: .35rem;
}

.fo-login-logo-mark {
  width: 48px;
  height: 48px;
  display: inline-grid;
  place-items: center;
}

.fo-login-logo-mark img {
  width: 48px;
  height: 48px;
  object-fit: contain;
}

.fo-login-logo-text {
  color: #08090A;
  font-weight: 900;
  font-size: 1.55rem;
  line-height: 1;
  letter-spacing: 0;
}

.fo-login-logo-text em {
  color: #FF6B1A;
  font-style: normal;
}

.fo-login-tagline {
  grid-column: 1 / -1;
  text-align: center;
  color: var(--fo-muted);
  font-size: .75rem;
  font-weight: 600;
  margin-bottom: 1.75rem;
  text-transform: uppercase;
  letter-spacing: .1em;
}

.fo-turnstile-wrap {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  margin: .75rem 0 1rem;
}

.fo-login-btn {
  height: 2.8rem;
  font-size: .95rem;
  font-weight: 600;
  letter-spacing: .01em;
}

.fo-login-card .input-group-text {
  background: var(--fo-primary-soft);
  border-color: var(--fo-border);
  color: var(--fo-primary);
}

/* ---------- Theme-Toggle ---------- */

.fo-theme-toggle {
  background: none; border: none; cursor: pointer; line-height: 1;
  padding: .3rem .4rem; border-radius: .4rem;
  color: #8b96ab; font-size: 1.05rem; flex-shrink: 0;
  transition: color .15s, background .15s;
}
.fo-theme-toggle:hover { color: #fff; background: rgba(255,255,255,.08); }

/* ---------- Dark Theme ---------- */

/*
 * Palette: "Midnight"
 * Basis: GitHub-Dark-Dimmed – bewährt lesbar, nie grell.
 * Akzent: Indigo etwas aufgehellt (#7c6ef5) damit er auf dunklem
 *         Grund dieselbe Leuchtkraft hat wie auf hellem.
 */

[data-bs-theme="dark"] {
  /* Hintergründe – drei Ebenen statt hartem Kontrast */
  --fo-bg:      #0e1525;   /* Seite */
  --fo-surface: #111a2e;   /* Karten, Panels */
  --fo-surface2:#162035;   /* leicht erhöhte Elemente */

  /* Trennlinien */
  --fo-border:  #1e2d45;
  --fo-border2: #263650;   /* stärkere Borders */

  /* Typografie */
  --fo-text:    #e6edf3;   /* Primärtext */
  --fo-muted:   #cdd5e0;   /* Sekundär – hell, kein Grau */

  /* Akzentfarbe */
  --fo-primary:        #7c6ef5;
  --fo-primary-dark:   #6a5de0;
  --fo-primary-soft:   rgba(124,110,245,.14);
  --fo-primary-border: rgba(124,110,245,.32);

  /* Schatten – auf dunklem Bg wichtiger */
  --fo-shadow:    0 0 0 1px rgba(255,255,255,.04), 0 2px 8px rgba(0,0,0,.45);
  --fo-shadow-lg: 0 0 0 1px rgba(255,255,255,.04), 0 12px 40px rgba(0,0,0,.65);

  /* Bootstrap-Vars synchronisieren */
  --bs-body-bg:      #0e1525;
  --bs-body-color:   #c9d1d9;
  --bs-card-bg:      #111a2e;
  --bs-border-color: #1e2d45;

  color-scheme: dark;
}

/* Basis */
[data-bs-theme="dark"] body { background: var(--fo-bg); color: var(--fo-text); }

/* Sidebar: rechte Trennlinie für klare Abgrenzung */
[data-bs-theme="dark"] .sidebar { border-right: 1px solid #21262d; }

/* Karten */
[data-bs-theme="dark"] .card                   { background: var(--fo-surface); border-color: var(--fo-border); }
[data-bs-theme="dark"] .card > .card-header    { border-bottom-color: var(--fo-border); background: var(--fo-surface2); }

/* Tabellen */
[data-bs-theme="dark"] .table-responsive       { background: var(--fo-surface); border-color: var(--fo-border); }
[data-bs-theme="dark"] .table > thead th       { background: var(--fo-surface2); color: var(--fo-muted); border-bottom-color: var(--fo-border2); }
[data-bs-theme="dark"] .table {
  --bs-table-hover-bg:   rgba(255,255,255,.035);
  --bs-table-border-color: var(--fo-border);
  color: var(--fo-text);
}
[data-bs-theme="dark"] .table > tbody tr.fo-order-unread > td {
  background: rgba(249, 115, 22, .12) !important;
  border-bottom-color: rgba(249, 115, 22, .24);
}
[data-bs-theme="dark"] .table > tbody tr.fo-order-unread:hover > td {
  background: rgba(249, 115, 22, .18) !important;
}
[data-bs-theme="dark"] .table > tbody tr.fo-order-unread > td:first-child {
  box-shadow: inset 4px 0 0 #fb923c;
}
[data-bs-theme="dark"] .table > tbody tr.fo-order-storno > td {
  background: rgba(220, 38, 38, .12) !important;
  border-bottom-color: rgba(220, 38, 38, .24);
}
[data-bs-theme="dark"] .table > tbody tr.fo-order-storno:hover > td {
  background: rgba(220, 38, 38, .18) !important;
}
[data-bs-theme="dark"] .table > tbody tr.fo-order-storno > td:first-child {
  box-shadow: inset 4px 0 0 #f87171;
}
[data-bs-theme="dark"] .fo-live-card .card-header,
[data-bs-theme="dark"] .fo-live-item {
  background: var(--fo-surface);
}
[data-bs-theme="dark"] .fo-live-item {
  border-top-color: var(--fo-border);
}
[data-bs-theme="dark"] .fo-live-item:hover {
  background: var(--fo-surface2);
}
[data-bs-theme="dark"] .fo-live-icon-info { color: #58a6ff; background: #132031; }
[data-bs-theme="dark"] .fo-live-icon-warning { color: #e3b341; background: #2d2002; }
[data-bs-theme="dark"] .fo-live-icon-danger { color: #f85149; background: #2d1215; }
[data-bs-theme="dark"] .fo-live-pulse {
  background: #3fb950;
  box-shadow: 0 0 0 5px rgba(63, 185, 80, .16);
}
[data-bs-theme="dark"] .fo-live-empty i {
  color: #3fb950;
}

/* Badges – satte Töne die auf dem dunklen Bg gut lesbar sind */
[data-bs-theme="dark"] .badge.text-bg-light,
[data-bs-theme="dark"] .badge.text-bg-light.text-body { background: var(--fo-surface2) !important; color: #e6edf3 !important; border-color: var(--fo-border2) !important; }
[data-bs-theme="dark"] .badge.text-bg-success   { background: #1a3a2a !important; color: #3fb950 !important; border: 1px solid rgba(63,185,80,.25) !important; }
[data-bs-theme="dark"] .badge.text-bg-secondary { background: #162035 !important; color: #cdd5e0 !important; border: 1px solid #1e2d45 !important; }
[data-bs-theme="dark"] .badge.text-bg-info      { background: #132031 !important; color: #58a6ff !important; border: 1px solid rgba(88,166,255,.25) !important; }
[data-bs-theme="dark"] .badge.text-bg-warning   { background: #2d2002 !important; color: #e3b341 !important; border: 1px solid rgba(227,179,65,.25) !important; }
[data-bs-theme="dark"] .badge.text-bg-danger    { background: #2d1215 !important; color: #f85149 !important; border: 1px solid rgba(248,81,73,.25) !important; }
[data-bs-theme="dark"] .badge.text-bg-dark      { background: #162035 !important; color: #e6edf3 !important; border: 1px solid #1e2d45 !important; }
[data-bs-theme="dark"] .badge.bg-secondary      { background: var(--fo-surface2) !important; color: #cdd5e0 !important; }

/* bg-light Elemente (Massenaktions-Bar, Einstellungen-Karten, Card-Header) */
[data-bs-theme="dark"] .bg-light                { background-color: var(--fo-surface2) !important; }
[data-bs-theme="dark"] .card-header.bg-light    { background-color: var(--fo-surface2) !important; color: var(--fo-text) !important; }
[data-bs-theme="dark"] .card.bg-light           { background-color: var(--fo-surface)  !important; border-color: var(--fo-border) !important; }

/* Primär-Buttons – leuchtender Indigo, subtiler Glow */
[data-bs-theme="dark"] .btn-primary {
  --bs-btn-bg:            var(--fo-primary);
  --bs-btn-border-color:  var(--fo-primary);
  --bs-btn-hover-bg:      var(--fo-primary-dark);
  --bs-btn-hover-border-color: var(--fo-primary-dark);
  --bs-btn-active-bg:     var(--fo-primary-dark);
  box-shadow: 0 0 0 0 transparent;
}
[data-bs-theme="dark"] .btn-primary:hover {
  box-shadow: 0 0 16px rgba(124,110,245,.35);
}

/* Nav-Aktiv-State – gleicher Glow-Effekt */
[data-bs-theme="dark"] .fo-nav-link.active {
  background: linear-gradient(90deg, #7c6ef5, #8a7ef8);
  box-shadow: 0 3px 12px rgba(124,110,245,.4);
}

/* Formulare */
[data-bs-theme="dark"] .form-control:focus,
[data-bs-theme="dark"] .form-select:focus {
  border-color: #7c6ef5;
  box-shadow: 0 0 0 .22rem rgba(124,110,245,.2);
}

/* Sticky-Leiste – Glaseffekt auf dunkel */
[data-bs-theme="dark"] .fo-action-bar {
  background: rgba(14,21,37,.92);
  backdrop-filter: blur(12px);
  border-color: var(--fo-border2);
  box-shadow: 0 -4px 24px rgba(0,0,0,.5);
}

/* Dropzone */
[data-bs-theme="dark"] .fo-dropzone            { border-color: #1e2d45; background: #0e1525; }
[data-bs-theme="dark"] .fo-dropzone:hover,
[data-bs-theme="dark"] .fo-dropzone.is-dragover{ background: rgba(124,110,245,.1); border-color: #7c6ef5; }
[data-bs-theme="dark"] .fo-dz-icon             { color: #1e2d45; }
[data-bs-theme="dark"] .fo-drag-handle         { color: #1e2d45; }

/* Bildvorschau-Hintergründe */
[data-bs-theme="dark"] .fo-image-open img,
[data-bs-theme="dark"] .fo-image-tile > img,
[data-bs-theme="dark"] .fo-thumb               { background: #0e1525; }

/* Sonstiges */
[data-bs-theme="dark"] .fo-ebay-description    { color: #8b949e; }
[data-bs-theme="dark"] code                    { background: rgba(124,110,245,.15); color: #a78bfa; }
[data-bs-theme="dark"] .modal-content          { background: var(--fo-surface); border-color: var(--fo-border2); }
[data-bs-theme="dark"] .dropdown-menu          { background: var(--fo-surface2); border-color: var(--fo-border2); }
[data-bs-theme="dark"] .dropdown-item          { color: var(--fo-text); }
[data-bs-theme="dark"] .dropdown-item:hover    { background: rgba(255,255,255,.06); }

/* Scrollbar */
[data-bs-theme="dark"] ::-webkit-scrollbar-thumb       { background: #30363d; border-color: var(--fo-bg); }
[data-bs-theme="dark"] ::-webkit-scrollbar-thumb:hover { background: #484f58; }

/* Sidebar-Texte: alle grauen Farben auf hell setzen */
[data-bs-theme="dark"] .fo-nav-link            { color: #d0d8e8; }
[data-bs-theme="dark"] .fo-nav-link:hover      { background: rgba(255,255,255,.08); color: #fff; }
[data-bs-theme="dark"] .fo-nav-label           { color: #8b949e; }
[data-bs-theme="dark"] .fo-sidebar-user > .bi  { color: #d0d8e8; }
[data-bs-theme="dark"] .fo-sidebar-username    { color: #e6edf3; }
[data-bs-theme="dark"] .fo-sidebar-user a      { color: #b0bac8; }
[data-bs-theme="dark"] .fo-sidebar-user a:hover{ color: #fff; }
[data-bs-theme="dark"] .fo-theme-toggle        { color: #b0bac8; }
[data-bs-theme="dark"] .fo-theme-toggle:hover  { color: #fff; }

/* ── Responsive: Tabellen → gestapelte Karten auf Mobile ─────────────── */
@media (max-width: 767px) {
  /* Kein seitliches Scrollen auf dem Wrapper */
  .fo-tbl-mobile-wrap { overflow: visible !important; }

  /* Tabellen-Grundgerüst auf Block umstellen */
  .fo-tbl-mobile,
  .fo-tbl-mobile tbody { display: block !important; width: 100%; }
  .fo-tbl-mobile thead { display: none !important; }

  /* fo-coldrag (Spalten verschieben/Breite, Desktop) darf die Mobil-Karten nicht brechen */
  .fo-tbl-mobile.fo-coldrag-fixed { width: 100% !important; table-layout: auto !important; }
  .fo-tbl-mobile.fo-coldrag-fixed td {
    width: auto !important; white-space: normal !important; overflow: visible !important; text-overflow: clip !important;
  }
  .fo-tbl-mobile td.fo-frozen-cell { position: static !important; left: auto !important; box-shadow: none !important; z-index: auto !important; }
  .fo-xscroll-proxy { display: none !important; }

  /* Jede Zeile wird zur Karte */
  .fo-tbl-mobile tbody tr {
    display: block !important;
    border: 1px solid var(--fo-border);
    border-radius: var(--fo-radius-sm);
    margin-bottom: .6rem;
    background: var(--bs-card-bg, var(--fo-surface));
    overflow: hidden;
    box-shadow: var(--fo-shadow);
  }

  /* Zelle: Label-Spalte links · Wert rechts */
  .fo-tbl-mobile td {
    display: flex !important;         /* überschreibt d-none d-*-table-cell */
    align-items: flex-start;
    justify-content: space-between;
    padding: .42rem .75rem !important;
    border: none !important;
    border-bottom: 1px solid var(--fo-border) !important;
    font-size: .85rem;
    gap: .5rem;
  }
  .fo-tbl-mobile td:last-child { border-bottom: none !important; }
  .fo-tbl-mobile td:empty      { display: none !important; }

  /* Spaltentitel via data-label-Attribut */
  .fo-tbl-mobile td[data-label]::before {
    content: attr(data-label);
    font-size: .67rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: .05em;
    color: var(--fo-muted);
    min-width: 72px;
    flex-shrink: 0;
    padding-top: .2em;
    line-height: 1.3;
    white-space: nowrap;
  }

  /* Aktions-Zellen (leere <th>) → rechtsbündig, kein Label */
  .fo-tbl-mobile .fo-td-actions {
    justify-content: flex-end;
    gap: .35rem;
    background: var(--fo-surface);
    padding: .45rem .6rem !important;
    border-bottom: none !important;
  }
  .fo-tbl-mobile .fo-td-actions::before { display: none; }

  /* Collapse-/Detail-Zeilen in Bestellungen */
  .fo-tbl-mobile tbody tr.collapse:not(.show) { display: none !important; }
  .fo-tbl-mobile tbody tr.collapse.show,
  .fo-tbl-mobile tbody tr.collapsing {
    border: 1px solid var(--fo-border);
    border-top: none;
    border-radius: 0 0 var(--fo-radius-sm) var(--fo-radius-sm);
    margin-top: -.55rem;
    margin-bottom: .6rem;
    box-shadow: none;
  }
  .fo-tbl-mobile tbody tr.collapse.show td,
  .fo-tbl-mobile tbody tr.collapsing td {
    display: block !important;
    padding: .75rem !important;
    border-bottom: none !important;
  }
  .fo-tbl-mobile tbody tr.collapse.show td::before,
  .fo-tbl-mobile tbody tr.collapsing td::before { display: none; }

  /* Dark-Mode-Anpassungen */
  [data-bs-theme="dark"] .fo-tbl-mobile .fo-td-actions { background: var(--fo-surface2); }
}

/* ---- Einstellungen: Hilfe-Boxen sauber in jeder Karte (auch randlose card-body p-0) ---- */
.einst-hilfe { border-radius: .5rem; max-width: 100%; }
.card-body.p-0 > .einst-hilfe { margin: .75rem; }
/* Flex-Overflow verhindern: Text-Element darf schrumpfen, lange Tokens (z. B. „A/B/C") brechen um */
.einst-hilfe > div { min-width: 0; }
.einst-hilfe, .einst-hilfe * { overflow-wrap: anywhere; word-break: break-word; }
/* Lange Wörter in Formular-Labels (z. B. „Differenzbesteuerung") brechen statt über den Rand zu laufen */
.form-label { overflow-wrap: anywhere; }

/* ---- Einstellungen: Schnittstellen-Verbindungen ---- */
.fo-schnittstellen-grid {
  align-items: flex-start;
}
.fo-schnittstellen-grid > [class*="col-"] > .card {
  overflow: hidden;
  border-color: #dfe4ee;
  background: linear-gradient(180deg, #ffffff 0%, #fbfcff 100%);
  transition: border-color .16s ease, box-shadow .16s ease, transform .16s ease;
}
.fo-schnittstellen-grid > [class*="col-"] > .card:hover {
  border-color: #cbd5e8;
  box-shadow: 0 10px 26px rgba(16, 24, 40, .08);
  transform: translateY(-1px);
}
.fo-schnittstellen-grid .fo-conn-head {
  min-height: 72px;
  padding: .85rem .95rem;
  background: linear-gradient(180deg, rgba(255,255,255,.96) 0%, rgba(248,250,252,.98) 100%);
  border-bottom: 1px solid #e4e8f1;
}
.fo-schnittstellen-grid .card-body {
  border-top: 1px solid #edf0f6;
  background: var(--fo-surface);
}
.fo-conn-toggle {
  appearance: none;
  border: 0;
  background: transparent;
  color: var(--fo-text);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: .75rem;
  min-width: 0;
  flex: 1 1 auto;
  padding: 0;
  text-align: left;
  cursor: pointer;
}
.fo-conn-toggle:focus-visible {
  outline: 3px solid rgba(79,70,229,.22);
  outline-offset: 4px;
  border-radius: .7rem;
}
.fo-conn-main {
  display: flex;
  align-items: center;
  gap: .72rem;
  min-width: 0;
}
.fo-conn-icon {
  width: 2.35rem;
  height: 2.35rem;
  border-radius: .7rem;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex: 0 0 auto;
  background: var(--fo-primary-soft);
  color: var(--fo-primary);
  box-shadow: inset 0 0 0 1px rgba(79,70,229,.12);
}
.fo-schnittstellen-grid .fo-conn-icon .bi {
  color: inherit;
  font-size: 1.05rem;
}
.fo-conn-title {
  min-width: 0;
  font-size: .95rem;
  font-weight: 750;
  line-height: 1.2;
  overflow-wrap: anywhere;
}
.fo-schnittstellen-grid .fo-conn-chevron.bi {
  flex: 0 0 auto;
  color: var(--fo-muted);
  transition: transform .16s ease, color .16s ease;
}
.fo-conn-toggle:hover .fo-conn-title,
.fo-conn-toggle:not(.collapsed) .fo-conn-title {
  color: var(--fo-primary);
}
.fo-schnittstellen-grid .fo-conn-toggle:not(.collapsed) .fo-conn-chevron.bi {
  transform: rotate(180deg);
  color: var(--fo-primary);
}
.fo-conn-actions {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: .6rem;
  flex: 0 0 auto;
  min-width: 0;
}
.fo-conn-status {
  max-width: 15rem;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  font-weight: 650;
}
[data-bs-theme="dark"] .fo-schnittstellen-grid > [class*="col-"] > .card {
  background: var(--fo-surface);
  border-color: var(--fo-border2);
}
[data-bs-theme="dark"] .fo-schnittstellen-grid .fo-conn-head {
  background: linear-gradient(180deg, #162035 0%, #111a2e 100%);
  border-bottom-color: var(--fo-border2);
}
[data-bs-theme="dark"] .fo-schnittstellen-grid .card-body {
  border-top-color: var(--fo-border2);
  background: var(--fo-surface);
}
[data-bs-theme="dark"] .fo-conn-icon {
  background: rgba(124,110,245,.14);
  box-shadow: inset 0 0 0 1px rgba(124,110,245,.22);
}

/* ---- Einstellungen: E-Mail-Vorlagen ---- */
.fo-mailtpl .accordion-button {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 7.25rem 1.25rem;
  align-items: center;
  column-gap: .75rem;
  min-width: 0;
}
.fo-mailtpl .accordion-button::after {
  grid-column: 3;
  justify-self: end;
  margin-left: 0;
}
.fo-mailtpl-title {
  min-width: 0;
  overflow-wrap: anywhere;
}
.fo-mailtpl-badge {
  grid-column: 2;
  justify-self: start;
  min-width: 5.4rem;
  text-align: center;
}
.fo-mailtpl-html {
  min-height: 340px;
  resize: vertical;
  font-size: .82rem;
  line-height: 1.45;
}
.fo-mailtpl-preview {
  width: 100%;
  min-height: 680px;
  border: 1px solid var(--bs-border-color);
  border-radius: .5rem;
  background: #f4f4f5;
}
.fo-mailtpl-preview-head { min-height: 1.5rem; }

@media (max-width: 575.98px) {
  .fo-mailtpl .accordion-button {
    grid-template-columns: minmax(0, 1fr) 6.4rem 1.25rem;
    column-gap: .5rem;
    align-items: center;
    line-height: 1.25;
  }
  .fo-mailtpl-badge { min-width: 5.2rem; }
  .fo-mailtpl-html { min-height: 280px; }
  .fo-mailtpl-preview { min-height: 430px; }
}

@media (max-width: 575.98px) {
  .fo-schnittstellen-grid .fo-conn-head {
    align-items: stretch !important;
    flex-direction: column;
    gap: .8rem !important;
    min-height: 0;
  }
  .fo-conn-toggle {
    width: 100%;
  }
  .fo-conn-actions {
    width: 100%;
    justify-content: space-between;
  }
  .fo-conn-status {
    max-width: calc(100% - 4.25rem);
  }
}

/* ---- Horizontal scroll-/schiebbare Tab- & Chip-Leisten ---- */
.fo-tab-scroll {
  display: flex;
  flex-wrap: nowrap;
  overflow-x: auto;
  gap: .5rem;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: thin;
  cursor: grab;
}
.fo-tab-scroll.is-dragging { cursor: grabbing; user-select: none; }
.fo-tab-scroll > * { flex: 0 0 auto; }
.fo-tab-scroll::-webkit-scrollbar { height: 6px; }
.fo-tab-scroll::-webkit-scrollbar-thumb { background: rgba(128,128,128,.4); border-radius: 3px; }

/* ---- Vollbild: Header + Seitenmenü ausblenden (globaler Umschalter) ---- */
.fo-fullscreen-btn {
  position: fixed; bottom: 1rem; right: 1rem; z-index: 1090;
  width: 40px; height: 40px; border-radius: 10px;
  border: 1px solid var(--bs-border-color, #ccc);
  background: var(--bs-body-bg, #fff); color: var(--bs-body-color, #222);
  display: inline-flex; align-items: center; justify-content: center;
  box-shadow: 0 2px 8px rgba(0,0,0,.18); opacity: .85;
}
.fo-fullscreen-btn:hover { opacity: 1; }
html.fo-fullscreen .fo-topbar,
html.fo-fullscreen .sidebar { display: none !important; }
html.fo-fullscreen main.flex-grow-1 { padding: 1rem 1rem 3.5rem !important; }
/* Vollbild 3. Stufe „reine Tabelle": zusätzlich Titel, Suche & Status-Leiste ausblenden */
html.fo-pur .fo-listenkopf { display: none !important; }
html.fo-pur main.flex-grow-1 { padding-top: .5rem !important; }

/* ---------- Seitenmenü ein-/ausklappen (Desktop) ---------- */
.fo-sidebar-collapse {
  background: none; border: none; cursor: pointer; line-height: 1;
  padding: .05rem .2rem; border-radius: .35rem;
  color: #8b96ab; font-size: .8rem; flex-shrink: 0;
  transition: color .15s, background .15s;
}
.fo-sidebar-collapse:hover { color: #fff; background: rgba(255, 255, 255, .08); }
[data-bs-theme="dark"] .fo-sidebar-collapse { color: #b0bac8; }
[data-bs-theme="dark"] .fo-sidebar-collapse:hover { color: #fff; }

/* Dezenter „Einblenden"-Button, nur sichtbar wenn das Menü eingeklappt ist */
.fo-sidebar-show {
  position: fixed; top: .75rem; left: .75rem; z-index: 1091;
  width: 38px; height: 38px; border-radius: 10px;
  border: 1px solid var(--bs-border-color, #ccc);
  background: var(--bs-body-bg, #fff); color: var(--bs-body-color, #222);
  display: none; align-items: center; justify-content: center;
  box-shadow: 0 2px 8px rgba(0, 0, 0, .15); opacity: .9;
  transition: opacity .15s, transform .15s;
}
.fo-sidebar-show:hover { opacity: 1; transform: translateX(2px); }
@media (min-width: 992px) {
  html.fo-sidebar-collapsed .sidebar { display: none !important; }
  html.fo-sidebar-collapsed main.flex-grow-1 { padding-left: 3.5rem !important; }
  html.fo-sidebar-collapsed .fo-sidebar-show { display: inline-flex; }
  /* Kein Konflikt mit dem Artikel-Vollbild: dort keinen Einblenden-Button zeigen */
  html.fo-sidebar-collapsed.fo-fullscreen .fo-sidebar-show { display: none !important; }
}

/* Dashboard-Kacheln anordnen (Drag & Drop) */
.fo-dash-table {
  table-layout: fixed;
  width: 100%;
}
.fo-dash-table td {
  min-width: 0;
  overflow: hidden;
  vertical-align: middle;
}
.fo-dash-table .badge {
  max-width: 100%;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.fo-dash-col-badge { width: 38%; }
.fo-dash-col-typ { width: 4.8rem; }
.fo-dash-col-date { width: 5.9rem; }
.fo-dash-col-aktion { width: 2.6rem; }

@media (max-width: 575.98px) {
  .fo-dash-table td {
    padding-left: .5rem;
    padding-right: .5rem;
  }
  .fo-dash-table td:first-child { padding-left: .75rem !important; }
  .fo-dash-table td:last-child { padding-right: .75rem !important; }
  .fo-dash-col-badge { width: 34%; }
  .fo-dash-col-typ { width: 4.2rem; }
  .fo-dash-col-date { width: 5.2rem; }
  .fo-dash-col-aktion { width: 2.4rem; }
}

.fo-dash-grip { display: none; cursor: grab; }
#foDashGrid.fo-dash-arrange .fo-dash-grip { display: inline-flex; align-items: center; }
#foDashGrid.fo-dash-arrange [data-dash-id] { cursor: grab; }
#foDashGrid.fo-dash-arrange [data-dash-id] .card {
  outline: 2px dashed var(--bs-border-color, #c5c9cf);
  outline-offset: -2px;
  transition: outline-color .12s ease;
}
#foDashGrid.fo-dash-arrange [data-dash-id]:hover .card { outline-color: var(--bs-primary, #0d6efd); }
#foDashGrid .fo-dash-dragging { opacity: .45; }
#foDashGrid .fo-dash-dragging .card { outline-color: var(--bs-success, #198754) !important; }
#foDashArrange.active { background: var(--bs-primary, #0d6efd); color: #fff; border-color: var(--bs-primary, #0d6efd); }

/* ---- Sticky horizontale Scrollleiste für breite Tabellen ---- */
.fo-xscroll-proxy {
  position: fixed; bottom: 0; left: 0; height: 16px;
  overflow-x: auto; overflow-y: hidden; z-index: 1040;
  background: var(--bs-body-bg, #fff);
  border-top: 1px solid var(--bs-border-color, #ddd);
}
.fo-xscroll-proxy > div { height: 1px; }
/* Platz unten, damit die fixe Scrollleiste die Pagination o. Ä. nicht überdeckt */
body.fo-has-xproxy main.flex-grow-1 { padding-bottom: 2.5rem; }
/* native Scrollleiste der Tabelle ausblenden – gescrollt wird über den Sticky-Proxy */
.fo-xscroll { scrollbar-width: none; -ms-overflow-style: none; }
.fo-xscroll::-webkit-scrollbar { height: 0; width: 0; }

/* ---- Spalten per Drag&Drop verschieben + Breite ziehen ---- */
.fo-coldrag thead tr:first-child th { user-select: none; cursor: grab; position: relative; }
.fo-coldrag thead tr:first-child th:active { cursor: grabbing; }
.fo-col-dragging { opacity: .45; }
.fo-col-over { box-shadow: inset 3px 0 0 var(--bs-primary, #0d6efd); }
.fo-col-resizer { position: absolute; top: 0; right: 0; width: 8px; height: 100%; cursor: col-resize; z-index: 2; }
.fo-col-resizer:hover { background: var(--bs-primary, #0d6efd); opacity: .35; }
/* feste Spaltenbreiten: Inhalt kürzen, damit Spalten auch schmaler gezogen werden können */
.fo-coldrag-fixed td, .fo-coldrag-fixed th { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
/* Aktionsspalte nicht abschneiden (Dropdown-Menü soll sichtbar bleiben) */
.fo-coldrag-fixed th[data-col="akt"], .fo-coldrag-fixed td.fo-col-noclip { overflow: visible; }
/* Zellen während der Inline-Bearbeitung nicht abschneiden (z. B. Fahrzeuge-Liste) */
.fo-coldrag-fixed td[contenteditable="true"] { overflow: visible !important; white-space: normal !important; }
/* Spalten-Picker: ausgeblendete Spalte – !important schlägt Bootstraps d-*-table-cell */
.fo-col-aus { display: none !important; }


/* Inline-Bearbeitung in der Artikelliste (Doppelklick: Preis/Bestand/Status) */
td.fo-inline { cursor: cell; }
td.fo-inline:hover { outline: 1px dashed var(--bs-primary); outline-offset: -2px; }
.fo-inline-input { width: 100%; min-width: 64px; }
td.fo-inline.fo-inline-saving { opacity: .55; }
td.fo-inline.fo-inline-ok  { background: rgba(25,135,84,.18); transition: background .3s; }
td.fo-inline.fo-inline-err { background: rgba(220,53,69,.18); transition: background .3s; }
/* beim Bearbeiten nicht abschneiden (überschreibt feste Spaltenbreiten) */
td.fo-inline.fo-inline-editing, .fo-coldrag-fixed td.fo-inline.fo-inline-editing { overflow: visible; }

/* Dezenter Hinweis nach Inline-Änderung von Preis/Bestand (live im Shop/eBay) */
.fo-inline-toasts {
  position: fixed; right: 1rem; bottom: 1rem; z-index: 1095;
  display: flex; flex-direction: column-reverse; gap: .4rem;
  pointer-events: none;
}
.fo-inline-toast {
  display: flex; align-items: center; gap: .5rem;
  padding: .5rem .85rem; border-radius: .5rem;
  background: var(--bs-body-bg, #fff); color: var(--bs-body-color, #222);
  border: 1px solid var(--bs-border-color, #ccc);
  box-shadow: 0 4px 16px rgba(0, 0, 0, .18);
  font-size: .85rem; max-width: 320px;
  opacity: 0; transform: translateY(6px);
  transition: opacity .2s, transform .2s;
}
.fo-inline-toast.is-show { opacity: 1; transform: translateY(0); }
.fo-inline-toast-ok i { color: #198754; }
.fo-inline-toast-warn i { color: #dc2626; }

/* === Artikelliste: Sticky-Kopf, eingefrorene Spalten, Warn-Icons, Bildvorschau === */
/* Sticky Kopfzeile: Container scrollt intern (sonst klebt sticky wegen overflow-x nicht) */
.fo-sticky-head { max-height: calc(100vh - 250px); overflow-y: auto; }
html.fo-fullscreen .fo-sticky-head { max-height: calc(100vh - 90px); }
/* vertikale Leiste sichtbar lassen (horizontale bleibt versteckt -> Proxy-Balken) */
.fo-sticky-head::-webkit-scrollbar { width: 10px; }
.fo-sticky-head thead tr:first-child th {
  position: sticky; top: 0; z-index: 3;
  background: var(--bs-body-bg);
}
/* Eingefrorene erste Spalten */
.fo-frozen-cell { position: sticky; background: var(--bs-body-bg); z-index: 2; }
thead .fo-frozen-cell { z-index: 5; }            /* Kopfzeile der eingefrorenen Spalten ganz oben */
.fo-frozen-last { box-shadow: inset -2px 0 0 var(--bs-border-color); }
/* Warn-Icons stehen am Zellenanfang -> von der Ellipsis nicht abgeschnitten */
.fo-warn-icons { white-space: nowrap; }
/* Aktive-Filter-Chips */
.fo-filter-chip { cursor: pointer; }
.fo-filter-chip:hover { background: var(--bs-danger-bg-subtle) !important; border-color: var(--bs-danger) !important; }
/* Zeilendichte: kompakt (deutlich sichtbar) */
.table.fo-dichte-kompakt > :not(caption) > * > * { padding-top: .12rem; padding-bottom: .12rem; }
.table.fo-dichte-kompakt td, .table.fo-dichte-kompakt th { font-size: .82rem; }
.table.fo-dichte-kompakt .fo-thumb { width: 28px; height: 28px; border-radius: .35rem; }
.table.fo-dichte-kompakt .badge { font-size: .68rem; padding: .2em .4em; }
.table.fo-dichte-kompakt .btn-sm { --bs-btn-padding-y: .1rem; --bs-btn-padding-x: .35rem; font-size: .75rem; }

/* Bild-Hovervorschau */
.fo-bildvorschau {
  position: fixed; z-index: 2000; display: none; pointer-events: none;
  background: var(--bs-body-bg); border: 1px solid var(--bs-border-color);
  border-radius: .5rem; padding: 4px; box-shadow: 0 8px 24px rgba(0,0,0,.25);
}
.fo-bildvorschau img { width: 210px; height: 210px; object-fit: contain; display: block; }
/* Mehrfach-Sortierung: Prioritätszahl */
.fo-sort-prio { font-size: .6rem; font-weight: 700; margin-left: 1px; color: var(--bs-primary); vertical-align: super; }
/* Tastatur-Navigation: aktive Zeile */
tr.fo-row.fo-row-active > td { background: var(--bs-primary-bg-subtle) !important; }
tr.fo-row:focus { outline: 2px solid var(--bs-primary); outline-offset: -2px; }
tr.fo-row:focus-visible { outline: 2px solid var(--bs-primary); outline-offset: -2px; }

/* Listen-Kopf: Titel + Toolbar in einer Zeile (Desktop), Suche schrumpft zuerst */
.fo-list-head {
  flex-wrap: nowrap !important;
}
.fo-list-head > h1 {
  min-width: 0;
  flex: 0 1 auto;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
/* Listen-Kopf: Pro-Seite-Auswahl links neben Suche halten */
.fo-list-toolbar {
  display: flex;
  align-items: center;
  flex-wrap: nowrap;
  gap: .5rem;
  margin-left: auto;
  min-width: 0;
}
.fo-list-search {
  display: flex;
  align-items: center;
  flex-wrap: nowrap;
  gap: .5rem;
  min-width: 0;
}
.fo-list-per-page {
  flex: 0 0 auto;
  width: auto;
}
.fo-list-search-input {
  flex: 1 1 300px;
  min-width: 0;
}
@media (max-width: 767.98px) {
  .fo-list-head {
    flex-wrap: wrap !important;
  }
  .fo-list-head > h1 {
    flex: 1 1 100%;
    white-space: normal;
  }
  .fo-list-toolbar {
    width: 100%;
    flex-wrap: wrap;
  }
  .fo-list-search {
    flex: 1 1 100%;
  }
  .fo-list-search-input {
    flex: 1 1 auto;
    min-width: 0;
  }
}

/* ---------- Dashboard To-do-Liste ---------- */
.fo-todo-add {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-start;
  gap: 8px;
  margin-bottom: 14px;
}
.fo-todo-add [name="titel"] { flex: 2 1 220px; }
.fo-todo-add [name="notiz"] { flex: 1 1 160px; }
.fo-todo-add .fo-todo-textarea {
  resize: vertical;
  min-height: 31px;
  max-height: 320px;
  line-height: 1.4;
  overflow-y: auto;
}
.fo-todo-list { display: flex; flex-direction: column; gap: 6px; }
.fo-todo-item {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  padding: 9px 11px;
  border: 1px solid var(--bs-border-color, #e9ecef);
  border-radius: 11px;
  background: var(--bs-body-bg, #fff);
  transition: border-color .15s ease, background .15s ease;
}
.fo-todo-item:hover { border-color: #c7ccd1; }
.fo-todo-check { flex: 0 0 auto; display: flex; }
.fo-todo-checkbtn {
  border: 0;
  background: transparent;
  padding: 0;
  margin-top: 1px;
  line-height: 1;
  font-size: 1.4rem;
  color: #b6bdc4;
  cursor: pointer;
  transition: color .15s ease;
}
.fo-todo-checkbtn:hover { color: #198754; }
.fo-todo-checkbtn.is-checked { color: #198754; }
.fo-todo-main { flex: 1 1 auto; min-width: 0; }
.fo-todo-title { font-weight: 600; line-height: 1.3; word-break: break-word; }
.fo-todo-note { font-size: .85rem; color: var(--bs-secondary-color, #6c757d); margin-top: 1px; }
.fo-todo-meta {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 4px 8px;
  margin-top: 4px;
  font-size: .76rem;
  color: var(--bs-secondary-color, #8a929b);
}
.fo-todo-meta .badge { font-weight: 600; }
.fo-todo-meta a { text-decoration: none; }
.fo-todo-del { flex: 0 0 auto; margin-left: 4px; }
.fo-todo-del .btn { font-size: 1rem; }
.fo-todo-item.is-done { opacity: .68; background: var(--bs-tertiary-bg, #f6f7f8); }
.fo-todo-item.is-done .fo-todo-title { text-decoration: line-through; font-weight: 500; }
.fo-todo-empty {
  text-align: center;
  color: var(--bs-secondary-color, #6c757d);
  font-size: .9rem;
  padding: 16px 0;
}
.fo-todo-done {
  margin-top: 14px;
  border-top: 1px dashed var(--bs-border-color, #e0e3e7);
  padding-top: 12px;
}
.fo-todo-done > summary {
  cursor: pointer;
  font-size: .82rem;
  font-weight: 600;
  color: var(--bs-secondary-color, #6c757d);
  margin-bottom: 9px;
}
