/* ============================================================
   SWELL テーマ互換: サイトヘッダー・ページヘッダー・パンくずを非表示
   ============================================================ */
body:has([data-job-posting-tool-root]) .l-header,
body:has([data-job-posting-tool-root]) #header {
  display: none !important;
}
body:has([data-job-posting-tool-root]) .p-pageHeader,
body:has([data-job-posting-tool-root]) .p-pageHeader__eyecatch,
body:has([data-job-posting-tool-root]) .p-breadcrumb,
body:has([data-job-posting-tool-root]) .p-eyecatch,
body:has([data-job-posting-tool-root]) .p-postEyecatch {
  display: none !important;
}
body:has([data-job-posting-tool-root]) .l-main,
body:has([data-job-posting-tool-root]) .l-contents {
  padding-top: 0 !important;
  margin-top: 0 !important;
}
body:has([data-job-posting-tool-root]) .l-article__body {
  padding: 0 !important;
}

/* サイドバー非表示（ツール専用レイアウト）— SWELL の #sidebar / .l-sidebar 等 */
body:has([data-job-posting-tool-root]) #sidebar,
body:has([data-job-posting-tool-root]) aside#sidebar,
body:has([data-job-posting-tool-root]) .l-sidebar,
body:has([data-job-posting-tool-root]) .p-sidebar {
  display: none !important;
}
body:has([data-job-posting-tool-root]) .l-mainContent {
  width: 100% !important;
  max-width: none !important;
}

/* メイン列内でツールだけ横幅いっぱいにし、テーマの2カラム（サイドバー横並び）を維持する */
[data-job-posting-tool-root] {
  display: block;
  width: 100%;
  max-width: 100%;
  min-width: 0;
  box-sizing: border-box;
}

/* ============================================================
   リセット & ルート
   ============================================================ */
.job-posting-tool-root,
.job-posting-tool-root *,
.job-posting-tool-root *::before,
.job-posting-tool-root *::after {
  box-sizing: border-box;
}
.job-posting-tool-root {
  font-family: 'Noto Sans JP', 'Hiragino Sans', 'Yu Gothic', sans-serif;
  color: #1a1a2e;
  line-height: 1.6;
  font-weight: 400;
  font-synthesis: none;
  text-rendering: optimizeLegibility;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}
.job-posting-tool-root button,
.job-posting-tool-root input,
.job-posting-tool-root textarea {
  font: inherit;
}
.job-posting-tool-root button {
  cursor: pointer;
}

/* ============================================================
   ページ外枠
   ============================================================ */
.job-posting-tool-root .jpt-page-outer {
  background: #EEF2F8;
  padding-bottom: 0;
  display: flex;
  flex-direction: column;
}
.job-posting-tool-root .jpt-page-outer--result {
  position: fixed;
  inset: 0;
  z-index: 9999;
  display: flex;
  flex-direction: column;
  padding-bottom: 0;
  min-height: 0;
  overflow: hidden;
}
.job-posting-tool-root .jpt-page-outer--generating {
  position: fixed;
  inset: 0;
  z-index: 9999;
  background: rgba(10, 16, 28, 0.74);
  display: flex;
  align-items: center;
  justify-content: center;
  animation: jpt-fade-out 0.25s ease both;
}
.job-posting-tool-root .jpt-generating-box {
  width: min(92vw, 420px);
  background: #fff;
  border-radius: 14px;
  box-shadow: 0 16px 40px rgba(0, 0, 0, 0.22);
  padding: 26px 20px 22px;
  text-align: center;
}
.job-posting-tool-root .jpt-generating-spinner {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  border: 3px solid #fed7aa;
  border-top-color: #f97316;
  margin: 0 auto 12px;
  animation: jpt-spin 0.9s linear infinite;
}
.job-posting-tool-root .jpt-generating-title {
  margin: 0;
  font-size: 20px;
  font-weight: 900;
  color: #1a1a2e;
}
.job-posting-tool-root .jpt-generating-sub {
  margin: 8px 0 0;
  font-size: 13px;
  color: #6b7280;
}
.job-posting-tool-root .jpt-fade-in {
  animation: jpt-fade-in 0.35s ease both;
}

/* 結果画面表示中はページ本体のスクロールを止める */
body.jpt-result-fullscreen {
  overflow: hidden !important;
}

/* ============================================================
   ステップバナー（上部ステップ表示）
   ============================================================ */
.job-posting-tool-root .jpt-salary-banner {
  background: #f97316;
  text-align: center;
  padding: 10px 16px 8px;
}
.job-posting-tool-root .jpt-salary-label {
  font-size: 11px;
  color: rgba(255,255,255,0.75);
  margin: 0 0 2px;
  letter-spacing: 1px;
  text-transform: uppercase;
}
.job-posting-tool-root .jpt-salary-value {
  font-size: 16px;
  font-weight: 900;
  color: #fff;
  letter-spacing: 3px;
}

/* ============================================================
   ステップドット
   ============================================================ */
.job-posting-tool-root .jpt-step-section {
  background: #ffffff;
  padding: 6px 20px 6px;
  border-bottom: 1px solid #e5e7eb;
}
.job-posting-tool-root .jpt-step-label {
  font-size: 11px;
  color: #999;
  margin: 0 0 4px;
  text-align: center;
  letter-spacing: 1px;
  text-transform: uppercase;
}
.job-posting-tool-root .jpt-step-dots {
  display: flex;
  align-items: center;
  justify-content: center;
}
.job-posting-tool-root .jpt-step-dot {
  width: 30px;
  height: 30px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 12px;
  font-weight: 700;
  flex-shrink: 0;
  border: 2.5px solid #e0e0e0;
  background: #fff;
  color: #ccc;
}
.job-posting-tool-root .jpt-step-dot.done {
  border-color: #f97316;
  background: #f97316;
  color: #fff;
}
.job-posting-tool-root .jpt-step-dot.current {
  border-color: #f97316;
  background: #fff;
  color: #f97316;
  box-shadow: 0 0 0 4px rgba(249,115,22,0.18);
}
.job-posting-tool-root .jpt-step-dot.pending {
  border-color: #e0e0e0;
  background: #fff;
  color: #ccc;
}
.job-posting-tool-root .jpt-step-line {
  flex: 1;
  height: 2.5px;
  background: #e0e0e0;
  max-width: 24px;
  min-width: 8px;
}
.job-posting-tool-root .jpt-step-line.done {
  background: #f97316;
}

