/* Core2Flow / Walter Roeder: one canvas, one visual hierarchy.
   Presentation only. See maintenance/design-audit-20261005/STYLEGUIDE.md.
   Scoped to application documents; never applied to mail HTML or PDFs. */
html.c2f-workflow[data-c2f-styleguide="v1"] {
  --c2f-accent:#397b2b; --c2f-accent-hover:#2d6322; --c2f-accent-soft:#eef6eb;
  --c2f-canvas:#fff; --c2f-surface:#f7f9f7; --c2f-ink:#18241d;
  --c2f-text:#344139; --c2f-muted:#56645c; --c2f-line:#dce4de;
  --c2f-positive:#246838; --c2f-warning:#805400; --c2f-danger:#a52b25;
  --c2f-warning-soft:#fff7e6; --c2f-danger-soft:#fff1ef;
  --c2f-space-1:4px; --c2f-space-2:8px; --c2f-space-3:12px;
  --c2f-space-4:16px; --c2f-space-5:24px; --c2f-space-6:32px;
  --c2f-radius-control:8px; --c2f-radius-surface:12px; --c2f-radius-overlay:16px;
  --c2f-control-height:44px; --c2f-overlay-shadow:0 16px 48px rgb(24 36 29 / 18%);
  --c2f-chrome-height:64px; --c2f-dock-height:64px;
  --c2f-font:system-ui,-apple-system,"Segoe UI",sans-serif;
  /* Alias existing module tokens instead of duplicating their theme. */
  --wr-green:var(--c2f-accent); --wr-green-deep:var(--c2f-accent-hover); --wr-green-soft:var(--c2f-accent-soft);
  --wr-canvas:var(--c2f-canvas); --wr-surface:var(--c2f-canvas); --wr-ink:var(--c2f-ink);
  --wr-text:var(--c2f-text); --wr-muted:var(--c2f-muted); --wr-line:var(--c2f-line); --wr-shadow-card:none;
  --wr-radius-sm:var(--c2f-radius-control); --wr-radius-md:var(--c2f-radius-surface);
  --c2f-primary:var(--c2f-accent); --c2f-primary-700:var(--c2f-accent-hover); --c2f-primary-100:var(--c2f-accent-soft);
  --c2f-bg:var(--c2f-canvas); --c2f-bg-soft:var(--c2f-surface); --c2f-card:var(--c2f-canvas); --c2f-border:var(--c2f-line);
  --c2f-shadow-xs:none; --c2f-shadow-sm:none; --c2f-shadow-md:var(--c2f-overlay-shadow);
  --g:var(--c2f-accent); --gd:var(--c2f-accent-hover); --bg:var(--c2f-canvas); --bd:var(--c2f-line);
  --tx:var(--c2f-text); --mu:var(--c2f-muted); --ink:var(--c2f-ink); --muted:var(--c2f-muted); --line:var(--c2f-line);
  --brand:var(--c2f-accent); --brand2:var(--c2f-accent-hover); --soft:var(--c2f-accent-soft);
  --green:var(--c2f-accent); --green-dark:var(--c2f-accent-hover);
  --red:var(--c2f-danger); --warn:var(--c2f-warning); --sf-brand:var(--c2f-accent); --sf-border:var(--c2f-line);
  color:var(--c2f-text); background:var(--c2f-canvas); font-family:var(--c2f-font);
  -webkit-text-size-adjust:100%; text-size-adjust:100%;
}
html.c2f-workflow[data-c2f-styleguide="v1"] body {
  color:var(--c2f-text)!important; background:var(--c2f-canvas)!important;
  font-family:var(--c2f-font)!important; font-size:14px; line-height:1.5;
}
/* A module is a page, never a decorated window around its content. */
html.c2f-workflow[data-c2f-styleguide="v1"] body>:is(main,.app,.page,.shell,.wrap,.container,.workspace,.content,.fa-outer),
html.c2f-workflow[data-c2f-styleguide="v1"] :is(.framebox,.embed-frame,.feedback-report-frame) {
  border:0!important; border-radius:0!important; box-shadow:none!important;
  background:var(--c2f-canvas)!important; min-width:0;
}
html.c2f-workflow[data-c2f-styleguide="v1"] body>.app-preview {width:100%!important;max-width:none!important;height:100dvh!important;margin:0!important;padding:0!important;border:0!important;border-radius:0!important;box-shadow:none!important}
html.c2f-workflow[data-c2f-styleguide="v1"] body.c2f-app-entry {padding:0!important;margin:0!important;display:block!important;height:100dvh!important;overflow:hidden!important}
html.c2f-workflow[data-c2f-styleguide="v1"] .app-preview iframe {border-radius:0!important}
html.c2f-workflow[data-c2f-styleguide="v1"] :is(.card,.panel,.section,.tile,.widget,.intel-card,.focusbar,.approval-box,.mb-panel):not(dialog):not([role=dialog]):not(.modal) {
  border:0!important; border-radius:0!important;
  box-shadow:none!important; background:transparent!important;
}
html.c2f-workflow[data-c2f-styleguide="v1"] :is(.metric,.kpi,.stat) {border:0!important;border-radius:var(--c2f-radius-control)!important;box-shadow:none!important;background:var(--c2f-surface)}
html.c2f-workflow[data-c2f-styleguide="v1"] .ceo-alert {border:0!important;border-bottom:1px solid var(--c2f-line)!important;border-radius:0!important;box-shadow:none!important}
html.c2f-workflow[data-c2f-styleguide="v1"] .ceo-fazit {border:0!important;border-radius:var(--c2f-radius-surface)!important;box-shadow:none!important}
html.c2f-workflow[data-c2f-styleguide="v1"] .card.form {padding:0!important}
/* Inner groups use spacing and separators, not another container. Exclude
   dialogs and document paper: those have their own deliberate surface. */
