.tw-wallet-buttons{display:flex;flex-wrap:wrap;gap:12px;margin-block:12px}
.tw-wallet-buttons>*{flex:1 1 180px;min-height:48px}
.tw-wallet-buttons>div,.tw-wallet-entry>div{height:48px}
/* Shop navigation to the review, not an SDK payment button. The real
   provider button is used only where the click opens the payment sheet. */
.tw-wallet-choice{display:flex;align-items:center;justify-content:center;gap:6px;width:100%;height:48px;min-height:48px;padding:8px 16px;border:1px solid var(--color-border);border-radius:var(--radius-pill);background:var(--navy-950);color:var(--color-text-inverse);font:500 16px/1.3 var(--font-body);cursor:pointer;white-space:nowrap}
.tw-wallet-choice img{display:block;width:53px;height:22px;object-fit:contain}
.tw-wallet-choice:hover{background:var(--navy-800);transform:translateY(-1px)}
/* W6: Im Dunkelmodus stand der Knopf Navy auf Navy, nur der Rahmen trennte. Googles Vorgabe fuer dunkle
   Flaechen ist der weisse Knopf mit dunkler Schrift und dem Zeichen fuer helle Knoepfe (light_gpay.svg). */
.tw-wallet-choice .twgp-weiss{display:none}
[data-theme="dark"] .tw-wallet-choice{background:var(--wallet-white);color:var(--wallet-ink);border-color:var(--wallet-outline)}
[data-theme="dark"] .tw-wallet-choice:hover{background:var(--wallet-white)}
[data-theme="dark"] .tw-wallet-choice .twgp-schwarz{display:none}
[data-theme="dark"] .tw-wallet-choice .twgp-weiss{display:block}
/* showModal ohne eigene Abdunklung: die Seite dahinter wirkte wie ein Darstellungsfehler. */
.tw-wallet-review::backdrop{background:var(--color-overlay)}
.tw-wallet-choice:focus-visible{outline:2px solid var(--color-link);outline-offset:3px}
.tw-wallet-buttons apple-pay-button,.tw-wallet-entry apple-pay-button{--apple-pay-button-width:100%;--apple-pay-button-height:48px;--apple-pay-button-border-radius:24px;display:block;height:48px}
.tw-wallet-entry{display:grid;gap:8px;width:100%;margin-block:8px}
.tw-wallet-entry[hidden]{display:none}
.tw-wallet-entry>[data-wallet="googlepay"]{order:1}
.tw-wallet-entry>[data-wallet="applepay"]{order:2}
.cfoot>.tw-wallet-entry{margin:0}
/* Bootstrap's col-12 flex-basis:100% means the entire footer HEIGHT in
   this flex column. With another button below it, that button fell outside. */
#tw-cart .cfoot:has([data-tw-wallet-entry])>[id^="paypal-button-"]{flex:0 0 auto;line-height:0}
.wsum:has([data-tw-wallet-entry]) .ppc-ecs-horizontal-container{margin:0!important;padding:0!important}
.wsum:has([data-tw-wallet-entry]) .ppc-standalone-buttons{flex:0 0 100%;max-width:100%;padding:0;line-height:0}
.tw-express-row{display:flex;flex-wrap:wrap;gap:8px;margin:12px 0}
/* NOVA's display:contents parent otherwise measures this flex item's height
   against an indefinite width, reserving extra rows after the buttons fit. */
.kexpress:has(.tw-express-row){width:100%}
.tw-express-row>[id^="paypal-button-"],.tw-express-row>[id^="ppc-paypal-button-custom-"],.tw-express-row [data-wallet-buttons]>*{flex:1 1 188px;min-width:188px}
.tw-express-row>#order_register_or_login:empty{display:none}
.tw-express-row [data-wallet-buttons]{display:contents}
.tw-express-row>[id^="paypal-button-"],.tw-express-row>[id^="ppc-paypal-button-custom-"]{margin:0!important;min-width:0}
.tw-express-row .ppc-ecs-horizontal-container{margin:0!important;padding:0!important}
.tw-express-row .ppc-ecs-horizontal-container>div{padding:0!important;flex-basis:100%;max-width:100%;min-width:0}
.tw-express-row .ppc-standalone-buttons{line-height:0}
.kexpress .tw-express-row .tw-wallet-notice{flex:0 0 100%;margin:4px 0 0;box-sizing:border-box}
.kexpress:has([data-wallet-buttons]>*),.kexpress:has([data-wallet-buttons]>*)+.kexor{display:block}
.kexpress:has([data-wallet-buttons]>*)+.kexor{display:flex}
/* W3: ein Ausschluss-Satz (Wunschtag, Guthaben, Gutschein) steht auch ohne Knoepfe sichtbar -
   B-3 nimmt dann den PayPal-Knopf weg, und kasse.css blendete den Kasten samt Satz aus. */