/* ============================================================
   メインコンテンツ
   ============================================================ */
.job-posting-tool-root .jpt-main {
  padding: 14px 16px 12px;
  max-width: 600px;
  margin: 0 auto;
  flex: 1;
  width: 100%;
  box-sizing: border-box;
}
.job-posting-tool-root .jpt-main-result {
  padding-bottom: 40px;
}
.job-posting-tool-root .jpt-page-title {
  font-size: 20px;
  font-weight: 900;
  color: #1a1a2e;
  margin: 0 0 10px;
  line-height: 1.5;
}
.job-posting-tool-root .jpt-page-title-sub {
  display: block;
  margin-top: 6px;
  font-size: 13px;
  font-weight: 400;
  color: #666;
}

/* ============================================================
   選択肢リスト（shindan 風: 個別カード + ホバー反転）
   ============================================================ */
.job-posting-tool-root .jpt-option-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.job-posting-tool-root .jpt-option-row {
  display: flex;
  align-items: center;
  width: 100%;
  padding: 14px 16px;
  gap: 12px;
  border: 2.5px solid #e5e7eb;
  border-radius: 10px;
  background: #ffffff;
  text-align: left;
  color: #1a1a2e;
  transition: border-color 0.15s, background 0.15s;
}
.job-posting-tool-root .jpt-option-row:hover {
  border-color: #f97316;
  background: #fff8f3;
}
.job-posting-tool-root .jpt-option-row.selected {
  border-color: #f97316;
  background: #fff8f3;
}
.job-posting-tool-root .jpt-check-custom {
  width: 24px;
  height: 24px;
  border-radius: 6px;
  border: 2px solid #d1d5db;
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 13px;
  font-weight: 900;
  color: #fff;
  transition: border-color 0.15s, background 0.15s;
}
.job-posting-tool-root .jpt-option-row.selected .jpt-check-custom {
  border-color: #f97316;
  background: #f97316;
}
.job-posting-tool-root .jpt-option-label {
  font-size: 14px;
  color: #1a1a2e;
  line-height: 1.5;
  font-weight: 500;
}

/* ============================================================
   最終ステップ 導入テキスト
   ============================================================ */
.job-posting-tool-root .jpt-last-step-intro {
  margin-bottom: 24px;
}
.job-posting-tool-root .jpt-last-step-intro-inner {
  background: linear-gradient(135deg, #fff7ed 0%, #fef3c7 100%);
  border: 1.5px solid #fed7aa;
  border-radius: 12px;
  padding: 20px 24px;
}
.job-posting-tool-root .jpt-last-step-intro-title {
  font-size: 18px;
  font-weight: 900;
  color: #ea580c;
  margin: 0 0 10px;
  letter-spacing: 0.3px;
}
.job-posting-tool-root .jpt-last-step-intro-body {
  font-size: 14px;
  color: #44403c;
  line-height: 1.8;
  margin: 0;
}
.job-posting-tool-root .jpt-last-step-intro-body strong {
  color: #ea580c;
  font-weight: 700;
}
.job-posting-tool-root .jpt-last-step-beforeafter {
  padding: 20px 16px;
  background: #fff;
  border-top: 1px solid #e5e7eb;
  width: 100%;
  box-sizing: border-box;
}
@media (min-width: 769px) {
  .job-posting-tool-root .jpt-last-step-beforeafter {
    padding: 24px 40px;
  }
}
.job-posting-tool-root .jpt-last-step-ba-caption {
  font-size: 16px;
  font-weight: 900;
  color: #ea580c;
  text-align: center;
  margin: 0 0 16px;
}
.job-posting-tool-root .jpt-last-step-ba-images {
  display: flex;
  align-items: center;
  gap: 8px;
}
.job-posting-tool-root .jpt-last-step-ba-item {
  flex: 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
}
.job-posting-tool-root .jpt-last-step-ba-img {
  width: 100%;
  border-radius: 6px;
  border: 1px solid #e5e7eb;
  box-shadow: 0 2px 8px rgba(0,0,0,0.10);
  display: block;
}
.job-posting-tool-root .jpt-last-step-ba-img--result {
  width: 70%;
}
.job-posting-tool-root .jpt-last-step-ba-img-label {
  font-size: 12px;
  color: #555;
  text-align: center;
  margin: 8px 0 0;
  line-height: 1.5;
}
.job-posting-tool-root .jpt-last-step-ba-arrow {
  font-size: 80px;
  color: #1a1a1a;
  font-weight: 900;
  flex-shrink: 0;
  line-height: 1;
  display: flex;
  align-items: center;
  align-self: center;
  padding: 0 8px;
}
@media (max-width: 768px) {
  .job-posting-tool-root .jpt-last-step-ba-images {
    flex-direction: column;
    gap: 4px;
  }
  .job-posting-tool-root .jpt-last-step-ba-item {
    width: 100%;
  }
  .job-posting-tool-root .jpt-last-step-ba-arrow {
    font-size: 0;
    padding: 4px 0;
  }
  .job-posting-tool-root .jpt-last-step-ba-arrow::before {
    content: '↓';
    font-size: 56px;
    display: block;
    line-height: 1;
  }
}

/* ============================================================
   フォーム
   ============================================================ */
.job-posting-tool-root .jpt-form-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 14px;
}
@media (min-width: 560px) {
  .job-posting-tool-root .jpt-form-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}
