/* 表と項目（custom-tables.js・2026-11-23）。カード・表・ボタンは dashboards.css の db- と members.css の ma- を使う */
#custom-tables-root { max-width:1180px; }
#custom-tables-root .ap-h:first-of-type { margin-top:4px; }
.db-card:disabled { cursor:default; opacity:.6; }
.db-card:disabled:hover { background:#fff; border-color:var(--nt-line); }
.ct-grid .db-table tbody tr.ct-row { cursor:pointer; }
.ct-grid .db-table tbody tr.ct-row:hover td { background:#FAFAFA; }
.ct-th-t { display:block; font-size:10.5px; font-weight:500; color:var(--nt-text-3); margin-top:1px; }
/* 行の入力・項目の編集の小窓 */
.ct-modal-bg { position:fixed; inset:0; z-index:1000; background:rgba(15,15,15,.32); display:flex; align-items:flex-start; justify-content:center; padding:72px 16px 24px; overflow:auto; }
.ct-modal { width:100%; max-width:560px; background:#fff; border-radius:12px; box-shadow:0 12px 40px rgba(0,0,0,.18); display:flex; flex-direction:column; max-height:calc(100vh - 96px); }
.ct-modal-h { display:flex; align-items:center; justify-content:space-between; gap:12px; padding:16px 20px 10px; }
.ct-modal-h b { font-size:15px; font-weight:700; color:var(--nt-text); }
.ct-x { border:0; background:none; font-size:20px; line-height:1; color:var(--nt-text-3); cursor:pointer; padding:4px 6px; border-radius:6px; }
.ct-x:hover { background:var(--nt-hover); color:var(--nt-text); }
.ct-modal-b { padding:4px 20px 8px; overflow:auto; }
.ct-modal-f { display:flex; flex-wrap:wrap; align-items:center; gap:8px; padding:12px 20px 16px; border-top:1px solid var(--nt-line); }
.ct-msg { flex:1 1 100%; font-size:12.5px; line-height:1.6; color:#B42318; min-height:0; }
.ct-msg:empty { display:none; }
.ct-form { display:flex; flex-direction:column; gap:12px; }
.ct-f { display:flex; flex-direction:column; gap:5px; margin:0 0 12px; }
.ct-form .ct-f { margin:0; }
.ct-f > span { font-size:12px; font-weight:600; color:var(--nt-text-2); }
.ct-f > span em { font-style:normal; font-size:10.5px; font-weight:600; color:#B42318; margin-left:4px; }
.ct-f small { font-size:11.5px; color:var(--nt-text-3); }
.ct-in, .ct-name, .ct-desc, .ct-cl, .ct-ct, .ct-co { font:inherit; font-size:13px; color:var(--nt-text); border:1px solid var(--nt-line-2); border-radius:8px; padding:7px 10px; background:#fff; width:100%; box-sizing:border-box; }
.ct-in:focus, .ct-name:focus, .ct-desc:focus, .ct-cl:focus, .ct-ct:focus, .ct-co:focus { outline:none; border-color:#1A1A1A; box-shadow:0 0 0 1px #1A1A1A; }
textarea.ct-in { resize:vertical; line-height:1.6; }
.ct-cols { display:flex; flex-direction:column; gap:8px; margin:4px 0 10px; }
.ct-col { display:grid; grid-template-columns:1fr 128px auto auto; gap:8px; align-items:center; }
.ct-col .ct-co { grid-column:1 / -1; }
.ct-req { display:flex; align-items:center; gap:4px; font-size:12px; color:var(--nt-text-2); white-space:nowrap; }
.ct-note { margin:12px 0 0; font-size:11.5px; line-height:1.6; color:var(--nt-text-3); }
/* タスク・案件・クライアントの詳しい画面に足した項目 */
.ct-props { margin-top:6px; padding-top:8px; border-top:1px dashed var(--nt-line-2); }
.ct-props-h { font-size:11px; font-weight:600; color:var(--nt-text-3); margin:0 0 4px; padding:0 6px; }
.ct-pv.is-edit { cursor:pointer; border-radius:4px; }
.ct-pv.is-edit:hover { background:var(--nt-hover); }
.ct-pv .ct-in { padding:4px 8px; font-size:13px; }
@media (max-width: 760px) {
  .ct-modal-bg { padding:16px 8px; }
  .ct-col { grid-template-columns:1fr 1fr; }
  .ct-col .ct-cl { grid-column:1 / -1; }
}
/* 一覧の見せ方の保存（notion.js の savedTabsHtml。2026-11-23） */
/* タブが増えても文字を折り返さず、入りきらないときは横に流す（スマホと同じ動き） */
#n-viewbar { overflow-x:auto; scrollbar-width:none; }
#n-viewbar::-webkit-scrollbar { display:none; }
#n-viewbar .n-viewtab { white-space:nowrap; flex-shrink:0; }
.n-sv-sep { display:inline-block; width:1px; height:16px; background:var(--nt-line-2); margin:0 6px; align-self:center; flex-shrink:0; }
.n-svtab .ic { color:var(--nt-text-3); }
.n-sv-add { color:var(--nt-text-3); }
.n-sv-add:hover { color:var(--nt-text); }
.n-sv-acts { display:inline-flex; align-items:center; gap:2px; flex-shrink:0; }
.n-sv-cur { font-size:12.5px; font-weight:600; color:var(--nt-text); margin-right:6px; white-space:nowrap; }
.n-sv-act { border:0; background:none; font:inherit; font-size:12px; color:var(--nt-text-2); padding:4px 6px; border-radius:6px; cursor:pointer; white-space:nowrap; }
.n-sv-act:hover { background:var(--nt-hover); color:var(--nt-text); }
/* お知らせ（ベル）と決まった動き（automations.js・2026-11-23） */
.nf-bell { position:relative; display:inline-grid; place-items:center; width:32px; height:32px; border:0; background:none; border-radius:8px; color:var(--nt-text-2); cursor:pointer; flex-shrink:0; }
.nf-bell:hover { background:var(--nt-hover); color:var(--nt-text); }
.nf-bell .ic { display:inline-flex; width:18px; height:18px; }
.nf-bell .ic svg { width:18px; height:18px; }
.nf-badge { position:absolute; top:2px; right:1px; min-width:16px; height:16px; padding:0 4px; border-radius:8px; background:#E5484D; color:#fff; font-size:10px; font-weight:700; line-height:16px; text-align:center; box-sizing:border-box; }
.nf-pop { position:fixed; z-index:1000; width:380px; max-width:calc(100vw - 16px); max-height:72vh; display:flex; flex-direction:column; background:#fff; border:1px solid var(--nt-line); border-radius:12px; box-shadow:0 12px 40px rgba(0,0,0,.14); overflow:hidden; }
/* 2026-11-23 坂本さん「ピクセル単位で詰められてない」「ごちゃごちゃ」: 左の端（16px）と間隔（4の倍数）をそろえ、色の印を1つにした。
   並びはスマホの通知と同じ（アイコン／送り元・時刻・未読の点／見出し／本文／ボタン） */
.nf-pop-h { display:flex; align-items:center; justify-content:space-between; height:48px; padding:0 8px 0 16px; box-sizing:border-box; }   /* 右は8px＋ボタンの中の8px＝16px（下の時刻・未読の点の右の端とそろえる） */
.nf-pop-h b { font-size:14px; font-weight:700; line-height:20px; color:var(--nt-text); }
.nf-allread { border:0; background:none; font:inherit; font-size:12px; line-height:16px; color:var(--nt-text-2); cursor:pointer; padding:6px 8px; border-radius:6px; white-space:nowrap; }
.nf-allread:hover { background:var(--nt-hover); color:var(--nt-text); }
.nf-tabs { display:flex; gap:4px; padding:0 16px 12px; border-bottom:1px solid var(--nt-line); }
.nf-tab { display:inline-flex; align-items:center; gap:6px; height:28px; padding:0 12px; border:0; border-radius:14px; background:none; font:inherit; font-size:12px; line-height:16px; color:var(--nt-text-2); cursor:pointer; white-space:nowrap; box-sizing:border-box; }
.nf-tab:hover { background:var(--nt-hover); color:var(--nt-text); }
.nf-tab.on { background:#EFEFED; color:var(--nt-text); font-weight:600; }
.nf-tab-n { font-size:11px; line-height:16px; font-weight:600; color:var(--nt-text-3); }
.nf-tab[data-tab="action"] .nf-tab-n { color:#D93025; }
.nf-list { overflow:auto; padding:4px 4px 8px; }
.nf-item { display:flex; align-items:flex-start; gap:12px; width:100%; box-sizing:border-box; padding:12px; border-radius:8px; text-align:left; font:inherit; cursor:pointer; white-space:normal; }   /* スマホの button { white-space:nowrap } を受け継がない */
.nf-item:hover { background:#F7F7F5; }
.nf-item:focus-visible { outline:2px solid #2F6FDE; outline-offset:-2px; }
.nf-ic { flex:0 0 32px; width:32px; height:32px; border-radius:50%; background:#F0F0EE; color:var(--nt-text-2); display:inline-flex; align-items:center; justify-content:center; }
.nf-ic svg { width:16px; height:16px; }
.nf-item.is-action .nf-ic { background:#FCEBEA; color:#D93025; }
.nf-body { flex:1 1 auto; display:flex; flex-direction:column; min-width:0; }
.nf-meta { display:flex; align-items:center; gap:8px; height:16px; font-size:11px; line-height:16px; color:var(--nt-text-3); }
.nf-src { flex:1 1 auto; min-width:0; overflow:hidden; text-overflow:ellipsis; white-space:nowrap; font-weight:600; }
.nf-time { flex:0 0 auto; white-space:nowrap; }
.nf-dot { flex:0 0 8px; width:8px; height:8px; border-radius:50%; background:transparent; }
.nf-item.is-unread .nf-dot { background:#2F6FDE; }
.nf-title { margin-top:4px; font-size:13px; line-height:20px; font-weight:600; color:var(--nt-text); display:-webkit-box; -webkit-line-clamp:2; -webkit-box-orient:vertical; overflow:hidden; }
.nf-item:not(.is-unread) .nf-title { font-weight:500; color:var(--nt-text-2); }
.nf-text { margin-top:4px; font-size:12px; line-height:18px; color:var(--nt-text-2); display:-webkit-box; -webkit-line-clamp:2; -webkit-box-orient:vertical; overflow:hidden; overflow-wrap:anywhere; }   /* 英単語（x-metrics）を途中で切らない */
.nf-act { align-self:flex-start; margin-top:12px; height:28px; padding:0 12px; border:1px solid var(--nt-line); border-radius:6px; background:#fff; font:inherit; font-size:12px; line-height:16px; font-weight:600; color:var(--nt-text); cursor:pointer; white-space:nowrap; box-sizing:border-box; }
.nf-act:hover { background:var(--nt-hover); }
.au-opt { flex-wrap:wrap; gap:10px; margin-top:6px; }
.au-opt .au-btn { flex:1 1 200px; }
.nf-empty { padding:16px 10px 18px; font-size:12.5px; line-height:1.7; color:var(--nt-text-3); }
#automations-root { max-width:960px; }
.au-sum { margin-top:6px; font-size:13px; line-height:1.7; color:var(--nt-text); }
.au-card.is-focus { border-color:#1A1A1A; box-shadow:0 0 0 1px #1A1A1A; }
.au-ch-bar { margin-top:10px; }
.au-modal { max-width:640px; }
.au-form { display:flex; flex-direction:column; }
.au-row { display:grid; grid-template-columns:1fr 1fr auto; gap:8px; align-items:end; }
.au-row .ct-f { margin:0 0 12px; }
.au-sec { font-size:12px; font-weight:600; color:var(--nt-text-2); margin:6px 0 6px; }
.au-cond { display:grid; grid-template-columns:1fr 1fr 1fr auto; gap:6px; align-items:center; margin:0 0 6px; }
.au-act { display:flex; flex-direction:column; gap:6px; padding:8px; border:1px solid var(--nt-line); border-radius:8px; margin:0 0 6px; }
.au-act .au-row { align-items:center; }
.au-on { margin-top:12px; }
.au-addc, .au-adda { align-self:flex-start; margin:0 0 12px; }
@media (max-width: 860px) {
  .nf-bell { width:44px; height:44px; flex:0 0 44px; margin-right:8px; border:1px solid var(--m-line-strong,var(--nt-line-2)); border-radius:12px; background:#fff; box-shadow:0 1px 3px rgba(0,0,0,.06); color:var(--nt-text); }
  .nf-bell .ic, .nf-bell .ic svg { width:19px; height:19px; }
  .nf-badge { top:3px; right:3px; }   /* ボタンの枠の中に置く（画面の上の端で切れないように） */
  .au-cond { grid-template-columns:1fr 1fr; }
  .au-row { grid-template-columns:1fr; }
}
