/* 業務アプリ(画面の名前は「アプリ」・2026-11-14)。UI v2 のトークン(--co-*)で描く。
 * 白いカードを薄い面(--co-surface)の上に置く・紫は操作・黄色は注目。
 * 選択肢・ステータスの色分け(t0〜t7)はこのファイルの --ba-t* だけで決める(紫と黄と緑と青は --co-* から)。
 */
#screen-bizapps {
  --ba-row: 64px;                               /* フォームの編集のマスの高さ */
  --ba-t0: var(--co-primary, #6c5ce7); --ba-t0w: var(--co-primary-weak, #f1efff);
  --ba-t1: var(--co-info, #2563eb);    --ba-t1w: var(--co-info-weak, #e8f0ff);
  --ba-t2: var(--co-success, #12a150); --ba-t2w: var(--co-success-weak, #e8f8ef);
  --ba-t3: var(--co-accent-ink, #8a5a00); --ba-t3w: var(--co-accent-weak, #fff6dd);
  --ba-t4: #c0266d; --ba-t4w: #fde8f1;
  --ba-t5: #0f766e; --ba-t5w: #e0f4f1;
  --ba-t6: #c2410c; --ba-t6w: #ffeddc;
  --ba-t7: #475467; --ba-t7w: #eef0f4;
  --ba-basic: var(--co-primary, #6c5ce7); --ba-adv: var(--co-info, #2563eb); --ba-lay: #d29a00;
  background: var(--co-surface, #f7f7fb); min-height: var(--co-app-h, 100dvh); color: var(--co-text, #1f1b2e);
}
#screen-bizapps .ba-root { width: 100%; box-sizing: border-box; max-width: 1320px; margin: 0 auto; padding: 20px 24px 40px; font-family: var(--co-font, inherit); container: baroot / inline-size; }
#screen-bizapps .ba-root.is-wide { max-width: none; padding: 12px 16px 24px; }
#screen-bizapps .ba-page { display: flex; flex-direction: column; gap: 14px; min-width: 0; }
#screen-bizapps .ba-spacer { flex: 1; }
#screen-bizapps .ba-dim, #screen-bizapps .ba-help { color: var(--co-muted, #7b7791); font-size: 12px; margin: 0; }
#screen-bizapps .ba-loading { color: var(--co-muted, #7b7791); padding: 40px; text-align: center; font-size: 13px; }
#screen-bizapps .ba-err { color: var(--co-danger, #e5484d); font-size: 12px; margin: 4px 0; }
#screen-bizapps .ba-err:empty { display: none; }
#screen-bizapps .ba-input.is-invalid { border-color: var(--co-danger, #e5484d); box-shadow: 0 0 0 3px rgba(229, 72, 77, .12); }
#screen-bizapps .ba-audit-row { display: flex; flex-wrap: wrap; gap: 4px 12px; margin: 0; padding: 6px 0; border-bottom: 1px solid var(--co-line, #ebebf2); font-size: 13px; }
#screen-bizapps .ba-audit-at { color: var(--co-muted, #6b6b80); font-variant-numeric: tabular-nums; }
#screen-bizapps .ba-audit-by { font-weight: 600; }

/* アイコン */
#screen-bizapps .ba-ico { display: inline-flex; width: 18px; height: 18px; flex: none; }
#screen-bizapps .ba-ico svg { width: 100%; height: 100%; }
#screen-bizapps .ba-ico.is-sm { width: 14px; height: 14px; }

/* ボタン */
#screen-bizapps .ba-btn { appearance: none; border: 1px solid var(--co-line, #ebebf2); background: var(--co-bg, #fff); color: var(--co-text-2, #4a4660); border-radius: 10px;
  height: 36px; padding: 0 14px; font: 600 13px/1 var(--co-font, inherit); cursor: pointer; white-space: nowrap; text-decoration: none; display: inline-flex; align-items: center; gap: 6px;
  transition: background .12s, border-color .12s, box-shadow .12s; }
#screen-bizapps .ba-btn:hover:not([disabled]) { border-color: var(--co-primary-line, #dcd6ff); background: var(--co-primary-weak, #f1efff); color: var(--co-primary, #6c5ce7); }
#screen-bizapps .ba-btn:focus-visible, #screen-bizapps .ba-ibtn:focus-visible { outline: 2px solid var(--co-primary, #6c5ce7); outline-offset: 2px; }
#screen-bizapps .ba-btn[disabled], #screen-bizapps .ba-ibtn[disabled] { opacity: .4; cursor: default; }
#screen-bizapps .ba-btn-primary { background: var(--co-primary, #6c5ce7); border-color: var(--co-primary, #6c5ce7); color: #fff; box-shadow: 0 1px 2px rgba(108, 92, 231, .35); }
#screen-bizapps .ba-btn-primary:hover:not([disabled]) { background: var(--co-primary-hover, #5b4bd6); border-color: var(--co-primary-hover, #5b4bd6); color: #fff; }
#screen-bizapps .ba-btn-ghost { background: var(--co-bg, #fff); }
#screen-bizapps .ba-btn-ghost.is-on { background: var(--co-primary-weak, #f1efff); border-color: var(--co-primary-line, #dcd6ff); color: var(--co-primary, #6c5ce7); }
#screen-bizapps .ba-btn-danger { color: var(--co-danger, #e5484d); border-color: var(--co-danger-weak, #fdecec); background: var(--co-bg, #fff); }
#screen-bizapps .ba-btn-danger:hover:not([disabled]) { background: var(--co-danger-weak, #fdecec); border-color: var(--co-danger, #e5484d); color: var(--co-danger, #e5484d); }
#screen-bizapps .ba-btn-sm { height: 30px; padding: 0 10px; font-size: 12px; }
#screen-bizapps .ba-btn-text { border: 0; background: none; color: var(--co-primary, #6c5ce7); height: auto; padding: 4px 6px; }
#screen-bizapps .ba-btn-text:hover:not([disabled]) { background: none; text-decoration: underline; }
#screen-bizapps .ba-badge { min-width: 18px; height: 18px; padding: 0 5px; border-radius: 9px; background: var(--co-primary, #6c5ce7); color: #fff; font-size: 11px; display: inline-flex; align-items: center; justify-content: center; }
#screen-bizapps .ba-ibtn { appearance: none; width: 34px; height: 34px; border-radius: 10px; border: 1px solid transparent; background: transparent; color: var(--co-text-2, #4a4660);
  display: inline-flex; align-items: center; justify-content: center; cursor: pointer; flex: none; padding: 0; }
#screen-bizapps .ba-ibtn:hover:not([disabled]) { background: var(--co-surface-2, #f1f1f7); color: var(--co-text, #1f1b2e); }
#screen-bizapps .ba-ibtn.is-danger { color: var(--co-danger, #e5484d); }
#screen-bizapps .ba-ibtn.is-danger:hover:not([disabled]) { background: var(--co-danger-weak, #fdecec); }
#screen-bizapps .ba-ibtn-primary { background: var(--co-primary, #6c5ce7); color: #fff; }
#screen-bizapps .ba-ibtn-primary:hover:not([disabled]) { background: var(--co-primary-hover, #5b4bd6); color: #fff; }
#screen-bizapps .ba-btngroup { display: inline-flex; gap: 2px; padding: 2px; border-radius: 12px; background: var(--co-surface-2, #f1f1f7); }

/* 入力 */
#screen-bizapps .ba-input { border: 1px solid var(--co-line, #ebebf2); border-radius: 10px; height: 40px; padding: 0 12px; font: 14px var(--co-font, inherit); background: var(--co-bg, #fff);
  color: inherit; min-width: 0; max-width: 100%; box-sizing: border-box; transition: border-color .12s, box-shadow .12s; }
#screen-bizapps .ba-input:focus { outline: none; border-color: var(--co-primary, #6c5ce7); box-shadow: 0 0 0 3px var(--co-primary-weak, #f1efff); }
#screen-bizapps textarea.ba-input { height: auto; padding: 10px 12px; width: 100%; resize: vertical; line-height: 1.6; }
#screen-bizapps select.ba-input { padding-right: 28px; }
#screen-bizapps .ba-label { display: flex; flex-direction: column; gap: 6px; font-size: 12px; font-weight: 600; color: var(--co-text-2, #4a4660); margin: 0; }
#screen-bizapps .ba-searchbox { display: inline-flex; align-items: center; gap: 6px; position: relative; color: var(--co-muted, #7b7791); }
#screen-bizapps .ba-searchbox .ba-ico { position: absolute; left: 12px; pointer-events: none; }
#screen-bizapps .ba-searchbox .ba-input { padding-left: 38px; width: 280px; }
#screen-bizapps .ba-unitbox { display: flex; align-items: center; gap: 6px; }
#screen-bizapps .ba-unitbox .ba-input { flex: 1; }
#screen-bizapps .ba-unit { font-size: 13px; color: var(--co-muted, #7b7791); }
#screen-bizapps .ba-file-input { font-size: 13px; }
#screen-bizapps .ba-switch { display: flex; align-items: center; gap: 10px; font-size: 13px; cursor: pointer; }
#screen-bizapps .ba-switch input { position: absolute; opacity: 0; width: 1px; height: 1px; }
#screen-bizapps .ba-switch-ui { width: 34px; height: 20px; border-radius: 10px; background: var(--co-line, #ebebf2); position: relative; flex: none; transition: background .15s; }
#screen-bizapps .ba-switch-ui::after { content: ''; position: absolute; top: 2px; left: 2px; width: 16px; height: 16px; border-radius: 50%; background: #fff; box-shadow: var(--co-shadow-sm); transition: left .15s; }
#screen-bizapps .ba-switch input:checked + .ba-switch-ui { background: var(--co-primary, #6c5ce7); }
#screen-bizapps .ba-switch input:checked + .ba-switch-ui::after { left: 16px; }
#screen-bizapps .ba-switch input:focus-visible + .ba-switch-ui { outline: 2px solid var(--co-primary, #6c5ce7); outline-offset: 2px; }

/* 札・色 */
#screen-bizapps .ba-tag { font-size: 11px; font-weight: 600; border-radius: 6px; padding: 2px 8px; background: var(--co-surface-2, #f1f1f7); color: var(--co-text-2, #4a4660); white-space: nowrap; }
#screen-bizapps .ba-tag.is-warn { background: var(--co-accent-weak, #fff6dd); color: var(--co-accent-ink, #8a5a00); }
#screen-bizapps .ba-tag.is-shared { background: var(--co-info-weak, #e8f0ff); color: var(--co-info, #2563eb); }
#screen-bizapps .ba-tag.is-owner { background: var(--co-accent-weak, #fff6dd); color: var(--co-accent-ink, #8a5a00); }
#screen-bizapps .ba-tag.is-primary { background: var(--co-primary-weak, #f1efff); color: var(--co-primary, #6c5ce7); align-self: flex-start; }
#screen-bizapps .ba-pill { display: inline-flex; align-items: center; gap: 5px; font-size: 12px; font-weight: 600; border-radius: 999px; padding: 3px 10px; white-space: nowrap; line-height: 1.3; }
#screen-bizapps .ba-pill::before { content: ''; width: 6px; height: 6px; border-radius: 50%; background: currentColor; }
#screen-bizapps .ba-pills { display: inline-flex; gap: 4px; flex-wrap: wrap; }
#screen-bizapps .t0 { --tc: var(--ba-t0); --tw: var(--ba-t0w); } #screen-bizapps .t1 { --tc: var(--ba-t1); --tw: var(--ba-t1w); }
#screen-bizapps .t2 { --tc: var(--ba-t2); --tw: var(--ba-t2w); } #screen-bizapps .t3 { --tc: var(--ba-t3); --tw: var(--ba-t3w); }
#screen-bizapps .t4 { --tc: var(--ba-t4); --tw: var(--ba-t4w); } #screen-bizapps .t5 { --tc: var(--ba-t5); --tw: var(--ba-t5w); }
#screen-bizapps .t6 { --tc: var(--ba-t6); --tw: var(--ba-t6w); } #screen-bizapps .t7 { --tc: var(--ba-t7); --tw: var(--ba-t7w); }
#screen-bizapps .ba-pill { color: var(--tc); background: var(--tw); }
#screen-bizapps .ba-av { width: 32px; height: 32px; border-radius: 50%; flex: none; display: inline-flex; align-items: center; justify-content: center;
  font-size: 13px; font-weight: 700; color: var(--tc); background: var(--tw); }
#screen-bizapps .ba-av.is-sm { width: 24px; height: 24px; font-size: 11px; }
#screen-bizapps .ba-av.is-lg { width: 64px; height: 64px; font-size: 26px; border-radius: 18px; }
#screen-bizapps .ba-user { display: inline-flex; align-items: center; gap: 6px; }
#screen-bizapps .ba-user .ba-av + .ba-av { margin-left: -10px; box-shadow: 0 0 0 2px #fff; }
#screen-bizapps .ba-link { color: var(--co-primary, #6c5ce7); text-decoration: none; }
#screen-bizapps .ba-link:hover { text-decoration: underline; }

/* お知らせ */
#screen-bizapps .ba-alert { border-radius: 12px; padding: 10px 14px; font-size: 13px; display: flex; align-items: center; gap: 8px; }
#screen-bizapps .ba-alert-error { background: var(--co-danger-weak, #fdecec); color: var(--co-danger, #e5484d); }
#screen-bizapps .ba-alert-error .ba-alert-x { margin-left: auto; width: 26px; height: 26px; color: inherit; }
#screen-bizapps .ba-alert-ok { background: var(--co-success-weak, #e8f8ef); color: var(--co-success, #12a150); }
#screen-bizapps .ba-alert-warn { background: var(--co-accent-weak, #fff6dd); color: var(--co-accent-ink, #8a5a00); }
#screen-bizapps .ba-empty { background: var(--co-bg, #fff); border: 1px dashed var(--co-primary-line, #dcd6ff); border-radius: 20px; padding: 48px 24px; text-align: center;
  display: flex; flex-direction: column; align-items: center; gap: 10px; }