.job-posting-tool-root .jpt-field {
  display: flex;
  flex-direction: column;
  gap: 6px;
}
.job-posting-tool-root .jpt-field span {
  font-size: 13px;
  font-weight: 700;
  color: #374151;
}
.job-posting-tool-root .jpt-field input {
  width: 100%;
  padding: 12px 14px;
  border: 2px solid #e5e7eb;
  border-radius: 8px;
  background: #fff;
  outline: none;
  color: #1a1a2e;
  transition: border-color 0.15s, box-shadow 0.15s;
}
.job-posting-tool-root .jpt-field input:focus {
  border-color: #f97316;
  box-shadow: 0 0 0 3px rgba(249,115,22,0.15);
}

/* ============================================================
   バリデーション
   ============================================================ */
.job-posting-tool-root .jpt-validation {
  min-height: 16px;
  margin: 6px 0 0;
  font-size: 13px;
  color: #dc2626;
}

/* ============================================================
   固定ナビゲーションバー
   ============================================================ */
.job-posting-tool-root .jpt-nav-bar {
  position: sticky;
  bottom: 0;
  background: #fff;
  border-top: 1px solid #e5e7eb;
  padding: 12px 16px;
  display: flex;
  align-items: center;
  gap: 10px;
  max-width: 600px;
  width: 100%;
  margin: 0 auto;
  box-sizing: border-box;
  z-index: 100;
  box-shadow: 0 -4px 16px rgba(0,0,0,0.07);
}
.job-posting-tool-root .jpt-btn-back {
  font-size: 14px;
  font-weight: 700;
  color: #999;
  background: none;
  border: none;
  padding: 10px 12px;
  flex-shrink: 0;
}
.job-posting-tool-root .jpt-btn-back:disabled {
  opacity: 0.35;
  cursor: not-allowed;
}

/* 次へボタン: 白地 + オレンジ枠 → ホバーで反転（shindan スタイル） */
.job-posting-tool-root .jpt-btn-next {
  flex: 1;
  padding: 13px 20px;
  border-radius: 8px;
  border: 2.5px solid #f97316;
  background: #ffffff;
  color: #f97316;
  font-size: 15px;
  font-weight: 700;
  text-align: center;
  transition: background 0.18s, color 0.18s;
}
.job-posting-tool-root .jpt-btn-next:hover:not(:disabled) {
  background: #f97316;
  color: #ffffff;
}
.job-posting-tool-root .jpt-btn-next:disabled {
  border-color: #d1d5db;
  background: #f9fafb;
  color: #9ca3af;
  cursor: not-allowed;
}

/* 最終ステップ（生成ボタン）はソリッドオレンジ */
.job-posting-tool-root .jpt-btn-next--final {
  background: #f97316;
  color: #ffffff;
  border-color: #f97316;
}
.job-posting-tool-root .jpt-btn-next--final:hover:not(:disabled) {
  background: #ea580c;
  border-color: #ea580c;
}

/* ============================================================
   結果エリア
   ============================================================ */
.job-posting-tool-root .jpt-result-wrap {
  background: #EEF2F8;
  min-height: calc(100vh - 140px);
}
.job-posting-tool-root .jpt-card {
  background: #fff;
  border-radius: 10px;
  box-shadow: 0 2px 10px rgba(0,0,0,0.08);
  margin: 0 auto 12px;
  width: 100%;
  max-width: 560px;
  overflow: hidden;
}
.job-posting-tool-root .jpt-card-head {
  background: #f97316;
  color: #fff;
  padding: 10px 16px;
  font-size: 14px;
  font-weight: 700;
}
.job-posting-tool-root .jpt-card-head-main {
  font-size: 18px;
  padding: 14px 16px;
  text-align: center;
  background: #1a1a2e;
}
.job-posting-tool-root .jpt-card-body {
  padding: 16px;
}
.job-posting-tool-root .jpt-result-note {
  font-size: 13px;
  color: #666;
  line-height: 1.6;
  margin: 0;
}
.job-posting-tool-root .jpt-body-text {
  font-size: 14px;
  line-height: 1.7;
  color: #374151;
  margin: 0;
}
.job-posting-tool-root .jpt-bullet-list {
  margin: 0;
  padding: 0;
  list-style: none;
  font-size: 14px;
  line-height: 1.8;
  color: #374151;
}
.job-posting-tool-root .jpt-dl {
  margin: 0;
}
.job-posting-tool-root .jpt-dl > div {
  display: grid;
  gap: 2px;
  margin-bottom: 12px;
}
.job-posting-tool-root .jpt-dl > div:last-child {
  margin-bottom: 0;
}
.job-posting-tool-root .jpt-dl dt {
  font-size: 11px;
  color: #999;
  margin: 0;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}
.job-posting-tool-root .jpt-dl dd {
  font-size: 14px;
  font-weight: 700;
  margin: 0;
  color: #1a1a2e;
}

/* ============================================================
   テキスト出力
   ============================================================ */
.job-posting-tool-root .jpt-card-body-output {
  display: flex;
  flex-direction: column;
  gap: 12px;
}
.job-posting-tool-root .jpt-output-textarea {
  width: 100%;
  min-height: 240px;
  resize: vertical;
  padding: 12px;
  border: 2px solid #e5e7eb;
  border-radius: 8px;
  background: #f9fafb;
  color: #111827;
  font-size: 12px;
  line-height: 1.7;
  white-space: pre-wrap;
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
}

/* コピーボタン: 白地 + オレンジ枠 → ホバーで反転 */
.job-posting-tool-root .jpt-btn-primary {
  display: block;
  width: 100%;
  padding: 13px 16px;
  border-radius: 8px;
  border: 2.5px solid #f97316;
  background: #ffffff;
  color: #f97316;
  font-size: 14px;
  font-weight: 700;
  text-align: center;
  transition: background 0.18s, color 0.18s;
}
.job-posting-tool-root .jpt-btn-primary:hover {
  background: #f97316;
  color: #fff;
}

