/*
 * DoyaPos design system — single source of truth for both the terminal and the panels.
 *
 * Mobile-first and touch-first. The terminal is used standing up, one-handed, in salon
 * lighting, by someone who wants to be done in five seconds. Every rule below serves
 * that: large hit targets, high contrast, no hover-dependent affordances, and the
 * payment buttons parked where a thumb naturally lands.
 *
 * Palette follows the customer concept PDF (deep navy surfaces, DOYA blue accent).
 */

:root {
    /* Surfaces — darkest at the back, lighter as elements come forward. */
    --dp-bg:            #0b1220;
    --dp-surface:       #101c33;
    --dp-surface-2:     #16273f;
    --dp-surface-3:     #1d3252;
    --dp-border:        #24406b;

    /* Brand */
    --dp-blue:          #1f6fff;
    --dp-blue-strong:   #0d5ae8;
    --dp-navy:          #16305c;

    /* Payment. Cash and card must never be confused at a glance, so they differ in
       hue AND in position — colour alone is not an accessible distinction. */
    --dp-cash:          #1a7a3c;
    --dp-cash-strong:   #14612f;
    --dp-card:          var(--dp-blue);
    --dp-card-strong:   var(--dp-blue-strong);

    /* Text */
    --dp-text:          #eaf1ff;
    --dp-text-muted:    #93a7c8;
    --dp-text-dim:      #64789b;

    /* Status */
    --dp-danger:        #d64545;
    --dp-warn:          #d99a2b;
    --dp-ok:            #2fa36b;

    /* Touch targets. 56px is the floor; primary actions get considerably more.
       Anything smaller gets mis-tapped by wet or gloved hands. */
    --dp-tap-min:       56px;
    /* Comfortably above the 44px a thumb needs, and small enough that a phone shows a
       whole category without scrolling. */
    --dp-tile-h:        76px;
    --dp-pay-h:         112px;

    --dp-radius:        14px;
    --dp-radius-sm:     10px;
    --dp-gap:           10px;

    --dp-font: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;

    /* Safe areas so the payment buttons clear the iOS home indicator. */
    --dp-safe-bottom: env(safe-area-inset-bottom, 0px);
    --dp-safe-top:    env(safe-area-inset-top, 0px);
}

*, *::before, *::after { box-sizing: border-box; }

/* The `hidden` attribute only sets `display: none` at the user-agent level, so ANY
   `display` declaration silently overrides it. That is not cosmetic: a hidden full-screen
   overlay keeps its layout box and swallows every click on the page beneath it. This rule
   makes `hidden` mean hidden, whatever a component's own display value happens to be. */
[hidden] { display: none !important; }

html, body {
    margin: 0;
    padding: 0;
    background: var(--dp-bg);
    color: var(--dp-text);
    font-family: var(--dp-font);
    /* The terminal is an app, not a document: no rubber-band scroll, no accidental zoom,
       no long-press text selection while tapping tiles quickly. */
    overscroll-behavior: none;
    -webkit-text-size-adjust: 100%;
    -webkit-tap-highlight-color: transparent;
}

body.dp-terminal {
    user-select: none;
    height: 100dvh;
    overflow: hidden;
}

/* ------------------------------------------------------------------ layout */

.dp-app {
    display: flex;
    flex-direction: column;
    height: 100dvh;
}

.dp-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    padding: calc(10px + var(--dp-safe-top)) 14px 10px;
    background: var(--dp-navy);
    border-bottom: 1px solid var(--dp-border);
    flex: 0 0 auto;
}

.dp-header__staff {
    font-size: 1.05rem;
    font-weight: 700;
    letter-spacing: .2px;
}

/* Brand block: the mark and the name it stands for, kept together on the left. */
.dp-header__brand {
    display: flex;
    align-items: center;
    gap: 10px;
    min-width: 0;
}
.dp-header__brand .dp-header__staff {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.dp-header__tools {
    display: flex;
    align-items: center;
    gap: 14px;
    flex: 0 0 auto;
}

.dp-header__logo { height: 22px; flex: 0 0 auto; opacity: .9; }

.dp-main {
    flex: 1 1 auto;
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
    padding: 12px 12px 0;
}

.dp-footer {
    /* The toast hangs off its top edge. */
    position: relative;
    flex: 0 0 auto;
    padding: 12px 12px calc(12px + var(--dp-safe-bottom));
    background: linear-gradient(to top, var(--dp-bg) 70%, transparent);
}

.dp-nachlauf {
    position: fixed;
    z-index: 850;
    left: 50%;
    bottom: calc(12px + var(--dp-safe-bottom));
    transform: translateX(-50%);
    width: min(560px, calc(100vw - 24px));
    padding: 12px 18px;
    border: 1px solid var(--dp-border);
    border-radius: var(--dp-radius-sm);
    background: var(--dp-surface-2);
    color: var(--dp-text);
    box-shadow: 0 8px 24px rgb(0 0 0 / .35);
    text-align: center;
    font-weight: 700;
    pointer-events: none;
}

.dp-nachlauf[hidden] { display: none; }

/* ------------------------------------------------------------------- tiles */

.dp-section-title {
    font-size: .72rem;
    font-weight: 700;
    letter-spacing: .12em;
    text-transform: uppercase;
    color: var(--dp-blue);
    margin: 14px 2px 8px;
}
.dp-section-title:first-child { margin-top: 2px; }

/* Two columns on a phone, more as the viewport grows. The tablet shows "mehr Kacheln
   auf einen Blick" with identical logic — same markup, only the column count changes. */
.dp-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: var(--dp-gap);
}

.dp-tile {
    display: flex;
    flex-direction: column;
    min-height: var(--dp-tile-h);

    /* The name and its price belong together. Spread to the corners of an 84px box they
       read as two separate things with a hole between them, and the hole cost a row of
       tiles on a phone. */
    gap: 2px;
    justify-content: center;
    padding: 10px 12px;
    background: var(--dp-surface-2);
    border: 1px solid var(--dp-border);
    border-radius: var(--dp-radius);
    color: var(--dp-text);
    text-align: left;
    font: inherit;
    cursor: pointer;
    /* Feedback has to be instant — an employee taps and looks away before the render lands. */
    transition: transform .06s ease, background-color .06s ease;
}
.dp-tile:active {
    transform: scale(.97);
    background: var(--dp-surface-3);
}
.dp-tile__name {
    font-size: .95rem;
    font-weight: 600;
    line-height: 1.25;
}
.dp-tile__price {
    font-size: .95rem;
    font-weight: 700;
    color: var(--dp-blue);
}
/* KB.1 (380c26): a tile with the article's picture - the picture on top, cut to fill, name and price below. */
.dp-tile--bild { justify-content: flex-start; padding-top: 6px; }
.dp-tile__bild {
    display: block;
    width: 100%;
    height: 64px;
    margin-bottom: 4px;
    border-radius: calc(var(--dp-radius) - 4px);
    object-fit: cover;
    pointer-events: none;
}
.dp-tile--submenu .dp-tile__price::after { content: "›"; font-size: 1.3rem; }
/* Ue.2 (E5): open-price and description tiles - shown, not bookable until U.4. */
.dp-tile--gesperrt { opacity: 0.45; cursor: not-allowed; }
.dp-tile--gesperrt .dp-tile__price { font-size: 0.8rem; }
/* GA.2: a sold-out tile says so in the place of its price, in the warning colour - locked, not broken. */
.dp-tile--ausverkauft .dp-tile__price { color: var(--dp-danger); font-weight: 700; letter-spacing: .02em; text-transform: uppercase; }

/* GA.2: the sold-out list - one switch per article, wide enough for a thumb. */
.dp-ausverkauft .dp-row { grid-template-columns: 1fr auto; }
.dp-ausverkauft__schalter { min-width: 11rem; margin: 0; }
.dp-ausverkauft .dp-row.is-ausverkauft .dp-row__title { color: var(--dp-text-muted); }

/* ------------------------------------------------------------------- cart */

/* The running receipt for the customer in the chair. It sits above the finish button,
   capped in height so a long visit scrolls instead of pushing the tiles off screen. */
.dp-cart {
    margin-bottom: 10px;
    background: var(--dp-surface-2);
    border: 1px solid var(--dp-border);
    border-radius: var(--dp-radius);
    overflow: hidden;
}
.dp-cart__lines {
    max-height: 30dvh;
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
}
.dp-cart__line {
    display: grid;
    grid-template-columns: 1fr auto auto;
    align-items: center;
    gap: 10px;
    padding: 8px 12px;
    border-bottom: 1px solid var(--dp-border);
}
.dp-cart__line:last-child { border-bottom: none; }
.dp-cart__name {
    font-size: .92rem;
    /* A typed "Sonstiges" description can be long; it must not push the price out of view. */
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}
.dp-cart__price {
    font-size: .92rem;
    font-weight: 700;
    font-variant-numeric: tabular-nums;
}
.dp-cart__remove {
    width: 34px;
    height: 34px;
    flex: 0 0 auto;
    background: transparent;
    border: 1px solid var(--dp-border);
    border-radius: 50%;
    color: var(--dp-text-muted);
    font-size: 1.1rem;
    line-height: 1;
    cursor: pointer;
}
.dp-cart__remove:active {
    background: var(--dp-danger);
    color: #fff;
}
/* R.6.b: the discount button of a cart line - shaped like its neighbour, but its own class so that
   the colour choice (D.4) can style it apart from the remove button's danger state. Tokens only. */
.dp-cart__discount {
    width: 34px;
    height: 34px;
    flex: 0 0 auto;
    background: transparent;
    border: 1px solid var(--dp-border);
    border-radius: 50%;
    color: var(--dp-text-muted);
    font-size: .95rem;
    line-height: 1;
    cursor: pointer;
}
.dp-cart__discount:active {
    border-color: var(--dp-blue);
    color: var(--dp-blue);
}
.dp-cart__total {
    display: flex;
    justify-content: space-between;
    padding: 10px 12px;
    background: var(--dp-surface-3);
    font-weight: 800;
    font-variant-numeric: tabular-nums;
}

.dp-btn:disabled {
    background: var(--dp-surface-3);
    color: var(--dp-text-dim);
    cursor: default;
}

/* The same lines again on the payment screen — read-only this time, because money is
   about to change hands and the list should not shift under the employee's thumb. */
.dp-receipt {
    margin-bottom: 12px;
    border: 1px solid var(--dp-border);
    border-radius: var(--dp-radius);
    overflow: hidden;
}
.dp-receipt__line {
    display: flex;
    justify-content: space-between;
    gap: 10px;
    padding: 9px 12px;
    background: var(--dp-surface-2);
    border-bottom: 1px solid var(--dp-border);
    font-size: .92rem;
    font-variant-numeric: tabular-nums;
}
.dp-receipt__line:last-child { border-bottom: none; }

/* GZ.1: a line of the split screen - the whole row is the button that moves it to the next guest. */
.dp-aufteilen__zeile {
    display: grid;
    grid-template-columns: 1fr auto auto;
    align-items: center;
    gap: 10px;
    width: 100%;
    min-height: var(--dp-tap-min);
    padding: 9px 12px;
    border: none;
    border-bottom: 1px solid var(--dp-border);
    background: var(--dp-surface-2);
    color: var(--dp-text);
    font: inherit;
    text-align: left;
    font-variant-numeric: tabular-nums;
    cursor: pointer;
}
.dp-aufteilen__zeile:last-child { border-bottom: none; }
.dp-aufteilen__gast {
    padding: 2px 10px;
    border: 2px solid var(--dp-blue);
    border-radius: var(--dp-radius-sm);
    color: var(--dp-text);
    font-weight: 600;
    white-space: nowrap;
}

/* ---------------------------------------------------------------- payment */

.dp-pay {
    display: grid;
    gap: var(--dp-gap);
}
.dp-pay__btn {
    min-height: var(--dp-pay-h);
    border: none;
    border-radius: var(--dp-radius);
    color: #fff;
    font-size: 1.6rem;
    font-weight: 800;
    letter-spacing: .06em;
    cursor: pointer;
    transition: transform .06s ease;
}
.dp-pay__btn:active { transform: scale(.98); }
.dp-pay__btn--cash { background: var(--dp-cash); }
.dp-pay__btn--cash:active { background: var(--dp-cash-strong); }
.dp-pay__btn--card { background: var(--dp-card); }
.dp-pay__btn--card:active { background: var(--dp-card-strong); }

.dp-mixed {
    display: grid;
    gap: 12px;
}
.dp-mixed__row {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(120px, .7fr);
    align-items: center;
    gap: 12px;
    padding: 12px 14px;
    border: 1px solid var(--dp-border);
    border-radius: var(--dp-radius);
    background: var(--dp-surface-2);
    font-weight: 700;
}
.dp-mixed__row input {
    width: 100%;
    min-height: var(--dp-tap-min);
    padding: 0 10px;
    border: 1px solid var(--dp-border);
    border-radius: 8px;
    background: var(--dp-surface);
    color: var(--dp-text);
    font: inherit;
    text-align: right;
}
.dp-mixed__row output {
    font-size: 1.25rem;
    text-align: right;
    font-variant-numeric: tabular-nums;
}
.dp-mixed__row--change output { color: var(--dp-ok); }

.dp-amount {
    padding: 16px;
    margin-bottom: 14px;
    background: var(--dp-surface-2);
    border: 1px solid var(--dp-border);
    border-radius: var(--dp-radius);
}
.dp-amount__label { font-size: .85rem; color: var(--dp-text-muted); }
.dp-amount__value { font-size: 2rem; font-weight: 800; margin-top: 4px; }

/* K.2: quick amounts for a cash payment - "passend" plus a few round notes above the total. */
.dp-cash-quick {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: var(--dp-gap);
    margin-bottom: 14px;
}
.dp-cash-quick__btn {
    min-height: 56px;
    font-size: 1.1rem;
}

/* GT.1: the tip question - "Kein Trinkgeld" is the largest key, so asking never slows the sale down. Two classes, so the
   later 56px minimum of every .dp-btn does not win over it. */
.dp-btn.dp-tip-ask__none {
    width: 100%;
    min-height: 96px;
    margin-bottom: 14px;
    font-size: 1.4rem;
    font-weight: 800;
}
#tipAskSuggestions { grid-template-columns: repeat(3, minmax(0, 1fr)); }

/* ---------------------------------------------------------------- buttons */

.dp-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: var(--dp-tap-min);
    width: 100%;
    padding: 0 18px;
    border: none;
    border-radius: var(--dp-radius);
    background: var(--dp-blue);
    color: #fff;
    font-size: 1rem;
    font-weight: 700;
    cursor: pointer;
}
.dp-btn:active { background: var(--dp-blue-strong); }
.dp-btn--ghost {
    background: transparent;
    border: 1px solid var(--dp-border);
    color: var(--dp-text-muted);
}
/* Used on its own, not alongside .dp-btn — so it has to undo the browser's default
   <button> chrome itself. Without the border reset every "Abmelden", "Bearbeiten" and
   "Mit DOYA koppeln" rendered as a boxed control instead of a quiet link. */
.dp-btn--link {
    width: auto;
    min-height: auto;
    padding: 6px 4px;
    border: none;
    border-radius: 6px;
    background: none;
    color: var(--dp-text-muted);
    font: inherit;
    font-size: .85rem;
    font-weight: 500;
    cursor: pointer;
}
.dp-btn--link:hover { color: var(--dp-text); }

/* Focus rings are shown for keyboard navigation but not after a tap. Without
   :focus-visible the browser leaves a stray outline on whatever was last touched,
   which reads as a stuck or selected control on a touch-only device. */
.dp-btn:focus,
.dp-tile:focus,
.dp-pay__btn:focus { outline: none; }

.dp-btn:focus-visible,
.dp-tile:focus-visible,
.dp-pay__btn:focus-visible {
    outline: 3px solid var(--dp-text);
    outline-offset: 2px;
}

/* ------------------------------------------------------------ form fields */

.dp-field {
    display: block;
    margin-bottom: 14px;
}
.dp-field > span {
    display: block;
    margin-bottom: 6px;
    font-size: .85rem;
    font-weight: 600;
    color: var(--dp-text-muted);
}
.dp-field input {
    width: 100%;
    min-height: var(--dp-tap-min);
    padding: 0 14px;
    background: var(--dp-surface-2);
    border: 1px solid var(--dp-border);
    border-radius: var(--dp-radius-sm);
    color: var(--dp-text);
    /* 16px minimum: iOS Safari zooms the whole page on focus for anything smaller,
       which throws off every tap target on the screen. */
    font-size: 1rem;
    font-family: inherit;
}
.dp-field input:focus {
    outline: 2px solid var(--dp-blue);
    outline-offset: 1px;
}

.dp-hint {
    margin: 0 2px 16px;
    font-size: .9rem;
    line-height: 1.5;
    color: var(--dp-text-muted);
}
#customError {
    color: var(--dp-danger);
    font-weight: 600;
}

/* ---------------------------------------------------------------- keypad */

.dp-grid--keypad {
    grid-template-columns: repeat(3, 1fr);
    margin-bottom: 12px;
}
@media (min-width: 600px) {
    /* Overrides the 3-column responsive rule above — a numeric keypad is always 3 wide,
       whatever the viewport. */
    .dp-grid--keypad { grid-template-columns: repeat(3, 1fr); }
}
.dp-tile--key {
    align-items: center;
    justify-content: center;
    min-height: 68px;
}
.dp-tile--key .dp-tile__name {
    font-size: 1.6rem;
    font-weight: 700;
}

#pinDots {
    letter-spacing: .3em;
    transition: color .15s ease;
}
#pinDots.is-error { color: var(--dp-danger); }

/* ----------------------------------------------------------------- toast */

/* Confirmation is a glance, not a dialog: it must never need dismissing, because the
   employee has already moved on to the next customer.

   Anchored to the TOP. It used to sit above the finish button, but the footer grows with
   the cart, so on a three-line receipt the toast landed on top of the lines and made the
   running total unreadable — obscuring the number the employee is about to charge. The top
   edge is the only position that stays clear however long the visit gets. */
.dp-toast {
    /* Fixed under the header, centred. It used to hang off the receipt's top edge, which
       works on a phone where the receipt is at the bottom — but on a wide screen the footer
       sits beside the tiles near the top, so the message landed in the header, half-hidden
       behind the language button. That is where an employee least expects it and exactly where
       "Tag abgeschlossen" was being missed. Fixed to the viewport, it is in the same place on
       every screen and covers nothing that is being tapped. */
    position: fixed;
    left: 50%;
    top: calc(var(--dp-safe-top) + 64px);

    transform: translateX(-50%);
    z-index: 900;
    padding: 10px 18px;
    max-width: calc(100vw - 32px);
    background: var(--dp-ok);
    color: #04170d;
    border-radius: 999px;
    font-size: .95rem;
    font-weight: 700;
    box-shadow: 0 8px 24px rgb(0 0 0 / .35);
    animation: dp-toast-in .16s ease-out;
}
@keyframes dp-toast-in {
    from { opacity: 0; transform: translate(-50%, -8px); }
    to   { opacity: 1; transform: translate(-50%, 0); }
}
@media (prefers-reduced-motion: reduce) {
    .dp-toast { animation: none; }
}

/* ------------------------------------------------------- offline indicator */

/* Offline is a normal state here, not an error — the shop keeps working. It is shown
   calmly and persistently rather than as an alarm, with the pending count so the owner
   can see nothing was lost. */
.dp-offline {
    display: none;
    align-items: center;
    gap: 8px;
    padding: 8px 14px;
    background: var(--dp-warn);
    color: #241a02;
    font-size: .85rem;
    font-weight: 700;
}
body.is-offline .dp-offline { display: flex; }

/* -------------------------------------------------------------- responsive */

