/* Shell v2 first slice. No role/visibility/status rules. POS and inspection excluded by installer. */
html[data-copyfoto-shell="v2"] {--cf-shell-bg:#eef0f4;--cf-shell-card:#fff;--cf-shell-raised:#f2f4f8;--cf-shell-line:#c3c9d4;--cf-shell-text:#252b36;--cf-shell-muted:#495768;--cf-shell-focus:#215eb0}
html[data-copyfoto-shell="v2"] body{background:var(--cf-shell-bg);color:var(--cf-shell-text)}
html[data-copyfoto-shell="v2"] .workspace{min-width:0}
html[data-copyfoto-shell="v2"] .content{max-width:1600px;padding:24px clamp(12px,2.2vw,32px) 80px}
html[data-copyfoto-shell="v2"] .sidebar{background:#292d35}
html[data-copyfoto-shell="v2"] .nav button.active{background:#3b424e;box-shadow:inset 3px 0 var(--red,#e30613)}
html[data-copyfoto-shell="v2"] .topbar{background:#fff;border-color:var(--cf-shell-line)}
html[data-copyfoto-shell="v2"] .view>.head{background:#fff;color:var(--cf-shell-text);border:1px solid var(--cf-shell-line);border-radius:14px;padding:20px;box-shadow:none;align-items:flex-start;flex-wrap:wrap}
html[data-copyfoto-shell="v2"] .view>.head:after{content:none}
html[data-copyfoto-shell="v2"] .view>.head h1{font-size:clamp(24px,2.4vw,32px);line-height:1.15;letter-spacing:-.025em}
html[data-copyfoto-shell="v2"] .view>.head p{color:var(--cf-shell-muted)}
html[data-copyfoto-shell="v2"] .view :is(.card,.settings-box,.stat,.metric,.production-info-card){border-radius:14px;border-color:var(--cf-shell-line);box-shadow:none}
html[data-copyfoto-shell="v2"] :is(.view,.modal,dialog) :is(input:not([type=checkbox]):not([type=radio]):not([type=range]):not([type=color]),select,textarea){border-color:var(--cf-shell-line);border-radius:9px;color:var(--cf-shell-text);background:var(--cf-shell-card);max-width:100%}
html[data-copyfoto-shell="v2"] :is(button,input,select,textarea,a):focus-visible{outline:3px solid var(--cf-shell-focus);outline-offset:2px}
html[data-copyfoto-shell="v2"] .view :is(.btn,button){min-height:36px}
html[data-copyfoto-shell="v2"] :is(.view,.modal,dialog) :is(.actions,.filters){flex-wrap:wrap;gap:8px}
html[data-copyfoto-shell="v2"] .view :is(.table-wrap,.table-scroll,.fh-table-wrap){max-width:100%;overflow-x:auto;overscroll-behavior-x:contain}
html[data-copyfoto-shell="v2"] .view table{font-variant-numeric:tabular-nums}
html[data-copyfoto-shell="v2"] .view :is(th,td){border-color:var(--cf-shell-line)}
html[data-copyfoto-shell="v2"] .view th{background:var(--cf-shell-raised);color:var(--cf-shell-muted)}
html[data-copyfoto-shell="v2"] .view .empty-module{border-radius:12px;color:var(--cf-shell-muted)}
html[data-copyfoto-shell="v2"] :is(.view,.modal,dialog) :disabled{cursor:not-allowed}
@media(max-width:760px){
 html[data-copyfoto-shell="v2"] .content{padding:12px 12px 88px}
 html[data-copyfoto-shell="v2"] .view>.head{padding:16px;gap:12px}
 html[data-copyfoto-shell="v2"] .view>.head .actions{justify-content:flex-start}
 html[data-copyfoto-shell="v2"] :is(.view,.modal,dialog) .fields{grid-template-columns:minmax(0,1fr)}
 html[data-copyfoto-shell="v2"] :is(.view,.modal,dialog) .field{min-width:0;grid-column:auto}
 html[data-copyfoto-shell="v2"] :is(.view,.modal,dialog) :is(.btn,button){min-height:44px}
 html[data-copyfoto-shell="v2"] :is(.view,.modal,dialog) :is(input,select,textarea){font-size:16px}
}
@media(prefers-reduced-motion:reduce){html[data-copyfoto-shell="v2"] :is(.view,.modal,dialog) *{scroll-behavior:auto}}

/* Existing omnichat search/status row overflows at390px; stack without replacing controls. */
@media(max-width:760px){html[data-copyfoto-shell="v2"] #omnichat .omni-tools-row{display:grid;grid-template-columns:minmax(0,1fr);gap:8px}html[data-copyfoto-shell="v2"] #omnichat .omni-tools-row>*{min-width:0;width:100%}}

.cf-shell-navigation{display:grid;grid-template-columns:minmax(200px,1fr) minmax(200px,1fr);gap:12px;margin-bottom:18px;padding:14px;border:1px solid #c3c9d4;border-radius:12px;background:#fff;color:#252b36}.cf-shell-navigation[hidden],.cf-shell-nav-results[hidden]{display:none!important}.cf-shell-navigation label{display:grid;gap:6px;font-size:12px;color:#495768}.cf-shell-navigation input{width:100%;min-height:40px;padding:10px;border:1px solid #c3c9d4;border-radius:8px}.cf-shell-navigation summary{cursor:pointer;font-weight:700}.cf-shell-navigation p{line-height:1.5;margin:10px 0}.cf-shell-nav-results{grid-column:1/-1;display:grid;gap:5px}.cf-shell-nav-results button{background:#f2f4f8;border:1px solid #c3c9d4;border-radius:8px;padding:12px;text-align:left;color:#252b36}@media(max-width:760px){.cf-shell-navigation{grid-template-columns:minmax(0,1fr)}.cf-shell-navigation input{font-size:16px}}

/* Full-page mobile acceptance: optional header actions must not widen the layout viewport. */
@media(max-width:760px){
 html[data-copyfoto-shell="v2"] .topbar{height:auto;min-height:66px;flex-wrap:wrap;justify-content:flex-start;gap:8px;padding:10px 12px}
 html[data-copyfoto-shell="v2"] .topbar .crumb{flex:1;min-width:0;overflow-wrap:anywhere}
 html[data-copyfoto-shell="v2"] .top-actions{flex:1 1 100%;min-width:0;max-width:100%;flex-wrap:wrap;gap:6px}
 html[data-copyfoto-shell="v2"] .top-actions>button,html[data-copyfoto-shell="v2"] .top-actions>a{max-width:100%;min-height:40px;white-space:normal}
 html[data-copyfoto-shell="v2"] .top-actions .user-menu{margin-left:auto;min-width:0}
 html[data-copyfoto-shell="v2"] #bottom-dock{max-width:calc(100vw - 16px);right:8px;flex-wrap:wrap;justify-content:flex-end}
}