#screen-bizapps .ba-empty h3 { margin: 4px 0 0; font-size: 16px; }
#screen-bizapps .ba-empty p { margin: 0; color: var(--co-muted, #7b7791); font-size: 13px; }

/* アプリのアイコン(色つきの角丸) */
#screen-bizapps .ba-appicon { width: 32px; height: 32px; border-radius: 10px; display: inline-flex; align-items: center; justify-content: center; flex: none; color: var(--tc); background: var(--tw); }
#screen-bizapps .ba-appicon .ba-ico { width: 18px; height: 18px; }
#screen-bizapps .ba-appicon.is-big { width: 44px; height: 44px; border-radius: 14px; }
#screen-bizapps .ba-appicon.is-big .ba-ico { width: 24px; height: 24px; }

/* アプリ一覧 */
#screen-bizapps .ba-cards { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 16px; }
#screen-bizapps .ba-card { text-align: left; border: 1px solid var(--co-line, #ebebf2); border-radius: 16px; background: var(--co-bg, #fff); padding: 18px; cursor: pointer;
  display: flex; flex-direction: column; gap: 12px; font: inherit; color: inherit; box-shadow: var(--co-shadow-sm); transition: transform .12s, box-shadow .12s, border-color .12s; min-height: 150px; }
#screen-bizapps .ba-card:hover { transform: translateY(-2px); box-shadow: var(--co-shadow); border-color: var(--co-primary-line, #dcd6ff); }
#screen-bizapps .ba-card:focus-visible { outline: 2px solid var(--co-primary, #6c5ce7); outline-offset: 2px; }
#screen-bizapps .ba-card-top { display: flex; align-items: center; gap: 12px; min-width: 0; }
#screen-bizapps .ba-card-titles { display: flex; flex-direction: column; min-width: 0; }
#screen-bizapps .ba-card-name { font-size: 16px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
#screen-bizapps .ba-card-owner { font-size: 11px; color: var(--co-muted, #7b7791); }
#screen-bizapps .ba-card-desc { margin: 0; font-size: 13px; color: var(--co-text-2, #4a4660); display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
#screen-bizapps .ba-card-foot { margin-top: auto; display: flex; align-items: center; gap: 8px; font-size: 12px; color: var(--co-muted, #7b7791); }
#screen-bizapps .ba-card-count b { font-size: 20px; color: var(--co-text, #1f1b2e); margin-right: 2px; }
#screen-bizapps .ba-card-when { margin-right: auto; }
#screen-bizapps .ba-card-new { border: 1.5px dashed var(--co-primary-line, #dcd6ff); background: linear-gradient(180deg, var(--co-primary-weak, #f1efff), var(--co-bg, #fff));
  align-items: center; justify-content: center; text-align: center; color: var(--co-primary, #6c5ce7); box-shadow: none; gap: 6px; }
#screen-bizapps .ba-card-new > span:last-child { font-size: 12px; color: var(--co-muted, #7b7791); }
#screen-bizapps .ba-card-plus { width: 44px; height: 44px; border-radius: 50%; background: var(--co-primary, #6c5ce7); color: #fff; display: inline-flex; align-items: center; justify-content: center; }
#screen-bizapps .ba-card-plus .ba-ico { width: 22px; height: 22px; }

/* ウィンドウ(共通ウィンドウの形: ヘッダー / スクロールする本文 / ボタン列) */
#screen-bizapps .ba-modal { position: fixed; inset: 0; background: rgba(31, 27, 46, .42); z-index: 400; display: flex; align-items: center; justify-content: center; padding: 16px; }
#screen-bizapps .ba-modal-card { background: var(--co-bg, #fff); border-radius: var(--co-radius-win, 20px); width: min(600px, 100%); max-height: calc(var(--co-app-h, 100vh) - 32px);
  display: flex; flex-direction: column; box-shadow: var(--co-shadow-lg); overflow: hidden; }
#screen-bizapps .ba-modal-head { display: flex; justify-content: space-between; align-items: center; padding: 14px 16px 14px 20px; border-bottom: 1px solid var(--co-line, #ebebf2); font-size: 16px; }
#screen-bizapps .ba-win-x { width: 30px; height: 30px; border-radius: 8px; background: var(--co-surface-2, #f1f1f7); }
#screen-bizapps .ba-modal-body { padding: 16px 20px; overflow: auto; display: flex; flex-direction: column; gap: 12px; }
#screen-bizapps .ba-modal-actions { display: flex; gap: 8px; align-items: center; padding: 12px 20px; border-top: 1px solid var(--co-line, #ebebf2); }
#screen-bizapps .ba-tpls { display: grid; grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); gap: 8px; }
#screen-bizapps .ba-tpl { text-align: left; border: 1.5px solid var(--co-line, #ebebf2); border-radius: 14px; background: var(--co-bg, #fff); padding: 12px; display: flex;
  gap: 10px; align-items: center; cursor: pointer; font: inherit; color: inherit; transition: border-color .12s, background .12s; }
#screen-bizapps .ba-tpl:hover { border-color: var(--co-primary-line, #dcd6ff); }
#screen-bizapps .ba-tpl.is-on { border-color: var(--co-primary, #6c5ce7); background: var(--co-primary-weak, #f1efff); }
#screen-bizapps .ba-tpl-text { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
#screen-bizapps .ba-tpl-text span { font-size: 11px; color: var(--co-muted, #7b7791); }
#screen-bizapps .ba-conds { display: flex; flex-direction: column; gap: 8px; }
#screen-bizapps .ba-cond { display: grid; grid-template-columns: minmax(0, 1.2fr) minmax(0, 1fr) minmax(0, 1.2fr) 34px; gap: 6px; align-items: center; }
#screen-bizapps .ba-cond > .ba-input:nth-child(3):last-child { grid-column: span 2; }
#screen-bizapps .ba-lookup-list { display: flex; flex-direction: column; gap: 4px; max-height: 360px; overflow: auto; }
#screen-bizapps .ba-lookup-item { display: flex; gap: 10px; align-items: center; text-align: left; border: 0; background: none; border-radius: 10px; padding: 8px; cursor: pointer; font: inherit; color: inherit; }
#screen-bizapps .ba-lookup-item:hover { background: var(--co-primary-weak, #f1efff); }
#screen-bizapps .ba-lookup-item > span:last-child { display: flex; flex-direction: column; }

