/*
 * BO の web（BO の本番ビルド）へ足す、スマホ幅だけの上書き css（refs #13927・Mawasu が配る BO の web の画面の直し）。
 *   BO の css は書き換えない。dist の根へ置き、index.html の </head> の前の <link> で BO の css の後に読ませて勝たせる。
 *   PC（769px 以上）は 1 行も変えない: 全ての規則を @media (max-width: 768px) の中に置く。
 *   選択子は css module の hash（style_xxx__AbC12）が建て直しで変わっても効くよう、class 名の前半だけを `[class*=…]` で指し、
 *   お知らせ（/notification）の頁の class だけに絞る（他の画面の ant-table には当たらない）。
 *
 * T70 / NOTIF390-OVERLAP（390 幅の /notification）:
 *   BO の css は 頁の頭（.notificationHeader = 「お知らせ」＋ 削除 / 既読にする の一括釦）を position:fixed; top:60px; z-index:1 に、
 *   表の頭（.ant-table-thead = 「全選択」）を position:fixed; top:112px; z-index:2 に置く（PC の 1 行の頭を前提にした数）。
 *   スマホ幅では頭の中身が 2 段に折り返し、「既読にする」の釦が top:112px の所へ落ちる ⇒ 白い背景の THEAD（z-index:2）が釦の上に乗り、
 *   行を選んで釦が有効になっても、釦の中心を押すと THEAD に当たる（スマホで一括の既読ができない）。
 *   直し: 固定をやめて流れの中に戻す。頭は position:sticky（上に張り付く・祖先に overflow があって張り付かない画面でも、
 *   ただ流れの中に居るだけで重ならない）・表の頭は static・表の上の余白（固定の頭の分の 80px）は 0。
 *   ⚠ 表の頭を static に戻さないと（固定のままだと）頭の 2 段目（top:112px 付近）に被さって 全選択（#all）と最初の行が隠れる。
 *     scroll-margin-top は focus / anchor の scroll で 張り付いた頭の下に 全選択・行が潜らないための余白（頭の高さ分）。
 *   選択子の頭の body は特異度を 1 つ上げるため: 頁ごとの css chunk は実行時に <head> の後ろへ足されるので、読み込み順では勝てない。
 *   ⚠ text-wrap: balance は使わない（WebKit / 古い Chromium で効かない）。
 */
@media (max-width: 768px) {
  body [class*="style_notificationHeader__"] {
    position: sticky;
    top: 60px;
    left: auto;
    width: auto;
    z-index: 3;
    padding-top: 12px;
    padding-bottom: 8px;
  }
  body [class*="style_notificationHeader__"] [class*="style_wrapperHeader__"] {
    flex-wrap: wrap;
    align-items: center;
    gap: 8px;
  }
  body [class*="style_tableNotification__"] {
    margin-top: 0;
  }
  body [class*="style_tableNotification__"] .ant-table-thead {
    position: static;
    top: auto;
    left: auto;
    width: auto;
  }
  body [class*="style_tableNotification__"] .ant-table-thead,
  body [class*="style_tableNotification__"] .ant-table-row {
    scroll-margin-top: 130px;
  }
}

/*
 * #15978 / TEHAI-DETAIL-390（390 幅の手配の詳細〈ポップアップ〉）:
 *   手配の詳細は幅に関わらず「左 12 ／ 右 12」の 2 列（antd の Col span=12 ＝ 50%）で組まれ、390 では各列が 170px 前後・
 *   その中の「見出し 8 ／ 値 16」がさらに割られて見出し 58px・値 115px 前後になり、会社名・顧客名・「開始時刻-終了時刻」・スタッフが 1 文字ずつ縦に折れる。
 *   直し: 576px 以下（antd の xs の境）だけ、手配の詳細の 2 列（ポップアップの中の Row.fixed-header-form の直下の Col）を縦に積む（各 100%）。
 *   見出しと値の 8 ／ 16 は積んだ後の幅（340px 前後）で割るので、見出し 110px・値 230px 前後になり、長い語は折り返す。
 *   `.fixed-header-form` は BO の styles/index.scss の global 名（css module の hash が付かない）・`.ant-modal` の中に絞る。
 *   576px を超える幅は 1 行も変えない（上の 768px の塊とは別の @media）。
 */
@media (max-width: 576px) {
  .ant-modal .ant-row.fixed-header-form > .ant-col {
    flex: 0 0 100%;
    max-width: 100%;
    min-width: 0;
  }
  .ant-modal .ant-row.fixed-header-form > .ant-col .ant-col {
    min-width: 0;
    overflow-wrap: anywhere;
  }
}