html.c2f-workflow[data-c2f-styleguide="v1"] :is(.card,.panel,.section,.tile,.widget,.intel-card,.approval-box) :is(.card,.panel,.section,.tile,.widget,.approval-box):not(dialog):not([role=dialog]):not(.modal) {
  border:0!important; border-radius:0!important; background:transparent!important;
  box-shadow:none!important;
}
html.c2f-workflow[data-c2f-styleguide="v1"] :is(.empty,.empty-state,.no-data) {
  border:0!important; border-radius:0!important; background:transparent!important;
  color:var(--c2f-muted)!important; box-shadow:none!important;
}
html.c2f-workflow[data-c2f-styleguide="v1"] :is(h1,h2,h3) {
  color:var(--c2f-ink)!important; font-family:var(--c2f-font)!important;
  font-weight:700; line-height:1.25; letter-spacing:-.025em!important;
}
html.c2f-workflow[data-c2f-styleguide="v1"] h1 {font-size:clamp(23px,2.4vw,28px)!important}
html.c2f-workflow[data-c2f-styleguide="v1"] h2 {font-size:18px!important}
html.c2f-workflow[data-c2f-styleguide="v1"] h3 {font-size:15px!important}
html.c2f-workflow[data-c2f-styleguide="v1"] :is(p,.muted,.hint,.help,.sub) {color:var(--c2f-muted)}
html.c2f-workflow[data-c2f-styleguide="v1"] :is(input,select,textarea,button,.btn) {
  font-family:var(--c2f-font)!important; border-radius:var(--c2f-radius-control)!important;
  box-shadow:none!important;
}
html.c2f-workflow[data-c2f-styleguide="v1"] :is(input,select,textarea):not([type=checkbox]):not([type=radio]):not([type=hidden]) {
  color:var(--c2f-ink)!important; background:var(--c2f-canvas)!important;
  border-color:var(--c2f-line)!important; font-size:16px!important;
  min-height:var(--c2f-control-height)!important;
}
html.c2f-workflow[data-c2f-styleguide="v1"] :is(button,.btn,[role=button]) {
  min-height:var(--c2f-control-height); font-size:14px; font-weight:650;
  touch-action:manipulation;
}
html.c2f-workflow[data-c2f-styleguide="v1"] :is(button,.btn,.card,.tile):hover {transform:none!important;box-shadow:none!important}
html.c2f-workflow[data-c2f-styleguide="v1"] :is(.primary,.btn-primary,.button-primary,.act,.submit,[data-primary=true]):not(:disabled) {
  color:var(--c2f-canvas)!important; background:var(--c2f-accent)!important;
  border-color:var(--c2f-accent)!important; box-shadow:none!important;
}
html.c2f-workflow[data-c2f-styleguide="v1"] :is(button,input,select,textarea,a,[tabindex]):focus-visible {
  outline:2px solid var(--c2f-accent)!important; outline-offset:3px;
}
html.c2f-workflow[data-c2f-styleguide="v1"] button:disabled {opacity:.6;cursor:not-allowed}
html.c2f-workflow[data-c2f-styleguide="v1"] :is(.metric,.kpi) small {font-size:12px!important;text-transform:none!important;letter-spacing:0!important;color:var(--c2f-muted)!important}
html.c2f-workflow[data-c2f-styleguide="v1"] :is(.metric,.kpi) :is(b,strong) {font-variant-numeric:tabular-nums;overflow-wrap:anywhere}
html.c2f-workflow[data-c2f-styleguide="v1"] table {font-size:13px}
html.c2f-workflow[data-c2f-styleguide="v1"] th {text-transform:none!important;font-size:12px!important}
html.c2f-workflow[data-c2f-styleguide="v1"] :is(.table-wrap,.tablewrap,.table-scroll,.loaded-data-table-wrap) {border-radius:0!important;box-shadow:none!important;scrollbar-width:thin!important}
/* Only actual overlays are elevated. Backdrops remain full-viewport; the
   content receives one surface, including on mobile and in embedded pages. */