/* フローティングメニュー(⋯) */
#screen-bizapps .ba-menu-wrap { position: relative; display: inline-flex; }
#screen-bizapps .ba-menu { position: absolute; right: 0; top: calc(100% + 6px); z-index: 50; min-width: 200px; background: var(--co-bg, #fff); border-radius: 14px; box-shadow: var(--co-shadow-lg);
  border: 1px solid var(--co-line, #ebebf2); padding: 6px; display: flex; flex-direction: column; }
#screen-bizapps .ba-menu-item { display: flex; align-items: center; gap: 10px; border: 0; background: none; border-radius: 10px; padding: 9px 10px; font: 13px var(--co-font, inherit); color: var(--co-text, #1f1b2e); cursor: pointer; text-align: left; }
#screen-bizapps .ba-menu-item:hover { background: var(--co-surface, #f7f7fb); }
#screen-bizapps .ba-menu-item.is-danger { color: var(--co-danger, #e5484d); border-top: 1px solid var(--co-line, #ebebf2); border-radius: 0 0 10px 10px; }

/* アプリの見出し・タブ(セグメント) */
#screen-bizapps .ba-apphead { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; min-width: 0; }
#screen-bizapps .ba-h2 { font-size: 20px; margin: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; min-width: 0; }
#screen-bizapps .ba-seg { display: inline-flex; gap: 2px; padding: 3px; border-radius: 12px; background: var(--co-surface-2, #f1f1f7); overflow-x: auto; scrollbar-width: none; max-width: 100%; }
#screen-bizapps .ba-seg-btn { appearance: none; border: 0; background: none; height: 32px; padding: 0 14px; border-radius: 9px; font: 600 13px var(--co-font, inherit); color: var(--co-text-2, #4a4660);
  display: inline-flex; align-items: center; gap: 6px; cursor: pointer; white-space: nowrap; }
#screen-bizapps .ba-seg-btn.is-on { background: var(--co-bg, #fff); color: var(--co-primary, #6c5ce7); box-shadow: var(--co-shadow-sm); }
#screen-bizapps .ba-seg-btn:focus-visible { outline: 2px solid var(--co-primary, #6c5ce7); outline-offset: -2px; }
@media (hover: hover) { #screen-bizapps .ba-seg-btn:not(.is-on):hover { color: var(--co-text, #1f1b2e); } }
#screen-bizapps .ba-seg.is-sm .ba-seg-btn { height: 28px; padding: 0 10px; font-size: 12px; }
#screen-bizapps .ba-body { min-width: 0; }

/* カード(白い面) */
#screen-bizapps .ba-card-box { background: var(--co-bg, #fff); border: 1px solid var(--co-line, #ebebf2); border-radius: 16px; padding: 20px; box-shadow: var(--co-shadow-sm); min-width: 0; }
#screen-bizapps .ba-box-title { margin: 0 0 14px; font-size: 14px; }

/* レコード一覧 */
#screen-bizapps .ba-records { display: flex; flex-direction: column; gap: 12px; }
#screen-bizapps .ba-toolbar { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
#screen-bizapps .ba-sortbox { display: inline-flex; align-items: center; gap: 2px; }
#screen-bizapps .ba-sort { max-width: 180px; }
#screen-bizapps .ba-chips { display: flex; gap: 6px; flex-wrap: wrap; align-items: center; }
#screen-bizapps .ba-fchip { display: inline-flex; align-items: center; gap: 4px; font-size: 12px; font-weight: 600; background: var(--co-primary-weak, #f1efff); color: var(--co-primary, #6c5ce7);
  border-radius: 999px; padding: 3px 4px 3px 10px; }
#screen-bizapps .ba-fchip-x { width: 20px; height: 20px; border-radius: 50%; color: inherit; }
#screen-bizapps .ba-fchip-x .ba-ico { width: 12px; height: 12px; }
#screen-bizapps .ba-countline { display: flex; align-items: center; gap: 10px; min-height: 30px; }
#screen-bizapps .ba-count { font-size: 13px; font-weight: 600; color: var(--co-text-2, #4a4660); }
#screen-bizapps .ba-tablewrap { max-width: 100%; overflow: auto; background: var(--co-bg, #fff); border: 1px solid var(--co-line, #ebebf2); border-radius: 16px; box-shadow: var(--co-shadow-sm); }
#screen-bizapps .ba-tablewrap.is-flat { box-shadow: none; border-radius: 10px; }
#screen-bizapps .ba-table { border-collapse: separate; border-spacing: 0; width: 100%; font-size: 13px; }
#screen-bizapps .ba-table th { position: sticky; top: 0; z-index: 1; background: var(--co-surface, #f7f7fb); text-align: left; padding: 0 12px; height: 40px; border-bottom: 1px solid var(--co-line, #ebebf2);
  white-space: nowrap; min-width: 60px; font-size: 12px; color: var(--co-muted, #7b7791); font-weight: 600; }
#screen-bizapps .ba-th-btn { appearance: none; border: 0; background: none; font: inherit; color: inherit; cursor: pointer; padding: 0; display: inline-flex; align-items: center; gap: 4px; }
#screen-bizapps .ba-table th.is-sorted { color: var(--co-primary, #6c5ce7); }
#screen-bizapps .ba-table td { padding: 0 12px; height: 54px; border-bottom: 1px solid var(--co-line, #ebebf2); max-width: 320px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
#screen-bizapps .ba-table tr:last-child td { border-bottom: 0; }
#screen-bizapps .ba-table .is-num { text-align: right; font-variant-numeric: tabular-nums; }
#screen-bizapps .ba-row { cursor: pointer; transition: background .08s; }
#screen-bizapps .ba-row:hover, #screen-bizapps .ba-row:focus-visible { background: var(--co-primary-weak, #f1efff); outline: none; }
#screen-bizapps .ba-row.is-sel { background: var(--co-primary-weak, #f1efff); }
#screen-bizapps .ba-titlecell { display: inline-flex; align-items: center; gap: 10px; max-width: 100%; }
#screen-bizapps .ba-titlecell b { overflow: hidden; text-overflow: ellipsis; }
#screen-bizapps .ba-th-id, #screen-bizapps .ba-td-id { width: 56px; color: var(--co-muted, #7b7791); font-variant-numeric: tabular-nums; text-align: right; }
#screen-bizapps .ba-th-check, #screen-bizapps .ba-td-check { width: 36px; padding-right: 0 !important; }
#screen-bizapps .ba-table input[type=checkbox] { accent-color: var(--co-primary, #6c5ce7); width: 16px; height: 16px; }
#screen-bizapps .ba-table th { position: sticky; }
#screen-bizapps .ba-resize { position: absolute; right: 0; top: 8px; bottom: 8px; width: 6px; cursor: col-resize; border-right: 2px solid transparent; }
#screen-bizapps .ba-table th:hover .ba-resize { border-right-color: var(--co-line, #ebebf2); }
#screen-bizapps .ba-pager { display: flex; gap: 8px; align-items: center; justify-content: center; font-size: 13px; color: var(--co-text-2, #4a4660); }

/* スマホの一覧(カード) */
#screen-bizapps .ba-mlist { display: flex; flex-direction: column; background: var(--co-bg, #fff); border: 1px solid var(--co-line, #ebebf2); border-radius: 16px; overflow: hidden; box-shadow: var(--co-shadow-sm); }
#screen-bizapps .ba-mitem { appearance: none; border: 0; border-bottom: 1px solid var(--co-line, #ebebf2); background: none; display: flex; align-items: center; gap: 12px; padding: 12px 14px;
  text-align: left; font: inherit; color: inherit; cursor: pointer; min-height: 64px; }
#screen-bizapps .ba-mitem:last-child { border-bottom: 0; }
#screen-bizapps .ba-mitem:active { background: var(--co-primary-weak, #f1efff); }
#screen-bizapps .ba-mitem-main { display: flex; flex-direction: column; gap: 3px; min-width: 0; flex: 1; }
#screen-bizapps .ba-mitem-main > * { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
#screen-bizapps .ba-mitem-go { color: var(--co-muted, #7b7791); }

/* ボード(ステータスごとの列) */
#screen-bizapps .ba-board { display: grid; grid-auto-flow: column; grid-auto-columns: minmax(260px, 1fr); gap: 12px; overflow-x: auto; padding-bottom: 8px; align-items: start; }
#screen-bizapps .ba-board-note { grid-column: 1 / -1; }
#screen-bizapps .ba-lane { background: var(--co-surface-2, #f1f1f7); border-radius: 16px; padding: 10px; display: flex; flex-direction: column; gap: 8px; min-height: 160px;
  border-top: 3px solid var(--tc); transition: background .12s, box-shadow .12s; }
#screen-bizapps .ba-lane.is-over { background: var(--tw); box-shadow: inset 0 0 0 2px var(--tc); }
#screen-bizapps .ba-lane-head { display: flex; align-items: center; gap: 8px; padding: 4px 4px 2px; font-size: 13px; }
#screen-bizapps .ba-lane-dot { width: 8px; height: 8px; border-radius: 50%; background: var(--tc); }
#screen-bizapps .ba-lane-n { font-size: 12px; font-weight: 700; color: var(--tc); background: var(--tw); border-radius: 999px; padding: 1px 8px; }
#screen-bizapps .ba-lane-sum { margin-left: auto; font-size: 12px; color: var(--co-text-2, #4a4660); font-variant-numeric: tabular-nums; }
#screen-bizapps .ba-lane-body { display: flex; flex-direction: column; gap: 8px; }
#screen-bizapps .ba-lane-empty { font-size: 12px; color: var(--co-muted, #7b7791); text-align: center; padding: 18px 0; border: 1.5px dashed var(--co-line, #ebebf2); border-radius: 12px; }
#screen-bizapps .ba-kcard { background: var(--co-bg, #fff); border-radius: 12px; padding: 12px; box-shadow: var(--co-shadow-sm); border: 1px solid var(--co-line, #ebebf2); cursor: pointer;
  display: flex; flex-direction: column; gap: 6px; font-size: 13px; transition: box-shadow .12s, transform .12s; }
#screen-bizapps .ba-kcard:hover, #screen-bizapps .ba-kcard:focus-visible { box-shadow: var(--co-shadow); border-color: var(--co-primary-line, #dcd6ff); outline: none; }
#screen-bizapps .ba-kcard.is-drag { opacity: .45; }
#screen-bizapps .ba-kcard-top { display: flex; align-items: center; gap: 8px; min-width: 0; }
#screen-bizapps .ba-kcard-top b { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
#screen-bizapps .ba-kcard-row { display: flex; gap: 8px; align-items: center; justify-content: space-between; min-width: 0; }
#screen-bizapps .ba-kcard-row > :last-child { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; min-width: 0; }
#screen-bizapps .ba-kcard-money { font-size: 15px; font-weight: 700; font-variant-numeric: tabular-nums; }
#screen-bizapps .ba-kcard-foot { display: flex; justify-content: space-between; font-size: 11px; color: var(--co-muted, #7b7791); }