/* Large phone / small tablet portrait. */
@media (min-width: 600px) {
    .dp-grid { grid-template-columns: repeat(3, 1fr); }
}

/* Tablet — the "mehr Kacheln auf einen Blick" layout from the concept. */
@media (min-width: 900px) {
    :root { --dp-tile-h: 96px; --dp-gap: 12px; }
    .dp-grid { grid-template-columns: repeat(4, 1fr); }
    .dp-main { padding: 16px 16px 0; }
    .dp-tile__name { font-size: 1.02rem; }
}

@media (min-width: 1280px) {
    .dp-grid { grid-template-columns: repeat(5, 1fr); }
}

/* Landscape tablet: put the payment buttons side by side so neither hand has to travel. */
@media (min-width: 720px) and (orientation: landscape) {
    .dp-pay { grid-template-columns: 1fr 1fr; }
}

/* Respect the user's motion preference — the scale feedback is a nicety, not a necessity. */
@media (prefers-reduced-motion: reduce) {
    .dp-tile, .dp-pay__btn { transition: none; }
    .dp-tile:active, .dp-pay__btn:active { transform: none; }
}

/* ==========================================================================
   PANEL — the owner's surface.
   Shares the terminal's palette and touch sizing, but is read at a desk on a
   laptop as often as on a phone, so it favours density over thumb reach.
   ========================================================================== */

body.dp-panel { min-height: 100dvh; }
body.dp-panel .dp-app { height: auto; min-height: 100dvh; }
body.dp-panel .dp-main { overflow: visible; padding-bottom: 40px; }

.dp-main--narrow { max-width: 420px; margin: 0 auto; width: 100%; }

/* Wide screens: cap the reading width. A table of sales stretched across a 27" monitor
   is a row of numbers nobody can track back to its label. */
@media (min-width: 900px) {
    body.dp-panel .dp-main,
    body.dp-panel .dp-tabs { max-width: 1080px; margin-inline: auto; width: 100%; }
}

/* ------------------------------------------------------------------- tabs */

.dp-tabs {
    display: flex;
    gap: 2px;
    padding: 0 12px;
    background: var(--dp-surface);
    border-bottom: 1px solid var(--dp-border);
    overflow-x: auto;
    /* The tab strip scrolls on a narrow phone rather than wrapping — a second row of
       tabs pushes the actual content below the fold. */
    scrollbar-width: none;
}
.dp-tabs::-webkit-scrollbar { display: none; }

.dp-tab {
    flex: 0 0 auto;
    min-height: 48px;
    padding: 0 16px;
    background: none;
    border: none;
    border-bottom: 3px solid transparent;
    color: var(--dp-text-muted);
    font: inherit;
    font-weight: 600;
    cursor: pointer;
    white-space: nowrap;
}
.dp-tab.is-active {
    color: var(--dp-text);
    border-bottom-color: var(--dp-blue);
}

/* ---------------------------------------------------------------- toolbar */

.dp-toolbar {
    display: flex;
    flex-wrap: wrap;
    align-items: flex-end;
    gap: 10px;
    margin-bottom: 16px;
}
.dp-btn--auto { width: auto; }

.dp-field--inline { margin-bottom: 0; }
.dp-field--inline input { min-width: 160px; }

.dp-field select {
    width: 100%;
    min-height: var(--dp-tap-min);
    padding: 0 12px;
    background: var(--dp-surface-2);
    border: 1px solid var(--dp-border);
    border-radius: var(--dp-radius-sm);
    color: var(--dp-text);
    font-size: 1rem;
    font-family: inherit;
}

.dp-check {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 12px;
    font-size: .9rem;
    cursor: pointer;
}
.dp-check input {
    /* Checkboxes default to ~13px, which is far below a reliable tap target. */
    width: 22px;
    height: 22px;
    accent-color: var(--dp-blue);
}

/* ------------------------------------------------------------------ stats */

.dp-stats {
    display: grid;
    /* Ü.6 (4b8fd1): so viele Kacheln nebeneinander, wie ihre Mindestbreite erlaubt - nie eine feste Spaltenzahl.
       Bei 1280 px lag der Tagesabschluss (max. 560 px breit) mit vier festen Spalten bei ~120 px je Kachel,
       "158,50 EUR" ragte über den Rand. Die Mindestbreite reicht für "99.999,99 EUR" in der kleinsten Schrift. */
    grid-template-columns: repeat(auto-fit, minmax(min(100%, 9.5rem), 1fr));
    gap: var(--dp-gap);
    margin-bottom: 18px;
}

/* Die Mindestbreite je Kachel (9,5 rem) hält auch "LEISTUNGEN" und "PRODUKTE (LADEN)" ohne Umbruch mitten im Wort. */

.dp-stat {
    padding: 14px;
    background: var(--dp-surface-2);
    border: 1px solid var(--dp-border);
    border-radius: var(--dp-radius);

    /* Ohne min-width:0 nimmt eine Gitterzelle die Breite ihres laengsten Wortes als
       Untergrenze. Mit der sechsten Kachel im Tagesabschluss ("Produkte (Laden)") wurde
       die Reihe dadurch breiter als der Bildschirm: BAR war abgeschnitten und darunter
       lag ein Querbalken. Auf einem Tablet heisst das, der Mitarbeiter sieht seine
       Bareinnahme beim Abschluss nicht. */
    min-width: 0;

    /* Der Betrag richtet seine Schrift nach der Kachel, nicht nach dem Fenster (cqw). */
    container-type: inline-size;
}
.dp-stat__label {
    display: block;
    /* Umbrechen statt ueberstehen — siehe min-width oben. Break-word, nicht anywhere:
       zuerst an der Wortgrenze, mitten im Wort nur als letzter Ausweg. */
    overflow-wrap: break-word;
    font-size: .78rem;
    text-transform: uppercase;
    letter-spacing: .08em;
    color: var(--dp-text-muted);
}
.dp-stat__value {
    display: block;
    margin-top: 4px;
    /* 11 Zeichen ("99.999,99 EUR") passen bei 12 cqw in die Kachelbreite; unten 1,05 rem, oben 1,5 rem.
       Die Zeile davor ist der Rückfall: ein Browser ohne Container-Einheiten verwirft die ganze clamp()-Zeile. */
    font-size: 1.5rem;
    font-size: clamp(1.05rem, 12cqw, 1.5rem);
    font-weight: 800;
    font-variant-numeric: tabular-nums;
    white-space: nowrap;
}

/* ------------------------------------------------------------------ lists */

.dp-group {
    margin-bottom: 18px;
    border: 1px solid var(--dp-border);
    border-radius: var(--dp-radius);
    overflow: hidden;
}
.dp-group__head {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 10px;
    padding: 10px 12px;
    background: var(--dp-surface-3);
    font-weight: 700;
}

.dp-row {
    display: grid;
    grid-template-columns: 1fr auto;
    align-items: center;
    gap: 4px 12px;
    padding: 12px;
    background: var(--dp-surface-2);
    border-bottom: 1px solid var(--dp-border);
}
.dp-row:last-child { border-bottom: none; }

/* Actions drop under the row on a phone rather than squeezing the amount. */
.dp-row__actions {
    grid-column: 1 / -1;
    display: flex;
    gap: 12px;
}
@media (min-width: 700px) {
    .dp-row { grid-template-columns: 1fr auto auto; }
    .dp-row__actions { grid-column: auto; }
}

.dp-row__title { font-size: .95rem; font-weight: 600; line-height: 1.45; }
.dp-row__meta { margin-top: 2px; font-size: .82rem; color: var(--dp-text-muted); }
.dp-row__value {
    font-size: 1.05rem;
    font-weight: 800;
    font-variant-numeric: tabular-nums;
    white-space: nowrap;
}

/* A reversed sale is dimmed and struck through, never removed. The record is
   append-only, so the owner must see that a correction happened rather than a gap. */
.dp-row.is-reversed .dp-row__title,
.dp-row.is-reversed .dp-row__value { text-decoration: line-through; opacity: .55; }

.dp-list { margin-bottom: 24px; }