html.c2f-workflow[data-c2f-styleguide="v1"] dialog {border:1px solid var(--c2f-line)!important;border-radius:var(--c2f-radius-overlay)!important;box-shadow:var(--c2f-overlay-shadow)!important}
html.c2f-workflow[data-c2f-styleguide="v1"] div.modal {border:0!important;border-radius:0!important;box-shadow:none!important;width:auto!important;max-width:none!important;max-height:none!important;margin:0!important}
html.c2f-workflow[data-c2f-styleguide="v1"] :is(.modal,.overlay) :is(.dialog,.modal-content,.modal-card) {border-radius:var(--c2f-radius-overlay)!important;box-shadow:var(--c2f-overlay-shadow)!important;max-height:calc(100dvh - 32px);overflow-y:auto;overscroll-behavior:contain}
html.c2f-workflow[data-c2f-styleguide="v1"] :is(.modal,.dialog) .card {border:0!important;box-shadow:none!important}
html.c2f-workflow[data-c2f-styleguide="v1"] [hidden] {display:none!important}
html.c2f-workflow[data-c2f-styleguide="v1"] [data-c2f-duplicate-title] {position:absolute!important;width:1px!important;height:1px!important;padding:0!important;margin:-1px!important;overflow:hidden!important;clip-path:inset(50%)!important;white-space:nowrap!important;border:0!important}
/* Area selection is a flat application toolbar, not a window titlebar. */
html.c2f-workflow[data-c2f-styleguide="v1"] .c2f-mobile-tab-nav {background:var(--c2f-canvas)!important}
html.c2f-workflow[data-c2f-styleguide="v1"] .c2f-mobile-tab-trigger {border:0!important;border-radius:0!important;border-bottom:1px solid var(--c2f-line)!important;background:var(--c2f-canvas)!important;color:var(--c2f-ink)!important;min-height:52px!important;padding:10px 16px!important;box-shadow:none!important;font-size:15px!important;font-weight:700!important}
html.c2f-workflow[data-c2f-styleguide="v1"] .c2f-mobile-tab-sheet {border-radius:var(--c2f-radius-overlay)!important;box-shadow:var(--c2f-overlay-shadow)!important}
html.c2f-workflow[data-c2f-styleguide="v1"] .switcher {border:0!important;border-radius:0!important;box-shadow:none!important;border-bottom:1px solid var(--c2f-line)!important;padding:0 12px 8px!important;background:var(--c2f-canvas)!important}
html.c2f-workflow[data-c2f-styleguide="v1"] .switcher button {border:0!important;border-radius:var(--c2f-radius-control)!important;background:transparent!important;color:var(--c2f-muted)!important}
html.c2f-workflow[data-c2f-styleguide="v1"] .switcher button.active {background:var(--c2f-accent-soft)!important;color:var(--c2f-accent-hover)!important}
html.c2f-workflow[data-c2f-styleguide="v1"][data-c2f-nested-workflow=true] body>.navbar {display:none!important}
html.c2f-workflow[data-c2f-styleguide="v1"][data-c2f-shell-navigation=true] body>.navbar {display:none!important}
html.c2f-workflow[data-c2f-styleguide="v1"][data-c2f-nested-workflow=true] body>.content:has(>iframe) {height:100dvh!important;margin:0!important;padding:0!important}
html.c2f-workflow[data-c2f-styleguide="v1"][data-c2f-shell-navigation=true] .workspace:has(iframe) {height:100dvh!important}
html.c2f-workflow[data-c2f-styleguide="v1"][data-c2f-app-page=einkaufvertrieb-freigaben] .workspace {padding:0!important;gap:0!important}
/* The native chrome joins the canvas edge-to-edge. No floating frame, photo
   header, glass, or nested button containers. */