/* レコードの詳細(CRM 風) */
#screen-bizapps .ba-detail { display: flex; flex-direction: column; gap: 14px; }
#screen-bizapps .ba-detail-bar.is-sticky { position: sticky; top: 0; z-index: 5; background: var(--co-surface, #f7f7fb); padding: 6px 0; }
#screen-bizapps .ba-navpair { display: inline-flex; }
#screen-bizapps .ba-edit-title { font-size: 15px; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
#screen-bizapps .ba-hero { display: flex; align-items: center; gap: 18px; padding: 22px 24px; border-radius: 20px; background: var(--co-bg, #fff); border: 1px solid var(--co-line, #ebebf2);
  box-shadow: var(--co-shadow-sm); position: relative; overflow: hidden; }
#screen-bizapps .ba-hero::before { content: ''; position: absolute; inset: 0 0 auto 0; height: 4px; background: linear-gradient(90deg, var(--co-primary, #6c5ce7), #a29bfe 60%, var(--co-accent, #ffd166)); }
#screen-bizapps .ba-hero-main { display: flex; flex-direction: column; gap: 8px; min-width: 0; flex: 1; }
#screen-bizapps .ba-hero-title { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; min-width: 0; }
#screen-bizapps .ba-hero-title h3 { margin: 0; font-size: 22px; overflow-wrap: anywhere; }
#screen-bizapps .ba-recno { font-size: 13px; color: var(--co-muted, #7b7791); font-variant-numeric: tabular-nums; }
#screen-bizapps .ba-hero-sub { display: flex; align-items: center; gap: 6px 14px; flex-wrap: wrap; font-size: 13px; }
#screen-bizapps .ba-contact { display: inline-flex; align-items: center; gap: 5px; color: var(--co-text-2, #4a4660); text-decoration: none; background: var(--co-surface, #f7f7fb);
  border-radius: 8px; padding: 4px 9px; max-width: 100%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
#screen-bizapps .ba-contact:hover { color: var(--co-primary, #6c5ce7); background: var(--co-primary-weak, #f1efff); }
#screen-bizapps .ba-hero-kpi { display: flex; flex-direction: column; align-items: flex-end; gap: 2px; padding-left: 18px; border-left: 1px solid var(--co-line, #ebebf2); }
#screen-bizapps .ba-hero-kpi span { font-size: 12px; color: var(--co-muted, #7b7791); }
#screen-bizapps .ba-hero-kpi strong { font-size: 24px; font-variant-numeric: tabular-nums; }
#screen-bizapps .ba-stages { display: flex; gap: 4px; overflow-x: auto; scrollbar-width: none; }
#screen-bizapps .ba-stages::-webkit-scrollbar { display: none; }
#screen-bizapps .ba-stage { appearance: none; border: 0; flex: 1 0 auto; min-width: 96px; height: 38px; padding: 0 18px; font: 600 13px var(--co-font, inherit); color: var(--co-text-2, #4a4660);
  background: var(--co-bg, #fff); display: inline-flex; align-items: center; justify-content: center; gap: 6px; cursor: pointer;
  clip-path: polygon(0 0, calc(100% - 12px) 0, 100% 50%, calc(100% - 12px) 100%, 0 100%, 12px 50%); transition: background .12s, color .12s; }
#screen-bizapps .ba-stage:first-child { clip-path: polygon(0 0, calc(100% - 12px) 0, 100% 50%, calc(100% - 12px) 100%, 0 100%); border-radius: 10px 0 0 10px; }
#screen-bizapps .ba-stage:last-child { clip-path: polygon(0 0, 100% 0, 100% 100%, 0 100%, 12px 50%); border-radius: 0 10px 10px 0; }
#screen-bizapps .ba-stage:hover:not([disabled]) { background: var(--co-primary-weak, #f1efff); color: var(--co-primary, #6c5ce7); }
#screen-bizapps .ba-stage.is-done { background: var(--co-primary-weak, #f1efff); color: var(--co-primary, #6c5ce7); }
#screen-bizapps .ba-stage.is-cur { background: var(--co-primary, #6c5ce7); color: #fff; cursor: default; }
#screen-bizapps .ba-stage[disabled]:not(.is-cur) { cursor: default; }
#screen-bizapps .ba-detail-wrap { display: grid; grid-template-columns: minmax(0, 1fr) 340px; gap: 16px; align-items: start; }
#screen-bizapps .ba-meta { margin: 18px 0 0; padding-top: 12px; border-top: 1px solid var(--co-line, #ebebf2); font-size: 12px; color: var(--co-muted, #7b7791); }
#screen-bizapps .ba-side { position: sticky; top: 12px; display: flex; flex-direction: column; gap: 12px; max-height: calc(var(--co-app-h, 100vh) - var(--co-header-h, 60px) - 40px); overflow: auto; }
#screen-bizapps .ba-side .ba-box-title { margin: 0; }
#screen-bizapps .ba-composer { display: flex; gap: 8px; align-items: flex-end; }
#screen-bizapps .ba-composer .ba-input { flex: 1; min-height: 40px; }
#screen-bizapps .ba-timeline { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 14px; position: relative; }
#screen-bizapps .ba-timeline > li { display: flex; gap: 10px; font-size: 13px; position: relative; min-width: 0; }
#screen-bizapps .ba-timeline > li > div { min-width: 0; flex: 1; display: flex; flex-direction: column; gap: 4px; }
#screen-bizapps .ba-tl-head { display: flex; gap: 6px; align-items: baseline; flex-wrap: wrap; font-size: 12px; }
#screen-bizapps .ba-tl-dot { width: 24px; height: 24px; border-radius: 50%; background: var(--co-surface-2, #f1f1f7); color: var(--co-text-2, #4a4660); display: inline-flex; align-items: center; justify-content: center; flex: none; }
#screen-bizapps .ba-bubble { margin: 0; background: var(--co-primary-weak, #f1efff); border-radius: 4px 12px 12px 12px; padding: 8px 12px; white-space: pre-wrap; overflow-wrap: anywhere; }
#screen-bizapps .ba-changes { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 3px; }
#screen-bizapps .ba-changes li { display: flex; align-items: center; gap: 6px; flex-wrap: wrap; font-size: 12px; overflow-wrap: anywhere; }
#screen-bizapps .ba-before { color: var(--co-muted, #7b7791); text-decoration: line-through; text-decoration-color: rgba(123, 119, 145, .4); }
#screen-bizapps .ba-after { font-weight: 600; }

/* 配置のグリッド(詳細・入力・プレビュー)。12 列・フォームで置いたマスのまま */
#screen-bizapps .ba-lay { display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); grid-auto-rows: minmax(0, auto); gap: 18px 16px; min-width: 0; }
#screen-bizapps .ba-cell { min-width: 0; display: flex; flex-direction: column; gap: 6px; align-self: start; }
#screen-bizapps .ba-cell .ba-input:not([type=checkbox]):not([type=radio]) { width: 100%; }
#screen-bizapps .ba-flabel { font-size: 12px; font-weight: 600; color: var(--co-muted, #7b7791); display: flex; gap: 3px; }
#screen-bizapps .ba-req { color: var(--co-danger, #e5484d); font-weight: 700; }
#screen-bizapps .ba-val { font-size: 14px; overflow-wrap: anywhere; min-height: 22px; display: flex; align-items: center; }
#screen-bizapps .ba-val.is-multi { white-space: pre-wrap; display: block; line-height: 1.7; }
#screen-bizapps .ba-val.is-numval { font-variant-numeric: tabular-nums; font-weight: 600; }
#screen-bizapps .ba-group { border: 1px solid var(--co-line, #ebebf2); border-radius: 14px; padding: 12px 16px 16px; background: var(--co-surface, #f7f7fb); min-width: 0; align-self: start; }
#screen-bizapps .ba-group > summary { font-weight: 700; font-size: 13px; cursor: pointer; margin-bottom: 12px; list-style: none; display: flex; align-items: center; gap: 6px; }
#screen-bizapps .ba-group > summary::-webkit-details-marker { display: none; }
#screen-bizapps .ba-group:not([open]) > summary { margin-bottom: 0; }
#screen-bizapps .ba-group:not([open]) > summary .ba-ico { transform: rotate(-90deg); }
#screen-bizapps .ba-hr { border: 0; border-top: 1px solid var(--co-line, #ebebf2); margin: 4px 0; align-self: center; }
#screen-bizapps .ba-labelpart { font-weight: 700; font-size: 14px; align-self: center; }
#screen-bizapps .ba-tabs-inner { display: flex; flex-direction: column; gap: 12px; }
#screen-bizapps .ba-choices { display: flex; flex-wrap: wrap; gap: 6px; font-size: 13px; }
#screen-bizapps .ba-choice { display: inline-flex; gap: 6px; align-items: center; border: 1px solid var(--co-line, #ebebf2); border-radius: 999px; padding: 6px 12px; cursor: pointer; background: var(--co-bg, #fff); }
#screen-bizapps .ba-choice:has(input:checked) { border-color: var(--co-primary, #6c5ce7); background: var(--co-primary-weak, #f1efff); color: var(--co-primary, #6c5ce7); }
#screen-bizapps .ba-choice input { accent-color: var(--co-primary, #6c5ce7); margin: 0; }
#screen-bizapps .ba-subtable { border-collapse: collapse; width: 100%; font-size: 13px; }
#screen-bizapps .ba-subtable th { background: var(--co-surface, #f7f7fb); color: var(--co-muted, #7b7791); font-size: 12px; font-weight: 600; }
#screen-bizapps .ba-subtable th, #screen-bizapps .ba-subtable td { border-bottom: 1px solid var(--co-line, #ebebf2); padding: 8px 10px; text-align: left; }
#screen-bizapps .ba-subtable .is-num { text-align: right; font-variant-numeric: tabular-nums; }
#screen-bizapps .ba-subtable .ba-input { height: 34px; }
#screen-bizapps .ba-files { display: flex; flex-wrap: wrap; gap: 6px; }
#screen-bizapps .ba-file { display: inline-flex; align-items: center; gap: 4px; font-size: 13px; color: var(--co-primary, #6c5ce7); text-decoration: none; background: var(--co-primary-weak, #f1efff); border-radius: 8px; padding: 4px 9px; }
#screen-bizapps .ba-lookup { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; min-height: 40px; }
#screen-bizapps .ba-editing .ba-card-box { padding: 24px; }

