/* Only original mobile work-item forms. Fields, permissions and actions stay unchanged. */
body.mobile-ui-active.mobile-task-workflow .mobile-task-workflow-view .task-detail-section {border-radius:12px;padding:14px;}
body.mobile-ui-active.mobile-task-workflow .mobile-task-workflow-view .task-detail-compose {padding:0;border-radius:0;}
body.mobile-ui-active.mobile-task-workflow .mobile-task-workflow-view .task-detail-header>h2 {font-size:18px;line-height:1.45;}
body.mobile-ui-active.mobile-task-workflow .mobile-task-workflow-view .task-detail-submit-actions>button {border-radius:10px;font-size:14px;}
body.mobile-ui-active.mobile-task-workflow .mobile-task-workflow-view .task-detail-acceptance .task-accept-action {background:#1d5ed0;color:#fff;border-radius:10px;}
body.mobile-ui-active.mobile-task-workflow .mobile-task-short-viewport .task-detail-header>h2 {font-size:15px;line-height:1.4;}

/* A work-queue approval occupies one screen; the original detail/action form scrolls inside it. */
body.mobile-ui-active:has(.mobile-workspace:is([data-mobile-hub-area="home"],[data-mobile-hub-area="overview"])) .cw-modal {padding:0!important;align-items:stretch;height:var(--mobile-visible-height,100dvh);color:#192c48;}
body.mobile-ui-active:has(.mobile-workspace:is([data-mobile-hub-area="home"],[data-mobile-hub-area="overview"])) .cw-modal .cw-shell {width:100%;height:100%;max-height:100%;border-radius:0;box-shadow:none;}
body.mobile-ui-active:has(.mobile-workspace:is([data-mobile-hub-area="home"],[data-mobile-hub-area="overview"])) .cw-modal .cw-header {flex:none;min-height:58px;box-sizing:border-box;padding:7px 16px;gap:12px;background:#fff;border-bottom:1px solid #dce4ef;}
body.mobile-ui-active:has(.mobile-workspace:is([data-mobile-hub-area="home"],[data-mobile-hub-area="overview"])) .cw-modal .cw-header h2 {font-size:18px;line-height:1.45;margin:0;overflow-wrap:anywhere;}
body.mobile-ui-active:has(.mobile-workspace:is([data-mobile-hub-area="home"],[data-mobile-hub-area="overview"])) .cw-modal .cw-kicker {display:none;}
body.mobile-ui-active:has(.mobile-workspace:is([data-mobile-hub-area="home"],[data-mobile-hub-area="overview"])) .cw-modal button {min-height:44px;box-sizing:border-box;padding:9px 12px;font-size:14px;line-height:1.4;border-radius:10px;}
body.mobile-ui-active:has(.mobile-workspace:is([data-mobile-hub-area="home"],[data-mobile-hub-area="overview"])) .cw-modal .cw-header button {flex:none;min-width:44px;background:#edf3ff;color:#1d5ed0;border:0;}
body.mobile-ui-active:has(.mobile-workspace:is([data-mobile-hub-area="home"],[data-mobile-hub-area="overview"])) .cw-modal .cw-body {flex:1;min-height:0;padding:16px;overflow:auto;overscroll-behavior:contain;}
body.mobile-ui-active:has(.mobile-workspace:is([data-mobile-hub-area="home"],[data-mobile-hub-area="overview"])) .cw-modal .cw-actions {display:flex;flex-wrap:wrap;gap:8px;overflow:visible;margin:0 0 16px;}
body.mobile-ui-active:has(.mobile-workspace:is([data-mobile-hub-area="home"],[data-mobile-hub-area="overview"])) .cw-modal .cw-actions [data-cw-action="approve"] {background:#1d5ed0;color:#fff;border-color:#1d5ed0;}
body.mobile-ui-active:has(.mobile-workspace:is([data-mobile-hub-area="home"],[data-mobile-hub-area="overview"])) .cw-modal .cw-detail {gap:16px 12px;margin:16px 0;font-size:14px;}
body.mobile-ui-active:has(.mobile-workspace:is([data-mobile-hub-area="home"],[data-mobile-hub-area="overview"])) .cw-modal .cw-detail dd {line-height:1.6;}
body.mobile-ui-active:has(.mobile-workspace:is([data-mobile-hub-area="home"],[data-mobile-hub-area="overview"])) .cw-modal .cw-body h3 {font-size:16px;line-height:1.5;margin:0 0 16px;overflow-wrap:anywhere;}
body.mobile-ui-active:has(.mobile-workspace:is([data-mobile-hub-area="home"],[data-mobile-hub-area="overview"])) .cw-modal .cw-message:not(:empty) {flex:none;max-height:74px;overflow:auto;padding:8px 16px;font-size:13px;line-height:1.5;}
body.mobile-ui-active:has(.mobile-workspace:is([data-mobile-hub-area="home"],[data-mobile-hub-area="overview"])) .cw-modal .cw-body:has(>form[data-mode="action"]) {display:flex;flex-direction:column;overflow:hidden;}
body.mobile-ui-active:has(.mobile-workspace:is([data-mobile-hub-area="home"],[data-mobile-hub-area="overview"])) .cw-modal .cw-body>form[data-mode="action"] {display:flex;flex-direction:column;flex:1;min-height:0;}
body.mobile-ui-active:has(.mobile-workspace:is([data-mobile-hub-area="home"],[data-mobile-hub-area="overview"])) .cw-modal form[data-mode="action"]>.cw-form {flex:1;min-height:0;overflow:auto;overscroll-behavior:contain;display:block;}
body.mobile-ui-active:has(.mobile-workspace:is([data-mobile-hub-area="home"],[data-mobile-hub-area="overview"])) .cw-modal form[data-mode="action"] .cw-field {margin:0 0 12px;font-size:14px;}
body.mobile-ui-active:has(.mobile-workspace:is([data-mobile-hub-area="home"],[data-mobile-hub-area="overview"])) .cw-modal form[data-mode="action"] :is(input:not([type="checkbox"]):not([type="radio"]):not([type="hidden"]),select,textarea) {min-height:44px;font-size:16px;box-sizing:border-box;}
body.mobile-ui-active:has(.mobile-workspace:is([data-mobile-hub-area="home"],[data-mobile-hub-area="overview"])) .cw-modal form[data-mode="action"] textarea {min-height:112px;line-height:1.6;}
body.mobile-ui-active:has(.mobile-workspace:is([data-mobile-hub-area="home"],[data-mobile-hub-area="overview"])) .cw-modal form[data-mode="action"]>.cw-footer {position:static;flex:none;display:flex;flex-wrap:nowrap;gap:8px;order:10;margin:12px -16px -16px;padding:12px 16px calc(12px + env(safe-area-inset-bottom));background:#fff;}
body.mobile-ui-active:has(.mobile-workspace:is([data-mobile-hub-area="home"],[data-mobile-hub-area="overview"])) .cw-modal form[data-mode="action"]>.cw-footer button {flex:1;min-width:0;margin:0;min-height:48px;}
body.mobile-ui-active:has(.mobile-workspace:is([data-mobile-hub-area="home"],[data-mobile-hub-area="overview"])) .cw-modal form[data-mode="action"]>.cw-footer button[type="submit"] {background:#1d5ed0;border-color:#1d5ed0;color:#fff;}

/* Technical plans use the same white title bar and blue actions in portrait and landscape. */
body.mobile-ui-active .mw-workspace:has(.ma-app) {position:fixed;inset:0;z-index:130;box-sizing:border-box;overflow:auto;overscroll-behavior:contain;min-height:0;height:var(--mobile-visible-height,100dvh);padding:0!important;background:#f4f6f9!important;color:#192c48;font-family:inherit;font-size:14px;}
body.mobile-ui-active .mw-workspace:has(.ma-app) .ma-header {position:sticky;top:0;z-index:21;display:flex;align-items:center;gap:10px;min-height:58px;box-sizing:border-box;margin:0;padding:7px 16px;background:#fff;border-bottom:1px solid #dce4ef;color:#192c48;}
body.mobile-ui-active .mw-workspace:has(.ma-app) .ma-header h2 {flex:1;min-width:0;margin:0!important;text-align:left;color:#192c48!important;font-size:18px!important;line-height:1.45;font-weight:700;}
body.mobile-ui-active .mw-workspace:has(.ma-app) .ma-header button {flex:none;min-width:44px;min-height:44px;width:44px;height:44px;padding:0;margin:0;border:0!important;border-radius:10px;background:#edf3ff!important;color:#1d5ed0!important;font-size:24px!important;box-shadow:none;}
body.mobile-ui-active .mw-workspace:has(.ma-app) .ma-app {box-sizing:border-box;min-height:0;padding:14px 16px calc(88px + env(safe-area-inset-bottom));background:#f4f6f9;}
body.mobile-ui-active .mw-workspace:has(.ma-app) :is(.ma-project-info,.ma-signin,.ma-month-section) {box-sizing:border-box;margin:0 0 12px;padding:14px;background:#fff;border:1px solid #dce4ef;border-radius:12px;}
body.mobile-ui-active .mw-workspace:has(.ma-app) .ma-app h3 {margin:0 0 12px!important;font-size:15px!important;line-height:1.5;color:#192c48!important;}
body.mobile-ui-active .mw-workspace:has(.ma-app) .ma-project-info h3 {padding-bottom:10px;border-bottom:1px solid #dce4ef;}
body.mobile-ui-active .mw-workspace:has(.ma-app) .ma-project-info dl {display:grid;grid-template-columns:68px minmax(0,1fr);gap:10px;margin:0;font-size:13px;line-height:1.6;}
body.mobile-ui-active .mw-workspace:has(.ma-app) .ma-project-info dt {color:#66758b;}
body.mobile-ui-active .mw-workspace:has(.ma-app) .ma-project-info dd {margin:0;overflow-wrap:anywhere;}
body.mobile-ui-active .mw-workspace:has(.ma-app) .ma-signin p {margin:6px 0;color:#66758b;font-size:13px;line-height:1.6;}
body.mobile-ui-active .mw-workspace:has(.ma-app) .ma-signin-identity {display:flex;align-items:center;gap:8px;margin-bottom:10px;}
body.mobile-ui-active .mw-workspace:has(.ma-app) :is(.ma-signin-identity span,.ma-signin small) {font-size:12px;color:#66758b;}
body.mobile-ui-active .mw-workspace:has(.ma-app) :is(.ma-sign-button,.ma-enter,.ma-portrait-capture) {box-sizing:border-box;min-height:44px;padding:10px 14px;border:0;border-radius:10px;background:#1d5ed0;color:#fff;font-size:14px;}
body.mobile-ui-active .mw-workspace:has(.ma-app) .ma-enter {display:block;width:100%;margin-top:12px;}
body.mobile-ui-active .mw-workspace:has(.ma-app) .ma-year {display:flex;align-items:center;justify-content:space-between;gap:8px;margin-bottom:10px;}
body.mobile-ui-active .mw-workspace:has(.ma-app) .ma-year strong {font-size:14px;}
body.mobile-ui-active .mw-workspace:has(.ma-app) .ma-year button {min-width:44px;min-height:44px;margin:0;padding:0;background:#edf3ff;border:0;border-radius:10px;color:#1d5ed0;font-size:22px;}
body.mobile-ui-active .mw-workspace:has(.ma-app) .ma-month-grid {display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:8px;}
body.mobile-ui-active .mw-workspace:has(.ma-app) .ma-month-grid button {display:block;margin:0;min-height:64px;padding:8px 4px;border:1px solid #dce4ef;border-radius:8px;background:#fff;color:#1d5ed0;box-shadow:none;}
body.mobile-ui-active .mw-workspace:has(.ma-app) .ma-month-grid button strong {display:block;font-size:15px;line-height:1.5;}
body.mobile-ui-active .mw-workspace:has(.ma-app) .ma-month-grid button small {display:block;margin-top:4px;font-size:11px;color:#66758b;}
body.mobile-ui-active .mw-workspace:has(.ma-app) .ma-month-grid button.is-current {border-color:#1d5ed0;background:#edf3ff;}
body.mobile-ui-active .mw-workspace:has(.ma-app) .ma-month-grid button:disabled {color:#8b96a7;background:#f8f9fb;border-color:#e8ecf2;}
body.mobile-ui-active .mw-workspace:has(.ma-app) .ma-bottom {position:fixed;inset:auto 0 0;z-index:135;display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:8px;box-sizing:border-box;padding:12px 16px calc(12px + env(safe-area-inset-bottom));background:#fff;border-top:1px solid #dce4ef;box-shadow:none;}
body.mobile-ui-active .mw-workspace:has(.ma-app) .ma-bottom.single {grid-template-columns:minmax(0,1fr);}
body.mobile-ui-active .mw-workspace:has(.ma-app) .ma-bottom button {box-sizing:border-box;min-width:0;min-height:48px;height:auto;margin:0;padding:10px 5px;border:0;border-radius:10px;background:#edf3ff;color:#1d5ed0;font-size:14px;line-height:1.4;font-weight:600;}
body.mobile-ui-active .mw-workspace:has(.ma-app) .ma-bottom.single button,
body.mobile-ui-active .mw-workspace:has(.ma-app) .ma-bottom [data-mw="assoc-save"] {background:#1d5ed0;color:#fff;}
body.mobile-ui-active .mw-workspace:has(.ma-app) .ma-bottom button:disabled {opacity:.5;}
body.mobile-ui-active .mw-workspace:has(.ma-app) .ma-message {margin:0;padding:10px 16px;font-size:13px;line-height:1.5;background:#edf8f3;color:#236548;}
body.mobile-ui-active .mw-workspace:has(.ma-app) .ma-message.is-error {background:#fff0ee;color:#b32128;}
body.mobile-ui-active .mw-workspace:has(.ma-app) .ma-message[hidden] {display:none;}
body.mobile-ui-active .mw-workspace:has(.ma-app) .ma-month-strip {padding:10px 12px;border-radius:8px 8px 0 0;background:#e9eff8;color:#385577;font-size:14px;text-align:center;}
body.mobile-ui-active .mw-workspace:has(.ma-app) .ma-sheet-heading {display:flex;justify-content:space-between;gap:10px;padding:12px;background:#fff;border-bottom:1px solid #dce4ef;}
body.mobile-ui-active .mw-workspace:has(.ma-app) .ma-sheet-heading strong {font-size:14px;white-space:nowrap;}
body.mobile-ui-active .mw-workspace:has(.ma-app) .ma-sheet-heading span {font-size:12px;color:#66758b;overflow-wrap:anywhere;}
body.mobile-ui-active .mw-workspace:has(.ma-app) .ma-pages {position:sticky;top:58px;z-index:19;display:flex;gap:6px;padding:8px 0;background:#f4f6f9;border-bottom:1px solid #dce4ef;}
body.mobile-ui-active .mw-workspace:has(.ma-app) .ma-pages button {flex:1;min-width:0;min-height:44px;padding:6px;margin:0;border:0;border-radius:8px;background:#fff;color:#66758b;font-size:14px;}
body.mobile-ui-active .mw-workspace:has(.ma-app) .ma-pages button.active {background:#1d5ed0;color:#fff;}
body.mobile-ui-active .mw-workspace:has(.ma-app) .ma-three-states button {min-height:44px;}
body.mobile-ui-active .mw-workspace:has(.ma-app) input.ma-row-note {min-height:44px!important;height:44px!important;font-size:14px!important;}
body.mobile-ui-active .mw-workspace:has(.ma-app) :is(.ma-signin textarea,.ma-end-section textarea,.ma-end-section select) {font-size:16px!important;min-height:44px;border-radius:8px!important;}
@media(min-width:769px) {
 body.mobile-ui-active .mw-workspace:has(.ma-app) .ma-project-view {display:grid;grid-template-columns:minmax(0,1fr) minmax(0,1fr);gap:12px;align-items:start;}
 body.mobile-ui-active .mw-workspace:has(.ma-app) .ma-project-view>:is(.ma-month-section,.ma-enter) {grid-column:1/-1;}
 body.mobile-ui-active .mw-workspace:has(.ma-app) .ma-month-grid {grid-template-columns:repeat(6,minmax(0,1fr));}
 body.mobile-ui-active .mw-workspace:has(.ma-app) .ma-sheet {min-width:0;}
 body.mobile-ui-active .mw-workspace:has(.ma-app) .ma-system {margin:0 0 12px;background:#fff;border:1px solid #dce4ef;border-radius:10px;overflow:hidden;}
 body.mobile-ui-active .mw-workspace:has(.ma-app) .ma-system-title {display:flex;justify-content:space-between;align-items:center;gap:10px;padding:10px 12px;background:#edf1f7;}
 body.mobile-ui-active .mw-workspace:has(.ma-app) .ma-system-title>div {display:flex;gap:6px;}
 body.mobile-ui-active .mw-workspace:has(.ma-app) .ma-system-title h3 {margin:0!important;}
 body.mobile-ui-active .mw-workspace:has(.ma-app) .ma-check-row {padding:12px;border-bottom:1px solid #dce4ef;}
 body.mobile-ui-active .mw-workspace:has(.ma-app) .ma-row-main {display:grid;grid-template-columns:32px minmax(0,1fr) 180px;gap:10px;}
 body.mobile-ui-active .mw-workspace:has(.ma-app) .ma-row-text strong {display:block;font-size:14px;line-height:1.6;}
 body.mobile-ui-active .mw-workspace:has(.ma-app) .ma-standard {margin:4px 0;padding:0;border:0;background:transparent;font-size:12px;line-height:1.6;color:#66758b;}
 body.mobile-ui-active .mw-workspace:has(.ma-app) .ma-three-states {display:flex;gap:4px;}
 body.mobile-ui-active .mw-workspace:has(.ma-app) .ma-three-states button {flex:1;min-width:0;min-height:44px;padding:6px 3px;border:1px solid #dce4ef;border-radius:7px;background:#fff;color:#66758b;font-size:13px;}
 body.mobile-ui-active .mw-workspace:has(.ma-app) .ma-three-states button.is-pass {background:#e7f5ec;color:#267143;border-color:#80b397;}
 body.mobile-ui-active .mw-workspace:has(.ma-app) .ma-three-states button.is-fail {background:#fff0ee;color:#b32128;border-color:#db9693;}
 body.mobile-ui-active .mw-workspace:has(.ma-app) .ma-three-states button.is-na {background:#fff8dd;color:#886c18;border-color:#d6c27b;}
 body.mobile-ui-active .mw-workspace:has(.ma-app) .ma-row-note {width:100%;min-height:44px;margin-top:6px;font-size:16px;}
 body.mobile-ui-active .mw-workspace:has(.ma-app) .ma-inline-measures {display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:10px;margin-top:12px;}
 body.mobile-ui-active .mw-workspace:has(.ma-app) .ma-inline-measures label {display:flex;align-items:center;gap:10px;font-size:13px;}
 body.mobile-ui-active .mw-workspace:has(.ma-app) .ma-inline-measures input {width:92px;min-height:44px;font-size:16px;}
 body.mobile-ui-active .mw-workspace:has(.ma-app) .ma-system-end {padding:12px;display:grid;gap:12px;}
 body.mobile-ui-active .mw-workspace:has(.ma-app) .ma-system-end textarea {width:100%;min-height:64px;font-size:16px;}
 body.mobile-ui-active .mw-workspace:has(.ma-app) .ma-end-section {padding:14px;margin-bottom:12px;border:1px solid #dce4ef;border-radius:10px;background:#fff;}
 body.mobile-ui-active .mw-workspace:has(.ma-app) .ma-end-row {display:grid;gap:10px;margin:10px 0;padding:10px 0;border-bottom:1px solid #dce4ef;}
}
@media(max-width:380px) {
 body.mobile-ui-active .mw-workspace:has(.ma-app) :is(.ma-header,.ma-app) {padding-left:12px;padding-right:12px;}
 body.mobile-ui-active .mw-workspace:has(.ma-app) .ma-bottom {padding-left:12px;padding-right:12px;}
 body.mobile-ui-active.mobile-task-workflow .mobile-task-workflow-view .task-detail-submit-actions>button {font-size:13px;}
}
@media(max-height:480px) {
 body.mobile-ui-active:has(.mobile-workspace:is([data-mobile-hub-area="home"],[data-mobile-hub-area="overview"])) .cw-modal .cw-body {padding-top:10px;}
 body.mobile-ui-active:has(.mobile-workspace:is([data-mobile-hub-area="home"],[data-mobile-hub-area="overview"])) .cw-modal .cw-body h3 {font-size:14px;margin-bottom:8px;}
 body.mobile-ui-active:has(.mobile-workspace:is([data-mobile-hub-area="home"],[data-mobile-hub-area="overview"])) .cw-modal form[data-mode="action"]>.cw-footer {margin-top:8px;padding-top:8px;padding-bottom:8px;}
}
