/* 工場事務。共通部品に加える、このページの表示。 */
#fv .jimu-key-data { grid-column: 1 / -1; order: 6; }
#fv .fv-photo-block { order: 8; min-width: 0; }
#fv .jimu-key-data .grid2 { align-items: stretch; }
.jimu-key-data .kpi { color: var(--color-navy); font-weight: 700; font-size: var(--font-note); line-height: 1.7; }
.jimu-key-data .big { margin-top: 12px; color: var(--color-navy); font-size: 32px; font-weight: 700; font-variant-numeric: tabular-nums; line-height: 1.3; }
.jimu-key-data .card > .small { margin-top: 12px; }
table[data-table-kind="bairitsu"] .hl > * { background: var(--color-accent-bg); font-weight: 700; }
table[data-table-kind="bairitsu"] td.n { white-space: nowrap; }
table[data-table-kind="koyou"] th:first-child { width: 6em; }
#faq .ex { margin-block: 16px; padding: 16px; border-left: 3px solid var(--color-border); background: var(--color-bg-alt); }

.ratio-figure, .process-figure, .checks-figure, .employment-figure { min-width: 0; padding: 20px; border: 1px solid var(--color-border); border-radius: var(--radius-card); background: var(--color-bg); }
.figure-title { color: var(--color-navy); font-size: 18px; line-height: 1.65; font-weight: 700; }
.ratio-legend { display: grid; gap: 12px; margin-block: 20px; font-size: 14px; }
.ratio-legend > p { display: flex; align-items: center; gap: 10px; margin: 0; }
.reference-key { display: inline-block; flex: 0 0 24px; width: 24px; border-top: 1px solid var(--color-navy); }
.reference-key.balance { border-top: 2px dashed var(--color-navy); }
.ratio-grid { --row-height: 166px; display: grid; grid-template-columns: minmax(0, 1.05fr) minmax(0, 1.1fr); padding-right: 56px; gap: 8px; }
.ratio-labels { display: grid; grid-template-rows: repeat(6, var(--row-height)); }
.ratio-label, .ratio-value { display: flex; align-items: center; margin: 0; font-size: 14px; line-height: 1.7; }
.ratio-label.highlighted, .ratio-value.highlighted { font-weight: 700; color: var(--color-navy); }
.ratio-value { position: absolute; left: calc(var(--bar-size) + 8px); top: 50%; z-index: 3; transform: translateY(-50%); padding-inline: 2px; background: white; white-space: nowrap; font-variant-numeric: tabular-nums; }
.ratio-plot { display: grid; grid-template-rows: repeat(6, var(--row-height)); position: relative; min-width: 0; }
.ratio-reference { position: absolute; inset-block: 0; left: var(--ref-position); border-left: 1px solid #7b8490; z-index: 2; pointer-events: none; }
.ratio-reference.balance { border-left: 2px dashed var(--color-navy); }
.ratio-band { display: flex; position: relative; align-items: center; min-width: 0; border-bottom: 1px solid var(--color-border); }
.ratio-bar { display: block; flex: 0 0 var(--bar-size); width: var(--bar-size); height: 18px; background: #b8cbe1; }
.ratio-bar.highlighted { background: var(--color-navy); outline: 2px solid var(--color-navy); outline-offset: 2px; }
.ratio-figure > .src { margin-top: 20px; }
.jimu-salary-chart .chart-item { display: block; padding-right: 88px; }
.jimu-salary-chart .chart-pair { gap: 20px; }
.jimu-salary-chart .chart-track { display: block; position: relative; }
.jimu-salary-chart .chart-value { position: absolute; top: 50%; left: calc(var(--bar-size) + 8px); transform: translateY(-50%); background: white; padding-inline: 2px; }

.process-legend { display: flex; flex-wrap: wrap; gap: 24px; margin-bottom: 24px; font-size: 14px; }
.process-legend > p { display: flex; align-items: center; gap: 8px; margin: 0; }
.process-key { display: block; width: 28px; height: 18px; }
.office { color: white; background: var(--color-navy); border: 2px solid var(--color-navy); }
.floor { color: var(--color-navy); background: var(--color-accent-bg); border: 1px solid #8a929e; }
.process-box.external { color: var(--color-navy); background: white; border: 1px solid var(--color-border); }
.process-flow { display: grid; grid-template-columns: minmax(0, 1fr); gap: 24px; list-style: none; margin: 0; padding: 0; }
.process-stage { position: relative; min-width: 0; }
.process-box { display: flex; align-items: center; justify-content: center; min-height: 72px; padding: 16px; border-radius: 8px; text-align: center; font-size: 16px; line-height: 1.7; }
.process-arrow { position: absolute; top: 100%; left: 50%; width: 1px; height: 24px; background: var(--color-navy); }
.process-arrow::after { content: ""; position: absolute; bottom: 2px; left: -4px; width: 9px; height: 9px; border-right: 1px solid var(--color-navy); border-bottom: 1px solid var(--color-navy); transform: rotate(45deg); }
.checks-list { display: grid; gap: 0; list-style: none; margin: 0; padding: 0; }
.checks-list > li { display: grid; grid-template-columns: 40px minmax(0, 1fr); gap: 16px; align-items: center; padding-block: 16px; }
.checks-list > li + li { border-top: 1px solid var(--color-border); }
.check-icon { width: 40px; height: 40px; color: var(--color-navy); }

.employment-columns { display: grid; grid-template-columns: minmax(0, 1fr); gap: 32px; }
.employment-column { min-width: 0; padding: 16px; border: 1px solid var(--color-border); border-radius: 8px; background: var(--color-bg-alt); }
.employment-heading { margin-bottom: 20px; font-size: 16px; line-height: 1.7; color: var(--color-navy); }
.relationship-box { min-width: 0; padding: 16px 12px; border: 1px solid var(--color-control-border); border-radius: 8px; background: white; text-align: center; font-size: 14px; line-height: 1.7; }
.relationship-box > p + p { margin-top: 4px; }
.relationship-box.employer { border: 2px solid var(--color-navy); }
.relationship-box.workplace { background: var(--color-accent-bg); }
.relationship-arrow { display: flex; align-items: center; justify-content: center; gap: 12px; height: 64px; }
.relationship-arrow > span { position: relative; display: block; width: 1px; height: 48px; background: var(--color-navy); }
.relationship-arrow > span::after { content: ""; position: absolute; bottom: 1px; left: -4px; width: 9px; height: 9px; border-right: 1px solid var(--color-navy); border-bottom: 1px solid var(--color-navy); transform: rotate(45deg); }
.relationship-arrow.employment > span::before { content: ""; position: absolute; top: 1px; left: -4px; width: 9px; height: 9px; border-left: 1px solid var(--color-navy); border-top: 1px solid var(--color-navy); transform: rotate(45deg); }
.relationship-arrow > p { margin: 0; font-size: 14px; }
.relationship-note { margin-top: 20px; }
.jimu-career .learning-stage .small { font-size: 14px; }

@media (max-width: 767px) {
  table[data-table-kind="nenshu"] { min-width: 0; table-layout: fixed; }
  table[data-table-kind="nenshu"] th:first-child { width: 3.8em; }
  table[data-table-kind="nenshu"] .n { text-align: left; }
  table[data-table-kind="nenshu"] .salary-amount, table[data-table-kind="nenshu"] .salary-age { display: block; white-space: nowrap; }
  table[data-table-kind="nenshu"] .salary-age { margin-top: 4px; }
}
@media (min-width: 768px) {
  #fv .fv-photo-block { grid-area: 4 / 2 / 5 / 3; }
  #fv .jimu-key-data { grid-area: 5 / 1 / 6 / -1; margin-top: 0; }
  #fv .fv-badges { grid-area: 6 / 1 / 7 / -1; }
  #fv .cta { grid-area: 7 / 1 / 8 / -1; }
  #fv .honest { grid-area: 8 / 1 / 9 / -1; }
  .ratio-grid { --row-height: 96px; grid-template-columns: 270px minmax(0, 1fr); padding-right: 80px; gap: 16px; }
  .process-flow { grid-template-columns: repeat(7, minmax(0, 1fr)); gap: 20px; }
  .process-box { min-height: 122px; padding: 12px 8px; font-size: 14px; }
  .process-arrow { top: 50%; left: 100%; width: 20px; height: 1px; }
  .process-arrow::after { top: -4px; bottom: auto; left: auto; right: 2px; transform: rotate(-45deg); }
  .employment-columns { grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 12px; }
  .employment-column { padding: 12px; }
  .employment-heading { min-height: 110px; }
  .relationship-box.employer { min-height: 110px; }
  .relationship-box.workplace { min-height: 130px; }
  #flow > .stack { max-width: var(--width-wide); grid-template-columns: repeat(6, minmax(0, 1fr)); gap: 16px; }
  #flow .step { display: flex; flex-direction: column; align-items: center; gap: 16px; padding: 0; }
  #flow .step > .num { position: relative; z-index: 2; }
  #flow .step > div { width: 100%; padding: 0; }
  #flow .step .h3 { min-height: 6.8em; font-size: 14px; line-height: 1.7; }
  #flow .step p { font-size: 14px; }
  #flow .step:not(:last-child)::after { top: 20px; left: calc(50% + 20px); bottom: auto; width: calc(100% - 24px); height: 0; border-left: 0; border-top: 1px solid var(--color-border); }
}
@media print {
  .ratio-grid, .process-stage, .employment-column { break-inside: avoid; }
}

/* 雇われ方の表は5列あるので、スマホでは枠の中で横にスクロール */
@media (max-width: 767px) { table[data-table-kind="koyou"] { min-width: 560px; } }