/* ============================================================
   結果下部アクションボタン
   ============================================================ */
.job-posting-tool-root .jpt-result-actions {
  display: flex;
  flex-direction: column;
  gap: 10px;
  max-width: 560px;
  margin: 8px auto 0;
  padding: 0 16px 24px;
}
.job-posting-tool-root .jpt-btn-secondary {
  display: block;
  width: 100%;
  padding: 12px 16px;
  border-radius: 8px;
  border: 2px solid #e5e7eb;
  background: #fff;
  color: #374151;
  font-size: 14px;
  font-weight: 700;
  text-align: center;
  transition: border-color 0.15s, background 0.15s;
}
.job-posting-tool-root .jpt-btn-secondary:hover {
  border-color: #f97316;
  background: #fff8f3;
}
.job-posting-tool-root .jpt-btn-text {
  display: block;
  width: 100%;
  padding: 10px;
  border: none;
  background: transparent;
  color: #999;
  font-size: 13px;
  font-weight: 400;
  text-decoration: underline;
  text-underline-offset: 2px;
}

/* ============================================================
   レスポンシブ（ステップ画面）
   ============================================================ */
@media (max-width: 480px) {
  .job-posting-tool-root .jpt-step-line {
    max-width: 16px;
  }
  .job-posting-tool-root .jpt-page-title {
    font-size: 18px;
  }
}

/* ============================================================
   結果画面: 左右分割レイアウト
   ============================================================ */
.job-posting-tool-root .jpt-result-split {
  display: flex;
  flex-direction: row;
  align-items: stretch;
  flex: 1;
  min-height: 0;
  overflow: hidden;
}

/* 左パネル（テンプレート画像） */
.job-posting-tool-root .jpt-result-left {
  flex: 0 0 45%;
  max-width: 45%;
  height: 100%;
  overflow-y: auto;
  background: #f1f5f9;
  border-right: 1px solid #e5e7eb;
  padding: 16px;
  box-sizing: border-box;
}

/* 右パネル（編集フォーム） */
.job-posting-tool-root .jpt-result-right {
  flex: 1;
  min-width: 0;
  padding: 24px 28px 60px;
  height: 100%;
  overflow-y: auto;
  box-sizing: border-box;
}

/* ============================================================
   求人票フォーム（HTML描画）
   ============================================================ */
.job-posting-tool-root .jpt-form-a4 {
  background: #fff;
  width: 100%;
  padding: 10px 12px 16px;
  box-sizing: border-box;
}

.job-posting-tool-root .jpt-kyu-table {
  width: 100%;
  border-collapse: collapse;
  table-layout: fixed;
  font-size: 11px;
  font-family: 'Noto Sans JP', 'Hiragino Sans', 'Yu Gothic', sans-serif;
  color: #111;
}

.job-posting-tool-root .jpt-kyu-table td,
.job-posting-tool-root .jpt-kyu-table th {
  border: 1px solid #444;
  padding: 3px 5px;
  vertical-align: middle;
  word-break: break-all;
  line-height: 1.4;
}

/* タイトルセル */
.job-posting-tool-root .jpt-kyu-title {
  font-size: 16px;
  font-weight: 900;
  padding: 6px 10px;
  letter-spacing: 6px;
  border: 1px solid #444;
}

/* 汎用 */
.job-posting-tool-root .jpt-kyu-cell { }
.job-posting-tool-root .jpt-kyu-center { text-align: center; }

/* ラベル th */
.job-posting-tool-root .jpt-kyu-th {
  background: #f0f0f0;
  font-weight: 700;
  font-size: 10px;
  text-align: center;
  white-space: nowrap;
  vertical-align: middle;
}
.job-posting-tool-root .jpt-kyu-th-tall  { height: 42px; }
.job-posting-tool-root .jpt-kyu-th-tall2 { height: 54px; }
.job-posting-tool-root .jpt-kyu-th-tall3 { height: 70px; }

/* 値 td */
.job-posting-tool-root .jpt-kyu-td {
  background: #fff;
  vertical-align: top;
  padding: 4px 6px;
  min-height: 26px;
  font-size: 11px;
}
.job-posting-tool-root .jpt-kyu-td-tall  { height: 42px; vertical-align: middle; }
.job-posting-tool-root .jpt-kyu-td-tall2 { height: 54px; }
.job-posting-tool-root .jpt-kyu-td-tall3 { height: 70px; }
.job-posting-tool-root .jpt-kyu-td-sm    { font-size: 10px; vertical-align: middle; }
/* 空欄時はおおよそ1行分の高さ。長文入力時は内容に応じて伸びる */
.job-posting-tool-root .jpt-kyu-td-notes {
  height: auto;
  min-height: 1.35em;
  vertical-align: top;
  font-size: 10px;
  padding: 2px 6px;
  line-height: 1.35;
}

/* ①②③ サブラベル */
.job-posting-tool-root .jpt-kyu-sublabel {
  background: #f9f9f9;
  text-align: center;
  font-weight: 700;
  font-size: 11px;
  vertical-align: middle;
  padding: 3px 2px;
}

/* セクションヘッダー行 */
.job-posting-tool-root .jpt-kyu-section {
  background: #e0e0e0;
  font-size: 10px;
  font-weight: 700;
  padding: 3px 8px;
  border: 1px solid #444;
}

/* その他備考欄ラベル（1行に収まるようインラインで詰める） */
.job-posting-tool-root .jpt-kyu-notes-label {
  display: inline;
  font-size: 10px;
  color: #555;
  margin-right: 4px;
}

