:root {
  color-scheme: light;
  --ink: #0c0e12;
  --ink-2: #20242c;
  --graphite: #5c6470;
  --graphite-2: #8a929c;
  --navy: #27407a;
  --navy-deep: #16264c;
  --navy-700: #1e3260;
  --navy-mist: #95a6cc;
  --gold: #e0a82e;
  --gold-deep: #be851a;
  --mist: #f5f3ef;
  --paper: #ffffff;
  --warm: #fbfaf7;
  --cloud: #ece9e3;
  --line: #e6e2db;
  --line-soft: #efebe4;
  --danger: #b64035;
  --success: #1d7257;
  --shadow: 0 20px 60px -44px rgba(12, 14, 18, 0.5);
  --font: "Sora", system-ui, sans-serif;
  --mono: "Space Grotesk", ui-monospace, monospace;
  font-family: var(--font);
  background: var(--warm);
  color: var(--ink);
}

* {
  box-sizing: border-box;
}

html {
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

body {
  margin: 0;
  min-width: 320px;
  min-height: 100svh;
  background:
    linear-gradient(180deg, rgba(245, 243, 239, 0.72), rgba(255, 255, 255, 0) 460px),
    var(--warm);
}

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

button {
  cursor: pointer;
}

.login-screen {
  min-height: 100svh;
  display: grid;
  grid-template-columns: minmax(360px, 0.86fr) minmax(520px, 1.14fr);
  background: var(--paper);
}

.login-brand {
  padding: clamp(28px, 5vw, 56px);
  background: var(--navy-deep);
  color: var(--paper);
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  gap: 42px;
  min-height: 100svh;
}

.brand-lockup {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  font-weight: 800;
  letter-spacing: 0;
}

.brand-lockup img {
  width: 38px;
  height: 38px;
  border-radius: 9px;
  flex: none;
}

.brand-word {
  font-size: 22px;
  line-height: 1;
}

.brand-word span {
  color: var(--gold);
}

.login-brand h1 {
  max-width: 12ch;
  margin: 0;
  font-size: clamp(34px, 4.5vw, 54px);
  line-height: 1.04;
  letter-spacing: 0;
}

.login-brand p {
  max-width: 48ch;
  margin: 14px 0 0;
  color: rgba(255, 255, 255, 0.72);
  font-size: 14px;
  line-height: 1.55;
}

.login-meta {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 14px;
}

.login-meta span {
  display: block;
  padding-top: 13px;
  border-top: 1px solid rgba(255, 255, 255, 0.16);
  font-family: var(--mono);
  font-size: 11px;
  letter-spacing: 0.11em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.56);
}

.login-panel {
  display: grid;
  align-items: center;
  padding: clamp(28px, 6vw, 84px);
  background:
    linear-gradient(120deg, rgba(224, 168, 46, 0.08), transparent 34%),
    var(--warm);
}

.login-card {
  width: min(100%, 470px);
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: 8px;
  box-shadow: var(--shadow);
  padding: 32px;
}

.eyebrow {
  margin: 0 0 10px;
  font-family: var(--mono);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--gold-deep);
}

.login-card h2,
.panel-title h2,
.workspace-head h1 {
  margin: 0;
  font-weight: 800;
  letter-spacing: 0;
  line-height: 1.08;
}

.login-card h2 {
  font-size: 30px;
}

.login-card .sub {
  margin: 10px 0 26px;
  color: var(--graphite);
  line-height: 1.6;
}

.field {
  display: grid;
  gap: 8px;
  margin-bottom: 16px;
}

.field span,
.mini-label {
  font-family: var(--mono);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--graphite);
}

.field input,
.field textarea,
.field select,
.compact-input,
.search-input {
  width: 100%;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: var(--paper);
  color: var(--ink);
  outline: none;
  transition: border-color 0.18s ease, box-shadow 0.18s ease, background 0.18s ease;
}

.field input,
.compact-input,
.search-input {
  min-height: 44px;
  padding: 11px 12px;
}

.field textarea {
  min-height: 120px;
  padding: 12px;
  resize: vertical;
  line-height: 1.55;
}