/* フォームの編集: 左 項目の種類・中央 キャンバス(広く)・右 設定(選んだときだけ) */
#screen-bizapps .ba-builder { display: flex; flex-direction: column; gap: 12px; }
#screen-bizapps .ba-builder-bar { position: sticky; top: 0; z-index: 6; background: var(--co-bg, #fff); border: 1px solid var(--co-line, #ebebf2); border-radius: 14px; padding: 8px 10px; box-shadow: var(--co-shadow-sm); }
#screen-bizapps .ba-state { font-size: 12px; color: var(--co-muted, #7b7791); display: inline-flex; align-items: center; gap: 4px; }
#screen-bizapps .ba-state.is-dirty { color: var(--co-accent-ink, #8a5a00); background: var(--co-accent-weak, #fff6dd); border-radius: 999px; padding: 3px 10px; }
#screen-bizapps .ba-state.is-ok { color: var(--co-success, #12a150); }
#screen-bizapps .ba-builder-cols { display: grid; grid-template-columns: 216px minmax(0, 1fr); gap: 12px; align-items: start; }
#screen-bizapps .ba-builder-cols.has-props { grid-template-columns: 216px minmax(0, 1fr) 300px; }
#screen-bizapps .ba-palette, #screen-bizapps .ba-props { background: var(--co-bg, #fff); border: 1px solid var(--co-line, #ebebf2); border-radius: 16px; padding: 12px;
  position: sticky; top: 64px; max-height: calc(var(--co-app-h, 100vh) - var(--co-header-h, 60px) - 96px); overflow: auto; box-shadow: var(--co-shadow-sm); }
#screen-bizapps .ba-pal-h { margin: 10px 4px 6px; font-size: 11px; letter-spacing: .04em; color: var(--co-muted, #7b7791); display: flex; align-items: center; gap: 6px; }
#screen-bizapps .ba-pal-h:first-child { margin-top: 2px; }
#screen-bizapps .ba-pal-h::before { content: ''; width: 8px; height: 8px; border-radius: 3px; background: var(--cc); }
#screen-bizapps .c-basic { --cc: var(--ba-basic); --cw: var(--co-primary-weak, #f1efff); }
#screen-bizapps .c-adv { --cc: var(--ba-adv); --cw: var(--co-info-weak, #e8f0ff); }
#screen-bizapps .c-lay { --cc: var(--ba-lay); --cw: var(--co-accent-weak, #fff6dd); }
#screen-bizapps .ba-pal-group { display: grid; grid-template-columns: minmax(0, 1fr); gap: 2px; }
#screen-bizapps .ba-pal-item { border: 1px solid transparent; border-radius: 10px; padding: 0 10px; height: 36px; font-size: 13px; font-weight: 600; cursor: grab; background: none;
  user-select: none; display: flex; align-items: center; gap: 10px; line-height: 1.2; color: var(--co-text-2, #4a4660); transition: border-color .1s, background .1s, transform .1s; white-space: nowrap; }
#screen-bizapps .ba-pal-item .ba-ico { color: var(--cc); width: 26px; height: 26px; padding: 4px; border-radius: 8px; background: var(--cw); box-sizing: border-box; }
#screen-bizapps .ba-pal-item span:last-child { overflow: hidden; text-overflow: ellipsis; }
#screen-bizapps .ba-pal-item:hover, #screen-bizapps .ba-pal-item:focus-visible { border-color: var(--cc); background: var(--co-bg, #fff); box-shadow: var(--co-shadow-sm); outline: none; }
#screen-bizapps .ba-pal-item:active { cursor: grabbing; }
#screen-bizapps .ba-canvas { background: var(--co-bg, #fff); border: 1px solid var(--co-line, #ebebf2); border-radius: 16px; padding: 16px; min-width: 0; box-shadow: var(--co-shadow-sm); position: relative;
  min-height: calc(var(--co-app-h, 100vh) - var(--co-header-h, 60px) - 170px); }
#screen-bizapps .ba-canvas-empty { position: absolute; inset: 120px 0 auto; display: flex; flex-direction: column; align-items: center; gap: 6px; color: var(--co-muted, #7b7791); font-size: 13px; pointer-events: none; z-index: 2; }
#screen-bizapps .ba-canvas-empty .ba-ico { width: 36px; height: 36px; color: var(--co-primary-line, #dcd6ff); }
#screen-bizapps .ba-canvas-empty b { color: var(--co-text-2, #4a4660); font-size: 14px; }
#screen-bizapps .ba-gc { display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); gap: 8px; position: relative; min-width: 0; }
#screen-bizapps .ba-gc-guide { border-radius: 10px; z-index: 0; pointer-events: none;
  background: repeating-linear-gradient(90deg, var(--co-surface, #f7f7fb) 0, var(--co-surface, #f7f7fb) calc((100% - 88px) / 12), transparent calc((100% - 88px) / 12), transparent calc((100% - 88px) / 12 + 8px));
  opacity: 0; transition: opacity .15s; }
#screen-bizapps .ba-gc.is-over > .ba-gc-guide, #screen-bizapps .ba-canvas:hover > .ba-gc > .ba-gc-guide { opacity: 1; }
#screen-bizapps .ba-gc.is-inner { margin-top: 8px; padding: 8px; border-radius: 12px; background: rgba(255, 255, 255, .7); border: 1.5px dashed var(--co-line, #ebebf2); --ba-row: 56px; }
#screen-bizapps .ba-gc.is-inner > .ba-gc-guide { opacity: 1; background: none; }
#screen-bizapps .ba-ghost { z-index: 3; border-radius: 12px; border: 2px dashed var(--co-primary, #6c5ce7); background: color-mix(in srgb, var(--co-primary, #6c5ce7) 10%, transparent); pointer-events: none; }
#screen-bizapps .ba-ghost[hidden] { display: none; }
/* 2026-11-16: 左だけ色の付いた枠をやめ、枠全体で状態を見せる(未選択は淡いグレー・ホバーは薄い紫・選択中は紫の枠全体)。種類の色はアイコンだけ */
#screen-bizapps .ba-cf { position: relative; z-index: 1; border: 1.5px solid var(--co-line, #ebebf2); border-radius: 12px; padding: 8px 10px 10px; background: var(--co-bg, #fff);
  cursor: grab; min-width: 0; display: flex; flex-direction: column; gap: 6px; box-shadow: var(--co-shadow-sm); transition: box-shadow .12s, border-color .12s; }
#screen-bizapps .ba-cf:hover { box-shadow: var(--co-shadow); border-color: color-mix(in srgb, var(--co-primary, #6c5ce7) 45%, var(--co-line, #ebebf2)); }
#screen-bizapps .ba-cf:focus-visible { outline: 2px solid var(--co-primary, #6c5ce7); outline-offset: 2px; }
#screen-bizapps .ba-cf.is-sel { border-color: var(--co-primary, #6c5ce7); box-shadow: 0 0 0 3px var(--co-primary-weak, #f1efff), var(--co-shadow); z-index: 2; }
#screen-bizapps .ba-cf.is-drag { opacity: .35; }
#screen-bizapps .ba-cf.is-spacer { background: repeating-linear-gradient(135deg, transparent 0 6px, var(--co-surface, #f7f7fb) 6px 12px); box-shadow: none; }
#screen-bizapps .ba-cf.is-container { background: var(--co-surface, #f7f7fb); }
#screen-bizapps .ba-cf-head { display: flex; align-items: center; gap: 6px; font-size: 13px; min-width: 0; padding-right: 2px; }
#screen-bizapps .ba-cf-head b { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
#screen-bizapps .ba-cf-ic { color: var(--cc); }
#screen-bizapps .ba-mock-input { height: 32px; border: 1px solid var(--co-line, #ebebf2); border-radius: 8px; background: var(--co-surface, #f7f7fb); font-size: 12px; color: var(--co-muted, #7b7791);
  padding: 0 10px; display: flex; align-items: center; gap: 6px; overflow: hidden; white-space: nowrap; text-overflow: ellipsis; flex: none; }