/* 各種手当 */
.job-posting-tool-root .jpt-kyu-allow-header {
  font-size: 9px;
  background: #e8e8e8;
  padding: 2px 4px;
}
/* 各種手当データ行: 点線で区切る */
.job-posting-tool-root .jpt-kyu-allow-data td {
  border-top: 1px dashed #bbb !important;
  height: 22px;
  min-height: 22px;
  padding: 2px 6px;
}
.job-posting-tool-root .jpt-kyu-allow-cell {
  vertical-align: middle;
}

/* 各種保険の小ラベル */
.job-posting-tool-root .jpt-kyu-ins-label {
  font-size: 9px;
  background: #f0f0f0;
  text-align: center;
  vertical-align: middle;
  white-space: nowrap;
}

/* フッター行（ご応募/お問合先）: 背景をやや色分け */
.job-posting-tool-root .jpt-kyu-row-footer th,
.job-posting-tool-root .jpt-kyu-row-footer td {
  background-color: #f5f5f5;
}

/* ラジオ選択の丸囲み表現 */
.job-posting-tool-root .jpt-kyu-circled {
  display: inline-block;
  border: 1.5px solid #222;
  border-radius: 1em;
  padding: 0 4px;
  font-weight: 700;
  line-height: 1.5;
}

/* クリックで右パネルにジャンプできるセル */
.job-posting-tool-root [data-focus-field] {
  cursor: pointer;
  transition: background-color 0.15s;
}
.job-posting-tool-root [data-focus-field]:hover {
  background-color: #fffbe6 !important;
  outline: 1px solid #f59e0b;
}

/* PDFボタン */
.job-posting-tool-root .jpt-left-actions {
  margin-top: 12px;
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}
.job-posting-tool-root .jpt-left-actions .jpt-btn-secondary,
.job-posting-tool-root .jpt-left-actions .jpt-btn-primary,
.job-posting-tool-root .jpt-left-actions .jpt-btn-pdf {
  width: auto;
  flex: 1 1 220px;
}

.job-posting-tool-root .jpt-btn-pdf {
  display: block;
  width: 100%;
  padding: 12px 16px;
  border-radius: 8px;
  border: 2.5px solid #f97316;
  background: #f97316;
  color: #fff;
  font-size: 14px;
  font-weight: 700;
  text-align: center;
  transition: background 0.18s;
}
.job-posting-tool-root .jpt-btn-pdf:hover {
  background: #ea580c;
  border-color: #ea580c;
}

/* ============================================================
   プレビューカード（テンプレート画像なし時）
   ============================================================ */
.job-posting-tool-root .jpt-preview-card {
  background: #fff;
  border-radius: 10px;
  box-shadow: 0 2px 10px rgba(0,0,0,0.08);
  overflow: hidden;
}
.job-posting-tool-root .jpt-preview-title {
  background: #1a1a2e;
  color: #fff;
  font-size: 14px;
  font-weight: 700;
  padding: 12px 16px;
  text-align: center;
}
.job-posting-tool-root .jpt-preview-note {
  font-size: 12px;
  color: #666;
  padding: 12px 16px 0;
  margin: 0;
  line-height: 1.6;
}
.job-posting-tool-root .jpt-preview-dl {
  margin: 0;
  padding: 12px 16px;
}
.job-posting-tool-root .jpt-preview-dl > div {
  display: grid;
  grid-template-columns: 120px 1fr;
  gap: 4px 8px;
  padding: 6px 0;
  border-bottom: 1px solid #f3f4f6;
}
.job-posting-tool-root .jpt-preview-dl > div:last-child {
  border-bottom: none;
}
.job-posting-tool-root .jpt-preview-dl dt {
  font-size: 11px;
  color: #999;
  font-weight: 700;
}
.job-posting-tool-root .jpt-preview-dl dd {
  font-size: 12px;
  color: #1a1a2e;
  margin: 0;
  word-break: break-all;
}

/* ============================================================
   結果フォーム（右パネル）
   ============================================================ */
/* p 要素（記事の h2 見出しスタイル・目次の階層に影響しない） */
.job-posting-tool-root .jpt-rf-heading {
  font-size: 18px;
  font-weight: 900;
  color: #1a1a2e;
  margin: 0 0 6px;
  line-height: 1.5;
}

.job-posting-tool-root .jpt-rf-note {
  font-size: 13px;
  color: #666;
  margin: 0 0 5px;
  line-height: 1.45;
}

/* PDF 関連の注釈（黄色マーカー風の下線で強調・行間は詰めめ） */
.job-posting-tool-root .jpt-rf-notes-hint {
  margin: 0 0 8px;
}
.job-posting-tool-root .jpt-rf-notes-hint .jpt-rf-note--marker {
  font-size: 13px;
  color: #991b1b;
  margin: 0 0 2px;
  line-height: 1.36;
  padding: 0;
  text-decoration: underline;
  text-decoration-color: rgba(255, 235, 59, 0.95);
  text-decoration-thickness: 0.42em;
  text-underline-offset: 0.08em;
  text-decoration-skip-ink: none;
}
.job-posting-tool-root .jpt-rf-notes-hint .jpt-rf-note--marker:last-child {
  margin-bottom: 0;
}

.job-posting-tool-root .jpt-rf-section {
  margin-bottom: 20px;
  border-radius: 10px;
  box-shadow: 0 2px 8px rgba(0,0,0,0.06);
  overflow: hidden;
  /* 2カラムグリッド: 1px gap が区切り線になる */
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1px;
  background: #e5e7eb;
}

.job-posting-tool-root .jpt-rf-section-title {
  grid-column: 1 / -1;
  background: #f97316;
  color: #fff;
  font-size: 13px;
  font-weight: 700;
  padding: 9px 14px;
  letter-spacing: 0.5px;
}