.dp-tag {
    display: inline-block;
    padding: 1px 7px;
    margin-left: 4px;
    background: var(--dp-surface-3);
    border-radius: 999px;
    font-size: .72rem;
    font-weight: 700;
    color: var(--dp-text-muted);
    vertical-align: middle;
}
.dp-tag--danger { background: var(--dp-danger); color: #fff; }

.dp-alert {
    padding: 10px 12px;
    margin: 0 0 14px;
    background: rgb(214 69 69 / .15);
    border: 1px solid var(--dp-danger);
    border-radius: var(--dp-radius-sm);
    color: #ffc9c9;
    font-size: .9rem;
}

/* ------------------------------------------------------------------ modal */

.dp-modal {
    position: fixed;
    inset: 0;
    z-index: 100;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 16px;
    background: rgb(0 0 0 / .6);
    overflow-y: auto;
}
.dp-modal__box {
    width: 100%;
    max-width: 460px;
    max-height: 90dvh;
    overflow-y: auto;
    padding: 20px;
    background: var(--dp-surface);
    border: 1px solid var(--dp-border);
    border-radius: var(--dp-radius);
}
.dp-modal__title { margin: 0 0 16px; font-size: 1.15rem; }
.dp-modal__actions {
    display: flex;
    gap: 10px;
    margin-top: 18px;
}
.dp-modal__actions .dp-btn { flex: 1; }

/* The pairing link. Wraps rather than truncating — it is copied by hand onto a tablet
   and is shown exactly once, so every character has to be visible. */
.dp-code {
    padding: 12px;
    background: var(--dp-bg);
    border: 1px solid var(--dp-border);
    border-radius: var(--dp-radius-sm);
    font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
    font-size: .82rem;
    word-break: break-all;
    user-select: all;
}

/* ==========================================================================
   CHARTS
   Palette validated with the dataviz validator against the dark chart surface
   (#16273f): lightness band, chroma floor, CVD separation and contrast all pass.
     BAR   #2fa36b   (= --dp-ok)
     KARTE #1f6fff   (= --dp-blue)
   Deutan ΔE 27.5, normal ΔE 29.4 — well clear. Tritan separation is 6.4, in the
   floor band, which is legal only with secondary encoding: both segments carry a
   direct label AND a 2px surface gap, so identity never rests on hue alone.
   ========================================================================== */

.dp-chart {
    margin-bottom: 24px;
    padding: 16px;
    background: var(--dp-surface-2);
    border: 1px solid var(--dp-border);
    border-radius: var(--dp-radius);
}
.dp-chart__title {
    margin: 0 0 4px;
    font-size: .95rem;
    font-weight: 700;
}
.dp-chart__sub {
    margin: 0 0 16px;
    font-size: .8rem;
    color: var(--dp-text-muted);
}
.dp-chart__empty {
    padding: 8px 0 4px;
    font-size: .9rem;
    color: var(--dp-text-muted);
}

/* ------------------------------------------------------- ranked bars (h) */

/* Horizontal because the labels are long German service names — rotating them or
   truncating would cost more than the vertical space saves. */
.dp-bars { display: flex; flex-direction: column; gap: 10px; }

.dp-bar__row {
    display: grid;
    grid-template-columns: minmax(90px, 27%) 1fr auto;
    align-items: center;
    gap: 10px;
}
.dp-bar__label {
    font-size: .85rem;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}
.dp-bar__track {
    /* display:block is load-bearing, not tidiness: these are spans, and height has no
       effect on an inline box — the bars rendered as empty tracks with no fill at all. */
    display: block;
    position: relative;
    height: 20px;                 /* mark spec: bars capped well under 24px */
    background: var(--dp-bg);
    border-radius: 4px;
}
.dp-bar__fill {
    display: block;
    height: 100%;
    min-width: 3px;
    background: var(--dp-blue);
    /* Square at the baseline, 4px rounded at the data end — the end is where the
       value is, so that is the end that gets shaped. */
    border-radius: 0 4px 4px 0;
}
.dp-bar__value {
    font-size: .85rem;
    font-weight: 700;
    font-variant-numeric: tabular-nums;
    white-space: nowrap;
}
.dp-bar__count {
    font-size: .78rem;
    color: var(--dp-text-muted);
    font-variant-numeric: tabular-nums;
}

/* ------------------------------------------------------------ split bar */

/* Two values, so this is one bar rather than a pie: a two-slice pie asks the reader
   to compare angles when a single length answers it instantly. */
.dp-split {
    display: flex;
    height: 28px;
    border-radius: 6px;
    overflow: hidden;
    /* The 2px surface gap between segments — separation by negative space, never a
       stroke, which would add ink that is not data. */
    gap: 2px;
    background: var(--dp-surface-2);
}
.dp-split__seg {
    display: flex;
    align-items: center;
    justify-content: center;
    min-width: 3px;
    font-size: .8rem;
    font-weight: 700;
    color: #fff;
    font-variant-numeric: tabular-nums;
}
.dp-split__seg--cash { background: var(--dp-ok); border-radius: 6px 0 0 6px; }
.dp-split__seg--card { background: var(--dp-blue); border-radius: 0 6px 6px 0; }

.dp-legend {
    display: flex;
    flex-wrap: wrap;
    gap: 16px;
    margin-top: 12px;
    font-size: .82rem;
    /* Text wears text tokens, never the series colour — the swatch beside it carries
       identity, so the label stays readable at any contrast. */
    color: var(--dp-text-muted);
}
.dp-legend__item { display: flex; align-items: center; gap: 6px; }
.dp-legend__dot { width: 10px; height: 10px; border-radius: 3px; flex: 0 0 auto; }

/* -------------------------------------------------------- hour columns */

.dp-hours {
    display: grid;
    grid-auto-flow: column;
    /* Capped so a day with a single busy hour renders as one column with air beside it,
       not a wall of colour that reads as a rendering fault. Mark spec caps bars at 24px;
       columns get a little more because they carry the hour label underneath. */
    grid-auto-columns: minmax(0, 34px);
    justify-content: start;
    align-items: end;
    gap: 2px;                     /* the surface gap again, between adjacent columns */
    height: 130px;
}
.dp-hour { display: flex; flex-direction: column; justify-content: flex-end; height: 100%; }
.dp-hour__col {
    display: block;
    background: var(--dp-blue);
    border-radius: 4px 4px 0 0;   /* rounded cap, square on the baseline */
    min-height: 2px;
}
.dp-hour__col--empty { background: var(--dp-border); }
.dp-hour__label {
    margin-top: 6px;
    font-size: .68rem;
    color: var(--dp-text-dim);
    text-align: center;
    font-variant-numeric: tabular-nums;
}

/* ------------------------------------------------------------ table view */

/* Every chart's numbers are also available as text — the contrast warning on any
   fill is discharged here, and a screen reader never depends on a bar's length. */
.dp-table { width: 100%; border-collapse: collapse; font-size: .85rem; }
.dp-table th, .dp-table td {
    padding: 7px 10px;
    text-align: left;
    border-bottom: 1px solid var(--dp-border);
}
.dp-table th { color: var(--dp-text-muted); font-weight: 600; font-size: .78rem; }
.dp-table td:last-child, .dp-table th:last-child { text-align: right; font-variant-numeric: tabular-nums; }

.dp-details { margin-top: 14px; }
.dp-details > summary {
    cursor: pointer;
    font-size: .82rem;
    color: var(--dp-text-muted);
    padding: 4px 0;
}

/* ==========================================================================
   DESKTOP LAYOUTS
   The terminal is a tablet app and stays touch-first. The panel and the admin
   are desk tools opened on a laptop, and were wrong: a phone column stretched
   across 1440px with one field per row. These give them the shape DoyaOps uses —
   a split sign-in, a capped content column, and forms that use the width.
   ========================================================================== */

/* -------------------------------------------------------------- sign-in */

/* Two columns on a desktop, stacked on a phone: brand and promise on the left,
   the form on the right — the same split cloud.doyaops.com uses, so someone who
   signs in there does not arrive somewhere that feels like a different product. */
.dp-auth {
    min-height: 100dvh;
    display: grid;
    grid-template-columns: 1fr;
    align-items: center;
    gap: 32px;
    padding: 24px;
    /* A faint grid, like the DoyaOps sign-in. Two gradients rather than an image:
       nothing to download, and it scales to any viewport. */
    background:
        linear-gradient(rgba(36, 64, 107, .16) 1px, transparent 1px) 0 0 / 44px 44px,
        linear-gradient(90deg, rgba(36, 64, 107, .16) 1px, transparent 1px) 0 0 / 44px 44px,
        radial-gradient(1200px 600px at 20% 15%, #12203a 0%, var(--dp-bg) 60%);
}

@media (min-width: 900px) {
    .dp-auth {
        grid-template-columns: 1fr minmax(380px, 440px);
        gap: 64px;
        padding: 48px min(8vw, 96px);
    }
}

/* Grid children default to min-width:auto, so one unbreakable string — the
   cloud.doyaops.com line under the button — was widening the column past the
   viewport and pushing the card off the right edge of a phone. */
.dp-auth > * { min-width: 0; }
.dp-auth__foot { overflow-wrap: anywhere; }

.dp-auth__brand { max-width: 560px; }

.dp-auth__logo { height: 46px; margin-bottom: 40px; }

.dp-auth__eyebrow {
    font-size: .74rem;
    font-weight: 700;
    letter-spacing: .22em;
    text-transform: uppercase;
    color: var(--dp-text-dim);
    margin: 0 0 14px;
}
.dp-auth__tagline {
    margin: 0 0 16px;
    font-size: clamp(1.6rem, 3.2vw, 2.4rem);
    font-weight: 800;
    line-height: 1.15;
}
.dp-auth__body {
    margin: 0 0 32px;
    font-size: 1rem;
    line-height: 1.6;
    color: var(--dp-text-muted);
    max-width: 46ch;
}
.dp-auth__features { display: flex; flex-direction: column; gap: 14px; }
.dp-auth__feature {
    display: flex;
    align-items: center;
    gap: 12px;
    font-size: .95rem;
    color: var(--dp-text);
}
.dp-auth__bullet {
    width: 34px; height: 34px;
    flex: 0 0 auto;
    display: grid;
    place-items: center;
    border-radius: 10px;
    background: var(--dp-surface-3);
    color: var(--dp-blue);
    font-weight: 800;
}

/* The brand column is the part that goes when there is no room: on a phone the
   form is the whole job, and a wall of marketing above it just pushes it down. */
@media (max-width: 899px) {
    .dp-auth__body, .dp-auth__features { display: none; }
    .dp-auth__logo { height: 36px; margin-bottom: 18px; }
    .dp-auth__brand { max-width: none; text-align: center; }
}

.dp-auth__card {
    width: 100%;
    padding: 32px;
    background: var(--dp-surface);
    border: 1px solid var(--dp-border);
    border-radius: 18px;
    box-shadow: 0 24px 60px rgb(0 0 0 / .35);
}
.dp-auth__title { margin: 0 0 6px; font-size: 1.45rem; font-weight: 800; }
.dp-auth__sub { margin: 0 0 24px; font-size: .92rem; color: var(--dp-text-muted); }
.dp-auth__foot {
    margin: 20px 0 0;
    font-size: .82rem;
    color: var(--dp-text-dim);
    text-align: center;
}

/* On a phone the header runs out of room: shop name, logo, language and sign-out do not
   fit across 390px, and the sign-out ran off the right edge. The logo goes first — it
   repeats a wordmark already spelled out beside it — and the language name follows,
   leaving the flag, which is the part that identifies the control anyway. */
@media (max-width: 599px) {
    .dp-lang--inline .dp-lang__name { display: none; }
    .dp-lang--inline .dp-lang__toggle { padding-inline: 10px; gap: 6px; }
}

/* -------------------------------------------------- language switcher */

/*
 * A flag, the language name and a chevron — the shape DoyaOps uses, so the switcher is
 * recognisable to anyone arriving from there.
 *
 * Built on <details>, so it opens and closes and answers the keyboard without a line of
 * JavaScript. The one thing that costs is closing on an outside click, which <details>
 * does not do on its own; a full-screen backdrop behind the open menu buys it back
 * without script.
 */
.dp-lang {
    position: fixed;
    top: 16px;
    right: 16px;
    z-index: 40;
}
/* Inside a header the switcher stops being fixed to the viewport — but it must stay a
   positioned box, or the menu below it anchors to the page instead and lands at the
   bottom of the document. */
.dp-lang--inline { position: relative; top: auto; right: auto; }

.dp-lang__toggle {
    display: flex;
    align-items: center;
    gap: 9px;
    min-height: 40px;
    padding: 0 14px;
    background: var(--dp-surface-2);
    border: 1px solid var(--dp-border);
    border-radius: 999px;
    color: var(--dp-text);
    font-size: .88rem;
    cursor: pointer;
    user-select: none;
    list-style: none;          /* Safari keeps a disclosure triangle without this. */
}
.dp-lang__toggle::-webkit-details-marker { display: none; }
.dp-lang__toggle:hover { border-color: var(--dp-blue); }
.dp-lang:not([open]) .dp-lang__toggle:focus-visible,
.dp-lang__toggle:focus-visible { outline: 2px solid var(--dp-blue); outline-offset: 2px; }

/* 4:3 keeps the German bands square-ish and the Union Jack from stretching. */
.dp-lang__flag {
    width: 22px;
    height: 16px;
    flex: 0 0 auto;
    border-radius: 3px;
    /* A hairline, so a white-heavy flag still reads as an object on a dark surface. */
    box-shadow: 0 0 0 1px rgb(255 255 255 / .18);
    object-fit: cover;
}
.dp-lang__name { font-weight: 600; }
.dp-lang__chevron { width: 14px; height: 14px; color: var(--dp-text-dim); }
.dp-lang[open] .dp-lang__chevron { transform: rotate(180deg); }

.dp-lang__menu {
    position: absolute;
    top: calc(100% + 8px);
    right: 0;
    z-index: 2;
    min-width: 100%;
    padding: 6px;
    background: var(--dp-surface);
    border: 1px solid var(--dp-border);
    border-radius: 12px;
    box-shadow: 0 16px 40px rgb(0 0 0 / .45);
}

/* Clicking anywhere else closes the menu — no script, just a backdrop that swallows
   the click and lets the <summary> toggle handle it. */
.dp-lang[open] .dp-lang__toggle::before {
    content: "";
    position: fixed;
    inset: 0;
    z-index: 1;
}

.dp-lang__item {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 9px 12px;
    border-radius: 8px;
    color: var(--dp-text);
    font-size: .9rem;
    text-decoration: none;
    white-space: nowrap;
}
.dp-lang__item:hover { background: var(--dp-surface-2); }
.dp-lang__item.is-current { color: var(--dp-blue); font-weight: 700; }

/* ----------------------------------------------------- panel / admin */

/* Capped, not stretched. A sales table pulled across a 27" monitor is a row of
   numbers nobody can trace back to its label. */
@media (min-width: 900px) {
    body.dp-panel .dp-main,
    body.dp-panel .dp-tabs,
    body.dp-panel .dp-header { max-width: 1200px; margin-inline: auto; width: 100%; }

    body.dp-panel .dp-header { border-radius: 0 0 14px 14px; }

    /* Same inset as the content below it, so the header's edges line up with the first
       field rather than sitting ten pixels proud of it. */
    body.dp-panel .dp-header { padding-inline: 24px; }
    body.dp-panel .dp-main { padding: 24px 24px 60px; }
}

/* Forms lay out in columns on a desk and stack on a phone — the toolbar was a
   single column at every width, which is what made the desktop look unfinished. */
@media (min-width: 700px) {
    .dp-toolbar { align-items: end; }
    .dp-toolbar .dp-field--inline { flex: 1 1 200px; margin-bottom: 0; }
    .dp-toolbar .dp-btn--auto { flex: 0 0 auto; }
}

/* A modal on a laptop can afford two columns; on a phone it must not. */
@media (min-width: 700px) {
    .dp-modal__box { max-width: 560px; padding: 28px; }
    .dp-form-grid {
        display: grid;
        grid-template-columns: 1fr 1fr;
        gap: 0 16px;
    }
    .dp-form-grid .dp-field--wide { grid-column: 1 / -1; }
}

@media (min-width: 1100px) {
    /* Two charts side by side once there is room for both to stay readable. */
    .dp-charts-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; align-items: start; }
}

/* --------------------------------------------- terminal on a wide screen */

/*
 * On a phone the receipt lives in a bar pinned to the bottom, because the tiles need
 * every pixel of a narrow screen. On a landscape tablet or a counter monitor there is
 * width to spare, so the receipt moves into a column of its own on the right: the tiles
 * stop being pushed up by a growing cart, and the running total sits at eye level next
 * to them rather than under the thumb.
 *
 * Purely a layout change — same markup, same elements, same JavaScript. The screens that
 * are not the catalog (login, payment, the free-amount form) keep the full width, since
 * a receipt column beside a two-field form would be empty furniture.
 */
@media (min-width: 1024px) {
    body.dp-terminal .dp-app {
        display: grid;
        grid-template-columns: 1fr minmax(300px, 360px);
        grid-template-rows: auto 1fr;
        align-items: start;
        max-width: 1600px;
        margin-inline: auto;
        column-gap: 20px;
        padding-inline: 20px;
    }

    body.dp-terminal .dp-offline,
    body.dp-terminal .dp-leiste,
    body.dp-terminal .dp-header { grid-column: 1 / -1; }

    body.dp-terminal .dp-main { grid-column: 1; grid-row: 2; }

    /* Only the catalog shares the row; every other screen takes the whole width. */
    body.dp-terminal .dp-main:not(#screenCatalog) { grid-column: 1 / -1; }

    body.dp-terminal .dp-footer {
        position: sticky;
        top: 20px;
        grid-column: 2;
        grid-row: 2;
        padding: 0;
        border-top: none;
        background: none;
        box-shadow: none;
    }

    /* With a column to itself the receipt can grow — it no longer eats the tiles. */
    body.dp-terminal .dp-cart__lines { max-height: 52dvh; }
    body.dp-terminal .dp-footer .dp-btn { min-height: 64px; font-size: 1.1rem; }
}

/* ------------------------------------------------- platform console (admin) */

/*
 * DOYA's own sign-in, deliberately unlike the shop owner's.
 *
 * The owner's screen sells the product: two columns, a promise, three bullets. This one
 * has no one to persuade — the people who reach it already work here, and everyone else
 * should realise within a second that they have the wrong address. So: one narrow card on
 * a plain surface, a steel accent instead of the product blue, and no marketing at all.
 *
 * The grid the customer screens use is dropped too. Shared styling was how this surface
 * ended up looking like a second front door for shop owners in the first place.
 */
.dp-console {
    min-height: 100dvh;
    display: grid;
    place-items: center;
    padding: 24px;
    background:
        radial-gradient(900px 500px at 50% -10%, #16233b 0%, var(--dp-bg) 70%);
}

.dp-console__card {
    width: 100%;
    max-width: 400px;
    padding: 32px 28px;
    background: var(--dp-surface);
    border: 1px solid var(--dp-border);
    border-radius: 16px;
    /* A flat top rule in steel, not the product blue: this is tooling, not the product. */
    border-top: 3px solid #64748b;
    box-shadow: 0 20px 50px rgb(0 0 0 / .4);
    text-align: left;
}

.dp-console__logo { height: 30px; margin-bottom: 22px; opacity: .9; }

.dp-console__eyebrow {
    margin: 0 0 6px;
    font-size: .68rem;
    font-weight: 700;
    letter-spacing: .2em;
    text-transform: uppercase;
    color: var(--dp-text-dim);
}

.dp-console__title { margin: 0 0 6px; font-size: 1.3rem; font-weight: 800; }

.dp-console__sub {
    margin: 0 0 24px;
    font-size: .88rem;
    line-height: 1.5;
    color: var(--dp-text-muted);
}

.dp-console__foot {
    margin: 20px 0 0;
    padding-top: 16px;
    border-top: 1px solid var(--dp-border);
    font-size: .78rem;
    line-height: 1.5;
    color: var(--dp-text-dim);
}

/* --------------------------------------------------------- pairing dialog */

/*
 * Three ways to get one token onto a tablet, numbered, because they are alternatives
 * rather than steps to follow in order — scanning is enough on its own.
 */
.dp-pair__step {
    margin: 18px 0 8px;
    font-size: .82rem;
    font-weight: 700;
    letter-spacing: .04em;
    color: var(--dp-text-muted);
}
.dp-pair__step:first-child { margin-top: 4px; }

.dp-pair__qr {
    display: block;
    width: 180px;
    height: 180px;
    /* White padding around it: a QR needs its quiet zone against a dark page or the
       camera cannot find the corner markers. */
    padding: 10px;
    background: #fff;
    border-radius: 10px;
}

.dp-code--copy {
    cursor: pointer;
    transition: border-color .15s ease;
}
.dp-code--copy:hover,
.dp-code--copy:focus-visible { border-color: var(--dp-blue); outline: none; }

/* The one route that works when the panel and the till are the same phone. */
.dp-pair__open {
    display: flex;
    text-decoration: none;
    margin-bottom: 8px;
}
.dp-pair__openhint { margin: 0 2px 4px; font-size: .82rem; }

/* ------------------------------------------------------------ my sales */

.dp-mine__head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    flex-wrap: wrap;
    /* Ü.6: Abstand zu den Kacheln darunter - das Datumsfeld berührte die KARTE-Kachel. */
    margin-bottom: 14px;
}
.dp-mine__head .dp-section-title { margin: 0; }
/* K58: the two closing buttons stood directly on each other. */
.dp-mine__close { margin-top: 10px; }

.dp-mine__date {
    min-height: var(--dp-tap-min);
    padding: 0 12px;
    background: var(--dp-surface-2);
    border: 1px solid var(--dp-border);
    border-radius: var(--dp-radius-sm);
    color: var(--dp-text);
    font: inherit;
    font-size: 1rem;
}

/* A corrected sale stays on the list, struck through — the record is the product. */
.dp-row.is-reversed .dp-row__title,
.dp-row.is-reversed .dp-row__value { text-decoration: line-through; opacity: .65; }

#screenMine .dp-btn--ghost { margin-top: 16px; }

/* A header button that keeps its words on a desk and becomes its icon on a phone. */
.dp-icon-btn {
    display: inline-flex;
    align-items: center;
    gap: 7px;
}
.dp-icon-btn svg { width: 19px; height: 19px; flex: 0 0 auto; }

@media (max-width: 599px) {
    /* The employee's name is the one thing on this bar that must not be cut, and with the
       label spelled out there was not room for it. */
    .dp-icon-btn__label { display: none; }
    .dp-icon-btn { padding: 6px 2px; }
}

/* The reason a sale was corrected — never struck through, even on a struck-through row:
   it is the one line on that row that still has to be read. */
.dp-row__reason {
    margin-top: 3px;
    color: var(--dp-text);
    font-style: italic;
    text-decoration: none;
    opacity: 1;
}
.dp-row.is-reversed .dp-row__reason { text-decoration: none; opacity: 1; }


/* Under the button, not above the fields: what an employee has to do on this screen is type
   two things, and the explanation of what else happens can wait until they have. */
.dp-claim__note { margin: 16px 2px 0; text-align: center; }

/* -------------------------------------------------------- install prompt */

/*
 * A slim bar at the foot of the sign-in screen offering "add to home screen". Above the
 * home indicator, out of the way of the form, and gone once dismissed or once the app is
 * running installed.
 */
.dp-install {
    position: fixed;
    left: 12px;
    right: 12px;
    bottom: calc(12px + var(--dp-safe-bottom));
    z-index: 60;
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px 12px;
    background: var(--dp-surface-2);
    border: 1px solid var(--dp-border);
    border-radius: 14px;
    box-shadow: 0 12px 34px rgb(0 0 0 / .45);
}
.dp-install__hint {
    flex: 1 1 auto;
    font-size: .86rem;
    line-height: 1.4;
    color: var(--dp-text);
}
.dp-install__go {
    flex: 1 1 auto;
    min-height: 44px;
    padding: 0 16px;
    border: none;
    border-radius: 10px;
    background: var(--dp-blue);
    color: #fff;
    font: inherit;
    font-weight: 700;
    cursor: pointer;
}
.dp-install__x {
    flex: 0 0 auto;
    width: 38px;
    height: 38px;
    border: none;
    border-radius: 10px;
    background: none;
    color: var(--dp-text-dim);
    font-size: 1.5rem;
    line-height: 1;
    cursor: pointer;
}
.dp-install__x:hover { color: var(--dp-text); }

/* Analytics trend badge — sits under a headline figure, shows the change vs the previous
   equal-length period. Colour carries direction; the arrow carries it again for anyone who
   cannot separate the two greens/reds by hue. */
.dp-stat__delta { display: inline-block; margin-top: 3px; font-size: .72rem; font-weight: 600; letter-spacing: .01em; }
.dp-stat__delta--up { color: var(--dp-ok); }
.dp-stat__delta--down { color: var(--dp-danger); }
.dp-stat__delta--flat { color: var(--dp-text); opacity: .5; }

/* Quick-range chips beside the date pickers. */
.dp-presets { display: inline-flex; gap: 12px; align-items: center; flex-wrap: wrap; }

/* "Logbuch, keine Kasse" notice — a one-time full-screen scrim the user clicks away. */
.dp-disclaimer { position: fixed; inset: 0; z-index: 1000; display: flex; align-items: center; justify-content: center; padding: 24px; background: rgba(4, 8, 16, .72); }
.dp-disclaimer__card { max-width: 440px; width: 100%; background: var(--dp-card); border: 1px solid var(--dp-border); border-radius: var(--dp-radius); padding: 28px; text-align: center; box-shadow: 0 20px 60px rgba(0, 0, 0, .5); }
.dp-disclaimer__title { margin: 0 0 12px; font-size: 1.15rem; }
.dp-disclaimer__body { margin: 0 0 22px; line-height: 1.55; font-size: .95rem; color: var(--dp-text); opacity: .85; }
.dp-disclaimer .dp-btn { width: 100%; }

/* Kiosk (shared till): big name tiles + a numeric PIN pad, sized for tapping on a tablet. */
.dp-kiosk-tiles { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 14px; }
.dp-kiosk-tile { min-height: 84px; border: 1px solid var(--dp-border); border-radius: var(--dp-radius); background: var(--dp-tile); color: var(--dp-text); font-size: 1.15rem; font-weight: 600; cursor: pointer; }
.dp-kiosk-tile:active { background: var(--dp-blue); color: #fff; }

.dp-pin { display: flex; gap: 16px; justify-content: center; margin: 14px 0 20px; }
.dp-pin__dot { width: 16px; height: 16px; border-radius: 50%; border: 2px solid var(--dp-border); }
.dp-pin__dot.is-filled { background: var(--dp-blue); border-color: var(--dp-blue); }

.dp-pinpad { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; max-width: 320px; margin: 0 auto; }
.dp-pinpad__key { min-height: 68px; border: 1px solid var(--dp-border); border-radius: var(--dp-radius); background: var(--dp-tile); color: var(--dp-text); font-size: 1.4rem; font-weight: 600; cursor: pointer; }
.dp-pinpad__key:active { background: var(--dp-blue); color: #fff; }
.dp-pinpad__key--muted { background: transparent; font-size: 1.2rem; opacity: .8; }

/* ---------------------------------------------------- shared panel filter
 *
 * One bar above the panes that governs Auswertung and Verkäufe alike. The chips carry a real
 * selected state: the old text links looked identical whether or not they were the range on
 * screen, so "7 Tage" and "30 Tage" were indistinguishable after the click.
 */
.dp-filterbar {
    /* Same gutter and cap as .dp-main / .dp-tabs, so the bar lines up with the cards it
       governs instead of floating off to the page edge. */
    padding: 14px 12px 10px;
    border-bottom: 1px solid var(--dp-border);
}
@media (min-width: 900px) {
    body.dp-panel .dp-filterbar { max-width: 1080px; margin-inline: auto; width: 100%; }
}
.dp-filterbar .dp-toolbar { margin-bottom: 6px; }
.dp-filterbar__summary {
    margin: 0;
    font-size: .88rem;
    color: var(--dp-muted);
}

.dp-chip {
    border: 1px solid var(--dp-border);
    background: transparent;
    color: var(--dp-muted);
    border-radius: 999px;
    padding: 7px 14px;
    font-size: .88rem;
    font-weight: 600;
    cursor: pointer;
}
.dp-chip:hover { color: var(--dp-text); border-color: var(--dp-border-strong, var(--dp-border)); }
.dp-chip.is-active {
    background: var(--dp-blue);
    border-color: var(--dp-blue);
    color: #fff;
}

/* "Nothing here" has to say so. An empty pane reads as a broken page. */
/* Spans the chart grid: a "nichts gefunden" box squeezed into one column reads like a
   chart that failed to draw, next to an empty space where the others should be. */
.dp-charts-2 > .dp-empty { grid-column: 1 / -1; }

.dp-empty {
    border: 1px dashed var(--dp-border);
    border-radius: var(--dp-radius);
    padding: 34px 22px;
    text-align: center;
}
.dp-empty__msg { margin: 0; font-size: 1rem; font-weight: 600; color: var(--dp-text); }
.dp-empty__hint { margin: 6px 0 0; font-size: .88rem; color: var(--dp-muted); }

/* An employee who has left still owns past numbers; the row says so instead of showing a name
 * nobody on the floor recognises. */
.dp-bar__row .dp-bar__label { white-space: normal; overflow: visible; text-overflow: clip; }

.dp-bar__off {
    font-size: .72rem;
    text-transform: uppercase;
    letter-spacing: .06em;
    color: var(--dp-muted);
    opacity: .8;
}

/* The day and time the till is on. Quiet, but never absent: the overview can be pointed at
   another date, and without this there is nothing on screen that says which day a tap would
   actually book. */
.dp-header__clock {
    margin-left: 10px;
    font-size: .8rem;
    color: var(--dp-muted);
    white-space: nowrap;
}
@media (max-width: 480px) { .dp-header__clock { display: none; } }

/* The header has to hold a logo, a name and up to five actions on a phone. It was letting the
   brand and the tools overlap — "DOYA" printed on top of "Logbuch" — because neither side was
   allowed to give way. The brand shrinks and truncates; the actions keep their size and scroll
   sideways if they must, so a button is never unreachable and never covered. */
.dp-terminal .dp-header { gap: 8px; }
.dp-terminal .dp-header__brand {
    min-width: 0;
    flex: 0 1 auto;
    overflow: hidden;
}
.dp-terminal .dp-header__staff {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}
.dp-terminal .dp-header__tools {
    flex: 0 0 auto;
    gap: 10px;
    overflow-x: auto;
    scrollbar-width: none;
}
.dp-terminal .dp-header__tools::-webkit-scrollbar { display: none; }

/* Under ~430px the logo alone carries the branding: a truncated shop name earns nothing and
   the actions are what an employee actually needs to reach. */
@media (max-width: 430px) {
    .dp-terminal .dp-header__staff { display: none; }
}

/* A sale the server refused for good: the customer paid and nothing was recorded. Loud on
   purpose and it does not fade — the toast pattern is wrong here, because the only repair is
   a person re-entering the booking. Pinned under the header, the one spot free on every
   screen (same reasoning as .dp-toast). */
.dp-lost {
    position: fixed;
    left: 50%;
    transform: translateX(-50%);
    top: 72px;
    z-index: 60;
    max-width: min(92vw, 460px);
    padding: 14px 16px;
    border-radius: 12px;
    border: 2px solid #f0b23c;
    background: #3b2408;
    color: #ffe9c2;
    font-size: 15px;
    line-height: 1.45;
    box-shadow: 0 10px 30px rgba(0, 0, 0, .45);
}

.dp-lost strong { display: block; margin-bottom: 6px; font-size: 16px; }
.dp-lost__hint { margin-top: 8px; font-weight: 600; }
.dp-lost .dp-btn--link { margin-top: 10px; color: #ffe9c2; text-decoration: underline; }

/* Ü.3: one line per lost case, its own "Verwerfen" beside it rather than only the banner's
   single "Verstanden" - a discard is a decision about that one case, not about the banner. */
.dp-lost__line {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    gap: 10px;
}
.dp-lost__line .dp-btn--link { margin-top: 0; flex: 0 0 auto; }
.dp-lost__line .dp-btn--link:disabled { opacity: .5; cursor: not-allowed; text-decoration: none; }

/* Ankreuzfeld im Formular-Baustein.
 *
 * `.dp-field input` stylt Texteingaben: volle Breite, 44 px hoch, gefuellter Hintergrund. Auf
 * ein <input type="checkbox"> angewandt ergab das einen 160 px breiten, leeren weissen Kasten
 * ueber der Beschriftung — der Schalter "Namen an der Kasse anzeigen" sah aus wie ein
 * kaputtes Textfeld, und ob er an oder aus war, konnte man ueberhaupt nicht sehen. */
.dp-field input[type="checkbox"] {
    width: 22px;
    min-width: 22px;
    height: 22px;
    min-height: 22px;
    padding: 0;
    margin: 0;
    accent-color: var(--dp-blue);
    cursor: pointer;
}

/* Kaestchen und Beschriftung nebeneinander, nicht untereinander. */
.dp-field--inline {
    display: flex;
    align-items: center;
    gap: 10px;
    cursor: pointer;
}
.dp-field--inline > span {
    display: inline;
    margin-bottom: 0;
    color: var(--dp-text);
}

/* Zweizeilige Kachel: Nummer klein und zurueckgenommen, Name gross und fett. Der Name ist,
   was der Mitarbeiter sucht; die Nummer ist nur die Bruecke zur alten neutralen Beschriftung. */
.dp-kiosk-tile {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 3px;
    line-height: 1.2;
    padding: 8px 10px;
}
.dp-kiosk-tile__num {
    font-size: .82rem;
    font-weight: 600;
    color: rgba(255, 255, 255, .42);
    letter-spacing: .04em;
}
.dp-kiosk-tile__name { font-size: 1.35rem; font-weight: 800; }

/* Dieselbe Ordnung in der Mitarbeiterliste des Inhabers. */
.dp-row__kiosk {
    font-size: .78rem;
    font-weight: 600;
    letter-spacing: .04em;
    color: var(--dp-text-muted);
    margin-bottom: 2px;
}

/* T.6 (5e257b): the TSE outage bar. Sticky at the top and in the flow, so it covers nothing it could
   block; no close control, and no pointer events of its own - there is nothing to tap on it. */
.dp-tse-banner {
    position: sticky;
    top: 0;
    z-index: 50;
    padding: 0.6rem 1rem;
    background: var(--dp-danger);
    color: #fff;
    font-weight: 600;
    text-align: center;
    pointer-events: none;
}
.dp-tse-banner[hidden] { display: none; }

/* ==========================================================================
   D.3 — approved "Einsatzfokus" presentation for the live till.

   The earlier rules remain the proven interaction layer. This final section maps that
   layer to the approved brand tokens and responsive zones without changing behaviour.
   ========================================================================== */

@font-face {
    font-family: "Montserrat";
    src: url("../fonts/Montserrat-Regular.woff2") format("woff2");
    font-style: normal;
    font-weight: 400;
    font-display: swap;
}
@font-face {
    font-family: "Montserrat";
    src: url("../fonts/Montserrat-Medium.woff2") format("woff2");
    font-style: normal;
    font-weight: 500;
    font-display: swap;
}
@font-face {
    font-family: "Montserrat";
    src: url("../fonts/Montserrat-SemiBold.woff2") format("woff2");
    font-style: normal;
    font-weight: 600;
    font-display: swap;
}
@font-face {
    font-family: "Montserrat";
    src: url("../fonts/Montserrat-Bold.woff2") format("woff2");
    font-style: normal;
    font-weight: 700;
    font-display: swap;
}

:root,
:root[data-kasse-palette="einsatzfokus"] {
    /* TH.3 (6fb6fc): the light side of the default world is the "Galerie" of TH.2 - a warm, nearly white surface, ink instead of
       blue-black text, navy for the quiet blue. Contrasts (text on its surface, measured on the rendered screens, not on the pairs):
       ink #0e1a2b on #faf8f5 16.5:1, grey #4f5b6b on #faf8f5 6.6:1, navy #073763 on white 12.1:1. The brand blue #11a6f6 is
       the logo and the focus ring's inner gap only, never text. */
    --k-light-page: #faf8f5; --k-light-app: #faf8f5; --k-light-bg: #ffffff;
    --k-light-surface: #ffffff; --k-light-surface-2: #f4f1ec; --k-light-surface-3: #e6edf5;
    --k-light-border: #7b8593; --k-light-line: #e6e1d8; --k-light-header: #ffffff;
    --k-light-text: #0e1a2b; --k-light-muted: #4f5b6b; --k-light-dim: #5b6370; --k-light-locked: #5b6370;
    --k-light-primary: #073763; --k-light-primary-strong: #052b4d; --k-light-eyebrow: #073763;
    --k-light-focus-outline: #073763; --k-light-focus-gap: #ffffff;
    --k-light-warn: #fff1cc; --k-light-warn-text: #4f3500; --k-light-warn-border: #a87a12;
    --k-light-tse: #e5f4ff; --k-light-tse-text: #102d49; --k-light-tse-border: #38516f;

    --k-dark-page: #0a0b0d; --k-dark-app: #171c26; --k-dark-bg: #1c2230;
    --k-dark-surface: #171c26; --k-dark-surface-2: #242c3d; --k-dark-surface-3: #0d2347;
    --k-dark-border: #7f97b8; --k-dark-line: #33405a; --k-dark-header: #010101;
    --k-dark-text: #f4f8fc; --k-dark-muted: #b9cbe0; --k-dark-dim: #b9cbe0; --k-dark-locked: #b9cbe0;
    --k-dark-primary: #001d86; --k-dark-primary-strong: #001466; --k-dark-eyebrow: #6cc8fa;
    --k-dark-focus-outline: #6cc8fa; --k-dark-focus-gap: #010101;
    --k-dark-warn: #3a2c0e; --k-dark-warn-text: #ffe3a3; --k-dark-warn-border: #a87a12;
    --k-dark-tse: #102d49; --k-dark-tse-text: #e5f4ff; --k-dark-tse-border: #38516f;
}

:root[data-kasse-palette="midnight"] {
    /* D.0 supplied dark; the light side keeps Onyx/Fresh Sky roles on pale tints. */
    --k-light-page: #dce8f4; --k-light-app: #e5f4ff; --k-light-bg: #ffffff;
    --k-light-surface: #f2f6fa; --k-light-surface-2: #e8f0f7; --k-light-surface-3: #d4e6f6;
    --k-light-border: #38516f; --k-light-line: #b9cbe0; --k-light-header: #ffffff;
    --k-light-text: #131112; --k-light-muted: #38516f; --k-light-dim: #4c6178; --k-light-locked: #4c6178;
    --k-light-primary: #001d86; --k-light-primary-strong: #001466; --k-light-eyebrow: #001d86;
    --k-light-focus-outline: #001d86; --k-light-focus-gap: #ffffff;
    --k-light-warn: #fff4d6; --k-light-warn-text: #5a3c08; --k-light-warn-border: #8a621b;
    --k-light-tse: #e5f4ff; --k-light-tse-text: #102d49; --k-light-tse-border: #38516f;

    --k-dark-page: #000000; --k-dark-app: #0d2347; --k-dark-bg: #000000;
    --k-dark-surface: #131112; --k-dark-surface-2: #1b2330; --k-dark-surface-3: #0d2347;
    --k-dark-border: #5e7894; --k-dark-line: #2b3748; --k-dark-header: #000000;
    --k-dark-text: #ffffff; --k-dark-muted: #b9cbe0; --k-dark-dim: #b9cbe0; --k-dark-locked: #b9cbe0;
    --k-dark-primary: #001d86; --k-dark-primary-strong: #001466; --k-dark-eyebrow: #8ed9ff;
    --k-dark-focus-outline: #11a6f6; --k-dark-focus-gap: #000000;
    --k-dark-warn: #5a3c08; --k-dark-warn-text: #fff4d6; --k-dark-warn-border: #8a621b;
    --k-dark-tse: #102d49; --k-dark-tse-text: #e5f4ff; --k-dark-tse-border: #38516f;
}

:root[data-kasse-palette="cobalt"] {
    /* D.0 supplied dark; the light side uses Pale Sky as the counter surface. */
    --k-light-page: #dce8f6; --k-light-app: #c8e5fc; --k-light-bg: #ffffff;
    --k-light-surface: #edf6fd; --k-light-surface-2: #e2f1fc; --k-light-surface-3: #c8e5fc;
    --k-light-border: #6684aa; --k-light-line: #b8cce0; --k-light-header: #ffffff;
    --k-light-text: #0d2347; --k-light-muted: #38516f; --k-light-dim: #526984; --k-light-locked: #526984;
    --k-light-primary: #001d86; --k-light-primary-strong: #001466; --k-light-eyebrow: #001d86;
    --k-light-focus-outline: #001d86; --k-light-focus-gap: #ffffff;
    --k-light-warn: #fff1cc; --k-light-warn-text: #4f3500; --k-light-warn-border: #a87a12;
    --k-light-tse: #dceeff; --k-light-tse-text: #091a36; --k-light-tse-border: #6684aa;

    --k-dark-page: #091a36; --k-dark-app: #0d2347; --k-dark-bg: #0d2347;
    --k-dark-surface: #091a36; --k-dark-surface-2: #152f59; --k-dark-surface-3: #1d3b6b;
    --k-dark-border: #6684aa; --k-dark-line: #3e5d83; --k-dark-header: #091a36;
    --k-dark-text: #ffffff; --k-dark-muted: #c8e5fc; --k-dark-dim: #c8e5fc; --k-dark-locked: #c8e5fc;
    --k-dark-primary: #001d86; --k-dark-primary-strong: #001466; --k-dark-eyebrow: #8ed9ff;
    --k-dark-focus-outline: #11a6f6; --k-dark-focus-gap: #091a36;
    --k-dark-warn: #5a3c08; --k-dark-warn-text: #fff4d6; --k-dark-warn-border: #8a621b;
    --k-dark-tse: #102d49; --k-dark-tse-text: #e5f4ff; --k-dark-tse-border: #6684aa;
}

:root[data-kasse-palette="calm"] {
    /* D.0 supplied dark; the light side derives neutral surfaces from its muted greens. */
    --k-light-page: #dfe5e1; --k-light-app: #edf2ef; --k-light-bg: #ffffff;
    --k-light-surface: #f6f8f7; --k-light-surface-2: #eef2f0; --k-light-surface-3: #d4ddd8;
    --k-light-border: #7e8983; --k-light-line: #c6cfca; --k-light-header: #ffffff;
    --k-light-text: #131112; --k-light-muted: #48534d; --k-light-dim: #59655f; --k-light-locked: #59655f;
    --k-light-primary: #001d86; --k-light-primary-strong: #001466; --k-light-eyebrow: #001d86;
    --k-light-focus-outline: #001d86; --k-light-focus-gap: #ffffff;
    --k-light-warn: #fff1cc; --k-light-warn-text: #4f3500; --k-light-warn-border: #a87a12;
    --k-light-tse: #e5f4ff; --k-light-tse-text: #102d49; --k-light-tse-border: #7e8983;

    --k-dark-page: #131112; --k-dark-app: #1f2321; --k-dark-bg: #131112;
    --k-dark-surface: #1f2321; --k-dark-surface-2: #1f2321; --k-dark-surface-3: #292e2b;
    --k-dark-border: #7e8983; --k-dark-line: #49514d; --k-dark-header: #131112;
    --k-dark-text: #ffffff; --k-dark-muted: #d4ddd8; --k-dark-dim: #aebbb4; --k-dark-locked: #d4ddd8;
    --k-dark-primary: #001d86; --k-dark-primary-strong: #001466; --k-dark-eyebrow: #c8e5fc;
    --k-dark-focus-outline: #c8e5fc; --k-dark-focus-gap: #131112;
    --k-dark-warn: #5a3c08; --k-dark-warn-text: #fff4d6; --k-dark-warn-border: #8a621b;
    --k-dark-tse: #102d49; --k-dark-tse-text: #e5f4ff; --k-dark-tse-border: #7e8983;
}

/* GA.4 (3e410f): the eight group colours - a fixed palette, chosen by number (data-farbe), never sent as a colour by
   the server. Light tints and deep tones, the same in every colour world: each keeps 4.5:1 against that world's tile
   text (tools/js-tests/kasse-theme.test.mjs computes it). Order: blue, green, red, orange, violet, teal, yellow, pink. */
:root {
    --k-light-gruppe-1: #cfe2ff; --k-dark-gruppe-1: #163f80;
    --k-light-gruppe-2: #ccebd2; --k-dark-gruppe-2: #1d5a2e;
    --k-light-gruppe-3: #ffd5d5; --k-dark-gruppe-3: #7a1f24;
    --k-light-gruppe-4: #ffdfbd; --k-dark-gruppe-4: #7a4108;
    --k-light-gruppe-5: #e4d6ff; --k-dark-gruppe-5: #4b2a80;
    --k-light-gruppe-6: #c4ece7; --k-dark-gruppe-6: #0f5751;
    --k-light-gruppe-7: #fff0a6; --k-dark-gruppe-7: #5c4a00;
    --k-light-gruppe-8: #ffd7ec; --k-dark-gruppe-8: #7a1f55;
}

:root {
    --dp-page: var(--k-light-page); --dp-app: var(--k-light-app); --dp-bg: var(--k-light-bg);
    --dp-surface: var(--k-light-surface); --dp-surface-2: var(--k-light-surface-2); --dp-surface-3: var(--k-light-surface-3);
    --dp-border: var(--k-light-border); --dp-line: var(--k-light-line);
    --dp-blue: var(--k-light-primary); --dp-blue-strong: var(--k-light-primary-strong); --dp-navy: var(--k-light-header);
    --dp-cash: #176b43;
    --dp-cash-strong: #0e4a2d;
    --dp-card: var(--k-light-primary); --dp-card-strong: var(--k-light-primary-strong);
    --dp-text: var(--k-light-text); --dp-text-muted: var(--k-light-muted); --dp-text-dim: var(--k-light-dim); --dp-locked: var(--k-light-locked);
    --dp-danger: #72111f;
    --dp-danger-bg: #fde6e9;
    --dp-danger-text: #72111f;
    --dp-warn: var(--k-light-warn); --dp-warn-text: var(--k-light-warn-text); --dp-warn-border: var(--k-light-warn-border);
    --dp-tse-bg: var(--k-light-tse); --dp-tse-text: var(--k-light-tse-text); --dp-tse-border: var(--k-light-tse-border);
    --dp-ok: #0e4a2d;
    --dp-ok-bg: #e2f4eb;
    --dp-focus: #11a6f6;
    --dp-eyebrow: var(--k-light-eyebrow);
    --dp-focus-outline: var(--k-light-focus-outline); --dp-focus-gap: var(--k-light-focus-gap);
    --dp-radius: 8px;
    --dp-radius-sm: 6px;
    --dp-font: "Montserrat", sans-serif;
    --dp-gruppe-1: var(--k-light-gruppe-1); --dp-gruppe-2: var(--k-light-gruppe-2); --dp-gruppe-3: var(--k-light-gruppe-3); --dp-gruppe-4: var(--k-light-gruppe-4); --dp-gruppe-5: var(--k-light-gruppe-5); --dp-gruppe-6: var(--k-light-gruppe-6); --dp-gruppe-7: var(--k-light-gruppe-7); --dp-gruppe-8: var(--k-light-gruppe-8);
    color-scheme: light;
}

:root[data-theme="dark"] {
        --dp-page: var(--k-dark-page); --dp-app: var(--k-dark-app); --dp-bg: var(--k-dark-bg);
        --dp-surface: var(--k-dark-surface); --dp-surface-2: var(--k-dark-surface-2); --dp-surface-3: var(--k-dark-surface-3);
        --dp-border: var(--k-dark-border); --dp-line: var(--k-dark-line);
        --dp-blue: var(--k-dark-primary); --dp-blue-strong: var(--k-dark-primary-strong); --dp-navy: var(--k-dark-header);
        --dp-card: var(--k-dark-primary); --dp-card-strong: var(--k-dark-primary-strong);
        --dp-text: var(--k-dark-text); --dp-text-muted: var(--k-dark-muted); --dp-text-dim: var(--k-dark-dim); --dp-locked: var(--k-dark-locked);
        --dp-danger: #c4485b;
        --dp-danger-bg: #3e1a20;
        --dp-danger-text: #ffd2d8;
        --dp-warn: var(--k-dark-warn); --dp-warn-text: var(--k-dark-warn-text); --dp-warn-border: var(--k-dark-warn-border);
        --dp-tse-bg: var(--k-dark-tse); --dp-tse-text: var(--k-dark-tse-text); --dp-tse-border: var(--k-dark-tse-border);
        --dp-ok: #bff0d6;
        --dp-ok-bg: #0f2e22;
        --dp-eyebrow: var(--k-dark-eyebrow);
        --dp-focus-outline: var(--k-dark-focus-outline); --dp-focus-gap: var(--k-dark-focus-gap);
        --dp-gruppe-1: var(--k-dark-gruppe-1); --dp-gruppe-2: var(--k-dark-gruppe-2); --dp-gruppe-3: var(--k-dark-gruppe-3); --dp-gruppe-4: var(--k-dark-gruppe-4); --dp-gruppe-5: var(--k-dark-gruppe-5); --dp-gruppe-6: var(--k-dark-gruppe-6); --dp-gruppe-7: var(--k-dark-gruppe-7); --dp-gruppe-8: var(--k-dark-gruppe-8);
        color-scheme: dark;
}

@media (prefers-color-scheme: dark) {
    :root:not([data-theme]) {
        --dp-page: var(--k-dark-page); --dp-app: var(--k-dark-app); --dp-bg: var(--k-dark-bg);
        --dp-surface: var(--k-dark-surface); --dp-surface-2: var(--k-dark-surface-2); --dp-surface-3: var(--k-dark-surface-3);
        --dp-border: var(--k-dark-border); --dp-line: var(--k-dark-line);
        --dp-blue: var(--k-dark-primary); --dp-blue-strong: var(--k-dark-primary-strong); --dp-navy: var(--k-dark-header);
        --dp-card: var(--k-dark-primary); --dp-card-strong: var(--k-dark-primary-strong);
        --dp-text: var(--k-dark-text); --dp-text-muted: var(--k-dark-muted); --dp-text-dim: var(--k-dark-dim); --dp-locked: var(--k-dark-locked);
        --dp-danger: #c4485b; --dp-danger-bg: #3e1a20; --dp-danger-text: #ffd2d8;
        --dp-warn: var(--k-dark-warn); --dp-warn-text: var(--k-dark-warn-text); --dp-warn-border: var(--k-dark-warn-border);
        --dp-tse-bg: var(--k-dark-tse); --dp-tse-text: var(--k-dark-tse-text); --dp-tse-border: var(--k-dark-tse-border);
        --dp-ok: #bff0d6; --dp-ok-bg: #0f2e22; --dp-eyebrow: var(--k-dark-eyebrow);
        --dp-focus-outline: var(--k-dark-focus-outline); --dp-focus-gap: var(--k-dark-focus-gap);
        --dp-gruppe-1: var(--k-dark-gruppe-1); --dp-gruppe-2: var(--k-dark-gruppe-2); --dp-gruppe-3: var(--k-dark-gruppe-3); --dp-gruppe-4: var(--k-dark-gruppe-4); --dp-gruppe-5: var(--k-dark-gruppe-5); --dp-gruppe-6: var(--k-dark-gruppe-6); --dp-gruppe-7: var(--k-dark-gruppe-7); --dp-gruppe-8: var(--k-dark-gruppe-8);
        color-scheme: dark;
    }
}

html,
body {
    background: var(--dp-page);
    color: var(--dp-text);
    font-family: var(--dp-font);
}

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

:focus-visible {
    outline: 3px solid var(--dp-focus-outline) !important;
    outline-offset: 3px;
    box-shadow: 0 0 0 3px var(--dp-focus-gap);
}

.dp-app {
    width: 100%;
    max-width: 1440px;
    margin-inline: auto;
    background: var(--dp-bg);
}

.dp-header {
    min-height: 70px;
    padding: calc(7px + var(--dp-safe-top)) 18px 7px;
    background: var(--dp-navy);
    border-bottom: 1px solid var(--dp-border);
    color: var(--dp-text);
}

.dp-header__picture {
    display: inline-flex;
    flex: 0 0 auto;
}

.dp-header__logo {
    width: 94px;
    height: 38px;
    object-fit: cover;
    opacity: 1;
}
.dp-header__logo--dark { display: none; }
:root[data-theme="dark"] .dp-header__logo--light { display: none; }
:root[data-theme="dark"] .dp-header__logo--dark { display: block; }
@media (prefers-color-scheme: dark) {
    :root:not([data-theme]) .dp-header__logo--light { display: none; }
    :root:not([data-theme]) .dp-header__logo--dark { display: block; }
}

.dp-header__staff { font-size: .9rem; }

.dp-header .dp-btn--link {
    flex: 0 0 auto;
    min-height: 56px;
    padding: 0 8px;
    color: var(--dp-text-muted);
    font-weight: 600;
}
.dp-header .dp-btn--link:hover { color: var(--dp-text); }

.dp-main {
    min-width: 0;
    padding: 22px 20px 28px;
    background: var(--dp-bg);
}

.dp-main--narrow { max-width: 560px; }

.dp-section-title {
    color: var(--dp-eyebrow);
    font-size: .75rem;
    letter-spacing: .08em;
}

.dp-tile,
.dp-receipt__line,
.dp-cart,
.dp-row,
.dp-stat,
.dp-amount,
.dp-group,
.dp-chart {
    background: var(--dp-surface-2);
    border-color: var(--dp-border);
}

.dp-tile__price { color: var(--dp-eyebrow); }
.dp-tile--gesperrt {
    opacity: 1;
    color: var(--dp-locked);
}
.dp-tile--gesperrt .dp-tile__price { color: var(--dp-locked); }

.dp-cart__line,
.dp-receipt__line,
.dp-row,
.dp-group__head,
.dp-cart__total { border-color: var(--dp-line); }

.dp-cart__total,
.dp-group__head { background: var(--dp-surface-3); }

.dp-cart__remove {
    width: 56px;
    height: 56px;
    border-color: var(--dp-border);
}

/* D.4 after R.6.b: the percent action is a full touch target and uses the palette's
   readable eyebrow colour instead of dark True Cobalt on a dark cart surface. */
.dp-cart__discount {
    width: 56px;
    height: 56px;
    border-color: var(--dp-border);
    background: var(--dp-surface-2);
    color: var(--dp-eyebrow);
}
.dp-cart__discount:active {
    border-color: var(--dp-focus-outline);
    color: var(--dp-eyebrow);
}

.dp-btn,
.dp-tile,
.dp-pay__btn,
.dp-btn--link,
.dp-pinpad__key,
.dp-kiosk-tile { min-height: 56px; }

.dp-btn--link {
    display: inline-flex;
    align-items: center;
    padding: 8px 10px;
    color: var(--dp-text-muted);
    font-weight: 600;
}

.dp-btn {
    background: var(--dp-blue);
    color: #ffffff;
}
.dp-btn:active { background: var(--dp-blue-strong); }

.dp-btn--ghost {
    background: transparent;
    border-color: var(--dp-border);
    color: var(--dp-text);
}

.dp-pay {
    grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
}

.dp-pay__btn {
    min-height: 112px;
    text-align: left;
    padding: 18px;
}

.dp-pay__btn--cash { background: var(--dp-cash); }
.dp-pay__btn--cash:active { background: var(--dp-cash-strong); }
.dp-pay__btn--card {
    background: var(--dp-card);
    border: 2px dashed var(--dp-focus);
}
.dp-pay__btn--card:active { background: var(--dp-card-strong); }

.dp-field input,
.dp-field select {
    background: var(--dp-surface-2);
    border-color: var(--dp-border);
    color: var(--dp-text);
}

.dp-field input::placeholder {
    color: var(--dp-text-muted);
    opacity: 1;
}

.dp-alert {
    background: var(--dp-danger-bg);
    border-color: var(--dp-danger);
    color: var(--dp-danger-text);
}

.dp-offline {
    background: var(--dp-warn);
    color: var(--dp-warn-text);
    border-bottom: 1px solid var(--dp-warn-border);
}

.dp-tse-banner {
    background: var(--dp-tse-bg);
    color: var(--dp-tse-text);
    border-bottom: 1px solid var(--dp-tse-border);
}

.dp-toast {
    background: var(--dp-ok-bg);
    color: var(--dp-ok);
    border: 2px solid var(--dp-ok);
    border-radius: 6px;
}

/* H.4: a notice that something did not happen (a scan that booked nothing) - not the green tick of a booking. */
.dp-toast.dp-toast--hinweis {
    background: var(--dp-bg);
    color: var(--dp-warn);
    border-color: var(--dp-warn);
}

.dp-kiosk-tile__num { color: var(--dp-text-muted); }

.dp-disclaimer__card,
dialog.dp-disclaimer__card {
    max-width: 500px;
    width: min(100%, 500px);
    padding: 24px;
    background: var(--dp-bg);
    border: 2px solid var(--dp-border);
    border-radius: 8px;
    color: var(--dp-text);
    text-align: left;
    box-shadow: 0 20px 60px rgb(0 0 0 / .35);
}

dialog.dp-disclaimer__card::backdrop { background: rgb(10 11 13 / .72); }
dialog.dp-disclaimer__card .dp-list { display: grid; gap: 8px; }
dialog.dp-disclaimer__card .dp-btn { margin-top: 8px; }
dialog.dp-disclaimer__card [data-kachel].is-active {
    border: 3px solid var(--dp-focus);
    background: var(--dp-surface-3);
}

.dp-flow { display: none; }
.dp-flow__eyebrow {
    margin: 0 0 8px;
    color: var(--dp-eyebrow);
    font-size: .75rem;
    font-weight: 700;
    letter-spacing: .08em;
    text-transform: uppercase;
}
.dp-flow h2 { margin: 0 0 14px; font-size: 1.15rem; }
.dp-flow__steps { margin: 0; padding: 0; list-style: none; }
.dp-flow__step {
    padding: 12px 10px;
    border-top: 1px solid var(--dp-line);
}
.dp-flow__step strong,
.dp-flow__step span { display: block; }
.dp-flow__step span {
    margin-top: 3px;
    color: var(--dp-text-muted);
    font-size: .78rem;
    line-height: 1.4;
}
.dp-flow__back {
    margin: 18px 0 0;
    padding: 12px;
    border-left: 5px solid var(--dp-eyebrow);
    background: var(--dp-surface-3);
    font-size: .8rem;
}
.dp-flow__back strong,
.dp-flow__back span { display: block; }
.dp-flow__back span { margin-top: 3px; color: var(--dp-text-muted); }

.dp-action-intro h2 {
    margin: 0 0 8px;
    font-size: 1.2rem;
    line-height: 1.25;
}
.dp-action-intro > p:last-child {
    margin: 0 0 16px;
    color: var(--dp-text-muted);
    font-size: .86rem;
    line-height: 1.45;
}

.dp-theme-dialog {
    width: min(92vw, 440px);
    padding: 0;
    border: 0;
    border-radius: var(--dp-radius);
    color: var(--dp-text);
    background: transparent;
}
.dp-theme-dialog::backdrop { background: rgb(0 0 0 / .62); }
.dp-theme-dialog__card {
    display: grid;
    gap: 16px;
    padding: 24px;
    border: 2px solid var(--dp-border);
    border-radius: var(--dp-radius);
    background: var(--dp-bg);
}
.dp-theme-dialog__card h2 { margin: 0; }
.dp-theme-dialog__card .dp-section-title { margin: 0; }
.dp-theme-dialog__card .dp-btn { margin-top: 4px; }

/* B.4: the customer's receipt code - large enough to scan from across the counter, black on white
   in every theme (a scanner reads dark on light), never larger than the screen when sideways. */
.dp-beleg-dialog { max-height: calc(100dvh - 32px); }
.dp-beleg-dialog__card {
    max-height: calc(100dvh - 32px);
    overflow-y: auto;
    justify-items: center;
    text-align: center;
}
.dp-beleg-dialog__qr {
    width: min(72vw, 52dvh, 320px);
    aspect-ratio: 1;
    background: #fff;
    border-radius: 8px;
}
.dp-beleg-dialog__qr svg { display: block; width: 100%; height: 100%; }
.dp-beleg-dialog__betrag { margin: 0; font-size: 1.25rem; font-weight: 700; }
.dp-beleg-dialog__hinweis { margin: 0; color: var(--dp-text-muted); font-size: .9rem; line-height: 1.4; }
.dp-beleg-dialog__card .dp-btn { width: 100%; }
/* A.15: "Drucken" next to "Fertig" - two equal buttons, the print note above them. */
.dp-beleg-dialog__aktionen {
    position: sticky;
    bottom: 0;
    z-index: 1;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 12px;
    width: 100%;
    padding-top: 4px;
    background: var(--dp-bg);
}
.dp-beleg-dialog__aktionen .dp-btn { margin-top: 0; min-height: 56px; }
.dp-beleg-dialog__druck { color: var(--dp-text); font-weight: 600; }
/* B.5.a: "Per E-Mail" - three equal buttons when it is offered; search, hits and a new customer above them. */
.dp-beleg-dialog__aktionen:has(#receiptQrMail:not([hidden])) { grid-template-columns: 1fr 1fr 1fr; }
.dp-beleg-dialog__email { display: grid; gap: 8px; width: 100%; text-align: left; }
.dp-beleg-dialog__label { font-size: .9rem; color: var(--dp-text-muted); }
.dp-beleg-dialog__eingabe {
    width: 100%; min-height: 48px; padding: 8px 12px; font-size: 1rem;
    border: 1px solid var(--dp-border); border-radius: 8px; background: var(--dp-surface-2); color: var(--dp-text);
}
.dp-beleg-dialog__treffer { list-style: none; margin: 0; padding: 0; display: grid; gap: 6px; }
.dp-beleg-dialog__treffer li { display: grid; gap: 4px; padding: 8px; border: 1px solid var(--dp-border); border-radius: 8px; }
.dp-beleg-dialog__neu { display: grid; gap: 8px; }
.dp-beleg-dialog__neu summary { cursor: pointer; min-height: 40px; line-height: 40px; }
.dp-beleg-dialog__neu[open] { display: grid; gap: 8px; }
.dp-beleg-dialog__zustimmung { display: flex; gap: 8px; align-items: center; font-size: .95rem; }
/* On a short window (a phone sideways, a small phone) the code gives way before the buttons do. */
@media (max-height: 760px) {
    .dp-beleg-dialog__card { padding: 16px; gap: 10px; }
    .dp-beleg-dialog__qr { width: min(72vw, 34dvh, 320px); }
}

@media (min-width: 900px) {
    body.dp-terminal .dp-app {
        display: grid;
        grid-template-columns: 190px minmax(0, 1fr) 310px;
        grid-template-rows: auto auto minmax(0, 1fr);
        align-items: stretch;
        column-gap: 0;
        padding-inline: 0;
        max-width: 1440px;
    }

    .dp-header,
    .dp-leiste,
    .dp-offline { grid-column: 1 / -1; }
    .dp-header { grid-row: 1; }
    .dp-leiste { grid-row: 2; }
    .dp-offline { grid-row: auto; }

    body.dp-terminal .dp-main,
    body.dp-terminal .dp-main:not(#screenCatalog) {
        grid-column: 1 / -1;
        grid-row: 3;
        width: 100%;
    }

    /* Z.7: a narrow screen taller than the window scrolls inside its own grid row. With "align-self: start"
       alone it grew to its content and the window clipped it - on a laptop the day close's refusal, its
       buttons and "Tag abschließen" itself lay below the edge, out of reach (the click test with real
       mouse events found it). */
    .dp-main--narrow { align-self: start; margin-top: 32px; max-height: calc(100% - 32px); }

    body:has(#screenCatalog:not([hidden])) .dp-flow,
    body:has(#screenCustom:not([hidden])) .dp-flow,
    body:has(#screenPayment:not([hidden])) .dp-flow {
        display: block;
        grid-column: 1;
        grid-row: 3;
        min-height: 0;
        overflow-y: auto;
        padding: 20px 14px;
        background: var(--dp-app);
        border-right: 1px solid var(--dp-border);
    }

    body:has(#screenCatalog:not([hidden])) #screenCatalog,
    body:has(#screenCustom:not([hidden])) #screenCustom,
    body:has(#screenPayment:not([hidden])) #screenPayment {
        grid-column: 2;
        grid-row: 3;
        margin: 0;
        max-width: none;
    }

    body:has(#screenCatalog:not([hidden])) .dp-footer {
        position: relative;
        top: auto;
        grid-column: 3;
        grid-row: 3;
        min-height: 0;
        overflow-y: auto;
        padding: 20px 16px;
        background: var(--dp-app);
        border-left: 1px solid var(--dp-border);
    }

    body:has(#screenCustom:not([hidden])) .dp-app,
    body:has(#screenPayment:not([hidden])) .dp-app {
        grid-template-columns: 190px minmax(0, 1fr);
    }

    body:has(#screenCatalog:not([hidden])) .dp-flow__step--items,
    body:has(#screenCustom:not([hidden])) .dp-flow__step--items,
    body:has(#screenPayment:not([hidden])) .dp-flow__step--payment {
        padding-left: 8px;
        background: var(--dp-surface-3);
        border-left: 5px solid var(--dp-focus);
    }
}

@media (max-width: 899px) {
    .dp-header {
        min-height: 64px;
        padding-inline: 10px;
    }
    .dp-header__logo { width: 78px; height: 32px; }
    .dp-header__tools { gap: 2px; }
    .dp-header .dp-btn--link { padding-inline: 6px; font-size: .75rem; }
    .dp-main { padding: 16px 12px 24px; }
    .dp-footer {
        padding: 12px 12px calc(12px + var(--dp-safe-bottom));
        background: var(--dp-app);
        border-top: 1px solid var(--dp-border);
    }
    .dp-action-intro { display: none; }
    .dp-pay { grid-template-columns: 1fr 1fr; }
}

@media (max-width: 520px) {
    .dp-header__picture { width: 28px; overflow: hidden; }
    .dp-header__logo { width: 78px; max-width: none; object-position: left; }
    .dp-header__tools { max-width: calc(100vw - 54px); overflow-x: auto; scrollbar-width: none; }
    .dp-header__tools::-webkit-scrollbar { display: none; }
    .dp-header .dp-btn--link { min-width: 56px; }
    .dp-header #themeBtn { order: 98; }
    .dp-header #lockBtn {
        order: 99;
        position: sticky;
        right: 0;
        background: var(--dp-navy);
        box-shadow: -8px 0 8px var(--dp-navy);
    }
    .dp-pay { grid-template-columns: 1fr; }
}

/* =====================================================================================
 * A.14 - the till on the phone, upright and sideways: calm, readable, nothing that jumps.
 * (Hakan, 08.10.2026: "die idiotensicherste Kasse der Welt, aber unauffällig".)
 *
 * Last in the file on purpose: it settles what the layers above leave open. Rules:
 *  - the page itself never scrolls and never moves (the system keyboard cannot push it up); only
 *    a screen's own content scrolls;
 *  - a compact header: logo, name, "Menü", "Sperren" - everything else is inside the menu;
 *  - sideways (landscape) the till is two columns: services | cart, like on the tablet;
 *  - PIN and amounts are typed on the till's own pad.
 * ===================================================================================== */

html { height: 100%; }
body.dp-terminal {
    position: fixed;
    inset: 0;
    width: 100%;
    height: auto;
    overflow: hidden;
    overscroll-behavior: none;
}
/* A.15 (237485): the outage bar and the till share the window - the bar takes its own height off the top
   and the till gets what is left. A fixed "height: 100%" for the till made it as tall as the whole window
   with the bar on top, pushing the pay button below the edge. */
body.dp-terminal { display: flex; flex-direction: column; }
body.dp-terminal .dp-app { height: auto; flex: 1 1 0; min-height: 0; }
body.dp-terminal .dp-tse-banner {
    position: relative;
    flex: 0 0 auto;
    padding-top: calc(0.6rem + var(--dp-safe-top));
    padding-left: calc(1rem + env(safe-area-inset-left, 0px));
    padding-right: calc(1rem + env(safe-area-inset-right, 0px));
}
/* The bar already stands in the notch; the header below it must not leave the notch's room a second time. */
body.dp-terminal:has(#tseBanner:not([hidden])) .dp-header { padding-top: 6px; }
body.dp-terminal .dp-main { min-height: 0; overscroll-behavior: contain; }

/* --- header: compact, the name always readable ----------------------------------------- */
body.dp-terminal .dp-header {
    position: relative;
    z-index: 700;
    min-height: 52px;
    padding: calc(6px + var(--dp-safe-top)) calc(12px + env(safe-area-inset-right, 0px)) 6px calc(12px + env(safe-area-inset-left, 0px));
    gap: 8px;
}
body.dp-terminal .dp-header__brand { flex: 1 1 auto; min-width: 0; overflow: hidden; gap: 10px; }
body.dp-terminal .dp-header__picture { flex: 0 0 auto; }
body.dp-terminal .dp-header__logo { width: 88px; height: 30px; object-fit: contain; object-position: left center; }
/* Narrow: the mark alone, so the employee's name has the room. */
@media (max-width: 479px) { body.dp-terminal .dp-header__logo { width: 32px; object-fit: cover; } }
body.dp-terminal .dp-header__staff { display: block; font-size: 1.05rem; font-weight: 700; min-width: 0; }
body.dp-terminal .dp-header__tools { gap: 8px; overflow: visible; flex: 0 0 auto; }
@media (max-width: 699px) { body.dp-terminal .dp-header__clock { display: none; } }

.dp-header__btn {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    min-height: 40px;
    padding: 0 14px;
    border: 1px solid var(--dp-border);
    border-radius: 999px;
    background: transparent;
    color: var(--dp-text);
    font: inherit;
    font-size: .92rem;
    font-weight: 600;
    cursor: pointer;
}
.dp-header__btn:active { background: var(--dp-surface-3); }
.dp-header__icon::before { content: "☰"; font-size: 1.05rem; line-height: 1; }

.dp-menu {
    position: absolute;
    top: calc(100% + 4px);
    right: 10px;
    z-index: 800;
    display: grid;
    gap: 2px;
    min-width: 230px;
    max-width: calc(100vw - 20px);
    padding: 6px;
    border: 1px solid var(--dp-border);
    border-radius: var(--dp-radius);
    background: var(--dp-surface);
    box-shadow: 0 12px 32px rgb(0 0 0 / .4);
}
.dp-menu[hidden], .dp-menu__item[hidden] { display: none; }
.dp-menu__item {
    min-height: 48px;
    padding: 0 14px;
    border: 0;
    border-radius: var(--dp-radius-sm);
    background: transparent;
    color: var(--dp-text);
    font: inherit;
    font-size: 1rem;
    font-weight: 500;
    text-align: left;
    cursor: pointer;
}
.dp-menu__item:active { background: var(--dp-surface-3); }

.dp-toast { top: calc(var(--dp-safe-top) + 58px); }

/* --- "?" circles: small, quiet, a short explanation on tap ------------------------------ */
.dp-help {
    position: relative;
    display: inline-grid;
    place-items: center;
    width: 22px;
    height: 22px;
    margin-left: 6px;
    padding: 0;
    border: 1px solid var(--dp-border);
    border-radius: 50%;
    background: transparent;
    color: var(--dp-text-muted);
    font: inherit;
    font-size: .75rem;
    font-weight: 700;
    line-height: 1;
    text-transform: none;
    letter-spacing: 0;
    vertical-align: middle;
    cursor: pointer;
}
.dp-help::after { content: ""; position: absolute; inset: -11px; }
.dp-help-dialog__text { margin: 0; font-size: 1.05rem; line-height: 1.5; }

/* --- the own pad: PIN, amounts ---------------------------------------------------------- */
.dp-main--pad { display: flex; flex-direction: column; align-items: center; }
.dp-main--pad .dp-hint { margin: 2px 0 0; text-align: center; }
.dp-main--pad .dp-alert { margin: 0 0 10px; width: 100%; max-width: 320px; }
.dp-pin { margin: 12px 0 14px; min-height: 18px; }
.dp-pinpad { width: 100%; gap: 10px; }
.dp-pinpad__key {
    min-height: clamp(48px, 8.5dvh, 68px);
    touch-action: manipulation;
}
/* A.17: PIN keys act on pointerdown (bindPadKey) - no pan or pinch may claim a quick second tap. Amount keys
   (data-cash, the day close's number pads) stay a click with pan allowed: a swipe to scroll must type nothing. */
.dp-pinpad__key[data-pin],
.dp-pinpad__key[data-pad],
.dp-numpad--pin .dp-pinpad__key {
    touch-action: none;
}
.dp-pinpad__key--ok { background: var(--dp-blue); border-color: var(--dp-blue); color: #fff; }
.dp-pinpad__key:disabled { opacity: .3; cursor: default; }
.dp-pinpad__key--ok:disabled { background: transparent; color: var(--dp-text-muted); border-color: var(--dp-border); }
/* CT.02 (589b40): the empty cell where the confirm key used to sit; and the neutral "being checked" look of the dots. */
.dp-pinpad__gap { min-height: 1px; }
.dp-pin.is-checking .dp-pin__dot { animation: dp-pin-check 0.9s ease-in-out infinite; }
.dp-pin.is-checking .dp-pin__dot:nth-child(2) { animation-delay: .1s; }
.dp-pin.is-checking .dp-pin__dot:nth-child(3) { animation-delay: .2s; }
.dp-pin.is-checking .dp-pin__dot:nth-child(4) { animation-delay: .3s; }
.dp-pin.is-checking .dp-pin__dot:nth-child(5) { animation-delay: .4s; }
.dp-pin.is-checking .dp-pin__dot:nth-child(6) { animation-delay: .5s; }
@keyframes dp-pin-check { 0%, 100% { opacity: 1; } 50% { opacity: .3; } }
@media (prefers-reduced-motion: reduce) { .dp-pin.is-checking .dp-pin__dot { animation: none; opacity: .5; } }
.dp-pin__back { margin-top: 12px; padding: 12px 16px; font-size: .95rem; }

/* --- cart: the whole position is the tap target; the discount is behind it, never a button on it --- */
.dp-cart__title {
    margin: 0;
    padding: 9px 12px 2px;
    color: var(--dp-eyebrow, var(--dp-blue));
    font-size: .72rem;
    font-weight: 700;
    letter-spacing: .1em;
    text-transform: uppercase;
}
.dp-cart__line--position { grid-template-columns: minmax(0, 1fr) auto 44px; gap: 8px; padding: 2px 4px 2px 12px; }
.dp-cart__line--position .dp-cart__name { padding: 10px 0; min-height: 44px; display: flex; flex-direction: column; justify-content: center; cursor: pointer; white-space: normal; }
.dp-cart__line--position .dp-cart__price { white-space: nowrap; text-align: right; cursor: pointer; }
.dp-cart__line--position .dp-cart__remove { width: 40px; height: 40px; justify-self: center; font-size: 1.3rem; }
.dp-cart__line--position .dp-hint { margin: 0; font-size: .75rem; }
.dp-cart__lines { max-height: 26dvh; }

/* --- groups as tabs -------------------------------------------------------------------- */
.dp-tabs-bar { display: flex; gap: 8px; margin: 0 0 12px; overflow-x: auto; scrollbar-width: none; }
.dp-tabs-bar::-webkit-scrollbar { display: none; }
.dp-tabs-bar__tab {
    flex: 0 0 auto;
    min-height: 44px;
    padding: 0 18px;
    border: 1px solid var(--dp-border);
    border-radius: 999px;
    background: transparent;
    color: var(--dp-text-muted);
    font: inherit;
    font-weight: 600;
    cursor: pointer;
}
.dp-tabs-bar__tab.is-active { background: var(--dp-blue); border-color: var(--dp-blue); color: #fff; }

/* GA.4: a tile, a tab and a chip take their group's colour from data-farbe (1..8); 0 or none keeps the default. */
.dp-tile[data-farbe="1"], .dp-tabs-bar__tab[data-farbe="1"], .dp-chip[data-farbe="1"],
.dp-swatch[data-farbe="1"] { --dp-gruppe: var(--dp-gruppe-1); }
.dp-tile[data-farbe="2"], .dp-tabs-bar__tab[data-farbe="2"], .dp-chip[data-farbe="2"],
.dp-swatch[data-farbe="2"] { --dp-gruppe: var(--dp-gruppe-2); }
.dp-tile[data-farbe="3"], .dp-tabs-bar__tab[data-farbe="3"], .dp-chip[data-farbe="3"],
.dp-swatch[data-farbe="3"] { --dp-gruppe: var(--dp-gruppe-3); }
.dp-tile[data-farbe="4"], .dp-tabs-bar__tab[data-farbe="4"], .dp-chip[data-farbe="4"],
.dp-swatch[data-farbe="4"] { --dp-gruppe: var(--dp-gruppe-4); }
.dp-tile[data-farbe="5"], .dp-tabs-bar__tab[data-farbe="5"], .dp-chip[data-farbe="5"],
.dp-swatch[data-farbe="5"] { --dp-gruppe: var(--dp-gruppe-5); }
.dp-tile[data-farbe="6"], .dp-tabs-bar__tab[data-farbe="6"], .dp-chip[data-farbe="6"],
.dp-swatch[data-farbe="6"] { --dp-gruppe: var(--dp-gruppe-6); }
.dp-tile[data-farbe="7"], .dp-tabs-bar__tab[data-farbe="7"], .dp-chip[data-farbe="7"],
.dp-swatch[data-farbe="7"] { --dp-gruppe: var(--dp-gruppe-7); }
.dp-tile[data-farbe="8"], .dp-tabs-bar__tab[data-farbe="8"], .dp-chip[data-farbe="8"],
.dp-swatch[data-farbe="8"] { --dp-gruppe: var(--dp-gruppe-8); }
.dp-tile[data-farbe]:not([data-farbe="0"]) { background: var(--dp-gruppe); }
.dp-tabs-bar__tab[data-farbe]:not([data-farbe="0"]):not(.is-active) { background: var(--dp-gruppe); color: var(--dp-text); }
.dp-tabs-bar__tab[data-farbe]:not([data-farbe="0"]).is-active { box-shadow: inset 0 -4px 0 var(--dp-gruppe); }
.dp-chips { display: flex; gap: 8px; margin: -4px 0 12px; overflow-x: auto; scrollbar-width: none; }
.dp-chips::-webkit-scrollbar { display: none; }
.dp-chip {
    flex: 0 0 auto; min-height: 36px; padding: 6px 14px; border: 1px solid var(--dp-border); border-radius: 999px;
    background: var(--dp-surface-2); color: var(--dp-text); font: inherit; font-size: .9rem; font-weight: 600; cursor: pointer;
}
.dp-chip[data-farbe]:not([data-farbe="0"]) { background: var(--dp-gruppe); }
.dp-chip.is-active { border-color: var(--dp-blue); box-shadow: inset 0 0 0 2px var(--dp-blue); }
.dp-tabs-bar__symbol { margin-right: 6px; }
/* KB.1 (380c26): the group's picture on its tab, in place of the symbol. */
.dp-tabs-bar__bild { width: 22px; height: 22px; margin-right: 6px; border-radius: 4px; object-fit: cover; vertical-align: middle; }
/* GA.4: the colour sample of a group or selection in the administration's catalog view. */
.dp-swatch {
    display: inline-flex; align-items: center; justify-content: center; min-width: 28px; height: 22px; padding: 0 6px;
    border: 1px solid var(--dp-border); border-radius: 6px; background: var(--dp-gruppe, var(--dp-surface-2)); vertical-align: middle;
}
/* --- GE.1: price level above the tabs; a tile that follows the level carries a dot ------------- */
.dp-tabs-bar--ebene { padding-bottom: 10px; border-bottom: 1px solid var(--dp-border); }
.dp-tile__ebene { display: inline-block; width: 8px; height: 8px; margin-right: 6px; border-radius: 50%; background: var(--dp-ok); vertical-align: middle; }

/* --- cash: given amount typed on the pad, notes add up ------------------------------------ */
.dp-cash { display: grid; gap: 10px; }
.dp-cash[hidden] { display: none; }
.dp-cash__sum { display: grid; gap: 6px; padding: 10px 14px; border: 1px solid var(--dp-border); border-radius: var(--dp-radius); background: var(--dp-surface-2); }
.dp-cash__row { display: flex; align-items: center; justify-content: space-between; gap: 10px; }
.dp-cash__label { color: var(--dp-text-muted); font-size: .9rem; }
.dp-cash__value { font-size: 1.7rem; font-weight: 800; font-variant-numeric: tabular-nums; }
.dp-cash__row--change .dp-cash__value { font-size: 1.3rem; color: var(--dp-ok); }
.dp-cash__keys { display: grid; gap: 8px; }
.dp-cash-quick { grid-template-columns: repeat(5, 1fr); gap: 6px; margin-bottom: 0; }
.dp-cash-quick__btn { min-height: 44px; padding: 0 2px; font-size: .95rem; }
.dp-pinpad--amount { max-width: none; gap: 6px; }
.dp-pinpad--amount .dp-pinpad__key { min-height: clamp(42px, 7dvh, 58px); }
.dp-cash__actions { display: grid; grid-template-columns: 1.6fr 1fr; gap: 8px; }
.dp-cash__actions .dp-btn { margin: 0 !important; }
#screenPayment.is-cash > .dp-section-title,
#screenPayment.is-cash #payLines { display: none; }
#screenPayment.is-cash .dp-amount { display: flex; align-items: baseline; justify-content: space-between; padding: 8px 14px; margin-bottom: 10px; }
#screenPayment.is-cash .dp-amount__value { font-size: 1.4rem; margin: 0; }

/* Before sign-in the logo already says "DOYA" - the name beside it said it twice. */
body.dp-terminal:has(#screenKioskPick:not([hidden])) .dp-header__staff,
body.dp-terminal:has(#screenKioskPin:not([hidden])) .dp-header__staff,
body.dp-terminal:has(#screenPairing:not([hidden])) .dp-header__staff { display: none; }

/* --- phones, short screens (sideways) ---------------------------------------------------- */
@media (orientation: landscape) and (max-height: 520px) {
    body.dp-terminal .dp-header { min-height: 44px; padding-top: calc(3px + var(--dp-safe-top)); padding-bottom: 3px; }
    .dp-header__btn { min-height: 36px; }
    body.dp-terminal .dp-main { padding: 8px 12px 8px; }
    .dp-toast { top: calc(var(--dp-safe-top) + 48px); }

    /* PIN screens: hint + dots on the left, pad on the right. */
    .dp-main--pad { display: grid; grid-template-columns: 1fr 1fr; grid-auto-rows: min-content; column-gap: 24px; align-content: center; justify-items: center; max-width: 760px; }
    .dp-main--pad > :not(.dp-pinpad) { grid-column: 1; width: 100%; text-align: center; }
    .dp-main--pad > .dp-pinpad { grid-column: 2; grid-row: 1 / span 6; align-self: center; max-width: 300px; }
    .dp-pinpad__key { min-height: 46px; }
    .dp-pin { margin: 8px 0; }

    /* Payment: BAR / KARTE and the two ways out stay in one view. */
    #screenPayment .dp-pay__btn { min-height: 64px; height: 64px; font-size: 1.3rem; }
    #screenPayment .dp-receipt { margin-bottom: 6px; }
    #screenPayment .dp-receipt__line { padding: 4px 12px; }
    #screenPayment .dp-amount { padding: 6px 14px; margin-bottom: 8px; }
    #screenPayment #payMethodGroup .dp-btn { min-height: 44px; margin-top: 6px !important; }

    /* Cash: sums left, keys right. */
    .dp-cash { grid-template-columns: 1fr 1.2fr; align-items: start; column-gap: 14px; }
    .dp-cash__sum { grid-column: 1; }
    .dp-cash__keys { grid-column: 2; grid-row: 1 / span 2; }
    .dp-cash__actions { grid-column: 1; align-self: end; }
    .dp-pinpad--amount .dp-pinpad__key { min-height: 38px; }
    .dp-cash-quick__btn { min-height: 38px; }
    #screenPayment.is-cash .dp-amount { margin-bottom: 6px; }
}

/* --- sideways on phone and small tablet: services left, cart right ------------------------ */
@media (min-width: 600px) and (max-width: 1099px) and (orientation: landscape) {
    body.dp-terminal .dp-app {
        display: grid;
        grid-template-columns: minmax(0, 1fr) clamp(290px, 40vw, 400px);
        grid-template-rows: auto auto minmax(0, 1fr);
        max-width: none;
        padding-inline: 0;
        column-gap: 0;
    }
    body.dp-terminal .dp-header,
    body.dp-terminal .dp-offline { grid-column: 1 / -1; }
    body.dp-terminal .dp-header { grid-row: 1; }
    body.dp-terminal .dp-offline { grid-row: 2; }
    body.dp-terminal .dp-flow { display: none !important; }

    body.dp-terminal .dp-main,
    body.dp-terminal .dp-main:not(#screenCatalog),
    body:has(#screenCustom:not([hidden])) #screenCustom,
    body:has(#screenPayment:not([hidden])) #screenPayment {
        grid-column: 1 / -1;
        grid-row: 3;
        width: 100%;
        margin: 0;
        max-width: none;
        align-self: stretch;
    }
    body.dp-terminal .dp-main--narrow { margin-inline: auto; max-width: 760px; }
    body.dp-terminal #screenCatalog,
    body:has(#screenCatalog:not([hidden])) #screenCatalog { grid-column: 1; grid-row: 3; }

    body.dp-terminal .dp-footer,
    body:has(#screenCatalog:not([hidden])) .dp-footer {
        position: relative;
        top: auto;
        grid-column: 2;
        grid-row: 3;
        display: flex;
        flex-direction: column;
        min-height: 0;
        overflow: hidden;
        padding: 8px 12px calc(8px + var(--dp-safe-bottom)) 8px;
        background: var(--dp-bg);
        border: 0;
    }
    .dp-footer[hidden] { display: none; }
    .dp-footer .dp-action-intro { display: none; }
    .dp-footer .dp-cart { flex: 1 1 auto; min-height: 0; display: flex; flex-direction: column; margin-bottom: 8px; }
    .dp-footer .dp-cart[hidden] { display: none; }
    .dp-footer .dp-cart__lines,
    body.dp-terminal .dp-cart__lines { flex: 1 1 auto; min-height: 0; max-height: none; }
    .dp-footer .dp-cart__total { flex: 0 0 auto; }
    .dp-footer .dp-btn { flex: 0 0 auto; min-height: 56px; font-size: 1.05rem; }
    .dp-grid { grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); }
    .dp-tile { min-height: 64px; }
}

/* --- keep the tablet's (>= 1100) three columns, but never a dead flow column on a phone ---- */
@media (max-width: 1099px) { body.dp-terminal .dp-flow { display: none !important; } }

/* --- portrait, small phones ------------------------------------------------------------------ */
@media (orientation: portrait) and (max-width: 599px) {
    body.dp-terminal .dp-main { padding: 12px 12px 8px; }
    .dp-tile { min-height: 68px; }
}

/* The lines on the payment screen scroll by themselves: BAR and KARTE are never pushed out of reach. */
#screenPayment #payLines { max-height: 30dvh; overflow-y: auto; -webkit-overflow-scrolling: touch; }
@media (orientation: landscape) and (max-height: 520px) { #screenPayment #payLines { max-height: 22dvh; } }
@media (orientation: portrait) and (max-width: 599px) {
    #screenPayment .dp-pay { gap: 8px; }
    #screenPayment .dp-pay__btn { min-height: clamp(72px, 11dvh, 112px); height: clamp(72px, 11dvh, 112px); }
}

/* Narrow upright phones: two header rows - logo and buttons on top, the employee's name below with the
   full width, so a long name ("Alexandra Müller-Lüdenscheidt") stays readable on a 375 px screen (review A.14). */
@media (max-width: 479px) {
    body.dp-terminal .dp-header {
        display: grid;
        grid-template-columns: auto minmax(0, 1fr) auto;
        align-items: center;
        column-gap: 8px;
        row-gap: 0;
    }
    body.dp-terminal .dp-header__brand { display: contents; }
    body.dp-terminal .dp-header__picture { grid-column: 1; grid-row: 1; }
    body.dp-terminal .dp-header__tools { grid-column: 3; grid-row: 1; }
    body.dp-terminal .dp-header__staff {
        grid-column: 1 / -1;
        grid-row: 2;
        padding: 2px 2px 7px;
        overflow: hidden;
        text-overflow: ellipsis;
        white-space: nowrap;
    }
}

/* A.14.a: the number pad under a field that must not open the system keyboard. */
.dp-numpad { max-width: 320px; margin: 8px auto 12px; }
.dp-numpad[hidden] { display: none; }

/* A.15 (237485), 568x320: a small phone sideways with the outage bar standing is shorter than the till's
   footer - the pay button slid 17 px under the edge. The footer gives up its intro text and some air, the
   cart its height, so "Kunde abschließen" is always inside the window. */
@media (orientation: landscape) and (max-height: 360px) and (max-width: 599px) {
    body.dp-terminal .dp-footer { padding: 6px 12px calc(6px + var(--dp-safe-bottom)); }
    body.dp-terminal .dp-footer .dp-action-intro { display: none; }
    body.dp-terminal .dp-footer .dp-cart { margin-bottom: 6px; }
    body.dp-terminal .dp-footer .dp-cart__lines { max-height: 14dvh; }
    body.dp-terminal .dp-footer .dp-btn { min-height: 48px; }
}

/* G1.1: add-ons - the choice page of an article and the indented line under its main line. */
.dp-zusatz { margin: 0 0 18px; }
.dp-zusatz__titel { font-weight: 600; margin: 0 0 8px; }
.dp-tile--zusatz[aria-pressed="true"],
.dp-tile--gewaehlt { outline: 3px solid var(--dp-blue); outline-offset: -3px; background: var(--dp-surface-3); }
.dp-cart__line--zusatz { grid-template-columns: minmax(0, 1fr) auto; padding-left: 32px; }
.dp-cart__line--zusatz .dp-cart__name { font-size: .92em; }

/* ------------------------------------------------ GR.1 (ec4713): the hospitality form */

.dp-bewirtung { max-width: 460px; text-align: left; }
/* The link in the receipt dialog steps aside while the e-mail search is open: that section needs the dialog's height. */
.dp-beleg-dialog__card:has(#receiptMail:not([hidden])) #receiptQrBewirtung { display: none; }
.dp-bewirtung__text {
    margin: 0 0 16px;
    max-height: 60dvh;
    overflow: auto;
    font-family: ui-monospace, "SFMono-Regular", Menlo, Consolas, monospace;
    font-size: .8rem;
    line-height: 1.25;
    white-space: pre;
}
.dp-bewirtung__aktionen { display: flex; gap: 10px; justify-content: flex-end; }

/* "Drucken": only the form leaves the page - the till, the buttons and the dark backdrop stay off the paper. */
@media print {
    body.dp-bewirtung-druck > *:not(dialog.dp-bewirtung) { display: none !important; }
    body.dp-bewirtung-druck dialog.dp-bewirtung { position: static; max-width: none; border: 0; box-shadow: none; background: #fff; color: #000; }
    body.dp-bewirtung-druck .dp-bewirtung__text { max-height: none; overflow: visible; }
    body.dp-bewirtung-druck .dp-bewirtung__aktionen { display: none; }
}

/* ------------------------------------------------ GQ.3 (f62633): status line and message box */

/* The line shows state and switches nothing: small, calm, always there. Tones: ok, info, warn, fehler. */
.dp-leiste { display: block; }
.dp-statuszeile {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 6px 8px;
    padding: 6px 14px;
    background: var(--dp-surface);
    border-bottom: 1px solid var(--dp-border);
    color: var(--dp-text);
    font-size: .85rem;
}
.dp-statuszeile[hidden] { display: none; }
.dp-statuszeile__platz {
    padding: 3px 10px;
    border: 1px solid var(--dp-border);
    border-radius: 999px;
    font-weight: 600;
    white-space: nowrap;
}
.dp-statuszeile__platz--ok { border-color: var(--dp-ok); color: var(--dp-ok); }
.dp-statuszeile__platz--info { color: var(--dp-text-muted); }
.dp-statuszeile__platz--warn { background: var(--dp-warn); border-color: var(--dp-warn); color: #241a02; }
.dp-statuszeile__platz--fehler { background: var(--dp-danger); border-color: var(--dp-danger); color: #fff; }

/* The box with OK (E.12): a dialog of the page, red for a refusal, yellow for a warning, green for success. */
.dp-meldung { border-top-width: 8px; border-top-style: solid; }
.dp-meldung--fehler { border-top-color: var(--dp-danger); }
.dp-meldung--warn { border-top-color: var(--dp-warn); }
.dp-meldung--ok { border-top-color: var(--dp-ok); }
.dp-meldung__text { margin: 0 0 16px; font-size: 1.1rem; line-height: 1.4; text-align: left; }

/* A short window (a phone sideways) cannot spare a row for calm news: only what needs attention stays, small and tight,
   and a line with nothing to say takes no row at all. The pay buttons stay inside the window (AusfallKlick). */
@media (max-height: 420px) {
    .dp-statuszeile { padding: 1px 8px; gap: 2px 6px; font-size: .7rem; line-height: 1.1; }
    .dp-statuszeile__platz { padding: 0 6px; }
    .dp-statuszeile__platz--ok,
    .dp-statuszeile__platz--info { display: none; }
    .dp-statuszeile:not(:has(.dp-statuszeile__platz--warn, .dp-statuszeile__platz--fehler)) { display: none; }
}

/* GJ.4: the receipt search - the filter fields in a grid that folds to one column on a phone. */
.dp-belegsuche { display: grid; grid-template-columns: repeat(auto-fill, minmax(160px, 1fr)); gap: 0 12px; }
.dp-belegsuche .dp-field select { width: 100%; }
.dp-belegsuche__zeile { width: 100%; text-align: left; background: none; border: 0; color: inherit; font: inherit; cursor: pointer; }

/* GQ.1 (8a565a): the owner's quick keys - a bar above the tiles and the page of special functions. The text stays the
   tile's own (contrast as every tile, in every palette); the colour is a strip at the left edge, set by one of eight
   classes and never by a style from the server. */
.dp-tasten {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(112px, 1fr));
    gap: var(--dp-gap);
    margin-bottom: 14px;
}
.dp-tasten--seite {
    grid-template-columns: repeat(auto-fill, minmax(140px, 1fr));
}
.dp-taste {
    min-height: var(--dp-tap-min);
    padding: 8px 12px;
    background: var(--dp-surface-2);
    border: 1px solid var(--dp-border);
    border-left: 6px solid var(--dp-taste-farbe, var(--dp-border));
    border-radius: var(--dp-radius-sm);
    color: var(--dp-text);
    font: inherit;
    font-size: .92rem;
    font-weight: 600;
    line-height: 1.2;
    text-align: left;
    cursor: pointer;
    touch-action: manipulation;
}
.dp-taste:active { transform: scale(.97); background: var(--dp-surface-3); }
.dp-taste.is-active { background: var(--dp-surface-3); outline: 2px solid var(--dp-blue); outline-offset: -2px; }
.dp-taste--gesperrt,
.dp-taste:disabled { opacity: .55; cursor: not-allowed; transform: none; }
.dp-taste--grau    { --dp-taste-farbe: #7b8794; }
.dp-taste--blau    { --dp-taste-farbe: #1f6fff; }
.dp-taste--gruen   { --dp-taste-farbe: #2fa36b; }
.dp-taste--gelb    { --dp-taste-farbe: #e0b400; }
.dp-taste--orange  { --dp-taste-farbe: #ef7d22; }
.dp-taste--rot     { --dp-taste-farbe: #d64545; }
.dp-taste--lila    { --dp-taste-farbe: #8a4fd8; }
.dp-taste--tuerkis { --dp-taste-farbe: #17a2a8; }

/* ------------------------------------------------ GL.1 (79b8f0): the owner's layout for this device */

/* Set on <html> by geraet-layout.js before the first paint; without an attribute nothing below applies and the
   till looks as it always did. Fixed tile columns beat the breakpoints - the keypad stays three wide. */
html[data-kasse-spalten="2"] .dp-grid:not(.dp-grid--keypad) { grid-template-columns: repeat(2, 1fr); }
html[data-kasse-spalten="3"] .dp-grid:not(.dp-grid--keypad) { grid-template-columns: repeat(3, 1fr); }
html[data-kasse-spalten="4"] .dp-grid:not(.dp-grid--keypad) { grid-template-columns: repeat(4, 1fr); }
html[data-kasse-spalten="5"] .dp-grid:not(.dp-grid--keypad) { grid-template-columns: repeat(5, 1fr); }
html[data-kasse-spalten="6"] .dp-grid:not(.dp-grid--keypad) { grid-template-columns: repeat(6, 1fr); }
html[data-kasse-spalten="7"] .dp-grid:not(.dp-grid--keypad) { grid-template-columns: repeat(7, 1fr); }
html[data-kasse-spalten="8"] .dp-grid:not(.dp-grid--keypad) { grid-template-columns: repeat(8, 1fr); }

/* On a phone held upright more than three columns leave tiles too small to hit: the owner's number is capped there. */
@media (max-width: 599px) {
    html[data-kasse-spalten="4"] .dp-grid:not(.dp-grid--keypad),
    html[data-kasse-spalten="5"] .dp-grid:not(.dp-grid--keypad),
    html[data-kasse-spalten="6"] .dp-grid:not(.dp-grid--keypad),
    html[data-kasse-spalten="7"] .dp-grid:not(.dp-grid--keypad),
    html[data-kasse-spalten="8"] .dp-grid:not(.dp-grid--keypad) { grid-template-columns: repeat(3, 1fr); }
}

/* A large tile: taller and with a bigger name, also where a media rule sets its own minimum. */
html[data-kasse-groesse="gross"] { --dp-tile-h: 120px; }
html[data-kasse-groesse="gross"] .dp-tile:not(.dp-tile--key) { min-height: var(--dp-tile-h); }
html[data-kasse-groesse="gross"] .dp-tile:not(.dp-tile--key) .dp-tile__name { font-size: 1.2rem; }
html[data-kasse-groesse="gross"] .dp-tile:not(.dp-tile--key) .dp-tile__price { font-size: 1.05rem; }

/* Mirrored for a left-handed person: the cart and the payment column change sides; the keypads stay as they are
   inside their block, the block as a whole changes sides. Same breakpoints and the same order as the plain rules. */
@media (min-width: 900px) {
    html[data-kasse-spiegel] body.dp-terminal .dp-app { grid-template-columns: 310px minmax(0, 1fr) 190px; }
    html[data-kasse-spiegel] body:has(#screenCustom:not([hidden])) .dp-app,
    html[data-kasse-spiegel] body:has(#screenPayment:not([hidden])) .dp-app { grid-template-columns: minmax(0, 1fr) 190px; }

    html[data-kasse-spiegel] body:has(#screenCatalog:not([hidden])) .dp-flow { grid-column: 3; border-right: 0; border-left: 1px solid var(--dp-border); }
    html[data-kasse-spiegel] body:has(#screenCustom:not([hidden])) .dp-flow,
    html[data-kasse-spiegel] body:has(#screenPayment:not([hidden])) .dp-flow { grid-column: 2; border-right: 0; border-left: 1px solid var(--dp-border); }

    html[data-kasse-spiegel] body:has(#screenCustom:not([hidden])) #screenCustom,
    html[data-kasse-spiegel] body:has(#screenPayment:not([hidden])) #screenPayment { grid-column: 1; }

    html[data-kasse-spiegel] body:has(#screenCatalog:not([hidden])) .dp-footer { grid-column: 1; border-left: 0; border-right: 1px solid var(--dp-border); }
}

@media (min-width: 600px) and (max-width: 1099px) and (orientation: landscape) {
    html[data-kasse-spiegel] body.dp-terminal .dp-app { grid-template-columns: clamp(290px, 40vw, 400px) minmax(0, 1fr); }
    html[data-kasse-spiegel] body.dp-terminal #screenCatalog,
    html[data-kasse-spiegel] body:has(#screenCatalog:not([hidden])) #screenCatalog { grid-column: 2; }
    html[data-kasse-spiegel] body.dp-terminal .dp-footer,
    html[data-kasse-spiegel] body:has(#screenCatalog:not([hidden])) .dp-footer { grid-column: 1; }
}

/* ------------------------------------------------ GL.4 (73b6fa): the rest screen after the idle lock */

.dp-ruhe {
    position: fixed;
    inset: 0;
    z-index: 100;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 18px;
    background: var(--dp-bg);
    color: var(--dp-text);
    cursor: pointer;
}
.dp-ruhe[hidden] { display: none; }
.dp-ruhe__logo { width: min(60vw, 320px); height: auto; }
.dp-ruhe__logo--dark { display: none; }
:root[data-theme="dark"] .dp-ruhe__logo--light { display: none; }
:root[data-theme="dark"] .dp-ruhe__logo--dark { display: block; }
@media (prefers-color-scheme: dark) {
    :root:not([data-theme]) .dp-ruhe__logo--light { display: none; }
    :root:not([data-theme]) .dp-ruhe__logo--dark { display: block; }
}
.dp-ruhe__uhr { margin: 0; font-size: clamp(3rem, 12vw, 6rem); font-weight: 700; font-variant-numeric: tabular-nums; }
.dp-ruhe__hinweis { margin: 0; color: var(--dp-text-muted); font-size: 1.1rem; }

/* ------------------------------------------------ GQ.4 (4fe200): the quantity before the article and in the line */

.dp-menge { display: flex; align-items: center; gap: 10px; padding: 6px 0 10px; }
.dp-menge__knopf { min-width: 96px; min-height: var(--dp-tap-min); font-weight: 700; }
.dp-menge__chip {
    min-height: 44px;
    padding: 0 16px;
    border: 2px solid var(--dp-blue);
    border-radius: 999px;
    background: transparent;
    color: var(--dp-text);
    font-size: 1.1rem;
    font-weight: 700;
    cursor: pointer;
}
.dp-menge__chip[hidden] { display: none; }

/* The cart line: name | minus, number, plus | sum | remove. Thumb-sized (44 px), the add-ons have none of it. */
.dp-cart__line--position:not(.dp-cart__line--zusatz) { grid-template-columns: minmax(0, 1fr) auto 44px; }
.dp-cart__line--position:not(.dp-cart__line--zusatz) .dp-cart__name { grid-column: 1; grid-row: 1; }
.dp-cart__line--position:not(.dp-cart__line--zusatz) .dp-cart__price { grid-column: 2; grid-row: 1; }
.dp-cart__line--position:not(.dp-cart__line--zusatz) .dp-cart__remove { grid-column: 3; grid-row: 1; }
/* The quantity keys get a row of their own under the name: the narrow cart column cannot hold name, three keys and the sum side by side. */
.dp-cart__line--position:not(.dp-cart__line--zusatz) .dp-cart__menge { grid-column: 1 / -1; grid-row: 2; justify-self: start; }
.dp-cart__menge { display: inline-flex; align-items: center; gap: 4px; }
.dp-cart__mengetaste {
    min-width: 44px;
    min-height: 44px;
    border: 1px solid var(--dp-border);
    border-radius: var(--dp-radius-sm);
    background: transparent;
    color: var(--dp-text);
    font-size: 1.25rem;
    font-weight: 700;
    cursor: pointer;
}
.dp-cart__mengezahl { min-width: 52px; font-size: 1.05rem; }

/* b6f9bc: on a phone held upright the receipt took ~57 % of the window (name and quantity keys one above the other, 88 px a line) and the tiles
   were a sliver. Name, quantity keys, sum and remove stand in ONE row (about 48 px a line); the keys keep a 40 px target. A longer receipt scrolls
   in its box (max-height of .dp-cart__lines). The add-on lines and the wide layouts are untouched. */
@media (max-width: 599px) and (orientation: portrait) {
    .dp-cart__line--position:not(.dp-cart__line--zusatz) { grid-template-columns: minmax(0, 1fr) auto auto 40px; column-gap: 6px; }
    .dp-cart__line--position:not(.dp-cart__line--zusatz) .dp-cart__name { grid-column: 1; grid-row: 1; padding: 4px 0; min-height: 48px; }
    .dp-cart__line--position:not(.dp-cart__line--zusatz) .dp-cart__menge { grid-column: 2; grid-row: 1; justify-self: end; }
    .dp-cart__line--position:not(.dp-cart__line--zusatz) .dp-cart__price { grid-column: 3; grid-row: 1; }
    .dp-cart__line--position:not(.dp-cart__line--zusatz) .dp-cart__remove { grid-column: 4; grid-row: 1; width: 40px; height: 40px; }
    .dp-cart__mengetaste { min-width: 40px; min-height: 40px; }
    .dp-cart__mengezahl { min-width: 36px; }
    /* The two action rows ("Rabatt auf den Beleg", "Kunde zuordnen") are as high as their 44 px button, no more; the box holds a bit more than
       two positions and scrolls beyond that - the tiles keep more than half of the window. */
    .dp-cart__line:not(.dp-cart__line--position):not(.dp-cart__line--zusatz) { padding-block: 0; }
    .dp-cart__lines { max-height: 18dvh; }
}

.dp-menge-dialog { max-width: 360px; }
.dp-menge-dialog__titel { margin: 0 0 8px; font-size: 1.1rem; }
.dp-menge-dialog__anzeige { display: block; margin: 0 0 12px; font-size: 2rem; font-weight: 700; font-variant-numeric: tabular-nums; }
.dp-pinpad--menge { margin-bottom: 12px; }

/* ------------------------------------------------ GA.11 (d924ae): article search at the till */

.dp-suche { display: flex; gap: 8px; align-items: stretch; margin: 0 0 12px; }
.dp-suche[hidden] { display: none; }
.dp-suche__feld, .dp-suche__nummer {
    min-height: 48px;
    padding: 8px 12px;
    border: 1px solid var(--dp-border);
    border-radius: 8px;
    background: var(--dp-surface);
    color: var(--dp-text);
    font: inherit;
}
.dp-suche__feld { flex: 1 1 auto; min-width: 0; }
.dp-suche__nummer { flex: 0 0 96px; width: 96px; font-variant-numeric: tabular-nums; }
.dp-suche__taste { flex: 0 0 auto; width: auto; min-height: 48px; margin: 0; padding-inline: 16px; }
.dp-suche__treffer { display: grid; gap: 6px; margin: 0 0 12px; }
.dp-suche__treffer[hidden] { display: none; }
.dp-suche__treffer-knopf {
    display: grid;
    grid-template-columns: auto minmax(0, 1fr) auto;
    gap: 12px;
    align-items: center;
    min-height: 56px;
    padding: 8px 14px;
    border: 1px solid var(--dp-border);
    border-radius: 8px;
    background: var(--dp-surface);
    color: var(--dp-text);
    font: inherit;
    text-align: left;
    cursor: pointer;
}
.dp-suche__nr { min-width: 3ch; font-weight: 700; font-variant-numeric: tabular-nums; color: var(--dp-eyebrow); }
.dp-suche__name { overflow-wrap: anywhere; }
.dp-suche__preis { font-weight: 700; font-variant-numeric: tabular-nums; }
.dp-suche__nichts { margin: 0; padding: 8px 4px; color: var(--dp-text-muted); }

/* GA.7 (fded2a): the info button of an article with details - its own button in the tile's corner, thumb-sized, so a
   tap on it never books and a tap on the tile never opens it. */
.dp-tile-wrap { position: relative; display: grid; }
.dp-tile-wrap > .dp-tile { width: 100%; height: 100%; padding-right: 52px; }
.dp-tile__info {
    position: absolute;
    top: 4px;
    right: 4px;
    width: 44px;
    height: 44px;
    border: 1px solid var(--dp-border);
    border-radius: 999px;
    background: var(--dp-surface);
    color: var(--dp-text);
    font: italic 700 1rem/1 Georgia, serif;
    cursor: pointer;
}
.dp-tile__info:focus-visible { outline: 3px solid var(--dp-blue); outline-offset: 2px; }
.dp-dialog__zeile { margin: 0 0 8px; text-align: left; }
.dp-dialog__zeile strong { display: block; font-size: 0.85rem; }

/* ------------------------------------------------ GK.4 (f3c8c8): standing label "Bondruck AUS" */

.dp-bondruck-aus {
    position: fixed;
    left: 10px;
    bottom: 10px;
    z-index: 90;
    padding: 6px 12px;
    border-radius: 999px;
    background: var(--dp-warn);
    color: #241a02;
    font-size: .9rem;
    font-weight: 700;
    pointer-events: none;
}
.dp-bondruck-aus[hidden] { display: none; }

/* GU.3: the details of a customer at the register - one input per line, touch-sized. */
.dp-dialog__felder { display: grid; gap: 0.5rem; margin-bottom: 0.75rem; }
.dp-dialog__felder .dp-field { display: grid; gap: 0.25rem; }
.dp-dialog__felder input, .dp-dialog__felder select, .dp-dialog__felder textarea { min-height: 44px; font: inherit; }

/* ------------------------------------------------ GH.1 (321a9b): the area of the device in the head */

.dp-header__bereich {
    padding: 2px 10px;
    border-radius: 999px;
    background: var(--dp-surface-3);
    color: var(--dp-text);
    font-size: .85rem;
    font-weight: 600;
    white-space: nowrap;
}
.dp-header__bereich[hidden] { display: none; }

/* =====================================================================================================================
 * TH.3 (6fb6fc): Theme Hell - the "Galerie" of TH.2 for the till (v1), with the missing-picture row of v2 (verwaltung.css)
 * and the cash quick amounts of v3.
 *
 * Only the light look. Every rule here hangs on :root[data-aussehen="hell"], which kasse-theme.js sets from the chosen
 * theme ("Hell", or "System" while the system is light). The dark look keeps every declaration it had; it only gets the
 * new tile PICTURES (a picture is the same in both) and nothing else.
 *
 * Tokens: ink #0e1a2b, grey #4f5b6b, navy #073763, warm white #faf8f5 (the colour world, above). 12 px corners, a 4/8/12/16/24/32
 * rhythm, Montserrat. No text sits on a picture without the dark gradient under it; measured contrasts are in the PR text.
 * ===================================================================================================================== */

:root[data-aussehen="hell"] {
    --dp-radius: 12px;
    --dp-radius-sm: 8px;
    --dp-gap: 12px;
    --dp-card: #0e1a2b;
    --dp-card-strong: #05090f;
    --th-ink: #0e1a2b;
    --th-line: var(--dp-line);
    --th-lift: 0 1px 2px rgb(14 26 43 / .06), 0 2px 8px rgb(14 26 43 / .04);
}

/* --- the tile picture: the same in light and dark (it is a photo) ---------------------------------------------------- */
.dp-tile__bild {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: inherit;
    pointer-events: none;
}

/* --- header: slim, white, hairline ---------------------------------------------------------------------------------- */
:root[data-aussehen="hell"] body.dp-terminal .dp-header {
    min-height: 56px;
    background: var(--dp-bg);
    border-bottom: 1px solid var(--th-line);
}
:root[data-aussehen="hell"] body.dp-terminal .dp-header__staff { font-size: 1rem; font-weight: 700; color: var(--th-ink); }
:root[data-aussehen="hell"] body.dp-terminal .dp-header__clock { color: var(--dp-text-muted); }
:root[data-aussehen="hell"] .dp-header__btn {
    min-height: 44px;
    border: 1px solid var(--th-line);
    border-radius: var(--dp-radius);
    background: var(--dp-bg);
    color: var(--th-ink);
}
:root[data-aussehen="hell"] .dp-header__btn:active { background: var(--dp-surface-2); }
:root[data-aussehen="hell"] .dp-menu {
    border-color: var(--th-line);
    border-radius: var(--dp-radius);
    box-shadow: 0 12px 32px rgb(14 26 43 / .16);
}
:root[data-aussehen="hell"] .dp-leiste { background: var(--dp-app); }

/* --- layout: no side guide, tiles and the bon ---------------------------------------------------------------------- */
@media (min-width: 900px) {
    :root[data-aussehen="hell"] body.dp-terminal .dp-app { grid-template-columns: 0 minmax(0, 1fr) 340px; }
    :root[data-aussehen="hell"] body:has(#screenCustom:not([hidden])) .dp-app,
    :root[data-aussehen="hell"] body:has(#screenPayment:not([hidden])) .dp-app { grid-template-columns: 0 minmax(0, 1fr); }
    :root[data-aussehen="hell"] body:has(#screenCatalog:not([hidden])) .dp-flow,
    :root[data-aussehen="hell"] body:has(#screenCustom:not([hidden])) .dp-flow,
    :root[data-aussehen="hell"] body:has(#screenPayment:not([hidden])) .dp-flow { display: none; }
    :root[data-aussehen="hell"] body:has(#screenCatalog:not([hidden])) #screenCatalog { padding: 16px 24px 24px; }
    :root[data-aussehen="hell"] body:has(#screenCatalog:not([hidden])) .dp-footer {
        padding: 16px;
        background: var(--dp-bg);
        border-left: 1px solid var(--th-line);
    }
}
:root[data-aussehen="hell"] .dp-main { background: var(--dp-app); }

/* --- group tabs: thin, text only, an underline for the chosen one (the group colour becomes the underline) ------------ */
:root[data-aussehen="hell"] .dp-tabs-bar { gap: 4px; margin: 0 0 16px; border-bottom: 1px solid var(--th-line); }
:root[data-aussehen="hell"] .dp-tabs-bar__tab {
    min-height: 44px;
    padding: 0 12px;
    background: transparent;
    border: 0;
    border-bottom: 3px solid transparent;
    border-radius: 0;
    color: var(--dp-text-muted);
    font-weight: 600;
    white-space: nowrap;
    box-shadow: none;
}
:root[data-aussehen="hell"] .dp-tabs-bar__tab.is-active {
    background: transparent;
    border-color: transparent;
    border-bottom-color: var(--th-ink);
    color: var(--th-ink);
    font-weight: 700;
}
/* The owner's group colour (GA.4) stays the tab's colour: a pale tab; the chosen one is the ink underline like every tab. */
:root[data-aussehen="hell"] .dp-tabs-bar__tab[data-farbe]:not([data-farbe="0"]):not(.is-active) {
    background: var(--dp-gruppe);
    color: var(--dp-text);
    border-radius: var(--dp-radius-sm) var(--dp-radius-sm) 0 0;
}
:root[data-aussehen="hell"] .dp-tabs-bar__tab[data-farbe]:not([data-farbe="0"]).is-active { box-shadow: none; border-bottom-color: var(--th-ink); }
:root[data-aussehen="hell"] .dp-tabs-bar--ebene { border-bottom: 0; padding-bottom: 0; }
:root[data-aussehen="hell"] .dp-chip {
    min-height: 40px;
    border: 1px solid var(--th-line);
    border-radius: 999px;
    background: var(--dp-bg);
    color: var(--dp-text);
}
:root[data-aussehen="hell"] .dp-chip.is-active { background: var(--th-ink); border-color: var(--th-ink); color: #fff; box-shadow: none; }
:root[data-aussehen="hell"] .dp-chip[data-farbe]:not([data-farbe="0"]):not(.is-active) { background: var(--dp-gruppe); border-color: transparent; }
:root[data-aussehen="hell"] .dp-section-title { color: var(--dp-text-muted); letter-spacing: .1em; }

/* --- the tiles: squares, name and price on the picture or on a calm surface ---------------------------------------- */
:root[data-aussehen="hell"] .dp-grid { gap: 12px; }
:root[data-aussehen="hell"] .dp-tile {
    background: var(--dp-bg);
    border: 1px solid var(--th-line);
    border-radius: var(--dp-radius);
    box-shadow: var(--th-lift);
}
:root[data-aussehen="hell"] .dp-tile:active { background: var(--dp-surface-3); }
:root[data-aussehen="hell"] .dp-tile[data-farbe]:not([data-farbe="0"]) { background: var(--dp-gruppe); border-color: transparent; }

:root[data-aussehen="hell"] .dp-tile--artikel {
    position: relative;
    min-height: 96px;
    padding: 12px;
    justify-content: center;
    overflow: hidden;
}
:root[data-aussehen="hell"] .dp-tile--artikel .dp-tile__name {
    position: relative;
    z-index: 1;
    font-size: .95rem;
    font-weight: 700;
    color: var(--th-ink);
}
:root[data-aussehen="hell"] .dp-tile--artikel .dp-tile__price {
    position: relative;
    z-index: 1;
    font-size: .9rem;
    font-weight: 600;
    color: var(--dp-text-muted);
    white-space: nowrap;
}
:root[data-aussehen="hell"] .dp-tile--artikel .dp-tile__ebene { background: var(--dp-ok); }

/* A shop with tile pictures: every article tile is a square; the ones without a picture show their first letter. This and the
   picture tile below are the same in the dark look (a photo is a photo): they apply as soon as the shop has pictures. */
.dp-bilder .dp-tile--artikel,
:root[data-aussehen="hell"] .dp-bilder .dp-tile--artikel {
    position: relative;
    aspect-ratio: 1;
    min-height: 0;
    padding: 12px;
    justify-content: flex-end;
    overflow: hidden;
}
.dp-bilder .dp-tile--artikel .dp-tile__name,
.dp-bilder .dp-tile--artikel .dp-tile__price { position: relative; z-index: 1; }
.dp-bilder .dp-tile--artikel:not(.dp-tile--bild)::before {
    content: attr(data-anfang);
    content: attr(data-anfang) / "";
    position: absolute;
    top: 12px;
    left: 12px;
    right: 12px;
    bottom: 52px;
    display: grid;
    place-items: center;
    color: var(--dp-text-muted);
    font-size: clamp(2rem, 4.5vw, 3.25rem);
    font-weight: 700;
    line-height: 1;
}
.dp-tile--bild,
:root[data-aussehen="hell"] .dp-tile--bild {
    position: relative;
    overflow: hidden;
    border-width: 0;
    background: #1b2430;
}
.dp-tile--bild[data-farbe]:not([data-farbe="0"]),
:root[data-aussehen="hell"] .dp-tile--bild[data-farbe]:not([data-farbe="0"]) { background: #1b2430; }
.dp-tile--bild::after {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(to top, rgb(8 14 24 / .9) 0%, rgb(8 14 24 / .76) 40%, rgb(8 14 24 / .42) 62%, rgb(8 14 24 / 0) 86%);
    pointer-events: none;
}
.dp-tile--bild .dp-tile__name,
.dp-tile--bild .dp-tile__price,
:root[data-aussehen="hell"] .dp-tile--bild .dp-tile__name,
:root[data-aussehen="hell"] .dp-tile--bild .dp-tile__price { position: relative; z-index: 1; color: #fff; text-shadow: 0 1px 2px rgb(0 0 0 / .45); }
.dp-tile--bild .dp-tile__name,
:root[data-aussehen="hell"] .dp-tile--bild .dp-tile__name { font-weight: 700; }
.dp-tile--bild .dp-tile__price,
:root[data-aussehen="hell"] .dp-tile--bild .dp-tile__price { font-weight: 600; }
.dp-tile--bild .dp-tile__ebene,
:root[data-aussehen="hell"] .dp-tile--bild .dp-tile__ebene { background: #7fe0ae; }
:root[data-aussehen="hell"] .dp-tile--gesperrt.dp-tile--artikel { opacity: .55; box-shadow: none; }
:root[data-aussehen="hell"] .dp-tile--ausverkauft .dp-tile__price { color: var(--dp-danger); }
:root[data-aussehen="hell"] .dp-tile-wrap > .dp-tile { padding-right: 12px; }
:root[data-aussehen="hell"] .dp-tile__info {
    top: 8px;
    right: 8px;
    z-index: 2;
    border-color: var(--th-line);
    background: rgb(255 255 255 / .94);
    color: var(--th-ink);
}
@media (max-width: 599px) {
    .dp-bilder .dp-tile--artikel,
    :root[data-aussehen="hell"] .dp-bilder .dp-tile--artikel { aspect-ratio: 4 / 3; }
}

/* --- the bon: calm, white, the amount large, the main action in ink ------------------------------------------------ */
:root[data-aussehen="hell"] .dp-action-intro .dp-section-title { color: var(--dp-text-muted); }
:root[data-aussehen="hell"] .dp-action-intro h2 { color: var(--th-ink); font-size: 1.15rem; }
:root[data-aussehen="hell"] .dp-cart {
    border: 0;
    border-radius: 0;
    background: transparent;
}
:root[data-aussehen="hell"] .dp-cart__title { color: var(--dp-text-muted); }
:root[data-aussehen="hell"] .dp-cart__line { border-bottom: 1px solid var(--th-line); background: transparent; }
:root[data-aussehen="hell"] .dp-cart__name { color: var(--th-ink); font-weight: 600; }
:root[data-aussehen="hell"] .dp-cart__price { color: var(--th-ink); }
:root[data-aussehen="hell"] .dp-cart__remove,
:root[data-aussehen="hell"] .dp-cart__discount { border-color: var(--th-line); }
:root[data-aussehen="hell"] .dp-cart__mengetaste {
    border: 1px solid var(--th-line);
    border-radius: var(--dp-radius-sm);
    background: var(--dp-bg);
    color: var(--th-ink);
}
:root[data-aussehen="hell"] .dp-cart__total {
    padding: 16px 0 12px;
    border-top: 1px solid var(--th-line);
    background: transparent;
    font-size: 1.15rem;
}
:root[data-aussehen="hell"] .dp-cart__total span:last-child { font-size: 1.6rem; font-weight: 800; }
:root[data-aussehen="hell"] #finishBtn:not(:disabled) { background: var(--th-ink); border-color: var(--th-ink); color: #fff; }
:root[data-aussehen="hell"] #finishBtn:not(:disabled):active { background: #05090f; }
:root[data-aussehen="hell"] #finishBtn:disabled { background: var(--dp-surface-2); color: var(--dp-text-muted); border-color: var(--th-line); }

/* --- the main buttons: round corners, ghost = white with a hairline ------------------------------------------------ */
:root[data-aussehen="hell"] .dp-btn { border-radius: var(--dp-radius); }
:root[data-aussehen="hell"] .dp-btn--ghost {
    background: var(--dp-bg);
    border: 1px solid var(--dp-border);
    color: var(--th-ink);
}
:root[data-aussehen="hell"] .dp-btn--ghost:active { background: var(--dp-surface-2); }
:root[data-aussehen="hell"] .dp-tile:focus-visible { box-shadow: 0 0 0 3px var(--dp-focus-gap); }

/* --- paying: the amount large, "Bar" white with a hairline, "Karte" in ink ------------------------------------------ */
:root[data-aussehen="hell"] #screenPayment .dp-section-title { color: var(--dp-text-muted); }
:root[data-aussehen="hell"] .dp-amount {
    border: 0;
    background: transparent;
    text-align: center;
    padding: 16px 0;
}
:root[data-aussehen="hell"] .dp-amount__label { color: var(--dp-text-muted); font-size: .95rem; font-weight: 600; }
:root[data-aussehen="hell"] .dp-amount__value { font-size: clamp(2.5rem, 6vw, 4rem); font-weight: 800; color: var(--th-ink); letter-spacing: -.01em; }
:root[data-aussehen="hell"] .dp-receipt { border-radius: var(--dp-radius); border-color: var(--th-line); background: var(--dp-bg); }
:root[data-aussehen="hell"] .dp-pay__btn { border-radius: var(--dp-radius); }
:root[data-aussehen="hell"] .dp-pay__btn--cash {
    background: var(--dp-bg);
    border: 1px solid var(--dp-border);
    color: var(--th-ink);
}
:root[data-aussehen="hell"] .dp-pay__btn--cash:active { background: var(--dp-surface-2); }
:root[data-aussehen="hell"] .dp-pay__btn--card { background: var(--th-ink); color: #fff; }
:root[data-aussehen="hell"] .dp-pay__btn--card:active { background: #05090f; }

/* --- the cash dialog: amounts that fill "Gegeben" in one tap (v3), then the pad ------------------------------------- */
.dp-cash-quick--schnell { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; }
.dp-cash-quick--schnell:empty { display: none; }
.dp-cash-quick__btn--schnell { min-height: 56px; font-size: 1.1rem; font-weight: 700; }
:root[data-aussehen="hell"] .dp-cash__sum {
    border: 1px solid var(--th-line);
    border-radius: var(--dp-radius);
    background: var(--dp-bg);
}
:root[data-aussehen="hell"] .dp-cash-quick__btn--schnell { border-color: var(--dp-eyebrow); color: var(--dp-eyebrow); }
:root[data-aussehen="hell"] .dp-cash-quick__btn--schnell:first-child { background: var(--dp-eyebrow); color: #fff; }
:root[data-aussehen="hell"] .dp-pinpad__key { border-color: var(--th-line); border-radius: var(--dp-radius); background: var(--dp-bg); }
:root[data-aussehen="hell"] .dp-pinpad__key--muted { background: transparent; }
:root[data-aussehen="hell"] #payCashConfirm:not(:disabled) { background: var(--th-ink); border-color: var(--th-ink); }

/* --- dialogs and fields --------------------------------------------------------------------------------------------- */
:root[data-aussehen="hell"] input,
:root[data-aussehen="hell"] select,
:root[data-aussehen="hell"] textarea { border-radius: var(--dp-radius-sm); }
:root[data-aussehen="hell"] .dp-theme-dialog__card,
:root[data-aussehen="hell"] .dp-disclaimer__card,
:root[data-aussehen="hell"] dialog.dp-disclaimer__card { border-radius: 16px; border-color: var(--th-line); }

/* --- paying: one calm column in the middle of the screen --------------------------------------------------------------- */
@media (min-width: 900px) {
    :root[data-aussehen="hell"] body:has(#screenPayment:not([hidden])) #screenPayment { padding-inline: max(24px, calc((100% - 720px) / 2)); }
}
:root[data-aussehen="hell"] .dp-pay__btn { justify-content: center; align-items: center; text-align: center; letter-spacing: .02em; }
:root[data-aussehen="hell"] .dp-receipt__line { background: transparent; border-color: var(--th-line); }
:root[data-aussehen="hell"] .dp-menge__knopf { min-width: 0; min-height: 44px; padding: 0 20px; }
:root[data-aussehen="hell"] .dp-pay__btn--card { border: 1px solid var(--th-ink); }

/* --- the bon takes the height of the column: lines scroll, the sum and the main action stay in view ------------------ */
@media (min-width: 900px) {
    :root[data-aussehen="hell"] body:has(#screenCatalog:not([hidden])) .dp-footer { display: flex; flex-direction: column; overflow: hidden; }
    :root[data-aussehen="hell"] body:has(#screenCatalog:not([hidden])) .dp-footer:has(#cart:not([hidden])) .dp-action-intro { display: none; }
    :root[data-aussehen="hell"] body:has(#screenCatalog:not([hidden])) .dp-footer .dp-cart {
        display: flex;
        flex: 1 1 auto;
        flex-direction: column;
        min-height: 0;
        margin-bottom: 12px;
        overflow: hidden;
    }
    :root[data-aussehen="hell"] body:has(#screenCatalog:not([hidden])) .dp-footer .dp-cart__lines { flex: 1 1 0; min-height: 0; max-height: none; }
    :root[data-aussehen="hell"] body:has(#screenCatalog:not([hidden])) .dp-footer .dp-btn { flex: 0 0 auto; }
}
:root[data-aussehen="hell"] .dp-menge__knopf { width: auto; }

/* TH.3 (6fb6fc), 568x320: the light theme gives header, sum and amount more air than the dark one - on a small phone
   sideways with the outage bar standing that pushed "Kunde abschließen" and the pay buttons under the edge
   (A.15, 237485). Same look, less air; the buttons keep their 44 px. */
@media (orientation: landscape) and (max-height: 360px) and (max-width: 599px) {
    :root[data-aussehen="hell"] body.dp-terminal .dp-header { min-height: 44px; }
    :root[data-aussehen="hell"] .dp-cart__total { padding: 6px 0; }
    :root[data-aussehen="hell"] .dp-cart__total span:last-child { font-size: 1.3rem; }
    :root[data-aussehen="hell"] .dp-amount { padding: 2px 0; margin-bottom: 6px; }
    :root[data-aussehen="hell"] .dp-amount__value { font-size: 1.75rem; margin-top: 0; }
    :root[data-aussehen="hell"] #screenPayment .dp-pay__btn { min-height: 56px; padding-block: 8px; }
}
