.invoice-project {
  padding-top: 35px;
}
.invoice-project .project-heading {
  font-size: clamp(35px, 4vw, 58px);
  max-width: 980px;
}
.invoice-project .project-lead {
  max-width: 830px;
  font-size: 17px;
}
.invoice-project .project-back {
  margin-bottom: 24px;
}
.invoice-intro {
  display: flex;
  flex-wrap: wrap;
  gap: 10px 25px;
  margin: 22px 0 30px;
  font-size: 12px;
}
.invoice-intro span::before {
  content: "↗ ";
  color: #ab391e;
}
.invoice-demo {
  border: 1px solid #cacbbf;
  border-radius: 12px;
  background: #fdfcf8;
  overflow: hidden;
}
.invoice-demo [hidden] {
  display: none !important;
}
.invoice-demo h2 {
  font-size: 26px;
  letter-spacing: -1px;
}
.invoice-demo h3 {
  font-size: 20px;
  letter-spacing: -0.5px;
}
.invoice-demo p {
  line-height: 1.55;
}
.invoice-demo button,
.invoice-demo select,
.invoice-demo input {
  font: inherit;
  font-size: 14px;
}
.invoice-demo button,
.invoice-demo select,
.invoice-demo input:not([type="checkbox"]) {
  min-height: 44px;
  border: 1px solid #b9baad;
  border-radius: 6px;
  padding: 9px 12px;
  color: #24241f;
  background: #fffefb;
}
.invoice-demo button:hover:not(:disabled) {
  background: #eeeee5;
  border-color: #77796c;
}
.invoice-demo button.primary {
  background: #272721;
  color: #fff;
  border-color: #272721;
}
.invoice-demo button.primary:hover:not(:disabled) {
  background: #46463b;
}
.invoice-demo button:disabled {
  opacity: 0.48;
  cursor: not-allowed;
}
.invoice-demo input[type="checkbox"] {
  width: 19px;
  height: 19px;
  accent-color: #9c381e;
  flex: none;
}
.inv-toolbar {
  padding: 23px 25px;
  background: #eaeae2;
  display: flex;
  flex-wrap: wrap;
  gap: 16px;
  align-items: end;
}
.inv-toolbar label,
.inv-controls label {
  display: grid;
  gap: 6px;
  font-size: 12px;
}
.inv-toolbar .inv-scenario {
  flex: 1;
  min-width: 210px;
}
.inv-toolbar select {
  width: 100%;
}
.inv-toolbar .inv-reset {
  margin-left: auto;
  background: transparent;
}
.inv-overview {
  display: flex;
  gap: 28px;
  flex-wrap: wrap;
  padding: 16px 25px;
  border-bottom: 1px solid #dedfd4;
  font-size: 12px;
  color: #626459;
}
.inv-overview strong {
  font-family: Avant;
  font-size: 22px;
  color: #24241f;
  margin-right: 6px;
  font-weight: normal;
}
.inv-overview .inv-clock {
  margin-left: auto;
  align-self: center;
}
.inv-tabs {
  display: flex;
  gap: 5px;
  padding: 12px 25px 0;
  border-bottom: 1px solid #cacbbf;
}
.invoice-demo .inv-tabs button {
  border: 0;
  border-radius: 5px 5px 0 0;
  border-bottom: 3px solid transparent;
  background: transparent;
  padding: 12px 16px;
}
.invoice-demo .inv-tabs button[aria-selected="true"] {
  border-bottom-color: #d94b25;
  background: #efefe7;
  font-weight: bold;
}
.inv-panel {
  padding: 24px 25px;
  min-height: 360px;
}
.inv-heading-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 18px;
  flex-wrap: wrap;
  margin-bottom: 18px;
}
.inv-heading-row p {
  font-size: 13px;
  color: #64665a;
  margin-top: 6px;
}
.inv-empty {
  border: 1px dashed #bdbfb2;
  padding: 35px;
  text-align: center;
  border-radius: 7px;
  background: #f7f6f1;
}
.inv-empty p {
  max-width: 520px;
  margin: 12px auto 0;
  font-size: 15px;
}
.inv-review-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  gap: 28px;
  align-items: start;
}
.inv-paper {
  background: #fff;
  border: 1px solid #dedfd4;
  box-shadow: 4px 5px 0 #eaeae2;
  padding: 25px;
  font-size: 13px;
}
.inv-paper .eyebrow {
  color: #a43b22;
  font-size: 9px;
}
.inv-paper h3 {
  margin: 14px 0 18px;
}
.inv-paper dl,
.inv-details dl {
  display: grid;
  grid-template-columns: minmax(100px, 0.8fr) minmax(0, 1.3fr);
  gap: 8px 16px;
  margin: 0;
}
.inv-paper dt,
.inv-details dt {
  color: #65675a;
}
.inv-paper dd,
.inv-details dd {
  margin: 0;
  overflow-wrap: anywhere;
}
.inv-paper .inv-total {
  border-top: 1px solid #d2d4c7;
  padding-top: 15px;
  margin-top: 18px;
  font-size: 23px;
  font-family: Avant;
}
.inv-note {
  color: #66685c;
  font-size: 12px;
  margin-top: 14px;
  overflow-wrap: anywhere;
}
.inv-checks {
  padding: 0;
  list-style: none;
  margin: 16px 0;
  font-size: 14px;
}
.inv-checks li {
  padding: 7px 0;
  border-bottom: 1px solid #e2e3d9;
}
.inv-status {
  display: inline-block;
  padding: 4px 8px;
  border-radius: 4px;
  background: #eeeee5;
  color: #414638;
  font-size: 11px;
  line-height: 1.4;
}
.inv-status.good {
  background: #e3eddf;
  color: #2f5231;
}
.inv-status.warn {
  background: #fbe8df;
  color: #8a321e;
}
.inv-approval {
  display: flex;
  gap: 10px;
  align-items: center;
  font-size: 14px;
  min-height: 48px;
  margin: 15px 0;
}
.inv-controls {
  display: flex;
  align-items: end;
  gap: 12px;
  flex-wrap: wrap;
  margin-top: 18px;
}
.inv-controls label {
  flex: 1;
  min-width: 145px;
}
.inv-controls input,
.inv-controls select {
  width: 100%;
  min-width: 0;
}
.inv-scroll {
  overflow-x: auto;
  border: 1px solid #d4d6ca;
  border-radius: 6px;
}
.inv-table {
  border-collapse: collapse;
  width: 100%;
  font-size: 13px;
  text-align: left;
}
.inv-table caption {
  text-align: left;
  padding: 12px;
  background: #f1f2e9;
  font-size: 12px;
}
.inv-table th,
.inv-table td {
  padding: 12px;
  border-right: 1px solid #e2e3da;
  border-bottom: 1px solid #d4d6ca;
  vertical-align: middle;
}
.inv-table th {
  font-size: 11px;
  font-weight: normal;
  color: #4e5547;
  background: #e9eee3;
  white-space: nowrap;
}
.inv-table td {
  min-width: 115px;
}
.inv-table tr[aria-selected="true"] {
  background: #f1f0e7;
}
.inv-table .inv-number {
  white-space: nowrap;
}
.inv-table .inv-select-cell {
  min-width: 52px;
}
.inv-table label.inv-selection {
  display: grid;
  place-items: center;
  min-width: 44px;
  min-height: 44px;
}
.invoice-demo .inv-table .inv-row-button {
  border: 0;
  background: transparent;
  padding: 3px;
  color: #84321f;
  text-decoration: underline;
  text-align: left;
}
.inv-table input.inv-account {
  width: 100px;
}
.inv-table .inv-reference {
  font-size: 11px;
  max-width: 190px;
  overflow-wrap: anywhere;
}
.inv-details {
  margin-top: 18px;
  padding: 16px 18px;
  background: #f3f3ec;
  border: 1px solid #dcded0;
  border-radius: 6px;
  font-size: 13px;
}
.inv-details summary {
  cursor: pointer;
  min-height: 30px;
  font-weight: bold;
}
.inv-details dl {
  margin-top: 12px;
}
.inv-message {
  white-space: pre-wrap;
  overflow-wrap: anywhere;
  font: inherit;
  font-size: 13px;
  background: #fffefb;
  border-left: 3px solid #d95b35;
  padding: 16px;
  margin: 14px 0 0;
}
.inv-detail-title {
  margin: 18px 0 8px;
}
.inv-feedback {
  padding: 15px 25px;
  border-top: 1px solid #d9dbcd;
  border-bottom: 1px solid #d9dbcd;
  background: #f1f0e7;
  font-size: 14px;
  min-height: 53px;
}
.inv-log {
  padding: 14px 25px 18px;
  font-size: 12px;
}
.inv-log summary {
  cursor: pointer;
  padding: 7px 0;
}
.inv-log ol {
  margin: 8px 0 0;
  padding-left: 20px;
  display: grid;
  gap: 5px;
}
.inv-log time {
  color: #757769;
  margin-right: 8px;
}
.invoice-about {
  border-top: 1px solid #cccac0;
  margin-top: 26px;
  padding-top: 20px;
  font-size: 13px;
  color: #5d6053;
}
.invoice-about summary {
  cursor: pointer;
  font-weight: bold;
  padding: 8px 0;
  color: #33362c;
}
.invoice-about p {
  margin: 10px 0;
  max-width: 940px;
}
.invoice-about ol {
  padding-left: 22px;
  line-height: 1.8;
}
@media (max-width: 700px) {
  .invoice-project {
    padding-top: 25px;
  }
  .invoice-project .project-heading {
    font-size: clamp(31px, 8vw, 43px);
    letter-spacing: -1.6px;
    overflow-wrap: anywhere;
  }
  .inv-toolbar,
  .inv-panel {
    padding: 17px 14px;
  }
  .inv-toolbar {
    gap: 10px;
  }
  .inv-toolbar .inv-scenario {
    flex-basis: 100%;
  }
  .inv-toolbar .inv-reset {
    margin-left: 0;
  }
  .inv-overview {
    gap: 10px 18px;
    padding: 12px 14px;
  }
  .inv-overview .inv-clock {
    margin-left: 0;
    flex-basis: 100%;
  }
  .inv-tabs {
    padding: 8px 6px 0;
    gap: 0;
  }
  .invoice-demo .inv-tabs button {
    flex: 1;
    padding: 11px 5px;
    font-size: 12px;
  }
  .inv-review-grid {
    grid-template-columns: 1fr;
    gap: 22px;
  }
  .inv-paper {
    padding: 18px;
  }
  .inv-controls {
    gap: 12px;
  }
  .inv-controls label {
    flex-basis: 100%;
  }
  .inv-controls > button {
    width: 100%;
  }
  .inv-feedback,
  .inv-log {
    padding: 14px;
  }
  .inv-details {
    padding: 12px;
  }
  .inv-details dl {
    grid-template-columns: 1fr;
    gap: 3px;
  }
  .inv-details dd {
    margin-bottom: 8px;
  }
  .inv-heading-row select {
    max-width: 100%;
    width: 100%;
  }
  .inv-empty {
    padding: 25px 16px;
  }
}
/* Mobile Tabellen ohne seitliches Scrollen */
@media (max-width: 700px) {
  .inv-scroll {
    overflow: visible;
    border: 0;
  }

  .inv-table,
  .inv-table tbody {
    display: block;
    width: 100%;
    min-width: 0;
  }

  .inv-table caption {
    display: block;
    margin-bottom: 12px;
    border-radius: 6px;
    line-height: 1.5;
  }

  /* Spaltenüberschriften visuell ausblenden */
  .inv-table thead {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    overflow: hidden;
    clip-path: inset(50%);
  }

  .inv-table tbody tr {
    display: block;
    margin-bottom: 16px;
    padding: 8px 14px;
    border: 1px solid #d4d6ca;
    border-radius: 8px;
    background: #fffefb;
  }

  .inv-table tbody tr[aria-selected="true"] {
    background: #f1f0e7;
    border-color: #858878;
  }

  .inv-table tbody td {
    display: grid;
    grid-template-columns: minmax(0, 1fr);
    gap: 5px;
    min-width: 0;
    max-width: 100%;
    padding: 12px 0;
    border-right: 0;
    border-bottom: 1px solid #e2e3da;
    overflow-wrap: anywhere;
    white-space: normal;
  }

  .inv-table tbody td:last-child {
    border-bottom: 0;
  }

  .inv-table tbody td::before {
    font-size: 11px;
    font-weight: bold;
    color: #65675a;
  }

  #inv-payment-rows td:nth-child(1)::before {
    content: "Rechnung";
  }

  #inv-payment-rows td:nth-child(2)::before {
    content: "Betrag";
  }

  #inv-payment-rows td:nth-child(3)::before {
    content: "Zahlungsstatus";
  }

  #inv-payment-rows td:nth-child(4)::before {
    content: "Buchhaltung";
  }

  #inv-payment-rows td:nth-child(5)::before {
    content: "Fällig am";
  }

  #inv-payment-rows td:nth-child(6)::before {
    content: "Erinnerung";
  }

  #inv-book-rows td:nth-child(1)::before {
    content: "Für Sammelübergabe auswählen";
  }

  #inv-book-rows td:nth-child(2)::before {
    content: "Beleg";
  }

  #inv-book-rows td:nth-child(3)::before {
    content: "Zahlungsstatus";
  }

  #inv-book-rows td:nth-child(4)::before {
    content: "Kontovorschlag";
  }

  #inv-book-rows td:nth-child(5)::before {
    content: "Buchhaltungsstatus";
  }

  #inv-book-rows td:nth-child(6)::before {
    content: "Übergabereferenz";
  }

  .inv-table tbody td[colspan]::before {
    content: none !important;
  }

  .inv-table .inv-number {
    white-space: normal;
  }

  .inv-table label.inv-selection {
    justify-self: start;
  }

  .inv-table input.inv-account {
    width: 100%;
    max-width: 220px;
  }

  .inv-table .inv-reference {
    max-width: 100%;
  }

  .invoice-demo .inv-table .inv-row-button {
    justify-self: start;
    max-width: 100%;
    white-space: normal;
  }
}