.field input:focus,
.field textarea:focus,
.field select:focus,
.compact-input:focus,
.search-input:focus {
  border-color: var(--navy);
  box-shadow: 0 0 0 3px rgba(39, 64, 122, 0.12);
}

.login-actions {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  margin-top: 22px;
}

.button {
  min-height: 40px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  border: 1px solid transparent;
  border-radius: 5px;
  padding: 10px 14px;
  color: var(--ink);
  background: transparent;
  font-weight: 750;
  font-size: 13px;
  line-height: 1;
  transition: transform 0.16s ease, background 0.16s ease, border-color 0.16s ease, color 0.16s ease;
}

.button:active {
  transform: translateY(1px);
}

.button.primary {
  background: var(--gold);
  color: var(--ink);
}

.button.primary:hover {
  background: var(--gold-deep);
  color: var(--paper);
}

.button.secondary {
  border-color: var(--line);
  background: var(--paper);
  color: var(--navy);
}

.button.secondary:hover {
  border-color: var(--navy-mist);
  background: var(--mist);
}

.button.dark {
  background: var(--navy);
  color: var(--paper);
}

.button.dark:hover {
  background: var(--navy-deep);
}

.button.ghost {
  color: var(--graphite);
}

.button.ghost:hover {
  background: var(--mist);
  color: var(--ink);
}

.button.success {
  border-color: rgba(29, 114, 87, 0.18);
  background: rgba(29, 114, 87, 0.1);
  color: var(--success);
}

.button.success:hover {
  background: rgba(29, 114, 87, 0.15);
}

.button.danger {
  border-color: rgba(182, 64, 53, 0.18);
  background: rgba(182, 64, 53, 0.08);
  color: var(--danger);
}

.button.danger:hover {
  background: rgba(182, 64, 53, 0.13);
}

.button.icon {
  width: 36px;
  height: 36px;
  min-height: 36px;
  padding: 0;
  border-color: var(--line);
  background: var(--paper);
}

.button.icon-check {
  width: 30px;
  height: 30px;
  min-height: 30px;
  padding: 0;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 6px;
  border: 1px solid rgba(29, 114, 87, 0.2);
  background: rgba(29, 114, 87, 0.1);
  color: var(--success);
}

.button.icon-check:hover {
  background: rgba(29, 114, 87, 0.2);
}

.button.icon-check svg {
  width: 14px;
  height: 14px;
}

.status-line {
  min-height: 20px;
  margin: 16px 0 0;
  color: var(--danger);
  font-size: 13px;
  line-height: 1.5;
}

.app-shell {
  min-height: 100svh;
  display: grid;
  grid-template-columns: 236px minmax(0, 1fr);
}

.sidebar {
  position: sticky;
  top: 0;
  height: 100svh;
  background: var(--navy-deep);
  color: var(--paper);
  display: flex;
  flex-direction: column;
  padding: 20px 16px;
  overflow-y: auto;
}

.sidebar .brand-lockup {
  padding: 4px 6px 22px;
}

.nav-section {
  display: grid;
  gap: 4px;
  margin: 10px 0 22px;
}

.nav-title {
  margin: 14px 8px 7px;
  font-family: var(--mono);
  font-size: 10px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.44);
}

.nav-item {
  display: flex;
  align-items: center;
  gap: 10px;
  width: 100%;
  min-height: 38px;
  border: 0;
  border-radius: 6px;
  padding: 9px 10px;
  color: rgba(255, 255, 255, 0.76);
  background: transparent;
  text-align: left;
  font-size: 13px;
  font-weight: 650;
}

.nav-item:hover,
.nav-item.active {
  color: var(--paper);
  background: rgba(255, 255, 255, 0.1);
}

.nav-item.active {
  box-shadow: inset 3px 0 0 var(--gold);
}

.nav-icon {
  width: 18px;
  height: 18px;
  flex: none;
}

.sidebar-bottom {
  margin-top: auto;
  display: grid;
  gap: 10px;
}

.user-chip {
  display: grid;
  grid-template-columns: 34px 1fr;
  gap: 10px;
  align-items: center;
  padding: 10px;
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.06);
}