.job-posting-tool-root .jpt-rf-group {
  background: #fff;
  padding: 10px 12px;
  display: flex;
  flex-direction: column;
  gap: 5px;
}
/* textarea・ラジオグループ含むもの、およびhidden要素は全幅 */
.job-posting-tool-root .jpt-rf-group:has(textarea),
.job-posting-tool-root .jpt-rf-group:has(.jpt-radio-group) {
  grid-column: 1 / -1;
}
/* 昇給・賞与・各種保険・賃金形態は例外的に半幅で横並び（詳細度 0,3,0 で :has ルールに勝つ） */
.job-posting-tool-root .jpt-rf-group[data-rf-id="rf_raise"],
.job-posting-tool-root .jpt-rf-group[data-rf-id="rf_bonus"],
.job-posting-tool-root .jpt-rf-group[data-rf-id="rf_health_ins"],
.job-posting-tool-root .jpt-rf-group[data-rf-id="rf_employ_ins"],
.job-posting-tool-root .jpt-rf-group[data-rf-id="rf_salaryType"] {
  grid-column: auto;
}
.job-posting-tool-root .jpt-rf-hidden {
  display: none !important;
}

.job-posting-tool-root .jpt-rf-label {
  display: block;
  font-size: 12px;
  font-weight: 700;
  color: #374151;
}

.job-posting-tool-root .jpt-rf-input {
  width: 100%;
  padding: 9px 12px;
  border: 2px solid #e5e7eb;
  border-radius: 6px;
  background: #fff;
  color: #1a1a2e;
  font-size: 13px;
  outline: none;
  transition: border-color 0.15s, box-shadow 0.15s;
}
.job-posting-tool-root .jpt-rf-input:focus {
  border-color: #f97316;
  box-shadow: 0 0 0 3px rgba(249,115,22,0.15);
}

.job-posting-tool-root .jpt-rf-select {
  width: 100%;
  padding: 9px 12px;
  border: 2px solid #e5e7eb;
  border-radius: 6px;
  background: #fff;
  color: #1a1a2e;
  font-size: 13px;
  outline: none;
  cursor: pointer;
  transition: border-color 0.15s, box-shadow 0.15s;
  appearance: auto;
}
.job-posting-tool-root .jpt-rf-select:focus {
  border-color: #f97316;
  box-shadow: 0 0 0 3px rgba(249,115,22,0.15);
}

.job-posting-tool-root .jpt-rf-textarea {
  width: 100%;
  min-height: 80px;
  padding: 9px 12px;
  border: 2px solid #e5e7eb;
  border-radius: 6px;
  background: #fff;
  color: #1a1a2e;
  font-size: 13px;
  line-height: 1.6;
  resize: vertical;
  outline: none;
  transition: border-color 0.15s, box-shadow 0.15s;
}
.job-posting-tool-root .jpt-rf-textarea:focus {
  border-color: #f97316;
  box-shadow: 0 0 0 3px rgba(249,115,22,0.15);
}