html.c2f-workflow[data-c2f-styleguide="v1"] body.c2f-native-workspace .wr-native-chrome {margin:0!important;padding:8px 16px!important;border:0!important;border-radius:0!important;background:var(--c2f-canvas)!important;box-shadow:none!important;min-height:64px!important;border-bottom:1px solid var(--c2f-line)!important}
html.c2f-workflow[data-c2f-styleguide="v1"] body.c2f-native-workspace .wr-native-brand {background:transparent!important;border-radius:0!important;padding:0!important;gap:12px!important}
html.c2f-workflow[data-c2f-styleguide="v1"] body.c2f-native-workspace .wr-native-live {background:transparent!important;box-shadow:none!important;color:var(--c2f-positive)!important;font-size:12px!important;padding:0!important}
html.c2f-workflow[data-c2f-styleguide="v1"] body.c2f-native-workspace .wr-native-live:before {box-shadow:none!important}
html.c2f-workflow[data-c2f-styleguide="v1"] body.c2f-native-workspace .wr-native-brand small {font-size:12px!important}
html.c2f-workflow[data-c2f-styleguide="v1"] body.c2f-native-workspace .app {padding-top:0!important;padding-bottom:calc(64px + env(safe-area-inset-bottom))!important}
html.c2f-workflow[data-c2f-styleguide="v1"] body.c2f-native-workspace .mobile-dock {left:0!important;right:0!important;bottom:0!important;gap:0!important;padding:4px 8px calc(4px + env(safe-area-inset-bottom))!important;border:0!important;border-top:1px solid var(--c2f-line)!important;border-radius:0!important;background:var(--c2f-canvas)!important;box-shadow:none!important;backdrop-filter:none!important}
html.c2f-workflow[data-c2f-styleguide="v1"] body.c2f-native-workspace .mobile-dock button {border:0!important;border-radius:0!important;background:transparent!important;color:var(--c2f-muted)!important;box-shadow:none!important;min-height:52px!important}
html.c2f-workflow[data-c2f-styleguide="v1"] body.c2f-native-workspace .mobile-dock button.active {color:var(--c2f-accent-hover)!important;background:transparent!important}
html.c2f-workflow[data-c2f-styleguide="v1"] body.c2f-native-workspace .process-inner-head {padding:0!important;border:0!important;border-radius:0!important;box-shadow:none!important;background:var(--c2f-canvas)!important}
html.c2f-workflow[data-c2f-styleguide="v1"] body.c2f-native-workspace .page-scale-wrap {height:calc(100dvh - var(--c2f-chrome-height))!important}
@media(max-width:700px) {
  html.c2f-workflow[data-c2f-styleguide="v1"][data-c2f-app-page=kunden-omnichannel] .rows {max-height:none!important;overflow:visible!important}
  html.c2f-workflow[data-c2f-styleguide="v1"][data-c2f-app-page=einkaufvertrieb-crm] :is(.bars,.follow-list,.drop-list) {max-height:none!important;overflow:visible!important}
}
@media(max-height:500px) {
  html.c2f-workflow[data-c2f-styleguide="v1"] {--c2f-chrome-height:48px;--c2f-dock-height:56px}
  html.c2f-workflow[data-c2f-styleguide="v1"] body.c2f-native-workspace .wr-native-chrome {min-height:48px!important}
  html.c2f-workflow[data-c2f-styleguide="v1"] body.c2f-native-workspace .mobile-dock button {min-height:44px!important}
  html.c2f-workflow[data-c2f-styleguide="v1"] body.c2f-native-workspace .app {padding-bottom:calc(56px + env(safe-area-inset-bottom))!important}
}
@media(prefers-reduced-motion:reduce) {html.c2f-workflow[data-c2f-styleguide="v1"] * {scroll-behavior:auto!important;transition:none!important;animation:none!important}}

/* Legacy working groups share the canvas rather than creating subwindows. */
html.c2f-workflow[data-c2f-styleguide="v1"] :is(.weighbox,.manual,.ai,.summary,.order-form,.offer-form,.loaded-data-panel,.assistant-shell,.fa-filter-bar,.dispo-filter-bar,.toolbar) {border:0!important;border-radius:0!important;box-shadow:none!important;background:transparent!important}

/* Older/generated modules use prefixed component names. Apply the same
   surface contract without changing selected/status backgrounds. */
