/* ==========================================================
   jobs.css
   求人ページ専用：列幅調整（admin / 非admin 分離）
   ========================================================== */

/* --------------------------------------
   共通設定
-------------------------------------- */
#page-jobs .fg-table {
    width: 100%;
    table-layout: fixed;
}

#page-jobs .fg-table th {
    white-space: nowrap;       /* 見出しの縦割れ防止 */
}

#page-jobs .fg-table td {
    word-break: break-word;    /* 中身は折り返しOK */
}

/* 非表示列（管理者列） */
#page-jobs .fg-hide {
    display: none;
}
/* テーブルの外側で余白を確保 */
#page-jobs .fg-table-wrapper {
    padding-right: 16px;   /* ← これ */
    box-sizing: border-box;
}

/* ==========================================================
   ▼ 一般ユーザー用（非ログイン）
   ※ 1〜3列は fg-hide で非表示
   ※ 4〜15列で幅を再配分（合計100%）
   ========================================================== */

/* 4: カテゴリ */
body:not(.admin-mode) #page-jobs .fg-table th:nth-child(4),
body:not(.admin-mode) #page-jobs .fg-table td:nth-child(4) {
    width: 8%;
}

/* 5: 事業所名 */
body:not(.admin-mode) #page-jobs .fg-table th:nth-child(5),
body:not(.admin-mode) #page-jobs .fg-table td:nth-child(5) {
    width: 14%;
}

/* 6: 住所 */
body:not(.admin-mode) #page-jobs .fg-table th:nth-child(6),
body:not(.admin-mode) #page-jobs .fg-table td:nth-child(6) {
    width: 14%;
}

/* 7: TEL */
body:not(.admin-mode) #page-jobs .fg-table th:nth-child(7),
body:not(.admin-mode) #page-jobs .fg-table td:nth-child(7) {
    width: 10%;
}

/* 8: 募集資格者 */
body:not(.admin-mode) #page-jobs .fg-table th:nth-child(8),
body:not(.admin-mode) #page-jobs .fg-table td:nth-child(8) {
    width: 10%;
}

/* 9: 雇用形態 */
body:not(.admin-mode) #page-jobs .fg-table th:nth-child(9),
body:not(.admin-mode) #page-jobs .fg-table td:nth-child(9) {
    width: 10%;
}

/* 10: 勤務時間 */
body:not(.admin-mode) #page-jobs .fg-table th:nth-child(10),
body:not(.admin-mode) #page-jobs .fg-table td:nth-child(10) {
    width: 15%;
}

/* 11: 時給 / 月給 */
body:not(.admin-mode) #page-jobs .fg-table th:nth-child(11),
body:not(.admin-mode) #page-jobs .fg-table td:nth-child(11) {
    width: 15%;
}

/* 12: 賞与 */
body:not(.admin-mode) #page-jobs .fg-table th:nth-child(12),
body:not(.admin-mode) #page-jobs .fg-table td:nth-child(12) {
    width: 10%;
}

/* 13: 交通費 */
body:not(.admin-mode) #page-jobs .fg-table th:nth-child(13),
body:not(.admin-mode) #page-jobs .fg-table td:nth-child(13) {
    width: 10%;
}

/* 14: その他 */
body:not(.admin-mode) #page-jobs .fg-table th:nth-child(14),
body:not(.admin-mode) #page-jobs .fg-table td:nth-child(14) {
    width: 10%;
}

/* 15: WEB */
body:not(.admin-mode) #page-jobs .fg-table th:nth-child(15),
body:not(.admin-mode) #page-jobs .fg-table td:nth-child(15) {
    width: 2%;
}

/* ==========================================================
   ▼ 管理者モード（admin-mode）
   ※ 1〜15列すべて表示（合計100%）
   ========================================================== */

/* 1: ID */
body.admin-mode #page-jobs .fg-table th:nth-child(1),
body.admin-mode #page-jobs .fg-table td:nth-child(1) {
    width: 3%;
}

/* 2: トークン */
body.admin-mode #page-jobs .fg-table th:nth-child(2),
body.admin-mode #page-jobs .fg-table td:nth-child(2) {
    width: 6%;
}

/* 3: 更新日 */
body.admin-mode #page-jobs .fg-table th:nth-child(3),
body.admin-mode #page-jobs .fg-table td:nth-child(3) {
    width: 7%;
}

/* 4: カテゴリ */
body.admin-mode #page-jobs .fg-table th:nth-child(4),
body.admin-mode #page-jobs .fg-table td:nth-child(4) {
    width: 6%;
}

/* 5: 事業所名 */
body.admin-mode #page-jobs .fg-table th:nth-child(5),
body.admin-mode #page-jobs .fg-table td:nth-child(5) {
    width: 13%;
}

/* 6: 住所 */
body.admin-mode #page-jobs .fg-table th:nth-child(6),
body.admin-mode #page-jobs .fg-table td:nth-child(6) {
    width: 16%;
}

/* 7: TEL */
body.admin-mode #page-jobs .fg-table th:nth-child(7),
body.admin-mode #page-jobs .fg-table td:nth-child(7) {
    width: 7%;
}

/* 8: 募集資格者 */
body.admin-mode #page-jobs .fg-table th:nth-child(8),
body.admin-mode #page-jobs .fg-table td:nth-child(8) {
    width: 10%;
}

/* 9: 雇用形態 */
body.admin-mode #page-jobs .fg-table th:nth-child(9),
body.admin-mode #page-jobs .fg-table td:nth-child(9) {
    width: 7%;
}

/* 10: 勤務時間 */
body.admin-mode #page-jobs .fg-table th:nth-child(10),
body.admin-mode #page-jobs .fg-table td:nth-child(10) {
    width: 10%;
}

/* 11: 時給 / 月給 */
body.admin-mode #page-jobs .fg-table th:nth-child(11),
body.admin-mode #page-jobs .fg-table td:nth-child(11) {
    width: 7%;
}

/* 12: 賞与 */
body.admin-mode #page-jobs .fg-table th:nth-child(12),
body.admin-mode #page-jobs .fg-table td:nth-child(12) {
    width: 6%;
}

/* 13: 交通費 */
body.admin-mode #page-jobs .fg-table th:nth-child(13),
body.admin-mode #page-jobs .fg-table td:nth-child(13) {
    width: 5%;
}

/* 14: その他 */
body.admin-mode #page-jobs .fg-table th:nth-child(14),
body.admin-mode #page-jobs .fg-table td:nth-child(14) {
    width: 6%;
}

/* 15: WEB */
body.admin-mode #page-jobs .fg-table th:nth-child(15),
body.admin-mode #page-jobs .fg-table td:nth-child(15) {
    width: 2%;
}

/* ▼ ページ全体スクロールを許可 */
#page-jobs .fg-table-wrapper {
    overflow-y: visible;
}
#page-jobs .fg-table-wrapper {
    margin-bottom: 120px;  /* footer分＋余裕 */
}

/* 編集可能な行 */
.job-row.can-edit {
    background: #fff8e1; /* 薄い黄色 */
}

/* 編集可能な事業所名をリンク風に */
.job-row.can-edit td:nth-child(5) {
    color: #1a73e8;
    text-decoration: underline;
    cursor: pointer;
    font-weight: 600;
}

/* ホバー時 */
.job-row.can-edit:hover {
    background: #fff3c4;
}

/* 編集可バッジ（左端） */
.job-row.can-edit td:first-child::before {
    content: "✏️ 編集可";
    display: inline-block;
    margin-right: 6px;
    font-size: 11px;
    color: #555;
}