#screen-bizapps .ba-mock-input.is-select { justify-content: space-between; }
#screen-bizapps .ba-mock-input.is-multi { height: auto; min-height: 32px; flex: 1; align-items: flex-start; padding-top: 6px; }
#screen-bizapps .ba-mock-input.is-file { border-style: dashed; justify-content: center; }
#screen-bizapps .ba-mock-input.is-calc { font-family: ui-monospace, SFMono-Regular, Menlo, monospace; color: var(--co-info, #2563eb); background: var(--co-info-weak, #e8f0ff); border-color: transparent; }
#screen-bizapps .ba-mock-opts { display: flex; gap: 4px; flex-wrap: wrap; overflow: hidden; max-height: 54px; }
#screen-bizapps .ba-mock-opt { font-size: 11px; border: 1px solid var(--co-line, #ebebf2); border-radius: 6px; padding: 2px 8px; background: var(--co-surface, #f7f7fb); white-space: nowrap; }
#screen-bizapps .ba-mock-opt.is-radio { border-radius: 999px; }
#screen-bizapps .ba-mock-table { display: flex; border: 1px solid var(--co-line, #ebebf2); border-radius: 8px; overflow: hidden; font-size: 11px; color: var(--co-muted, #7b7791); }
#screen-bizapps .ba-mock-table span { flex: 1; padding: 6px 8px; background: var(--co-surface, #f7f7fb); border-right: 1px solid var(--co-line, #ebebf2); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
#screen-bizapps .ba-mock-table span:last-child { border-right: 0; }
#screen-bizapps .ba-mock-label { font-size: 13px; color: var(--co-text-2, #4a4660); }
#screen-bizapps .ba-mock-hr { border-top: 2px solid var(--co-line, #ebebf2); margin: 6px 0; }
#screen-bizapps .ba-cf-tools { position: absolute; top: -14px; right: 8px; display: flex; gap: 2px; background: var(--co-bg, #fff); border-radius: 10px; box-shadow: var(--co-shadow); padding: 2px; z-index: 4; }
#screen-bizapps .ba-cf-tools .ba-ibtn { width: 28px; height: 28px; border-radius: 8px; }
#screen-bizapps .ba-rs { position: absolute; z-index: 4; touch-action: none; }
#screen-bizapps .ba-rs-e { top: 10px; bottom: 10px; right: -5px; width: 10px; cursor: ew-resize; }
#screen-bizapps .ba-rs-s { left: 10px; right: 10px; bottom: -5px; height: 10px; cursor: ns-resize; }
#screen-bizapps .ba-rs-se { right: -6px; bottom: -6px; width: 14px; height: 14px; cursor: nwse-resize; border-radius: 4px; background: var(--co-primary, #6c5ce7); box-shadow: 0 0 0 2px #fff; }
#screen-bizapps .ba-rs-e::after { content: ''; position: absolute; left: 3px; top: 50%; width: 4px; height: 22px; margin-top: -11px; border-radius: 2px; background: var(--co-primary, #6c5ce7); }
#screen-bizapps .ba-rs-s::after { content: ''; position: absolute; top: 3px; left: 50%; height: 4px; width: 22px; margin-left: -11px; border-radius: 2px; background: var(--co-primary, #6c5ce7); }
#screen-bizapps .ba-cf.is-resizing { transition: none; }
#screen-bizapps .ba-props-body { display: flex; flex-direction: column; gap: 14px; }
#screen-bizapps .ba-props-head { display: flex; align-items: center; gap: 8px; margin: -4px -4px 0; padding: 4px 4px 10px; border-bottom: 1px solid var(--co-line, #ebebf2); }
#screen-bizapps .ba-props-head > .ba-ico { color: var(--cc); }
#screen-bizapps .ba-adv { border-top: 1px solid var(--co-line, #ebebf2); padding-top: 10px; display: flex; flex-direction: column; gap: 12px; }
#screen-bizapps .ba-adv[open] { gap: 12px; }
#screen-bizapps .ba-adv > summary { cursor: pointer; font-size: 12px; font-weight: 600; color: var(--co-text-2, #4a4660); }
#screen-bizapps .ba-adv[open] > summary { margin-bottom: 12px; }
#screen-bizapps .ba-adv > :not(summary) + :not(summary) { margin-top: 12px; }
#screen-bizapps .ba-props-actions { display: flex; gap: 8px; }
#screen-bizapps .ba-ref, #screen-bizapps .ba-subset { display: flex; flex-direction: column; gap: 10px; }
#screen-bizapps .ba-copy { display: grid; grid-template-columns: 1fr 1fr 34px; gap: 6px; align-items: end; }
#screen-bizapps .ba-subcol { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr) 34px; gap: 6px; padding: 8px; border-radius: 10px; background: var(--co-surface, #f7f7fb); }
#screen-bizapps .ba-subcol .ba-input { height: 34px; font-size: 13px; }
#screen-bizapps .ba-subcol > .ba-input:nth-child(n+4) { grid-column: 1 / -1; }
#screen-bizapps .ba-subcode { font-family: ui-monospace, SFMono-Regular, Menlo, monospace; font-size: 12px !important; }
#screen-bizapps .ba-preview { display: flex; flex-direction: column; gap: 16px; max-width: 1080px; width: 100%; margin: 0 auto; }