/* ラジオボタン */
.job-posting-tool-root .jpt-radio-group {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.job-posting-tool-root .jpt-radio-label {
  display: flex;
  align-items: center;
  gap: 6px;
  cursor: pointer;
  font-size: 13px;
  color: #374151;
  padding: 6px 12px;
  border: 2px solid #e5e7eb;
  border-radius: 20px;
  transition: border-color 0.15s, background 0.15s;
}
.job-posting-tool-root .jpt-radio-label:hover {
  border-color: #f97316;
  background: #fff8f3;
}
.job-posting-tool-root .jpt-radio-label input[type="radio"] {
  accent-color: #f97316;
}
.job-posting-tool-root .jpt-radio-label:has(input:checked) {
  border-color: #f97316;
  background: #fff8f3;
  font-weight: 700;
  color: #f97316;
}

/* テキスト出力 */
.job-posting-tool-root .jpt-output-textarea {
  width: 100%;
  min-height: 200px;
  resize: vertical;
  padding: 12px;
  border: 2px solid #e5e7eb;
  border-radius: 8px;
  background: #f9fafb;
  color: #111827;
  font-size: 12px;
  line-height: 1.7;
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
  outline: none;
  transition: border-color 0.15s;
  display: block;
}
.job-posting-tool-root .jpt-output-textarea:focus {
  border-color: #f97316;
}
.job-posting-tool-root .jpt-output-actions {
  display: flex;
  gap: 8px;
  margin-top: 10px;
}
.job-posting-tool-root .jpt-output-actions .jpt-btn-primary {
  flex: 1;
}

/* ============================================================
   結果下部アクションボタン
   ============================================================ */
.job-posting-tool-root .jpt-result-actions {
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin-top: 8px;
  padding-bottom: 24px;
}

/* ============================================================
   画面幅警告バナー（769px〜1023px のみ表示）
   ============================================================ */
.job-posting-tool-root .jpt-narrow-warning {
  display: none;
  flex-shrink: 0;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 8px 16px;
  background: #fffbeb;
  border-bottom: 1px solid #fcd34d;
  font-size: 12px;
  color: #78350f;
}
@media (min-width: 769px) and (max-width: 1023px) {
  .job-posting-tool-root .jpt-narrow-warning {
    display: flex;
  }
}
.job-posting-tool-root .jpt-narrow-warning-text {
  flex: 1;
  line-height: 1.5;
}
.job-posting-tool-root .jpt-narrow-warning-btns {
  display: flex;
  gap: 6px;
  align-items: center;
  flex-shrink: 0;
}
.job-posting-tool-root .jpt-btn-narrow-fs {
  background: #f59e0b;
  color: #fff;
  border: none;
  border-radius: 4px;
  padding: 5px 12px;
  font-size: 12px;
  font-weight: 700;
  cursor: pointer;
  white-space: nowrap;
}
.job-posting-tool-root .jpt-btn-narrow-fs:hover {
  background: #d97706;
}
.job-posting-tool-root .jpt-btn-narrow-dismiss {
  background: none;
  border: none;
  color: #92400e;
  font-size: 16px;
  line-height: 1;
  padding: 2px 4px;
  cursor: pointer;
}

/* ============================================================
   結果画面: ステップバー内ボタン（PC用）
   ============================================================ */
.job-posting-tool-root .jpt-step-section--result {
  position: relative;
  display: flex;
  justify-content: center;
  align-items: center;
}
.job-posting-tool-root .jpt-step-center {
  text-align: center;
}
.job-posting-tool-root .jpt-step-bar-actions-left {
  position: absolute;
  left: 20px;
  top: 50%;
  transform: translateY(-50%);
  display: flex;
  flex-direction: row;
  gap: 8px;
  align-items: center;
}
.job-posting-tool-root .jpt-step-bar-actions {
  position: absolute;
  right: 20px;
  top: 50%;
  transform: translateY(-50%);
  display: flex;
  flex-direction: row;
  gap: 8px;
  align-items: center;
}
/* バー内ボタン共通: inline・コンパクトサイズ */
.job-posting-tool-root .jpt-btn-bar {
  display: inline-block;
  width: auto;
  padding: 8px 14px;
  font-size: 12px;
  white-space: nowrap;
}

/* ============================================================
   スマホ用レイアウト（768px以下）
   ============================================================ */
@media (max-width: 768px) {
  /* バー内ボタンを非表示（画面が狭いため） */
  .job-posting-tool-root .jpt-step-bar-actions-left,
  .job-posting-tool-root .jpt-step-bar-actions {
    display: none;
  }

  /* 左右分割 → 上下スタック */
  .job-posting-tool-root .jpt-result-split {
    flex-direction: column;
    overflow-y: auto;
    overflow-x: hidden;
  }

  /* 上段: 求人票（高さ auto、横幅 100%） */
  .job-posting-tool-root .jpt-result-left {
    flex: none;
    max-width: 100%;
    height: auto;
    overflow-y: visible;
    overflow-x: hidden;
    border-right: none;
    border-bottom: 2px solid #e5e7eb;
    padding: 6px 4px;
  }

  /* 求人票テーブルを縮小表示:
     560px で内部レイアウトし zoom で 308px に縮小 → iPhone SE (320px) 以上に収まる
     13% col = 72.8px になるため日本語ラベルが1行に収まる */
  .job-posting-tool-root .jpt-form-a4 {
    width: 560px;
    zoom: 0.55;
  }
  /* th ラベルを折り返し可・小さめフォントに */
  .job-posting-tool-root .jpt-kyu-th {
    white-space: normal;
    font-size: 9px;
  }
  .job-posting-tool-root .jpt-kyu-ins-label {
    font-size: 8px;
  }

  /* 下段: 入力フォーム（高さ auto） */
  .job-posting-tool-root .jpt-result-right {
    flex: none;
    height: auto;
    padding: 16px 12px 80px;
  }
  .job-posting-tool-root .jpt-left-actions {
    flex-direction: column;
  }
  .job-posting-tool-root .jpt-left-actions .jpt-btn-secondary,
  .job-posting-tool-root .jpt-left-actions .jpt-btn-primary,
  .job-posting-tool-root .jpt-left-actions .jpt-btn-pdf {
    width: 100%;
    flex: none;
  }
  /* スマホでは基本1カラムに戻す */
  .job-posting-tool-root .jpt-rf-section {
    grid-template-columns: 1fr;
  }
  .job-posting-tool-root .jpt-rf-group:has(textarea),
  .job-posting-tool-root .jpt-rf-group:has(.jpt-radio-group) {
    grid-column: auto;
  }
  /* 昇給・賞与セクション、保険セクションは2カラム維持して対象ペアを横並び */
  .job-posting-tool-root [data-section="各種手当・昇給"],
  .job-posting-tool-root [data-section="各種保険・福利厚生"] {
    grid-template-columns: 1fr 1fr;
  }
  /* そのセクション内のグループはデフォルト全幅 */
  .job-posting-tool-root [data-section="各種手当・昇給"] .jpt-rf-group,
  .job-posting-tool-root [data-section="各種保険・福利厚生"] .jpt-rf-group {
    grid-column: 1 / -1;
  }
  /* セクションタイトルも全幅（上書き） */
  .job-posting-tool-root [data-section="各種手当・昇給"] .jpt-rf-section-title,
  .job-posting-tool-root [data-section="各種保険・福利厚生"] .jpt-rf-section-title {
    grid-column: 1 / -1;
  }
  /* 昇給・賞与・社会保険・雇用保険のみ半幅（詳細度 0,4,0 で上の全幅ルールに勝つ） */
  .job-posting-tool-root [data-section="各種手当・昇給"] .jpt-rf-group[data-rf-id="rf_raise"],
  .job-posting-tool-root [data-section="各種手当・昇給"] .jpt-rf-group[data-rf-id="rf_bonus"],
  .job-posting-tool-root [data-section="各種保険・福利厚生"] .jpt-rf-group[data-rf-id="rf_health_ins"],
  .job-posting-tool-root [data-section="各種保険・福利厚生"] .jpt-rf-group[data-rf-id="rf_employ_ins"] {
    grid-column: auto;
    padding: 8px;
  }
  .job-posting-tool-root [data-section="各種手当・昇給"] .jpt-rf-group[data-rf-id="rf_raise"] .jpt-rf-label,
  .job-posting-tool-root [data-section="各種手当・昇給"] .jpt-rf-group[data-rf-id="rf_bonus"] .jpt-rf-label,
  .job-posting-tool-root [data-section="各種保険・福利厚生"] .jpt-rf-group[data-rf-id="rf_health_ins"] .jpt-rf-label,
  .job-posting-tool-root [data-section="各種保険・福利厚生"] .jpt-rf-group[data-rf-id="rf_employ_ins"] .jpt-rf-label {
    font-size: 11px;
  }
  .job-posting-tool-root [data-section="各種手当・昇給"] .jpt-rf-group[data-rf-id="rf_raise"] .jpt-radio-label,
  .job-posting-tool-root [data-section="各種手当・昇給"] .jpt-rf-group[data-rf-id="rf_bonus"] .jpt-radio-label,
  .job-posting-tool-root [data-section="各種保険・福利厚生"] .jpt-rf-group[data-rf-id="rf_health_ins"] .jpt-radio-label,
  .job-posting-tool-root [data-section="各種保険・福利厚生"] .jpt-rf-group[data-rf-id="rf_employ_ins"] .jpt-radio-label {
    font-size: 11px;
    padding: 5px 7px;
  }
}

/* ============================================================
   印刷（PDF出力）
   ============================================================ */
@page {
  margin: 12mm;
  size: A4;
}

@media print {
  html,
  body {
    overflow: visible !important;
  }
  /*
   * テーマのページタイトル（h1）・ヘッダー・サイドバー等を印刷から除外し、
   * プラグインの求人票ブロックだけを表示する（visibility の上書きで子は表示可）
   */
  body * {
    visibility: hidden !important;
  }
  .job-posting-tool-root,
  .job-posting-tool-root * {
    visibility: visible !important;
  }
  /* width:100% かつ absolute だと右端の罫線がクリップされることがあるため left/right で拘束 */
  .job-posting-tool-root {
    position: absolute !important;
    left: 0 !important;
    right: 0 !important;
    top: 0 !important;
    width: auto !important;
    max-width: 100% !important;
    box-sizing: border-box !important;
    margin: 0 !important;
    padding: 0 !important;
    overflow: visible !important;
  }

  /* 全画面固定を解除してフォームのみ印刷 */
  body.jpt-result-fullscreen {
    overflow: visible !important;
  }
  .job-posting-tool-root .jpt-page-outer--result {
    position: static !important;
    display: block !important;
    overflow: visible !important;
    min-height: auto !important;
    padding-bottom: 0 !important;
    background: #fff !important;
  }
  /* 狭幅警告は編集画面のみ。印刷・PDF では出さない（.job-posting-tool-root * の visibility より後） */
  .job-posting-tool-root .jpt-salary-banner,
  .job-posting-tool-root .jpt-step-section,
  .job-posting-tool-root .jpt-result-right,
  .job-posting-tool-root .jpt-left-actions,
  .job-posting-tool-root .jpt-narrow-warning,
  .job-posting-tool-root #jpt-narrow-warning {
    display: none !important;
  }
  .job-posting-tool-root .jpt-result-split {
    display: block !important;
    overflow: visible !important;
  }
  .job-posting-tool-root .jpt-result-left {
    height: auto !important;
    max-width: 100% !important;
    width: 100% !important;
    overflow: visible !important;
    /* 右端の罫線がページ境界で欠けるのを防ぐためわずかに内側へ */
    padding: 0 3px 0 2px !important;
    border: none !important;
    background: #fff !important;
    box-sizing: border-box !important;
  }
  /* フォームテーブルを印刷用にリセット */
  .job-posting-tool-root .jpt-form-a4 {
    padding: 0 !important;
    zoom: 1 !important;
    width: 100% !important;
    max-width: 100% !important;
    box-sizing: border-box !important;
    overflow: visible !important;
    -webkit-print-color-adjust: exact !important;
    print-color-adjust: exact !important;
  }
  .job-posting-tool-root .jpt-kyu-th {
    white-space: nowrap !important;
    font-size: 10px !important;
  }
  .job-posting-tool-root .jpt-kyu-table {
    font-size: 10pt !important;
    color: #000 !important;
    border-collapse: collapse !important;
    table-layout: fixed !important;
    width: 100% !important;
    max-width: 100% !important;
    box-sizing: border-box !important;
    -webkit-print-color-adjust: exact !important;
    print-color-adjust: exact !important;
  }
  /* border-color だけだと PDF エンジンによっては線が抜けるため solid を明示 */
  .job-posting-tool-root .jpt-kyu-table td,
  .job-posting-tool-root .jpt-kyu-table th {
    border: 1px solid #000 !important;
  }
  .job-posting-tool-root .jpt-kyu-title {
    border: 1px solid #000 !important;
    font-size: 18pt !important;
  }
}

