/* 求人一覧・絞り込みページの統計 (user/job/common/market_stats.blade.php) */
.ks_stats {
  margin: 40px 0;
  padding: 32px 28px;
  background: #fff;
  border-radius: 20px;
  color: #414141;
  font-family: "Noto Sans JP", sans-serif;
}
.ks_stats_title {
  margin: 0 0 14px;
  font-size: 22px;
  font-weight: 700;
  line-height: 1.5;
  color: #111;
}
.ks_stats_title small {
  display: block;
  margin-top: 2px;
  font-size: 13px;
  font-weight: 500;
  color: #777;
}
.ks_stats_lead {
  margin: 0 0 20px;
  font-size: 14px;
  line-height: 1.9;
}
.ks_stats_lead strong {
  color: #111;
}
.ks_stats_tiles {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 10px;
  margin: 0 0 28px;
  padding: 0;
  list-style: none;
}
.ks_stats_tiles_3 {
  grid-template-columns: repeat(3, 1fr);
  margin-bottom: 18px;
}
.ks_stats_tiles li {
  padding: 14px 12px;
  border-radius: 12px;
  background: #fff4e6;
  text-align: center;
}
.ks_stats_tile_label {
  display: block;
  font-size: 12px;
  color: #666;
}
.ks_stats_tile_value {
  display: block;
  margin-top: 4px;
  font-size: 26px;
  font-weight: 700;
  line-height: 1.2;
  color: #111;
}
.ks_stats_tile_value small {
  margin-left: 2px;
  font-size: 13px;
  font-weight: 500;
}
.ks_stats_block {
  margin: 0 0 32px;
}
.ks_stats_h3 {
  margin: 0 0 6px;
  padding-left: 12px;
  border-left: 4px solid #e86f00;
  font-size: 17px;
  font-weight: 700;
  line-height: 1.5;
  color: #111;
}
.ks_stats_note {
  margin: 0 0 12px;
  font-size: 12px;
  color: #777;
}