.avatar {
  width: 34px;
  height: 34px;
  display: grid;
  place-items: center;
  border-radius: 8px;
  background: var(--gold);
  color: var(--navy-deep);
  font-family: var(--mono);
  font-size: 12px;
  font-weight: 800;
  text-transform: uppercase;
}

.user-chip strong {
  display: block;
  color: var(--paper);
  font-size: 13px;
}

.user-chip span {
  display: block;
  margin-top: 2px;
  color: rgba(255, 255, 255, 0.54);
  font-size: 11px;
}

.main {
  min-width: 0;
  background: var(--warm);
}

.topbar {
  position: sticky;
  top: 0;
  z-index: 20;
  min-height: 70px;
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 18px;
  align-items: center;
  padding: 14px 28px;
  border-bottom: 1px solid rgba(230, 226, 219, 0.82);
  background: rgba(251, 250, 247, 0.88);
  backdrop-filter: blur(18px) saturate(1.2);
}

.search-wrap {
  position: relative;
  max-width: 620px;
}

.search-input {
  padding-left: 42px;
  background: var(--paper);
}

.search-wrap svg {
  position: absolute;
  left: 14px;
  top: 50%;
  width: 17px;
  height: 17px;
  color: var(--graphite-2);
  transform: translateY(-50%);
}

.topbar-actions {
  display: flex;
  align-items: center;
  gap: 10px;
}

.workspace {
  padding: 24px 22px;
}

.workspace-head {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 24px;
  align-items: center;
  margin-bottom: 16px;
}

.workspace-head h1 {
  font-size: clamp(26px, 2.3vw, 34px);
}

.workspace-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 10px;
}

.workspace-meta span {
  display: inline-flex;
  min-height: 24px;
  align-items: center;
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 4px 9px;
  background: var(--paper);
  color: var(--graphite);
  font-family: var(--mono);
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.date-block {
  min-width: 160px;
  padding: 13px 15px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--paper);
  text-align: right;
}

.date-block strong {
  display: block;
  font-size: 15px;
}

.date-block span {
  display: block;
  margin-top: 3px;
  font-family: var(--mono);
  font-size: 11px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--graphite-2);
}

.stats-row {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 14px;
  margin-bottom: 18px;
}

.stat {
  min-height: 86px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--paper);
  padding: 16px;
}

.stat span {
  font-family: var(--mono);
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--graphite-2);
}

.stat strong {
  display: block;
  margin-top: 8px;
  font-size: 26px;
  line-height: 1;
}

.stat em {
  display: block;
  margin-top: 9px;
  color: var(--graphite);
  font-size: 12px;
  font-style: normal;
}

.hub-grid {
  display: grid;
  grid-template-columns: minmax(240px, 0.9fr) minmax(440px, 1.36fr) minmax(220px, 0.82fr);
  gap: 18px;
  align-items: start;
}

.panel {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--paper);
  box-shadow: 0 16px 42px -38px rgba(12, 14, 18, 0.55);
  overflow: hidden;
}

.panel-header {
  min-height: 64px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  padding: 16px 18px;
  border-bottom: 1px solid var(--line-soft);
}

.panel-title h2 {
  font-size: 18px;
}

.panel-title p {
  margin: 4px 0 0;
  color: var(--graphite);
  font-size: 12px;
  line-height: 1.45;
}

.tabs,
.segmented {
  display: inline-flex;
  align-items: center;
  gap: 3px;
  padding: 3px;
  border: 1px solid var(--line);
  border-radius: 7px;
  background: var(--mist);
}

.tab,
.segment {
  min-height: 30px;
  border: 0;
  border-radius: 5px;
  padding: 7px 10px;
  background: transparent;
  color: var(--graphite);
  font-size: 12px;
  font-weight: 700;
}

.tab.active,
.segment.active {
  background: var(--paper);
  color: var(--navy);
  box-shadow: 0 1px 2px rgba(12, 14, 18, 0.05);
}

.task-list {
  display: grid;
  gap: 0;
}