/* ============================================================
   ステップドット アニメーション（「次へ」押下時のみ発火）
   ============================================================ */
.job-posting-tool-root .jpt-step-dots.jpt-animate .jpt-step-dot.done {
  animation: jpt-dot-fill 0.35s ease both;
}
.job-posting-tool-root .jpt-step-dots.jpt-animate .jpt-step-dot.current {
  animation: jpt-dot-activate 0.4s ease both;
}
.job-posting-tool-root .jpt-step-dots.jpt-animate .jpt-step-line.done {
  animation: jpt-line-fill 0.25s ease both;
}

@keyframes jpt-dot-fill {
  0%   { transform: scale(0.5); background: #fff; border-color: #e0e0e0; color: transparent; }
  60%  { transform: scale(1.2); }
  100% { transform: scale(1);   background: #f97316; border-color: #f97316; color: #fff; }
}

@keyframes jpt-fade-out {
  0%   { opacity: 0; transform: scale(1.02); }
  100% { opacity: 1; transform: scale(1); }
}

@keyframes jpt-fade-in {
  0%   { opacity: 0; transform: translateY(8px); }
  100% { opacity: 1; transform: translateY(0); }
}

@keyframes jpt-spin {
  from { transform: rotate(0deg); }
  to   { transform: rotate(360deg); }
}

@keyframes jpt-dot-activate {
  0%   { transform: scale(0.6); box-shadow: none; }
  65%  { transform: scale(1.15); }
  100% { transform: scale(1);   box-shadow: 0 0 0 4px rgba(249,115,22,0.2); }
}

@keyframes jpt-line-fill {
  0%   { background: #e0e0e0; }
  100% { background: #f97316; }
}