/* 横棒グラフ (単色。値は棒の先、同じ数字は表にもある) */
.ks_bars {
  margin: 0 0 14px;
  padding: 0;
  list-style: none;
}
.ks_bar_row {
  position: relative;
  display: grid;
  grid-template-columns: 9em 1fr;
  align-items: center;
  gap: 10px;
  padding: 3px 0;
  border-radius: 6px;
  outline: none;
}
.ks_bar_row:hover,
.ks_bar_row:focus-visible {
  background: #f7f6f4;
}
.ks_bar_label {
  overflow: hidden;
  font-size: 13px;
  text-align: right;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.ks_bar_label a {
  color: inherit;
  text-decoration: underline;
}
.ks_bar_track {
  display: flex;
  align-items: center;
  gap: 6px;
  min-width: 0;
  border-left: 1px solid #e3e1dd;
}
.ks_bar {
  display: block;
  height: 18px;
  max-width: calc(100% - 7em);
  border-radius: 0 4px 4px 0;
  background: #e86f00;
}
.ks_bar_value {
  flex-shrink: 0;
  font-size: 12px;
  font-weight: 700;
  color: #414141;
  white-space: nowrap;
}
.is_current .ks_bar {
  background: #a34c00;
}
.ks_bar_row.is_current .ks_bar_label {
  font-weight: 700;
}

/* ホバー・フォーカスで出す説明 */
[data-tip]:hover::after,
[data-tip]:focus-visible::after {
  content: attr(data-tip);
  position: absolute;
  z-index: 5;
  bottom: calc(100% + 4px);
  left: 50%;
  transform: translateX(-50%);
  padding: 5px 9px;
  border-radius: 6px;
  background: #222;
  color: #fff;
  font-size: 12px;
  font-weight: 500;
  white-space: nowrap;
  pointer-events: none;
}

/* 縦棒 (月別の新着) */
.ks_columns {
  display: flex;
  align-items: flex-end;
  gap: 8px;
  height: 160px;
  margin: 0 0 8px;
  padding: 0 4px;
  border-bottom: 1px solid #e3e1dd;
}
.ks_column {
  position: relative;
  display: flex;
  flex: 1;
  flex-direction: column;
  align-items: center;
  justify-content: flex-end;
  height: 100%;
  outline: none;
}
.ks_column_bar {
  display: block;
  width: 24px;
  max-width: 70%;
  border-radius: 4px 4px 0 0;
  background: #e86f00;
}
.ks_column_value {
  margin-bottom: 4px;
  font-size: 12px;
  font-weight: 700;
}
.ks_column_label {
  position: absolute;
  bottom: -20px;
  font-size: 11px;
  color: #777;
  white-space: nowrap;
}
.ks_columns + .ks_stats_note {
  margin-top: 28px;
}

/* 表 */
.ks_table_wrap {
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
}
.ks_table {
  width: 100%;
  min-width: 460px;
  border-collapse: collapse;
  font-size: 13px;
}
.ks_table th,
.ks_table td {
  padding: 9px 10px;
  border-bottom: 1px solid #eeece8;
  text-align: right;
  white-space: nowrap;
}
.ks_table thead th {
  background: #f7f6f4;
  font-size: 12px;
  font-weight: 700;
  color: #555;
}
.ks_table th:first-child {
  text-align: left;
}
.ks_table tbody th {
  font-weight: 500;
}
.ks_table tbody th a {
  color: #c45a00;
  text-decoration: underline;
}
.ks_table tr.is_current {
  background: #fff4e6;
}
.ks_table_cross td {
  text-align: center;
}
.ks_heat_0 { color: #aaa; }
.ks_heat_1 { background: #fff1e3; }
.ks_heat_2 { background: #ffd2a6; }
.ks_heat_3 { background: #ffad5c; }
.ks_heat_4 { background: #e86f00; color: #fff; font-weight: 700; }
.ks_stats_source {
  margin: 0;
  font-size: 11px;
  color: #999;
}

@media only screen and (max-width: 640px) {
  .ks_stats {
    margin: 28px 0;
    padding: 22px 14px;
    border-radius: 14px;
  }
  .ks_stats_title {
    font-size: 18px;
  }
  .ks_stats_tiles {
    grid-template-columns: repeat(2, 1fr);
  }
  .ks_stats_tiles_3 {
    grid-template-columns: repeat(3, 1fr);
  }
  .ks_stats_tile_value {
    font-size: 21px;
  }
  .ks_bar_row {
    grid-template-columns: 6.5em 1fr;
  }
  .ks_bar_label {
    font-size: 12px;
  }
}

/* ===== 求人詳細「この仕事に就いたら」(user/job/detail/decision_stats.blade.php) ===== */
.ks_decision .ks_stats_block {
  margin-top: 26px;
}
.ks_decision_text {
  margin: 0 0 12px;
  font-size: 14px;
  line-height: 1.85;
}
.ks_decision_text strong {
  color: #111;
}
.ks_decision_text .ks_up {
  color: #c45a00;
}
.ks_bars_wide .ks_bar_row {
  grid-template-columns: 13em 1fr;
}
.ks_bars_wide .ks_bar_label {
  white-space: normal;
  line-height: 1.4;
}
.ks_table_compare th:first-child {
  min-width: 12em;
  white-space: normal;
}
.ks_table_compare td {
  text-align: left;
}
.ks_table_kv {
  min-width: 0;
}
.ks_table_kv th {
  width: 8em;
  background: #f7f6f4;
  font-weight: 700;
  vertical-align: top;
}
.ks_table_kv th,
.ks_table_kv td {
  text-align: left;
  white-space: normal;
}
.ks_table_kv a {
  color: #c45a00;
  text-decoration: underline;
}

/* 1日の勤務スケジュール */
.ks_schedule {
  margin: 0 0 18px;
  padding: 14px 16px;
  border-radius: 12px;
  background: #fbfaf8;
}
.ks_schedule_head {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  margin: 0 0 10px;
  font-size: 15px;
  font-weight: 700;
  color: #111;
}
.ks_schedule_badge {
  padding: 2px 8px;
  border-radius: 999px;
  background: #fff4e6;
  color: #c45a00;
  font-size: 12px;
}
.ks_schedule_work {
  margin-left: auto;
  font-size: 12px;
  font-weight: 500;
  color: #666;
}
.ks_schedule_bar {
  display: flex;
  gap: 2px;
  height: 16px;
  margin: 0 0 10px;
}
.ks_schedule_seg {
  display: block;
  height: 100%;
}
.ks_schedule_seg.is_work {
  background: #e86f00;
}
.ks_schedule_seg.is_work:first-child {
  border-radius: 4px 0 0 4px;
}
.ks_schedule_seg.is_work:last-child {
  border-radius: 0 4px 4px 0;
}
.ks_schedule_seg.is_work:only-child {
  border-radius: 4px;
}
.ks_schedule_seg.is_break {
  background: repeating-linear-gradient(45deg, #d9d6d0 0 4px, #f1efeb 4px 8px);
}
.ks_schedule_points {
  display: flex;
  justify-content: space-between;
  gap: 8px;
  margin: 0;
  padding: 0;
  list-style: none;
  font-size: 13px;
}
.ks_schedule_points li {
  display: flex;
  flex-direction: column;
}
.ks_schedule_points li:nth-child(2):not(:last-child) {
  align-items: center;
  text-align: center;
}
.ks_schedule_points li:last-child {
  align-items: flex-end;
  text-align: right;
}
.ks_schedule_time {
  font-size: 15px;
  font-weight: 700;
  color: #111;
}

/* 業務フロー */
.ks_flow {
  display: flex;
  flex-wrap: wrap;
  gap: 10px 26px;
  margin: 0 0 10px;
  padding: 0;
  list-style: none;
}
.ks_flow_step {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: flex-start;
  gap: 8px;
  max-width: 100%;
  padding: 10px 14px;
  border: 2px solid #e86f00;
  border-radius: 10px;
  background: #fff;
  font-size: 14px;
  font-weight: 700;
  line-height: 1.5;
  color: #111;
}
.ks_flow_step.is_edge {
  border-color: #e3e1dd;
  background: #f7f6f4;
  font-weight: 500;
}
.ks_flow_step:not(:last-child)::after {
  content: "";
  position: absolute;
  top: 50%;
  right: -19px;
  width: 0;
  height: 0;
  border-top: 7px solid transparent;
  border-bottom: 7px solid transparent;
  border-left: 9px solid #e86f00;
  transform: translateY(-50%);
}
.ks_flow_num {
  display: inline-flex;
  flex-shrink: 0;
  align-items: center;
  justify-content: center;
  width: 22px;
  height: 22px;
  border-radius: 50%;
  background: #e86f00;
  color: #fff;
  font-size: 12px;
}
.is_edge .ks_flow_num {
  background: #999;
}

/* 応募から就業までの流れ */
.ks_steps {
  display: flex;
  margin: 0 0 14px;
  padding: 0;
  list-style: none;
  counter-reset: none;
}
.ks_step {
  position: relative;
  display: flex;
  flex: 1;
  flex-direction: column;
  align-items: center;
  gap: 6px;
  padding: 0 4px;
  text-align: center;
}
.ks_step::before {
  content: "";
  position: absolute;
  top: 14px;
  left: 50%;
  width: 100%;
  height: 2px;
  background: #ffd2a6;
  z-index: 0;
}
.ks_step:last-child::before {
  display: none;
}
.ks_step_num {
  position: relative;
  z-index: 1;
  padding: 5px 10px;
  border-radius: 999px;
  background: #e86f00;
  color: #fff;
  font-size: 11px;
  font-weight: 700;
}
.ks_step:last-child .ks_step_num {
  background: #a34c00;
}
.ks_step_text {
  font-size: 14px;
  font-weight: 700;
  color: #111;
}

@media only screen and (max-width: 640px) {
  .ks_bars_wide .ks_bar_row {
    grid-template-columns: 8.5em 1fr;
  }
  .ks_flow {
    flex-direction: column;
    gap: 22px;
  }
  .ks_flow_step:not(:last-child)::after {
    top: auto;
    right: auto;
    bottom: -18px;
    left: 24px;
    border-top: 9px solid #e86f00;
    border-right: 7px solid transparent;
    border-bottom: 0;
    border-left: 7px solid transparent;
    transform: none;
  }
  .ks_steps {
    flex-direction: column;
    gap: 10px;
  }
  .ks_step {
    flex-direction: row;
    gap: 10px;
    text-align: left;
  }
  .ks_step::before {
    display: none;
  }
}

.ks_flow_text,
.ks_step_text {
  text-align: left;
}
.ks_step_text {
  text-align: center;
}
@media only screen and (max-width: 640px) {
  .ks_step_text {
    text-align: left;
  }
}

/* 表のリンクの左のアイコン (App\Support\StatsIcons) */
.ks_table tbody th a {
  display: inline-flex;
  align-items: center;
  gap: 6px;
}
.ks_ico {
  flex-shrink: 0;
  width: 16px;
  height: 16px;
  fill: none;
  stroke: #e86f00;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
}

/* 見出しの下の関連サイト (Google のクローラーにだけ出す) */
.ks_stats_sites {
  margin: 4px 0 14px;
  padding: 10px 14px;
  border-radius: 10px;
  background: #f7f6f4;
  font-size: 13px;
}
.ks_stats_sites_title {
  margin: 0 0 6px;
  font-weight: 700;
}
.ks_stats_sites_list {
  margin: 0;
  padding-left: 1.4em;
}
.ks_stats_sites_list li {
  margin: 4px 0;
  line-height: 1.6;
}
.ks_stats_sites_list a {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  color: #c45a00;
  text-decoration: underline;
  word-break: break-all;
}
.ks_stats_sites_list span {
  display: block;
  color: #777;
  font-size: 12px;
}

/* 表のリンクの下の関連サイト */
.ks_table th .ks_stats_sites {
  min-width: 22em;
  margin: 8px 0 2px;
  white-space: normal;
  font-weight: 400;
}
