/* Redesign Runde 34 (2.99.0): Zahlungskarten, ein Statuswort, Dashboard, Belegliste, Neuigkeiten.
   Copyright © Fabian Stamminger @ The Platform Group */

/* R34-02: eine Chip-Variante, Höhe 24, Pille, Icon plus Wort, 13 px */
.documents-grid .doc-row .badge, .dash-recent-status .badge, .doc-head-pill .badge { display: inline-flex; align-items: center; gap: .3rem; min-height: 24px; max-height: 24px; padding: 0 .65rem; border-radius: 999px; font-size: 13px; line-height: 22px; white-space: nowrap; }
.doc-head-pill .badge i, .documents-grid .doc-row .badge i { font-size: 12px; }
.doc-head-pill { display: inline-flex; }
.doc-head-stage { color: var(--orlop-text-2, #4B5563); font-size: .875rem; }
.doc-head-stage:empty { display: none; }
.doc-mine-mark { margin-left: .5rem; padding: 0; border: 0; background: none; color: var(--orlop-text-2, #4B5563); font: inherit; font-size: .75rem; font-weight: 700; text-decoration: underline; text-underline-offset: 2px; cursor: pointer; position: relative; z-index: 3; }
.doc-mine-mark[aria-pressed="true"] { color: #0E1115; }
.doc-mine-mark:focus-visible { outline: 2px solid #0E1115; outline-offset: 2px; border-radius: 4px; }

/* R34-03: Tour-Hinweis als feste Zeile unter dem Titel, Karte "Zu klären" */
#tabDashboard > .tour-hint#tourHint { position: static; order: 0; display: flex; align-items: center; gap: .75rem; flex-wrap: wrap; min-height: 48px; max-width: none; width: 100%; margin: 0 0 1rem; padding: .5rem .75rem .5rem 1rem; border-radius: 12px; box-shadow: none; background: #fff; border: 1px solid var(--orlop-line, #D8DCE4); z-index: auto; box-sizing: border-box; }
#tabDashboard.dashboard-empty > .tour-hint#tourHint { display: flex !important; }
.dash-task-stack { list-style: none; margin: .75rem 0 .5rem; padding: 0; display: grid; gap: .25rem; max-width: 22rem; }
.dash-task-stack li { display: flex; justify-content: space-between; gap: 1rem; padding: .35rem 0; border-bottom: 1px solid var(--orlop-line, #D8DCE4); font-size: .9375rem; }
.dash-task-stack li strong { font-variant-numeric: tabular-nums; }
.dash-waiting-empty.is-warn > i { color: var(--orlop-amber, #B45309); }
.dash-waiting-empty.is-warn { height: auto; min-height: 0; }
.dash-recent-name { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; min-width: 0; }
@media (max-width: 767px) { #tabDashboard #dashStrip { display: none !important; } }

/* R34-04: Belegliste, Dateiname als Titel, Chevron, volle Breite */
.documents-grid .doc-row.is-novendor .dr-sub-file { display: block !important; }
.documents-grid .doc-row .dr-amount { text-align: right; font-variant-numeric: tabular-nums; }
.documents-grid .doc-row { cursor: pointer; }
.documents-grid .doc-row .dr-chev { color: var(--orlop-text-2, #4B5563); font-size: .75rem; justify-self: end; }
/* R53-01: Listen-Umbruch bei 1100 px */
@media (max-width: 1099px) {
  .documents-grid .doc-row .dr-status { grid-column: 1 / -1; }
}

/* R34-01: Zahlungen als Karten unter 768 px, Auswahlleiste höchstens 72 px */
.pay-cards { list-style: none; margin: 0; padding: 0; display: grid; gap: .75rem; }
.pay-card { display: grid; grid-template-columns: auto minmax(0, 1fr) auto; grid-template-areas: "pick main amount" "pick due due" "pick skonto skonto" "pick status status" "act act act"; gap: .25rem .75rem; padding: .85rem; background: #fff; border: 1px solid var(--orlop-line, #D8DCE4); border-radius: 14px; box-shadow: 0 1px 3px rgba(14,17,21,.06); align-items: start; }
.pay-card.is-escalated { box-shadow: inset 4px 0 0 #B91C1C; }
.pay-card-pick { grid-area: pick; min-width: 44px; min-height: 44px; display: inline-flex; align-items: center; justify-content: center; }
.pay-card-pick input { width: 22px; height: 22px; }
.pay-card-main { grid-area: main; min-width: 0; overflow-wrap: anywhere; }
.pay-card-amount { grid-area: amount; text-align: right; font-variant-numeric: tabular-nums; white-space: nowrap; }
.pay-card-due { grid-area: due; font-size: .875rem; }
.pay-card-skonto { grid-area: skonto; font-size: .875rem; }
.pay-card-status { grid-area: status; font-size: .875rem; }
.pay-card-actions { grid-area: act; display: flex; gap: .5rem; justify-content: flex-end; align-items: center; margin-top: .25rem; }
.pay-card:not(:has(.pay-card-pick)) { grid-template-areas: "main amount" "due due" "skonto skonto" "status status" "act act"; grid-template-columns: minmax(0, 1fr) auto; }
.pay-card-confirm { grid-column: 1 / -1; }
@media (max-width: 767px) {
  .pay-selbar { max-height: 72px; min-height: 0; padding: .5rem .75rem; display: flex; align-items: center; gap: .5rem; flex-wrap: nowrap; overflow: hidden; }
  .pay-selbar .pay-selbar-sum { flex: 1 1 auto; min-width: 0; font-size: .8125rem; line-height: 1.2; }
  .pay-selbar .pay-selbar-go { flex: 0 0 auto; min-height: 44px; white-space: nowrap; }
  .pay-selbar .pay-selbar-clear { flex: 0 0 auto; min-height: 44px; }
  .pay-head-actions { flex-wrap: nowrap; }
}


/* Mobil: Chevron an jeder Zeile, kein zweiter Pfeil im Betragsfeld */
/* R53-01: Listen-Umbruch bei 1100 px */
@media (max-width: 1099px) {
  .documents-grid .doc-row { position: relative; padding-right: 28px; }
  .documents-grid .doc-row::after { content: "\203A"; position: absolute; right: 8px; top: 50%; transform: translateY(-50%); font-size: 1.5rem; line-height: 1; color: var(--orlop-muted-text, #565C67); pointer-events: none; }
  .documents-grid .doc-row .dr-tap { display: none !important; }
  .documents-grid .doc-row .dr-amount { padding-right: 0; }
}
.documents-grid .doc-table .doc-row .dr-actcol { display: flex; align-items: center; gap: .5rem; justify-content: flex-end; }
.documents-grid .doc-row .dr-missing-text { color: var(--orlop-text-2, #4B5563); font-size: .8125rem; font-weight: 500; white-space: nowrap; }

/* R34-05: Neuigkeiten, Versionskarte mit Innenabstand, Balken innerhalb der Karte */
#newsList > .news-entry, #newsList .news-entry.news-entry { padding-left: 24px; box-sizing: border-box; }
#newsList .news-entry.is-target::before, #newsList .news-entry--lead::before { left: 0; top: 0; bottom: 0; border-radius: 12px 0 0 12px; }
.news-latest-banner { position: sticky; top: 8px; z-index: 5; display: flex; gap: .75rem; align-items: center; justify-content: space-between; flex-wrap: wrap; margin: 0 0 1rem; padding: .6rem 1rem; border: 1px solid var(--orlop-line, #D8DCE4); border-radius: 12px; background: #fff; box-shadow: 0 1px 3px rgba(14,17,21,.06); font-size: .9375rem; font-weight: 700; }
@media (min-width: 1440px) { #newsList .news-entry--lead .news-entry-body ul { column-gap: 3rem; } }

/* R34-04: Upload-Knopf am Handy beschriftet ("Hochladen") */
@media (max-width: 767px) {
  #docsHead .docs-upload-btn { width: auto; min-width: 44px; padding: 0 16px; border-radius: 999px; font-size: .9375rem; gap: .4rem; }
  #docsHead .docs-upload-btn i { font-size: .9rem; }
  #docsHead .docs-upload-btn span { display: inline; }
}