.kexpress:has([data-wallet-error]:not([hidden])){display:block}
.kexpress:has([data-wallet-error]:not([hidden]))+.kexor{display:flex}
/* W3: Konto-Zeile (tw_onepage.tpl) steht direkt in .k1form, dessen Spaltenabstand (28/20 px) sonst
   zu den kexor-Raendern dazukaeme - bei Gaesten liegt beides in #customer ohne Abstand. Oben ist der
   Spaltenabstand immer 8 px groesser als der kexor-Rand der Gaeste (28/20 gegen 20/12, gemessen mit
   kasse-zahlknopf-check.mjs), deshalb -8 px statt 0. */
.k1form>.kexpress+.kexor{margin-top:-8px;margin-bottom:0}
/* Keep navigation and PayPal readable side by side on mobile.
   Below 370px stack; never crop the acceptance mark or provider control. */
@media(min-width:370px) and (max-width:575px){
 .tw-express-row:has(.paypal-buttons)>[id^="paypal-button-"]{flex:1 1 0;min-width:150px}
 .tw-express-row:has(.paypal-buttons) [data-wallet-buttons]>*{flex:1 1 0;min-width:188px}
 .tw-express-row:has([data-wallet-buttons]>:nth-child(2)) [data-wallet-buttons]>:last-child{flex-basis:100%}
}
.kexpress>[data-tw-wallet-express]>.tw-wallet-buttons{margin-inline:16px}
.kexpress .tw-wallet-notice{display:flex;align-items:flex-start;gap:12px;margin:12px 16px 16px;padding:12px 16px;border:1px solid var(--color-border);border-radius:var(--radius-sm);background:var(--color-surface-2);color:var(--color-text);font:400 var(--text-small)/1.5 var(--font-body);text-align:left;overflow-wrap:anywhere}
.kexpress .tw-wallet-notice[hidden]{display:none}
.tw-wallet-notice>svg{flex:0 0 18px;width:18px;height:18px;margin-top:1px;color:var(--color-error)}
.tw-wallet-notice-content{min-width:0}
.tw-wallet-error-actions{display:flex;flex-wrap:wrap;gap:8px;margin-top:12px}
.tw-wallet-error-actions[hidden]{display:none}
.kexpress .tw-wallet-error-actions button{min-height:48px;padding:10px 16px;border:1px solid var(--color-border);border-radius:var(--radius-pill);background:var(--color-surface);color:var(--color-text);font:600 var(--text-small)/1.3 var(--font-body);cursor:pointer}
.kexpress .tw-wallet-error-actions button:hover{background:var(--color-cta);color:var(--color-cta-ink)}
.tw-wallet-error-actions button:focus-visible,.tw-wallet-notice:focus-visible{outline:2px solid var(--color-link);outline-offset:3px}
.k1 .tw-wallet-review{color:var(--color-text);width:min(480px,calc(100vw - 24px));max-height:calc(100dvh - 24px);padding:20px;overflow:auto;text-align:left;box-sizing:border-box}
.tw-wallet-review-head{display:flex;align-items:center;justify-content:space-between;gap:8px;margin-bottom:12px}
.k1 .tw-wallet-review h2{font:700 20px/1.25 var(--font-body);margin:0}
.tw-wallet-review .tw-wallet-close{display:grid;place-items:center;flex:0 0 44px;width:44px;height:44px;padding:0;border:0;border-radius:var(--radius-pill);background:transparent;color:var(--color-text);cursor:pointer}
.tw-wallet-review .tw-wallet-close:hover{background:var(--color-surface-2)}
.tw-wallet-close svg{width:20px;height:20px}
.k1 .tw-wallet-review p{font:400 14px/1.4 var(--font-body);margin:0}
.tw-wallet-order{border:1px solid var(--color-border);border-radius:var(--radius-sm);background:var(--color-surface-2)}
.tw-wallet-order summary{display:flex;align-items:center;justify-content:space-between;gap:8px;min-height:44px;padding:10px 12px;box-sizing:border-box;list-style:none;cursor:pointer;color:var(--color-link);font:600 14px/1.4 var(--font-body)}
.tw-wallet-order summary::-webkit-details-marker{display:none}
.tw-wallet-order summary:focus-visible{outline:2px solid var(--color-link);outline-offset:2px;border-radius:var(--radius-sm)}
.tw-wallet-order summary svg{width:16px;height:16px;flex-shrink:0}
.tw-wallet-order[open] summary svg{transform:rotate(180deg)}
.tw-wallet-order [data-wallet-items]{padding:0 12px 12px}
.tw-wallet-review [data-wallet-items]>div{display:grid;gap:10px}
.tw-wallet-review .ksitem{gap:10px;align-items:center}
.tw-wallet-review .ksimg{width:40px;height:40px;border-radius:var(--radius-sm)}
.tw-wallet-review .ksitem b,.tw-wallet-review .ksitem em{font-size:14px;line-height:1.3}
.tw-wallet-review .ksitem>span:not(.ksimg):not(.kspr){min-width:0;flex:1;overflow-wrap:anywhere}
.tw-wallet-review .kspr{white-space:nowrap;font-size:14px;flex-shrink:0}
.tw-wallet-totals{display:grid;gap:8px;border-top:1px solid var(--color-border);margin-top:12px;padding-top:12px}
.tw-wallet-totals .csr{align-items:baseline;gap:8px}
.tw-wallet-totals .csr[hidden]{display:none}
.tw-wallet-totals .csr>b,.tw-wallet-totals .csr>strong:last-child{white-space:nowrap}
.k1 .tw-wallet-review .tw-wallet-total{font-size:16px;color:var(--color-text)}
.tw-wallet-total small{font:400 12px/1.4 var(--font-body);color:var(--color-text-muted)}
.tw-wallet-review .checkout-confirmation-legal-notice{margin-top:12px}
.k1 .tw-wallet-review .checkout-confirmation-legal-notice p{font-size:13px;line-height:1.4}
.tw-wallet-review .checkout-confirmation-legal-notice p+p{margin-top:4px}
.k1 .tw-wallet-review .tw-wallet-commit-note{margin-top:12px;font-size:13px}
.tw-wallet-review [data-wallet-final]{margin:10px 0 0}
.tw-wallet-working{min-height:250px}
.k1 .tw-wallet-review:focus-visible{outline:2px solid var(--color-link);outline-offset:2px}
.tw-wallet-working [data-wallet-content]{opacity:.12;user-select:none}
.tw-wallet-review .tw-wallet-close:disabled{opacity:.25;cursor:wait}
.k1 .tw-wallet-review [data-wallet-status]{position:absolute;inset:64px 16px 16px;display:flex;flex-direction:column;align-items:center;justify-content:center;gap:12px;padding:16px;border-radius:var(--radius-sm);background:var(--color-surface);color:var(--color-text);text-align:center;font:600 15px/1.4 var(--font-body);cursor:wait}
.k1 .tw-wallet-review [data-wallet-status][hidden]{display:none}
.k1 .tw-wallet-review [data-wallet-status] p{font-size:13px;color:var(--color-text-muted)}
.tw-wallet-spinner{width:28px;height:28px;border:3px solid var(--color-border);border-top-color:var(--color-link);border-radius:50%;animation:tw-wallet-spin .8s linear infinite}
@keyframes tw-wallet-spin{to{transform:rotate(360deg)}}
@media(prefers-reduced-motion:reduce){.tw-wallet-spinner{animation:none}}
.tw-wallet-review .tw-wallet-buttons apple-pay-button{--apple-pay-button-width:100%;--apple-pay-button-height:48px}
.tw-wallet-review button:focus-visible{box-shadow:var(--focus-ring)}
.tw-wallet-recovery{max-width:560px;margin:10vh auto;padding:24px;color:var(--color-text)}
.tw-wallet-recovery h1{font-size:24px;line-height:1.25}
@media(max-width:575px){.k1 .tw-wallet-review{padding:16px}}
/* W2/F1: Aktionen der Abschluss-Seiten (KasseAbschluss) - nebeneinander, auf 390 px umbrechend. */
.tw-wallet-recovery-actions{display:flex;flex-wrap:wrap;gap:12px;margin-top:24px}