.task-row {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 12px;
  padding: 14px 18px;
  border-bottom: 1px solid var(--line-soft);
  background: var(--paper);
  transition: background 0.16s ease, opacity 0.16s ease;
}

.task-row:last-child {
  border-bottom: 0;
}

.task-row:hover,
.task-card:hover {
  background: #fbfaf8;
}

.task-row.dragging,
.task-card.dragging {
  opacity: 0.45;
}

.task-row.overdue {
  box-shadow: inset 3px 0 0 var(--danger);
}

.task-card.overdue {
  border-color: var(--danger);
}

.task-main {
  min-width: 0;
}

.task-title {
  display: flex;
  align-items: center;
  gap: 8px;
  min-width: 0;
  font-size: 14px;
  font-weight: 750;
}

.task-title span {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.task-description {
  margin: 6px 0 0;
  color: var(--graphite);
  font-size: 12px;
  line-height: 1.45;
}

.task-meta {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
  margin-top: 8px;
}

.chip {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  min-height: 22px;
  padding: 4px 8px;
  border-radius: 999px;
  background: var(--mist);
  color: var(--graphite);
  font-family: var(--mono);
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.05em;
  text-transform: uppercase;
}

.chip.gold {
  background: rgba(224, 168, 46, 0.16);
  color: var(--gold-deep);
}

.chip.navy {
  background: rgba(39, 64, 122, 0.1);
  color: var(--navy);
}

.chip.success {
  background: rgba(29, 114, 87, 0.1);
  color: var(--success);
}

.chip.danger {
  background: rgba(182, 64, 53, 0.1);
  color: var(--danger);
}

.chip-creator {
  background: rgba(116, 82, 30, 0.1);
  color: var(--gold-deep);
  font-style: italic;
}

.task-actions {
  display: flex;
  align-items: start;
  justify-content: flex-end;
  flex-wrap: wrap;
  gap: 6px;
  max-width: 220px;
}

.task-card-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: 12px;
}

.task-card-footer {
  padding-top: 10px;
  margin-top: 10px;
  border-top: 1px solid var(--line-soft);
}

.task-card-footer-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 6px;
}

.button.card-icon-btn {
  width: 30px;
  height: 30px;
  min-height: 30px;
  padding: 0;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 6px;
  border: 1px solid var(--line);
  background: var(--paper);
  color: var(--graphite);
}

.button.card-icon-btn:hover {
  background: var(--mist);
  color: var(--ink);
}

.button.card-icon-btn svg {
  width: 14px;
  height: 14px;
}

.button.icon-delete {
  width: 30px;
  height: 30px;
  min-height: 30px;
  padding: 0;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 6px;
  border: 1px solid rgba(182, 64, 53, 0.2);
  background: rgba(182, 64, 53, 0.08);
  color: var(--danger);
}

.button.icon-delete:hover {
  background: rgba(182, 64, 53, 0.16);
}

.button.icon-delete svg {
  width: 14px;
  height: 14px;
}

.task-comments {
  display: grid;
  gap: 8px;
  margin-top: 12px;
}

.task-comment {
  display: grid;
  grid-template-columns: 28px 1fr;
  gap: 8px;
  align-items: start;
  color: var(--graphite);
  font-size: 12px;
  line-height: 1.45;
}

.task-comment strong {
  display: grid;
  place-items: center;
  min-height: 24px;
  border-radius: 6px;
  background: rgba(39, 64, 122, 0.1);
  color: var(--navy);
  font-family: var(--mono);
  font-size: 10px;
}

.comment-form {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 8px;
}

.comment-form input {
  width: 100%;
  min-height: 34px;
  border: 1px solid var(--line);
  border-radius: 7px;
  padding: 8px 10px;
  background: #fff;
  color: var(--ink);
  font: inherit;
  font-size: 12px;
}

.board {
  display: grid;
  grid-template-columns: repeat(3, minmax(120px, 1fr));
  gap: 10px;
  padding: 14px;
}

.lane {
  min-height: 80px;
  border: 1px dashed transparent;
  border-radius: 8px;
  background: #fbfaf8;
  overflow: hidden;
}