html.c2f-workflow[data-c2f-styleguide="v1"] :is([class$="-card"],[class*="-card "],[class$="-panel"],[class*="-panel "],[class$="-toolbar"]):not(:is(.col-filter-panel,.abn-select-panel,.aus-cf-panel,.cp-confirm-panel,.feedback-filter-panel,.modal-card,.document-viewer-card,.fahrer-lightbox-card,.image-modal-card,.celebration-card,.c2f-loader-card)):not(:where(.modal,.overlay,[role=dialog]) *) {border:0!important;border-radius:0!important;box-shadow:none!important}
html.c2f-workflow[data-c2f-styleguide="v1"] :is(.fcto,.fcto-card,.fcto-toolbar,.fcto-kpi) {background:transparent!important;border:0!important;border-radius:0!important;box-shadow:none!important}
html.c2f-workflow[data-c2f-styleguide="v1"] iframe {border:0!important;border-radius:0!important;box-shadow:none!important;min-width:0}

html.c2f-workflow[data-c2f-styleguide="v1"][data-c2f-shell-navigation=true] .switch-title {display:none!important}
html.c2f-workflow[data-c2f-styleguide="v1"][data-c2f-nested-workflow=true] {--navbar-h:0px}
html.c2f-workflow[data-c2f-styleguide="v1"][data-c2f-nested-workflow=true] main.page-main {padding-top:16px!important}
html.c2f-workflow[data-c2f-styleguide="v1"] .fcto {padding:16px!important}

/* Stateful Trading metrics previously outranked the shared surface rule. */
html.c2f-workflow[data-c2f-styleguide="v1"][data-c2f-app-shell][data-c2f-app-page][data-c2f-trade-view] .metric {box-shadow:none!important}
html.c2f-workflow[data-c2f-styleguide="v1"][data-c2f-app-shell][data-c2f-app-page][data-c2f-trade-view] .metric:is([data-metric-filter="unfixed"],[data-metric-filter="deliverable"]) {background:var(--c2f-accent)!important;color:white!important}