/* 設定(基本・一覧・アクセス権) */
#screen-bizapps .ba-settings-wrap { display: grid; grid-template-columns: 200px minmax(0, 1fr); gap: 16px; align-items: start; }
#screen-bizapps .ba-subnav { display: flex; flex-direction: column; gap: 2px; position: sticky; top: 12px; }
#screen-bizapps .ba-subnav-btn { appearance: none; border: 0; background: none; display: flex; align-items: center; gap: 8px; height: 40px; padding: 0 12px; border-radius: 10px;
  font: 600 13px var(--co-font, inherit); color: var(--co-text-2, #4a4660); cursor: pointer; text-align: left; }
#screen-bizapps .ba-subnav-btn.is-on { background: var(--co-bg, #fff); color: var(--co-primary, #6c5ce7); box-shadow: var(--co-shadow-sm); }
@media (hover: hover) { #screen-bizapps .ba-subnav-btn:not(.is-on):hover { background: var(--co-surface-2, #f1f1f7); } }
#screen-bizapps .ba-settings, #screen-bizapps .ba-views, #screen-bizapps .ba-acl { display: flex; flex-direction: column; gap: 14px; max-width: 860px; min-width: 0; }
#screen-bizapps .ba-settings .ba-card-box, #screen-bizapps .ba-view, #screen-bizapps .ba-acl .ba-card-box { display: flex; flex-direction: column; gap: 14px; }
#screen-bizapps .ba-row2 { display: flex; gap: 12px; align-items: flex-end; flex-wrap: wrap; }
#screen-bizapps .ba-row2 > .ba-label { flex: 1 1 200px; }
#screen-bizapps .ba-colrow { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; }
#screen-bizapps .ba-colchips { display: flex; gap: 6px; flex-wrap: wrap; }
#screen-bizapps .ba-colchip { display: inline-flex; align-items: center; gap: 4px; font-size: 12px; font-weight: 600; background: var(--co-surface, #f7f7fb); border: 1px solid var(--co-line, #ebebf2);
  border-radius: 999px; padding: 3px 4px 3px 10px; }
#screen-bizapps .ba-addcol { width: auto; height: 32px; font-size: 12px; }
#screen-bizapps .ba-icons { display: flex; gap: 8px; flex-wrap: wrap; }
#screen-bizapps .ba-iconpick { border: 2px solid transparent; border-radius: 14px; background: none; padding: 3px; cursor: pointer; }
#screen-bizapps .ba-iconpick.is-on { border-color: var(--co-primary, #6c5ce7); }
#screen-bizapps .ba-fold > summary { cursor: pointer; font-weight: 700; font-size: 14px; }
#screen-bizapps .ba-fold[open] > summary { margin-bottom: 4px; }
#screen-bizapps .ba-listrow { display: flex; align-items: center; gap: 8px; padding: 8px 0; border-bottom: 1px solid var(--co-line, #ebebf2); font-size: 13px; }
#screen-bizapps .ba-audit p { margin: 4px 0; font-size: 12px; color: var(--co-muted, #7b7791); }
#screen-bizapps .ba-danger-zone { flex-direction: row !important; align-items: center; justify-content: space-between; gap: 16px; border-color: var(--co-danger-weak, #fdecec); }
#screen-bizapps .ba-members { display: flex; flex-direction: column; }
#screen-bizapps .ba-member { display: flex; align-items: center; gap: 10px; padding: 10px 0; border-bottom: 1px solid var(--co-line, #ebebf2); font-size: 13px; flex-wrap: wrap; }
#screen-bizapps .ba-member .ba-input { width: 140px; height: 34px; font-size: 13px; }
#screen-bizapps .ba-addrow { display: flex; gap: 8px; }
#screen-bizapps .ba-addrow .ba-input { flex: 1; max-width: 280px; }
#screen-bizapps .ba-ruletable { border-collapse: collapse; width: 100%; font-size: 13px; }
#screen-bizapps .ba-ruletable th, #screen-bizapps .ba-ruletable td { padding: 8px 12px; border-bottom: 1px solid var(--co-line, #ebebf2); text-align: center; }
#screen-bizapps .ba-ruletable th:first-child, #screen-bizapps .ba-ruletable td:first-child { text-align: left; }
#screen-bizapps .ba-ruletable th { font-size: 12px; color: var(--co-muted, #7b7791); background: var(--co-surface, #f7f7fb); }
#screen-bizapps .ba-ruletable input { accent-color: var(--co-primary, #6c5ce7); width: 16px; height: 16px; }

/* 本文の幅で並びを変える(サイドメニューを除いた幅・コンテナクエリ) */
@container baroot (max-width: 1100px) {
  #screen-bizapps .ba-builder-cols.has-props { grid-template-columns: 180px minmax(0, 1fr); }
  #screen-bizapps .ba-builder-cols.has-props .ba-props { grid-column: 1 / -1; position: static; max-height: none; }
  #screen-bizapps .ba-builder-cols { grid-template-columns: 180px minmax(0, 1fr); }
  #screen-bizapps .ba-detail-wrap { grid-template-columns: minmax(0, 1fr); }
  #screen-bizapps .ba-side { position: static; max-height: none; }
}
@container baroot (max-width: 760px) {
  #screen-bizapps .ba-settings-wrap { grid-template-columns: minmax(0, 1fr); }
  #screen-bizapps .ba-subnav { flex-direction: row; overflow-x: auto; position: static; }
  #screen-bizapps .ba-builder-cols, #screen-bizapps .ba-builder-cols.has-props { grid-template-columns: minmax(0, 1fr); }
  #screen-bizapps .ba-palette { position: static; max-height: none; }
  #screen-bizapps .ba-pal-group { grid-template-columns: repeat(auto-fill, minmax(120px, 1fr)); }
  #screen-bizapps .ba-hero { flex-wrap: wrap; padding: 18px; }
  #screen-bizapps .ba-hero-kpi { border-left: 0; padding-left: 0; align-items: flex-start; width: 100%; }
}
@container baroot (max-width: 640px) {
  #screen-bizapps .ba-lay { grid-template-columns: minmax(0, 1fr); }
  #screen-bizapps .ba-lay > * { grid-column: 1 / -1 !important; grid-row: auto !important; }
  #screen-bizapps .ba-searchbox, #screen-bizapps .ba-searchbox .ba-input { width: 100%; }
  #screen-bizapps .ba-searchbox { flex: 1 1 100%; }
  #screen-bizapps .ba-sortbox { display: none; }
  #screen-bizapps .ba-board { grid-auto-columns: 82%; }
  #screen-bizapps .ba-cond { grid-template-columns: minmax(0, 1fr) 34px; }
  #screen-bizapps .ba-cond > select:nth-child(2) { grid-column: 1; }
  #screen-bizapps .ba-cond > .ba-input:nth-child(3) { grid-column: 1; }
  #screen-bizapps .ba-av.is-lg { width: 52px; height: 52px; font-size: 22px; }
  #screen-bizapps .ba-hero-title h3 { font-size: 19px; }
  #screen-bizapps .ba-table td { height: 50px; }
}
@media (max-width: 640px) {
  #screen-bizapps .ba-root { padding: 12px; }
  #screen-bizapps .ba-modal { padding: 8px; }
  #screen-bizapps .ba-modal-card { max-height: calc(var(--co-app-h, 100vh) - 16px); }
}

/* 2026-11-14 アイコンの画像・切り取り・共有のリンク */
#screen-bizapps .ba-hidden { display: none; }
#screen-bizapps .ba-appicon.is-img { background: #fff; overflow: hidden; padding: 0; box-shadow: 0 0 0 1px var(--co-line, #e7e5f0) inset; }
#screen-bizapps .ba-appicon.is-img img { width: 100%; height: 100%; object-fit: cover; display: block; }
#screen-bizapps .ba-iconimg-row { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; margin: 4px 0 6px; }
#screen-bizapps .ba-modal-card.is-crop { width: min(360px, calc(100vw - 32px)); }
#screen-bizapps .ba-crop { display: flex; flex-direction: column; align-items: center; gap: 12px; }
#screen-bizapps .ba-crop-frame { width: 240px; height: 240px; border-radius: 20px; overflow: hidden; background:
  repeating-conic-gradient(#f1eff8 0% 25%, #fff 0% 50%) 50% / 20px 20px; box-shadow: 0 0 0 2px var(--co-primary, #6d4aff); }
#screen-bizapps .ba-crop-canvas { display: block; width: 240px; height: 240px; cursor: grab; touch-action: none; }
#screen-bizapps .ba-crop-canvas:active { cursor: grabbing; }
#screen-bizapps .ba-crop-row { display: flex; align-items: center; gap: 8px; width: 240px; color: var(--co-text-2, #6b6880); }
#screen-bizapps .ba-crop-zoom { flex: 1; accent-color: var(--co-primary, #6d4aff); }
#screen-bizapps .ba-share .ba-share-url { font-family: ui-monospace, SFMono-Regular, Menlo, monospace; font-size: 12.5px; background: var(--co-surface-2, #f7f6fd); }

/* 2026-11-14 詳細・入力: 中くらいの幅では 6 列にして、狭い項目(4 マス以下)は半分・それ以外は 1 行(入力欄が小さくなりすぎない) */
@container baroot (min-width: 641px) and (max-width: 980px) {
  #screen-bizapps .ba-lay { grid-template-columns: repeat(6, minmax(0, 1fr)); }
  #screen-bizapps .ba-lay > * { grid-column: auto / span 6 !important; grid-row: auto !important; }
  #screen-bizapps .ba-lay > .ba-cell[data-w="1"], #screen-bizapps .ba-lay > .ba-cell[data-w="2"],
  #screen-bizapps .ba-lay > .ba-cell[data-w="3"], #screen-bizapps .ba-lay > .ba-cell[data-w="4"],
  #screen-bizapps .ba-lay > .ba-cell[data-w="5"], #screen-bizapps .ba-lay > .ba-cell[data-w="6"] { grid-column: auto / span 3 !important; }
}
#screen-bizapps .ba-cell .ba-input, #screen-bizapps .ba-cell select, #screen-bizapps .ba-cell textarea { min-width: 0; width: 100%; box-sizing: border-box; }
#screen-bizapps .ba-root.is-wide .ba-tablewrap { overflow-x: auto; }
#screen-bizapps .ba-table { table-layout: fixed; min-width: max-content; }

/* 2026-11-14 フォームの種類・公開フォームの設定 */
#screen-bizapps .ba-kinds { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
#screen-bizapps .ba-kind { display: flex; gap: 10px; align-items: flex-start; text-align: left; padding: 12px; border: 1.5px solid var(--co-line, #e7e5f0);
  border-radius: 14px; background: #fff; cursor: pointer; font: inherit; color: inherit; }
#screen-bizapps .ba-kind.is-on { border-color: var(--co-primary, #6d4aff); background: var(--co-primary-weak, #f3f0ff); box-shadow: 0 0 0 3px rgba(109, 74, 255, .12); }
#screen-bizapps .ba-kind svg { flex: none; width: 20px; height: 20px; color: var(--co-primary, #6d4aff); margin-top: 2px; }
#screen-bizapps .ba-public { display: flex; flex-direction: column; gap: 14px; }
#screen-bizapps .ba-pf-statusrow { display: flex; align-items: center; gap: 10px; margin-bottom: 10px; }
#screen-bizapps .ba-pf-status.is-on { border-color: #b7e4c7; background: linear-gradient(180deg, #f2fbf5, #fff 60%); }
#screen-bizapps .ba-tag.is-ok { background: #e3f6ea; color: #1b7a43; }
#screen-bizapps .ba-pf-cols { display: grid; grid-template-columns: minmax(0, 1.2fr) minmax(0, 1fr); gap: 14px; align-items: start; }
#screen-bizapps .ba-row3 { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 10px; }
#screen-bizapps .ba-colorpick input[type=color] { width: 100%; height: 38px; border: 1px solid var(--co-line, #e7e5f0); border-radius: 10px; padding: 3px; background: #fff; cursor: pointer; }
#screen-bizapps .ba-pf-preview { background: var(--pfp-bg, #f6f4ff); border-radius: 16px; padding: 18px; color: var(--pfp-text, #1f1d2b); }
#screen-bizapps .ba-pf-card { background: #fff; border-radius: 14px; padding: 16px; display: flex; flex-direction: column; gap: 10px; box-shadow: 0 6px 20px rgba(30, 20, 80, .08); overflow: hidden; }
#screen-bizapps .ba-pf-head { margin: -16px -16px 4px; aspect-ratio: 3 / 1; background: repeating-linear-gradient(45deg, #ece9f8 0 10px, #f6f4ff 10px 20px); display: grid; place-items: center; }
#screen-bizapps .ba-pf-title { font-size: 17px; }
#screen-bizapps .ba-pf-card p { margin: 0; font-size: 13px; opacity: .8; white-space: pre-wrap; }
#screen-bizapps .ba-pf-input { height: 34px; border: 1.5px solid #e6e3f2; border-radius: 10px; }
#screen-bizapps .ba-pf-btn { background: var(--pfp-btn, #6d4aff); color: #fff; border-radius: 10px; text-align: center; padding: 9px; font-weight: 800; }
#screen-bizapps .ba-crop-frame.is-wide { width: 330px; height: 110px; border-radius: 12px; }
#screen-bizapps .ba-crop-canvas.is-wide { width: 330px; height: 110px; }
#screen-bizapps .ba-crop-row.is-wide { width: 330px; }
#screen-bizapps .ba-modal-card.is-crop.is-wide { width: min(420px, calc(100vw - 32px)); }
@container baroot (max-width: 760px) {
  #screen-bizapps .ba-kinds, #screen-bizapps .ba-pf-cols, #screen-bizapps .ba-row3 { grid-template-columns: minmax(0, 1fr); }
}

/* 2026-11-14 レコードの詳細: 概要カードをやめ、値は表示だけの枠(入力欄の白い地と見分ける薄い地・淡い枠・角丸) */
#screen-bizapps .ba-detail-title { display: inline-flex; align-items: baseline; gap: 8px; min-width: 0; margin-left: 4px; }
#screen-bizapps .ba-detail-title strong { font-size: 16px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; max-width: 40vw; }
#screen-bizapps .ba-detail-main .ba-cell { display: flex; flex-direction: column; gap: 6px; min-width: 0; }
#screen-bizapps .ba-fval { min-height: 42px; padding: 10px 14px; border: 1px solid var(--co-line, #ebebf2); border-radius: 12px; background: #faf9fe;
  color: var(--co-text, #1f1b2e); font-size: 14px; line-height: 1.6; overflow-wrap: anywhere; display: flex; align-items: center; flex-wrap: wrap; gap: 6px; cursor: default; }
#screen-bizapps .ba-fval.is-empty { background: #fcfcfd; color: var(--co-muted, #8a86a0); }
#screen-bizapps .ba-fval.is-number, #screen-bizapps .ba-fval.is-currency, #screen-bizapps .ba-fval.is-calc { font-variant-numeric: tabular-nums; font-weight: 600; }
#screen-bizapps .ba-fval .is-multi { white-space: pre-wrap; display: block; width: 100%; }
#screen-bizapps .ba-fval.is-subtable, #screen-bizapps .ba-fval.is-reference_table { display: block; padding: 8px; }
#screen-bizapps .ba-fval .ba-users { display: flex; flex-wrap: wrap; gap: 6px 12px; }
#screen-bizapps .ba-fval .ba-lookup { display: inline-flex; align-items: center; gap: 6px; color: var(--co-primary, #6c5ce7); font-weight: 600; }
#screen-bizapps .ba-thumbs { display: flex; flex-wrap: wrap; gap: 10px; }
#screen-bizapps .ba-thumbfig { margin: 0; display: flex; flex-direction: column; gap: 4px; max-width: 160px; }
#screen-bizapps .ba-thumb { width: 160px; height: 110px; object-fit: cover; border-radius: 8px; border: 1px solid var(--co-line, #ebebf2); background: #fff; }
#screen-bizapps .ba-thumbfig figcaption { font-size: 12px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
/* 2026-11-14(その3) 選んだレコードの CSV */
#screen-bizapps .ba-selinfo { display: inline-flex; align-items: center; gap: 6px; font-size: 13px; color: var(--co-primary, #6c5ce7); font-weight: 600; }
#screen-bizapps .ba-radios { display: flex; flex-direction: column; gap: 8px; margin: 10px 0; }
#screen-bizapps .ba-radio { display: flex; gap: 10px; align-items: flex-start; padding: 10px 12px; border: 1px solid var(--co-line, #ebebf2); border-radius: 10px; cursor: pointer; }
#screen-bizapps .ba-radio:has(input:checked) { border-color: var(--co-primary, #6c5ce7); background: var(--co-primary-weak, #f1efff); }
#screen-bizapps .ba-radio > span { display: flex; flex-direction: column; gap: 2px; }
#screen-bizapps .ba-radio input { accent-color: var(--co-primary, #6c5ce7); margin-top: 3px; }

/* 2026-11-18: 「アプリを作成」は2つのカードと縦並びのボタンだけ */
#screen-bizapps .ba-modal-card.is-create { width: min(520px, calc(100vw - 32px)); }
#screen-bizapps .ba-kinds.is-create { grid-template-columns: minmax(0, 1fr); gap: 10px; }
#screen-bizapps .ba-kinds.is-create .ba-kind { padding: 16px; border-width: 2px; }
#screen-bizapps .ba-kinds.is-create .ba-kind.is-on { border-color: var(--co-primary, #6c5ce7); }
#screen-bizapps .ba-kind.is-locked { opacity: .55; cursor: not-allowed; }
#screen-bizapps .ba-kind-note { display: block; margin-top: 4px; font-size: 12px; color: var(--co-muted, #7b7791); }
#screen-bizapps .ba-create-actions { display: flex; flex-direction: column; gap: 8px; margin: 16px 4px 4px; }
#screen-bizapps .ba-btn-block { width: 100%; justify-content: center; height: 44px; }

/* 2026-11-18: レコードの作成・編集は「キャンセル」の右に「保存」を並べる(見出しなし・新規と編集で同じ)。
   共通ヘッダー(固定)の下に貼り付く(top: 0 だとヘッダーの下に隠れていた) */
#screen-bizapps .ba-edit-actions { display: inline-flex; gap: 8px; align-items: center; }
body.co-has-header #screen-bizapps .ba-detail-bar.is-sticky, body.co-has-header #screen-bizapps .ba-builder-bar { top: var(--co-header-h, 60px); }
@media (max-width: 640px) {
  #screen-bizapps .ba-edit-bar { justify-content: stretch; }
  #screen-bizapps .ba-edit-actions { display: grid; grid-template-columns: 1fr 1fr; width: 100%; }
  #screen-bizapps .ba-edit-actions .ba-btn { justify-content: center; height: 44px; }
}

/* 2026-11-18 タブ: 外枠でタブの範囲を示す・タブの幅は名前に合わせる(引き伸ばさない)・多いときは横にスクロール */
#screen-bizapps .ba-tabs-inner { border: 1px solid var(--co-line, #ebebf2); border-radius: 14px; background: var(--co-bg, #fff); padding: 0 16px 16px; gap: 14px; min-width: 0; }
#screen-bizapps .ba-tabbar { display: flex; gap: 4px; overflow-x: auto; scrollbar-width: thin; border-bottom: 1px solid var(--co-line, #ebebf2); margin: 0 -16px; padding: 0 12px; }
#screen-bizapps .ba-tab { appearance: none; flex: none; border: 0; background: none; padding: 10px 14px 9px; font: 600 13px var(--co-font, inherit); color: var(--co-muted, #7b7791);
  border-bottom: 2px solid transparent; margin-bottom: -1px; cursor: pointer; white-space: nowrap; }
#screen-bizapps .ba-tab.is-on { color: var(--co-primary, #6c5ce7); border-bottom-color: var(--co-primary, #6c5ce7); }
#screen-bizapps .ba-tab:focus-visible { outline: 2px solid var(--co-primary, #6c5ce7); outline-offset: -2px; border-radius: 8px 8px 0 0; }
@media (hover: hover) { #screen-bizapps .ba-tab:not(.is-on):hover { color: var(--co-text, #1f1b2e); } }
#screen-bizapps .ba-tab-empty { display: none; margin: 0; font-size: 12px; }
#screen-bizapps .ba-tabs-inner.is-none .ba-tab-empty { display: block; }
#screen-bizapps .ba-tabs-inner.is-none { padding-bottom: 12px; }
#screen-bizapps .ba-cell.is-error .ba-input { border-color: var(--co-danger, #e5484d); }
/* フォームの編集: タブの入れ物には「タブ」の札(同じ段のタブが1つの並びになる) */
#screen-bizapps .ba-cf[data-type="TAB"] > .ba-cf-head b::before { content: 'タブ'; display: inline-block; margin-right: 6px; padding: 0 6px; border-radius: 6px; font-size: 11px; font-weight: 700;
  color: var(--co-primary, #6c5ce7); background: var(--co-primary-weak, #f1efff); }

/* 2026-11-18 アクティビティ: 最初は閉じる・ボタンで右に開く(スマホは詳細の下)。閉じているときは詳細を全幅に */
#screen-bizapps .ba-detail-wrap.is-solo { grid-template-columns: minmax(0, 1fr); }
#screen-bizapps .ba-side[hidden] { display: none; }
#screen-bizapps .ba-side-head { display: flex; align-items: center; justify-content: space-between; gap: 8px; }
#screen-bizapps .ba-count { display: inline-flex; min-width: 18px; height: 18px; padding: 0 5px; border-radius: 999px; align-items: center; justify-content: center;
  font-size: 11px; font-weight: 700; background: var(--co-primary-weak, #f1efff); color: var(--co-primary, #6c5ce7); }
#screen-bizapps .ba-av-img { width: 32px; height: 32px; border-radius: 50%; flex: none; background: var(--co-surface, #f7f7fb); border: 1px solid var(--co-line, #ebebf2); }
body.co-has-header #screen-bizapps .ba-side { top: calc(var(--co-header-h, 60px) + 12px); }

/* 2026-11-18 進み具合(表示だけ)と操作のボタン(左詰め)を分ける */
#screen-bizapps .ba-progress { display: flex; flex-direction: column; gap: 10px; background: var(--co-bg, #fff); border: 1px solid var(--co-line, #ebebf2); border-radius: 16px; padding: 14px 16px; }
#screen-bizapps .ba-progress-head { display: flex; align-items: baseline; gap: 10px; font-size: 13px; }
#screen-bizapps .ba-progress-cur { font-size: 15px; }
#screen-bizapps .ba-stages.is-static { list-style: none; margin: 0; padding: 0; }
#screen-bizapps .ba-stages.is-static .ba-stage { cursor: default; }
#screen-bizapps .ba-actions { display: flex; flex-wrap: wrap; gap: 8px; justify-content: flex-start; align-items: center; }
/* 遷移図(設定と、分岐のあるレコードの進み具合) */
#screen-bizapps .ba-flow-wrap { overflow-x: auto; padding-bottom: 4px; }
#screen-bizapps .ba-flow { display: block; font-family: var(--co-font, inherit); }
#screen-bizapps .ba-flow-node rect { fill: var(--co-surface, #f7f7fb); stroke: var(--co-line, #d9d7e5); stroke-width: 1.5; }
#screen-bizapps .ba-flow-node.is-first rect { stroke: var(--co-primary-line, #dcd6ff); }
#screen-bizapps .ba-flow-node.is-cur rect { fill: var(--co-primary, #6c5ce7); stroke: var(--co-primary, #6c5ce7); }
#screen-bizapps .ba-flow-node text { font-size: 13px; font-weight: 700; fill: var(--co-text, #1f1b2e); }
#screen-bizapps .ba-flow-node.is-cur text { fill: #fff; }
#screen-bizapps .ba-flow-edge path { fill: none; stroke-width: 1.8; }
#screen-bizapps .ba-flow-edge.is-fwd path { stroke: var(--co-primary, #6c5ce7); }
#screen-bizapps .ba-flow-edge.is-back path { stroke: var(--co-accent-ink, #8a5a00); stroke-dasharray: 5 4; }
#screen-bizapps .ba-flow-edge text { font-size: 11px; font-weight: 600; fill: var(--co-text-2, #4a4660); paint-order: stroke; stroke: #fff; stroke-width: 4px; }
/* プロセス管理の設定 */
#screen-bizapps .ba-process { display: flex; flex-direction: column; gap: 16px; min-width: 0; }
#screen-bizapps .ba-st-list { list-style: none; margin: 0 0 10px; padding: 0; display: flex; flex-direction: column; gap: 6px; }
#screen-bizapps .ba-st-row { display: flex; align-items: center; gap: 8px; }
#screen-bizapps .ba-st-row .ba-input { max-width: 280px; }
#screen-bizapps .ba-st-no { width: 24px; height: 24px; border-radius: 50%; display: inline-flex; align-items: center; justify-content: center; font-size: 12px; font-weight: 700;
  background: var(--co-primary-weak, #f1efff); color: var(--co-primary, #6c5ce7); flex: none; }
#screen-bizapps .ba-act-list { display: flex; flex-direction: column; gap: 12px; margin-bottom: 10px; }
#screen-bizapps .ba-act { border: 1px solid var(--co-line, #ebebf2); border-radius: 14px; padding: 12px; display: flex; flex-direction: column; gap: 10px; }
#screen-bizapps .ba-act-main { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr) auto minmax(0, 1fr) auto; gap: 8px; align-items: end; }
#screen-bizapps .ba-act-arrow { padding-bottom: 10px; color: var(--co-primary, #6c5ce7); }
#screen-bizapps .ba-act-who, #screen-bizapps .ba-act-cond { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; font-size: 12px; }
#screen-bizapps .ba-act-cond .ba-input { width: auto; min-width: 140px; }
#screen-bizapps .ba-proc-note { gap: 8px; }
#screen-bizapps [data-field].is-error .ba-input, #screen-bizapps [data-field].is-error { border-color: var(--co-danger, #e5484d); }
/* ボード: 分類の表示・列の検索・さらに表示 */
#screen-bizapps .ba-board-wrap { display: flex; flex-direction: column; gap: 10px; min-width: 0; }
#screen-bizapps .ba-board-bar { display: flex; flex-wrap: wrap; gap: 12px; align-items: center; font-size: 12px; }
#screen-bizapps .ba-searchbox.is-sm .ba-input { height: 32px; }
@media (max-width: 640px) {
  #screen-bizapps .ba-act-main { grid-template-columns: minmax(0, 1fr); }
  #screen-bizapps .ba-act-arrow { display: none; }
  #screen-bizapps .ba-actions .ba-btn { flex: 1 1 auto; justify-content: center; }
}

/* 2026-11-19 アクセス権の「削除可能」(役割とは別のチェック) */
#screen-bizapps .ba-del-perm { display: inline-flex; align-items: center; gap: 6px; font-size: 13px; white-space: nowrap; padding: 0 6px; min-height: 36px; cursor: pointer; }
#screen-bizapps .ba-del-perm input { accent-color: var(--co-primary, #6c5ce7); width: 16px; height: 16px; }
#screen-bizapps .ba-del-perm:has(input:disabled) { color: var(--co-muted, #7b7791); cursor: default; }
@media (max-width: 640px) { #screen-bizapps .ba-member { flex-wrap: wrap; } }