.lane.drag-over {
  border-color: var(--gold);
  background: rgba(224, 168, 46, 0.08);
}

.lane-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 12px;
  border-bottom: 1px solid var(--line-soft);
}

.lane-head strong {
  font-size: 13px;
}

.lane-head span {
  font-family: var(--mono);
  font-size: 11px;
  color: var(--graphite-2);
}

.lane-tasks {
  display: grid;
  gap: 10px;
  padding: 10px;
}

.task-card {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--paper);
  padding: 12px;
  transition: background 0.16s ease, transform 0.16s ease;
}

.task-card:active {
  transform: scale(0.99);
}

.task-card h3 {
  margin: 0;
  font-size: 13px;
  line-height: 1.35;
}

.task-card p {
  margin: 8px 0 0;
  color: var(--graphite);
  font-size: 12px;
  line-height: 1.45;
}

.done-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
  padding: 0 14px 14px;
}

.done-panel {
  border: 1px solid var(--line-soft);
  border-radius: 8px;
  background: #fbfaf8;
  overflow: hidden;
}

.done-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 12px;
  border-bottom: 1px solid var(--line-soft);
}

.done-head strong {
  font-size: 13px;
}

.done-head span {
  font-family: var(--mono);
  font-size: 11px;
  color: var(--graphite-2);
}

.done-list {
  display: grid;
}

.done-item {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 10px;
  align-items: center;
  padding: 12px;
  border-bottom: 1px solid var(--line-soft);
  background: var(--paper);
}

.done-item:last-child {
  border-bottom: 0;
}

.done-item strong {
  display: block;
  font-size: 13px;
  line-height: 1.35;
}

.done-item span {
  display: block;
  margin-top: 4px;
  color: var(--graphite);
  font-size: 12px;
}

.done-item-note {
  display: block;
  margin-top: 6px;
  padding: 6px 8px;
  border-radius: 5px;
  background: rgba(39, 64, 122, 0.07);
  color: var(--ink-2);
  font-size: 12px;
  line-height: 1.45;
}

.compact-empty {
  padding: 18px 12px;
}

.side-stack {
  display: grid;
  gap: 18px;
}

.notes-list {
  display: grid;
  max-height: 390px;
  overflow: auto;
}

.note-row {
  width: 100%;
  border: 0;
  border-bottom: 1px solid var(--line-soft);
  padding: 13px 18px;
  background: var(--paper);
  text-align: left;
}

.note-row:hover,
.note-row.active {
  background: #fbfaf8;
}

.note-row.active {
  box-shadow: inset 3px 0 0 var(--gold);
}

.note-row strong {
  display: block;
  color: var(--ink);
  font-size: 13px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.note-row span {
  display: block;
  margin-top: 5px;
  color: var(--graphite);
  font-size: 12px;
  line-height: 1.4;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.note-editor {
  display: grid;
  gap: 12px;
  padding: 14px 18px 18px;
  border-top: 1px solid var(--line-soft);
}

.team-aufgaben-list {
  display: grid;
  gap: 0;
}

.team-member-card {
  padding: 14px 18px;
  border-bottom: 1px solid var(--line-soft);
}

.team-member-card:last-child {
  border-bottom: 0;
}

.team-member-header {
  display: grid;
  grid-template-columns: 34px 1fr;
  gap: 10px;
  align-items: center;
  margin-bottom: 10px;
}

.team-member-info {
  display: flex;
  align-items: center;
  gap: 8px;
}

.team-member-info strong {
  font-size: 13px;
  font-weight: 600;
}

.team-member-tasks {
  display: grid;
  gap: 6px;
  padding-left: 44px;
}

.team-task-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  padding: 7px 10px;
  background: var(--mist);
  border-radius: 6px;
}

.team-task-title {
  font-size: 12px;
  color: var(--ink-2);
  flex: 1;
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.team-task-empty {
  margin: 0;
  font-size: 12px;
  color: var(--graphite);
  font-style: italic;
}

.chip-status-today {
  background: rgba(29, 114, 87, 0.12);
  color: var(--success);
}

.chip-status-week {
  background: rgba(39, 64, 122, 0.12);
  color: var(--navy);
}

.chip-status-blocked {
  background: rgba(182, 64, 53, 0.12);
  color: var(--danger);
}

.empty-state {
  padding: 32px 18px;
  text-align: center;
  color: var(--graphite);
  font-size: 13px;
  line-height: 1.5;
}

.modal-backdrop {
  position: fixed;
  inset: 0;
  z-index: 80;
  display: grid;
  place-items: center;
  padding: 20px;
  background: rgba(12, 14, 18, 0.38);
}

.modal {
  width: min(100%, 520px);
  border-radius: 8px;
  background: var(--paper);
  box-shadow: 0 34px 90px -40px rgba(12, 14, 18, 0.72);
  overflow: hidden;
}

.modal-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 18px 20px;
  border-bottom: 1px solid var(--line-soft);
}

.modal-header h2 {
  margin: 0;
  font-size: 18px;
}

.modal-body {
  padding: 20px;
}

.modal-footer {
  display: flex;
  justify-content: flex-end;
  gap: 10px;
  padding: 16px 20px;
  border-top: 1px solid var(--line-soft);
  background: #fbfaf8;
}

.toast {
  position: fixed;
  right: 22px;
  bottom: 22px;
  z-index: 100;
  max-width: 360px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--navy-deep);
  color: var(--paper);
  padding: 14px 16px;
  box-shadow: 0 20px 46px -28px rgba(12, 14, 18, 0.7);
  font-size: 13px;
  line-height: 1.5;
}