/* App surfaces follow the visible viewport, including keyboard and safe areas. */
html.c2f-workflow[data-c2f-styleguide="v1"] body.c2f-native-workspace .wr-native-chrome {padding-top:calc(8px + env(safe-area-inset-top))!important;padding-left:max(16px,env(safe-area-inset-left))!important;padding-right:max(16px,env(safe-area-inset-right))!important;min-height:calc(var(--c2f-chrome-height) + env(safe-area-inset-top))!important}
html.c2f-workflow[data-c2f-styleguide="v1"] body.c2f-native-workspace .page-scale-wrap {height:calc(var(--c2f-visual-height,100dvh) - var(--c2f-chrome-height) - env(safe-area-inset-top))!important}
html.c2f-workflow[data-c2f-styleguide="v1"] body.c2f-native-workspace .mobile-dock {padding-left:max(8px,env(safe-area-inset-left))!important;padding-right:max(8px,env(safe-area-inset-right))!important}
html.c2f-workflow.c2f-keyboard-open[data-c2f-styleguide="v1"] body.c2f-native-workspace .mobile-dock {display:none!important}
html.c2f-workflow.c2f-keyboard-open[data-c2f-styleguide="v1"] body.c2f-native-workspace .app {padding-bottom:0!important}
html.c2f-workflow[data-c2f-login=true] body>:not(#loginOverlay):not(script) {display:none!important}
html.c2f-workflow[data-c2f-login=true] body.c2f-native-login {position:static!important;min-height:var(--c2f-visual-height,100dvh);overflow-y:auto!important;background:var(--c2f-canvas)!important}
html.c2f-workflow[data-c2f-login=true] body.c2f-native-login .modal-overlay {position:absolute!important;inset:0!important;min-height:var(--c2f-visual-height,100dvh)!important;overflow-y:auto!important;display:flex!important;align-items:center!important;justify-content:center!important;background:var(--c2f-canvas)!important;padding:calc(24px + env(safe-area-inset-top)) max(24px,env(safe-area-inset-right)) calc(24px + env(safe-area-inset-bottom)) max(24px,env(safe-area-inset-left))!important}
html.c2f-workflow[data-c2f-login=true] body.c2f-native-login .modal-overlay::before {display:none!important}
html.c2f-workflow[data-c2f-login=true] body.c2f-native-login #loginOverlay .modal {width:min(420px,100%)!important;max-width:100%!important;min-height:0!important;margin:0!important;padding:0!important;border:0!important;border-radius:0!important;box-shadow:none!important;background:transparent!important;overflow:visible!important}
html.c2f-workflow[data-c2f-login=true] body.c2f-native-login #loginOverlay input {border-radius:var(--c2f-radius-control)!important}
html.c2f-workflow[data-c2f-login=true] body.c2f-native-login #loginOverlay .btn-primary {background:var(--c2f-accent)!important;box-shadow:none!important;border-radius:var(--c2f-radius-control)!important}
html.c2f-workflow[data-c2f-login=true] body.c2f-native-login #loginForm .input-wrap {border:0!important;box-shadow:none!important;background:transparent!important}
html.c2f-keyboard-open[data-c2f-login=true] body.c2f-native-login .modal-overlay {align-items:flex-start!important}

/* Legacy CRM and invoice surfaces follow the shared page and dialog rules. */
html.c2f-workflow[data-c2f-styleguide="v1"] :is(.c2f-intake,.c2f-intake-card,.c2f-intake-head,.twin,.drop) {border:0!important;border-radius:0!important;box-shadow:none!important;background:transparent!important}
html.c2f-workflow[data-c2f-styleguide="v1"] :is(.twin-status,.twin-kpi,.twin-card) {color:var(--c2f-ink)!important;background:var(--c2f-surface)!important;border-color:var(--c2f-line)!important;box-shadow:none!important}
html.c2f-workflow[data-c2f-styleguide="v1"] :is(.twin-status,.twin-kpi,.twin-card,.twin-head) :is(small,p) {color:var(--c2f-muted)!important}
html.c2f-workflow[data-c2f-styleguide="v1"] div.modal:has(>.dialog) {padding:16px!important;min-width:0!important;background:rgb(24 36 29 / 28%)!important}
html.c2f-workflow[data-c2f-styleguide="v1"] div.modal>.dialog {box-sizing:border-box!important;width:100%!important;min-width:0!important;max-width:min(720px,calc(100vw - 32px))!important;margin:0!important;max-height:calc(var(--c2f-visual-height,100dvh) - 32px)!important;overflow-x:hidden!important}
html.c2f-workflow[data-c2f-styleguide="v1"] :is(.dialog,.c2f-dialog) :is(input,select,textarea,.field,.pos) {min-width:0!important;max-width:100%!important}
html.c2f-workflow[data-c2f-styleguide="v1"] :is(.dialog .foot,.c2f-dialog footer) {flex-wrap:wrap!important}
@media(max-width:700px){
 html.c2f-workflow[data-c2f-styleguide="v1"] :is(.hero .actions,.c2f-intake-actions) {flex-wrap:wrap!important;width:100%!important;margin:0!important}
 html.c2f-workflow[data-c2f-styleguide="v1"] .hero .actions button {flex:1 1 auto;white-space:normal!important}
 html.c2f-workflow[data-c2f-styleguide="v1"] .c2f-intake-grid {grid-template-columns:minmax(0,1fr)!important}
 html.c2f-workflow[data-c2f-styleguide="v1"] .twin-kpis {grid-template-columns:minmax(0,1fr)!important}
 html.c2f-workflow[data-c2f-styleguide="v1"] .c2f-dialog {width:100%!important;max-width:100%!important}
 html.c2f-workflow[data-c2f-styleguide="v1"] .c2f-form {grid-template-columns:minmax(0,1fr)!important}
}

/* On phones an edit task fills its workspace; actions stay reachable. */
@media(max-width:700px){
 html.c2f-workflow[data-c2f-styleguide="v1"] :is(div.modal:has(>.dialog),.c2f-modal:has(>.c2f-dialog)) {padding:0!important;align-items:stretch!important;background:var(--c2f-canvas)!important;overflow:hidden!important}
 html.c2f-workflow[data-c2f-styleguide="v1"] :is(div.modal>.dialog,.c2f-modal>.c2f-dialog) {width:100%!important;max-width:100%!important;height:100%!important;max-height:100%!important;margin:0!important;border:0!important;border-radius:0!important;box-shadow:none!important;overflow-y:auto!important;background:var(--c2f-canvas)!important;padding:16px!important}
 html.c2f-workflow[data-c2f-styleguide="v1"] :is(.dialog .foot,.c2f-dialog footer) {position:sticky!important;bottom:-16px!important;z-index:2;background:var(--c2f-canvas)!important;border-top:1px solid var(--c2f-line)!important;padding:12px 0 calc(12px + env(safe-area-inset-bottom))!important}
}

/* All entry points share the same working surface and touch contract. */
html.c2f-workflow[data-c2f-styleguide="v1"] :is(.layout,.grid,.workspace,.split,.master-detail,.pm-shell,.pm-query,.pm-field,.pm-grid,.side,.form,.pane,.toolbar,.filters,.table-wrap,.tablewrap,.table-scroll) {min-width:0!important}
html.c2f-workflow[data-c2f-styleguide="v1"] .c2f-table-region {max-width:100%!important;min-width:0!important;overflow-x:auto;overscroll-behavior-x:contain}
html.c2f-workflow[data-c2f-styleguide="v1"] #c2f-workspace-return {display:flex;align-items:center;justify-content:space-between;gap:12px;min-height:52px;padding:env(safe-area-inset-top) max(16px,env(safe-area-inset-right)) 0 max(16px,env(safe-area-inset-left));border-bottom:1px solid var(--c2f-line);background:var(--c2f-canvas);color:var(--c2f-muted);font:600 12px var(--c2f-font)}
html.c2f-workflow[data-c2f-styleguide="v1"] #c2f-workspace-return a {display:inline-flex;align-items:center;min-height:48px;color:var(--c2f-accent-hover);font-size:14px;text-decoration:none}
@media(max-width:700px){
 html.c2f-workflow[data-c2f-styleguide="v1"] :is(button,.btn,[role=button],summary) {min-height:44px!important;touch-action:manipulation}
 html.c2f-workflow[data-c2f-styleguide="v1"] :is(input,select,textarea):not([type=checkbox]):not([type=radio]):not([type=hidden]) {min-width:0!important;max-width:100%!important}
 html.c2f-workflow[data-c2f-styleguide="v1"] :is(.toolbar,.actions,.head,.top,.pm-head,.view-tabs) {max-width:100%!important;min-width:0!important;flex-wrap:wrap!important}
 html.c2f-workflow[data-c2f-styleguide="v1"] :is(.layout,.workspace,.pm-grid,.pm-query,.source-grid) {grid-template-columns:minmax(0,1fr)!important}
 html.c2f-workflow[data-c2f-styleguide="v1"] :is(.toolbar,.actions,.head,.top)>* {min-width:0!important;max-width:100%!important}
 html.c2f-workflow[data-c2f-styleguide="v1"] :is(.form,.side,.pm-card) {min-width:0!important}
 html.c2f-workflow[data-c2f-styleguide="v1"] .pm-query input {width:100%!important}
 html.c2f-workflow[data-c2f-styleguide="v1"] .c2f-app-card-table {min-width:0!important;max-width:100%!important;width:100%!important}
 html.c2f-workflow[data-c2f-styleguide="v1"] :is(.view-tabs,.doc-tabs,.type-tabs,.tabs) {scrollbar-width:thin}
 html.c2f-workflow[data-c2f-styleguide="v1"][data-c2f-app-page=mobile-start] body {background:var(--c2f-canvas)!important}
 html.c2f-workflow[data-c2f-styleguide="v1"][data-c2f-app-page=mobile-start] main>section {padding:0!important;border:0!important;border-radius:0!important;background:transparent!important;box-shadow:none!important}
}

@media(pointer:coarse) and (max-width:1366px){html.c2f-workflow[data-c2f-styleguide="v1"] :is(button,.btn,[role=button],summary){min-height:44px!important;touch-action:manipulation}}

html.c2f-workflow[data-c2f-app-shell=standalone]:has(#c2f-workspace-return) {--c2f-workspace-height:calc(var(--c2f-visual-height,100dvh) - 52px - env(safe-area-inset-top))}
html.c2f-workflow[data-c2f-app-shell=standalone] #c2f-workspace-return {height:calc(52px + env(safe-area-inset-top));box-sizing:border-box}
html.c2f-workflow[data-c2f-app-shell=standalone] body>:is(main,.page,.shell,.pm-shell,.wrap,.container) {padding-left:max(16px,env(safe-area-inset-left))!important;padding-right:max(16px,env(safe-area-inset-right))!important}
@media(max-width:700px){
 html.c2f-workflow[data-c2f-styleguide="v1"][data-c2f-app-page=kunden-auftragserfassung] #orderForm>.actions {position:sticky;bottom:0;z-index:20;background:var(--c2f-canvas);border-top:1px solid var(--c2f-line);padding:12px 0 calc(12px + env(safe-area-inset-bottom));flex-wrap:wrap}
 html.c2f-workflow[data-c2f-styleguide="v1"][data-c2f-app-page=kunden-auftragserfassung] #orderForm>.actions .primary {width:100%}
}

@media(max-width:700px),(pointer:coarse){html.c2f-workflow[data-c2f-styleguide="v1"] form label:has(>input:is([type=checkbox],[type=radio])){min-height:44px;cursor:pointer}}

@media(max-width:700px),(pointer:coarse){html.c2f-workflow[data-c2f-styleguide="v1"] .leaflet-control-zoom a{min-width:44px!important;min-height:44px!important;line-height:44px!important}html.c2f-workflow[data-c2f-styleguide="v1"] .leaflet-popup-close-button{min-width:44px!important;min-height:44px!important;display:flex!important;align-items:center;justify-content:center}}

html.c2f-workflow[data-c2f-styleguide="v1"] .c2f-filter-picker {margin:8px 0;border:0;border-bottom:1px solid var(--c2f-line);border-radius:0;background:transparent}
html.c2f-workflow[data-c2f-styleguide="v1"] .c2f-filter-picker>summary {display:flex;align-items:center;justify-content:space-between;min-height:48px;padding:8px 4px;color:var(--c2f-ink);font-weight:650;cursor:pointer;list-style:none}
html.c2f-workflow[data-c2f-styleguide="v1"] .c2f-filter-picker>summary::after {content:'⌄';font-size:20px;margin-left:12px}
html.c2f-workflow[data-c2f-styleguide="v1"] .c2f-filter-picker>summary::-webkit-details-marker {display:none}
@media(min-width:981px){html.c2f-workflow[data-c2f-styleguide="v1"] .c2f-filter-picker>summary{display:none}}
@media(max-width:700px),(pointer:coarse){html.c2f-workflow[data-c2f-styleguide="v1"] label:has(>input:is([type=checkbox],[type=radio])){min-height:44px;cursor:pointer}}

/* Tablet rows must shrink without enlarging invisible radio hit boxes. */
html.c2f-workflow[data-c2f-styleguide="v1"][data-c2f-app-page=kunden-auftragserfassung] .type {position:relative}
html.c2f-workflow[data-c2f-styleguide="v1"][data-c2f-app-page=kunden-auftragserfassung] .type>input {width:1px!important;height:1px!important;min-width:0!important;min-height:0!important;padding:0!important;margin:0!important;inset:0!important}
html.c2f-workflow[data-c2f-styleguide="v1"][data-c2f-app-page=kunden-auftragserfassung] .type>input:focus-visible+span {outline:2px solid var(--c2f-accent);outline-offset:3px}
@media(max-width:1100px){
 html.c2f-workflow[data-c2f-styleguide="v1"] :is(button,.btn,[role=button],summary){min-height:44px!important;touch-action:manipulation}
 html.c2f-workflow[data-c2f-styleguide="v1"] label:has(>input:is([type=checkbox],[type=radio])){min-height:44px}
 html.c2f-workflow[data-c2f-styleguide="v1"][data-c2f-app-page=einkaufvertrieb-ausschreibungen] .page-grid{grid-template-columns:minmax(0,1fr)!important}
 html.c2f-workflow[data-c2f-styleguide="v1"][data-c2f-app-page=einkaufvertrieb-ausschreibungen] .page-grid>*{min-width:0!important}
}

@media(max-width:1100px){html.c2f-workflow[data-c2f-styleguide="v1"] :is(input,select,textarea):not([type=checkbox]):not([type=radio]):not([type=hidden]){font-size:16px!important;min-height:44px!important;min-width:0!important;max-width:100%!important}}

/* A dialog role on a backdrop must never turn the backdrop into a card. */
html.c2f-workflow[data-c2f-styleguide="v1"] div.c2f-modal {width:auto!important;max-width:none!important;height:auto!important;max-height:none!important;margin:0!important;border:0!important;border-radius:0!important;box-shadow:none!important;transform:none!important}
@media(max-width:700px){
 html.c2f-workflow[data-c2f-styleguide="v1"] div.c2f-modal {inset:0!important;overflow:hidden!important;padding:0!important}
 html.c2f-workflow[data-c2f-styleguide="v1"] dialog[open]:has(form){position:fixed!important;inset:0!important;margin:0!important;transform:none!important;width:100%!important;max-width:100%!important;height:var(--c2f-visual-height,100dvh)!important;max-height:var(--c2f-visual-height,100dvh)!important;border:0!important;border-radius:0!important;box-shadow:none!important;background:var(--c2f-canvas)!important;overflow-y:auto!important;padding:16px!important}
 html.c2f-workflow[data-c2f-styleguide="v1"] dialog:has(form)::backdrop{background:var(--c2f-canvas)}
}