.hidden {
  display: none !important;
}

/* Posteingang: Badges, breites Modal und Anfrage-Karten */
.inbox-button {
  position: relative;
}

.inbox-badge,
.nav-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 18px;
  height: 18px;
  margin-left: 6px;
  padding: 0 5px;
  border-radius: 999px;
  background: var(--gold);
  color: var(--navy-deep);
  font-size: 11px;
  font-weight: 700;
}

.nav-badge {
  margin-left: auto;
}

.field-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 14px;
}

.modal-wide {
  width: min(100%, 720px);
}

.inbox-body {
  display: grid;
  gap: 26px;
  max-height: min(72vh, 640px);
  overflow-y: auto;
}

.inbox-heading {
  display: flex;
  align-items: center;
  gap: 8px;
  margin: 0 0 4px;
  font-size: 15px;
}

.inbox-count {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 20px;
  height: 20px;
  padding: 0 6px;
  border-radius: 999px;
  background: var(--mist);
  color: var(--graphite);
  font-size: 12px;
  font-weight: 700;
}

.inbox-hint {
  margin: 0 0 12px;
  color: var(--graphite);
  font-size: 12px;
}

.inbox-list {
  display: grid;
  gap: 12px;
}

.inbox-card {
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 14px;
  background: var(--warm);
}

.inbox-card-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 6px;
}

.inbox-card-head strong {
  font-size: 14px;
}

.inbox-card-desc {
  margin: 0 0 10px;
  color: var(--ink-2);
  font-size: 13px;
  line-height: 1.5;
}

.inbox-card-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-bottom: 10px;
}

.inbox-reason {
  width: 100%;
  min-height: 56px;
  margin-bottom: 10px;
  resize: vertical;
}

.inbox-card-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.inbox-feedback {
  margin: 8px 0 0;
  padding: 10px 12px;
  border-radius: 6px;
  background: var(--mist);
  color: var(--ink-2);
  font-size: 12px;
  line-height: 1.5;
}

.chip-assign-pending {
  background: rgba(224, 168, 46, 0.16);
  color: var(--gold-deep);
}

.chip-assign-accepted {
  background: rgba(29, 114, 87, 0.12);
  color: var(--success);
}

.chip-assign-rejected {
  background: rgba(182, 64, 53, 0.12);
  color: var(--danger);
}

.chip-assign-deferred {
  background: rgba(39, 64, 122, 0.12);
  color: var(--navy);
}

/* Inbox-Tabs */
.inbox-tabs {
  display: flex;
  gap: 0;
  border-bottom: 1px solid var(--line-soft);
  background: var(--warm);
}

.inbox-tab {
  flex: 1;
  min-height: 40px;
  border: 0;
  border-bottom: 2px solid transparent;
  padding: 10px 14px;
  background: transparent;
  color: var(--graphite);
  font-size: 13px;
  font-weight: 700;
  text-align: center;
  cursor: pointer;
  transition: color 0.15s ease, border-color 0.15s ease;
}

.inbox-tab.active {
  color: var(--navy);
  border-bottom-color: var(--gold);
}

.inbox-tab:hover:not(.active) {
  background: var(--mist);
  color: var(--ink);
}

.inbox-badge-inline {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 17px;
  height: 17px;
  padding: 0 5px;
  border-radius: 999px;
  background: var(--gold);
  color: var(--navy-deep);
  font-size: 10px;
  font-weight: 700;
  vertical-align: middle;
  margin-left: 4px;
}

.inbox-body {
  display: grid;
  gap: 0;
  max-height: 420px;
  overflow-y: auto;
}

/* Direktauftrag-Zeilen */
.direktauftrag-row {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 12px;
  align-items: start;
  padding: 14px 18px;
  border-bottom: 1px solid var(--line-soft);
  background: var(--paper);
}

.direktauftrag-row:last-child {
  border-bottom: 0;
}

.direktauftrag-row.gesendet {
  grid-template-columns: 1fr;
}

.direktauftrag-info {
  min-width: 0;
}

.direktauftrag-info strong {
  display: block;
  font-size: 13px;
  font-weight: 700;
  margin-bottom: 4px;
}

.direktauftrag-desc {
  display: block;
  margin: 4px 0 6px;
  color: var(--graphite);
  font-size: 12px;
  line-height: 1.45;
}

.direktauftrag-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: 6px;
}

.direktauftrag-actions {
  display: flex;
  flex-direction: column;
  gap: 6px;
  flex: none;
}

.direktauftrag-reason {
  margin: 6px 0 0;
  padding: 8px 10px;
  border-radius: 6px;
  background: rgba(182, 64, 53, 0.07);
  color: var(--danger);
  font-size: 12px;
  line-height: 1.45;
}

/* Direktauftrag-Status-Chips */
.direktauftrag-status-pending {
  background: rgba(224, 168, 46, 0.16);
  color: var(--gold-deep);
}

.direktauftrag-status-accepted {
  background: rgba(29, 114, 87, 0.12);
  color: var(--success);
}

.direktauftrag-status-rejected {
  background: rgba(182, 64, 53, 0.12);
  color: var(--danger);
}

.direktauftrag-status-deferred {
  background: rgba(39, 64, 122, 0.12);
  color: var(--navy);
}

/* Modal: Readonly-Felder */
.field-label {
  display: block;
  font-family: var(--mono);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--graphite);
  margin-bottom: 4px;
}

.field-value {
  margin: 0;
  font-size: 14px;
  color: var(--ink);
  font-weight: 600;
}

@media (max-width: 1340px) {
  .hub-grid {
    grid-template-columns: 1fr;
  }

  .side-stack {
    grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
    align-items: start;
  }
}

@media (max-width: 900px) {
  .login-screen {
    grid-template-columns: 1fr;
  }

  .login-brand {
    min-height: auto;
  }

  .login-meta {
    grid-template-columns: 1fr;
  }

  .app-shell {
    grid-template-columns: 1fr;
  }

  .sidebar {
    position: static;
    height: auto;
  }

  .nav-section {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .topbar,
  .workspace-head {
    grid-template-columns: 1fr;
  }

  .topbar-actions,
  .workspace-head .date-block {
    justify-self: start;
  }

  .stats-row,
  .side-stack,
  .board,
  .done-grid {
    grid-template-columns: 1fr;
  }

  .lane {
    min-height: 220px;
  }
}

@media (max-width: 620px) {
  .login-card,
  .workspace,
  .topbar {
    padding: 18px;
  }

  .workspace {
    padding: 18px 14px;
  }

  .topbar-actions,
  .login-actions,
  .panel-header,
  .workspace-head {
    align-items: start;
  }
}
