/*
 * Smart Contents ブランドガイドライン v1.0 に合わせた画面の見た目。
 * 余白・高さは 4px の倍数。色・文字・角丸は :root の値だけを使う（画面ごとに色や余白を足さない）。
 */
:root {
  /* ブランドの色 */
  --teal-50: #ecf8fa; --teal-100: #cfedf1; --teal-500: #159ead; --teal-600: #0e8694; --teal-700: #016471; --teal-800: #07505a;
  --n-0: #fff; --n-25: #fafbfb; --n-50: #f6f7f7; --n-100: #eceded; --n-200: #dcdede; --n-300: #c2c5c5; --n-500: #6e7373; --n-600: #545858; --n-700: #3e4040; --n-800: #2c2d2d;
  /* 役割ごとの色（画面の中の style 属性からも使うので、名前は変えない） */
  --bg: var(--n-25); --card: var(--n-0); --surface-2: var(--n-50); --chip: var(--n-100); --line: var(--n-100); --line-strong: var(--n-200);
  --ink: var(--n-800); --mute: var(--n-600); --faint: var(--n-500);
  --pri: var(--teal-700); --pri-dark: var(--teal-800); --pri-soft: var(--teal-50);
  --ok: #13744d; --ok-soft: #e7f6ef; --ng: #b4282d; --ng-soft: #fbe9e8; --ng-fill: #c7353a;
  --warn: #7a5200; --warn-soft: #fbf1dc; --star: #c98a14;
  --radius-sm: 6px; --radius: 10px; --radius-lg: 14px;
  --shadow: 0 1px 2px rgba(12, 20, 22, .06); --shadow-lg: 0 12px 32px rgba(12, 20, 22, .16), 0 2px 6px rgba(12, 20, 22, .08);
  --ease: cubic-bezier(.4, 0, .2, 1);
  --font: "Noto Sans JP", "Hiragino Kaku Gothic ProN", "Hiragino Sans", "Yu Gothic UI", "Yu Gothic", Meiryo, system-ui, sans-serif;
  --font-display: "Poppins", var(--font);
  --font-mono: "Roboto Mono", ui-monospace, "SF Mono", Menlo, Consolas, monospace;
  --side-w: 240px;
}
* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; background: var(--bg); color: var(--ink); font: 400 14px/24px var(--font); overflow-wrap: anywhere; }
a { color: var(--pri); text-decoration-thickness: 1px; text-underline-offset: 3px; text-decoration-color: color-mix(in srgb, currentColor 36%, transparent); transition: text-decoration-color .12s var(--ease), color .12s var(--ease); }
a:hover { text-decoration-color: currentColor; }
/* 一覧や表の中のリンクは、下線を出さず色と太さで示す（行が下線だらけにならないように）。重ねたときに下線を出す */
.list a, td a, th a, .kv a, .app-card a, .summary a { text-decoration: none; }
.list a:hover, td a:hover, .kv a:hover, .app-card a:hover { text-decoration: underline; }
h1, h2, h3 { margin: 0 0 8px; font-weight: 700; }
h1 { font: 700 24px/32px var(--font-display); margin-bottom: 24px; }
h2 { font-size: 16px; line-height: 24px; }
h3 { font-size: 14px; line-height: 24px; }
h1 small, h2 small, h3 small { font: 400 13px/20px var(--font); margin-left: 8px; }
p { margin: 0 0 12px; }
small, .mute { color: var(--mute); }
small, .small { font-size: 13px; line-height: 20px; }
code { font: 13px/20px var(--font-mono); background: var(--n-50); border-radius: 4px; padding: 0 4px; }
hr { border: 0; border-top: 1px solid var(--line); margin: 16px 0; }
:focus-visible { outline: 2px solid var(--teal-500); outline-offset: 2px; border-radius: 4px; }

/* ---------- 枠組み（管理画面） ---------- */
.demo-bar { background: var(--warn-soft); color: var(--warn); border-bottom: 1px solid #efdcae; text-align: center; font-size: 12px; line-height: 16px; padding: 8px 16px; }
.app { display: grid; grid-template-columns: var(--side-w) minmax(0, 1fr); min-height: 100vh; }
.menu-toggle { position: absolute; opacity: 0; pointer-events: none; }
.app-top { display: none; }
.side { background: var(--teal-50); border-right: 1px solid var(--teal-100); padding: 24px 16px 16px; display: flex; flex-direction: column; gap: 24px; position: sticky; top: 0; height: 100vh; overflow-y: auto; }
.brand { display: flex; flex-direction: column; gap: 8px; padding: 0 8px; text-decoration: none; color: var(--mute); font-size: 12px; line-height: 16px; font-weight: 500; }
.brand img { height: 32px; width: auto; align-self: flex-start; display: block; }
.side-nav { display: grid; gap: 24px; }
.nav-group h2 { font: 500 12px/16px var(--font); color: var(--mute); padding: 0 12px; margin: 0 0 8px; }
.nav-group ul { list-style: none; margin: 0; padding: 0; display: grid; gap: 4px; }
.nav-group a { display: flex; align-items: center; justify-content: space-between; gap: 8px; min-height: 40px; padding: 8px 12px; border-radius: var(--radius); color: var(--ink); text-decoration: none; font-weight: 500; line-height: 24px; transition: background-color .12s var(--ease), color .12s var(--ease); }
.nav-group a:hover { background: var(--teal-100); color: var(--teal-800); }
.nav-group a.on { background: var(--teal-700); color: var(--n-0); font-weight: 700; }
.nav-group a.on .dot { box-shadow: 0 0 0 2px var(--teal-700); }
.dot { display: inline-block; min-width: 20px; height: 20px; padding: 0 6px; border-radius: 999px; background: var(--ng-fill); color: #fff; font: 700 12px/20px var(--font-display); text-align: center; flex: none; }
.side .who { margin-top: auto; border-top: 1px solid var(--teal-100); padding: 16px 12px 0; display: grid; gap: 4px; font-size: 13px; line-height: 20px; }
.side .who b { font-weight: 500; }
.who-links { display: flex; flex-wrap: wrap; gap: 4px 16px; }
.inline { display: inline; }
.linkbtn { background: none; border: 0; color: var(--pri); padding: 0; font: inherit; cursor: pointer; text-decoration: underline; text-decoration-thickness: 1px; text-underline-offset: 3px; text-decoration-color: color-mix(in srgb, currentColor 36%, transparent); }
.linkbtn:hover { text-decoration-color: currentColor; }
.wrap { width: 100%; max-width: 1280px; margin: 0 auto; padding: 32px; min-width: 0; }
.wrap.wide { max-width: none; }
body.admin .wrap { max-width: 1600px; margin: 0; }
details.card:not([open]) { padding-top: 12px; padding-bottom: 12px; }
.narrow { max-width: 720px; }
.tabbar { display: none; }

@media (max-width: 1023px) {
  .app { display: block; padding-bottom: 0; }
  .app-top { display: flex; align-items: center; justify-content: space-between; gap: 16px; height: 56px; padding: 0 16px; background: var(--card); border-bottom: 1px solid var(--line); position: sticky; top: 0; z-index: 20; }
  .app-top .brand { padding: 0; flex-direction: row; align-items: center; }
  .app-top .brand img { height: 24px; }
  .menu-btn { display: inline-flex; align-items: center; height: 40px; padding: 0 16px; border: 1px solid var(--line-strong); border-radius: var(--radius); font-weight: 700; cursor: pointer; margin: 0; font-size: 14px; }
  .menu-toggle:focus-visible ~ .app-top .menu-btn { outline: 2px solid var(--teal-500); outline-offset: 2px; }
  /* メニューは、開いたときだけ本文の代わりに出す（重ねて出さないので、見出しの帯やデモの帯を隠さない） */
  .side { display: none; position: static; height: auto; border-right: 0; padding: 16px; min-height: calc(100vh - 56px); }
  .side > .brand { display: none; }
  .menu-toggle:checked ~ .side { display: flex; }
  .menu-toggle:checked ~ .wrap { display: none; }
  .wrap { padding: 24px 16px; }
}
@media (max-width: 639px) {
  .app { padding-bottom: 72px; }
  .tabbar { display: grid; grid-auto-flow: column; grid-auto-columns: 1fr; gap: 4px; position: fixed; left: 0; right: 0; bottom: 0; z-index: 25; background: var(--card); border-top: 1px solid var(--line); padding: 8px 8px calc(8px + env(safe-area-inset-bottom)); }
  .tabbar a, .tabbar label { display: flex; align-items: center; justify-content: center; gap: 4px; min-height: 48px; border-radius: var(--radius); font-size: 12px; line-height: 16px; font-weight: 500; color: var(--n-600); text-decoration: none; margin: 0; cursor: pointer; white-space: nowrap; }
  .tabbar a.on { background: var(--teal-50); color: var(--teal-700); font-weight: 700; }
  .tabbar .dot { min-width: 16px; height: 16px; font-size: 11px; line-height: 16px; padding: 0 4px; }
  .app-top .menu-btn { display: none; }
  .side { min-height: calc(100vh - 128px); }
  h1 { font-size: 20px; line-height: 28px; margin-bottom: 16px; }
  h2 small { display: block; margin-left: 0; }
}

/* ---------- 枠組み（公開ページ・応募者マイページ） ---------- */
body:not(.admin) { font-size: 16px; line-height: 28px; }
body:not(.admin) .wrap { max-width: 1120px; }
body:not(.admin) .wrap.narrow { max-width: 720px; }
body:not(.admin) small, body:not(.admin) .small { font-size: 14px; line-height: 24px; }
.langbar { display: flex; justify-content: flex-end; gap: 8px; max-width: 1120px; margin: 0 auto; padding: 8px 32px 0; }
.langbar a, .auth-foot a, .top-lang a { display: inline-flex; align-items: center; min-height: 32px; padding: 0 16px; border: 1px solid var(--line-strong); border-radius: 999px; background: var(--card); color: var(--n-700); font-size: 13px; line-height: 20px; font-weight: 500; text-decoration: none; }
.langbar a:hover, .auth-foot a:hover, .top-lang a:hover { border-color: var(--teal-500); color: var(--teal-700); }
.top { background: var(--card); border-bottom: 1px solid var(--line); position: sticky; top: 0; z-index: 20; }
.langbar + .top { margin-top: 8px; }
.top-lang { display: flex; gap: 8px; flex: none; }
.top-in { max-width: 1120px; margin: 0 auto; min-height: 64px; padding: 8px 32px; display: flex; align-items: center; gap: 24px; }
.top .brand { flex-direction: row; align-items: center; gap: 12px; padding: 0; flex: none; }
.top .brand img { height: 28px; align-self: center; }
.top .brand small { font-size: 13px; line-height: 20px; font-weight: 500; color: var(--mute); white-space: nowrap; }
.nav { display: flex; gap: 4px; margin-left: auto; min-width: 0; }
.nav a { display: inline-flex; align-items: center; gap: 8px; min-height: 40px; padding: 0 16px; border-radius: var(--radius); color: var(--n-700); text-decoration: none; font-size: 14px; line-height: 20px; font-weight: 500; white-space: nowrap; position: relative; transition: background-color .12s var(--ease), color .12s var(--ease); }
.nav a:hover { background: var(--n-50); }
.nav a.on { background: var(--teal-50); color: var(--teal-700); font-weight: 700; }
.nav .ico { width: 20px; height: 20px; flex: none; }
.top .who { font-size: 13px; line-height: 20px; color: var(--mute); white-space: nowrap; min-width: 0; overflow: hidden; text-overflow: ellipsis; flex: 0 1 auto; }
.has-tabs .nav { flex: none; }
footer.foot { text-align: center; color: var(--mute); font-size: 13px; line-height: 24px; padding: 32px 16px 48px; }
footer.foot a, footer.foot .linkbtn { color: var(--n-700); }
@media (max-width: 760px) {
  .langbar { padding: 8px 16px 0; }
  .top-in { padding: 8px 16px; gap: 12px; flex-wrap: wrap; row-gap: 4px; min-height: 56px; }
  .top .brand img { height: 24px; }
  body:not(.admin) .wrap { padding: 24px 16px; }
  /* 公開ページ：メニューはロゴの下の段に置く */
  body:not(.has-tabs) .nav { margin-left: -8px; width: calc(100% + 16px); overflow-x: auto; scrollbar-width: none; }
  footer.foot { padding-bottom: 32px; }
}
/* マイページ：1024px 未満では、メニューを画面の下に固定し、印と文字で示す（上の段には、ロゴ・氏名・言語だけを置く） */
@media (max-width: 1023px) {
  body.has-tabs { padding-bottom: 88px; }
  .has-tabs .top .who { margin-left: auto; }
  .has-tabs .nav { position: fixed; left: 0; right: 0; bottom: 0; z-index: 30; margin: 0; display: grid; grid-auto-flow: column; grid-auto-columns: minmax(0, 1fr); gap: 4px; background: var(--card); border-top: 1px solid var(--line); padding: 8px 8px calc(8px + env(safe-area-inset-bottom)); }
  .has-tabs .nav a { flex-direction: column; justify-content: center; gap: 4px; min-height: 56px; padding: 4px 0; font-size: 11px; line-height: 16px; }
  .has-tabs .nav a .ico { width: 24px; height: 24px; }
  .has-tabs .nav a .lbl { max-width: 100%; overflow: hidden; text-overflow: ellipsis; }
  .has-tabs .nav a .dot { position: absolute; top: 2px; left: calc(50% + 4px); min-width: 16px; height: 16px; padding: 0 4px; font-size: 11px; line-height: 16px; box-shadow: 0 0 0 2px var(--card); }
  .has-tabs .nav.n6 a { font-size: 10px; letter-spacing: -.02em; }
  html:not([lang="ja"]) .has-tabs .nav.n6 a { font-size: 9px; letter-spacing: -.03em; }
  .has-tabs .top-in { flex-wrap: nowrap; }
}
/* マイページ：1024〜1279px は、上の段にメニューが並びきるよう間隔を詰め、氏名は出さない（氏名はホームの見出しにある） */
@media (min-width: 1024px) and (max-width: 1279px) {
  .has-tabs .top-in { gap: 12px; }
  .has-tabs .top .brand small, .has-tabs .top .who { display: none; }
  .has-tabs .nav a { padding: 0 10px; gap: 6px; }
}
@media (min-width: 1280px) {
  .has-tabs .top-in { max-width: 1240px; gap: 16px; }
  .has-tabs .nav a { padding: 0 12px; }
}
@media (max-width: 480px) {
  .has-tabs .top .brand small { display: none; }
  .top-lang a { padding: 0 12px; }
}

/* ---------- 公開ページの部品 ---------- */
/* 公開ページのトップ：囲みのない見出しと紹介文 */
.intro { padding: 16px 0 32px; }
.intro h1 { font-size: 28px; line-height: 40px; margin-bottom: 12px; }
.intro p { max-width: 46em; }
@media (max-width: 639px) { .intro { padding: 8px 0 24px; } .intro h1 { font-size: 22px; line-height: 32px; } }
.steps { counter-reset: st; list-style: none; padding: 0; margin: 0; display: grid; gap: 12px; }
.steps li { counter-increment: st; display: flex; gap: 12px; align-items: flex-start; }
.steps li::before { content: counter(st); flex: none; width: 28px; height: 28px; border-radius: 50%; background: var(--teal-700); color: #fff; font: 700 13px/1 var(--font-display); display: grid; place-items: center; }
/* 募集職種の一覧：職種名がリンク */
.job-link { font: 700 18px/28px var(--font); color: var(--teal-700); text-decoration: none; }
.job-link:hover { text-decoration: underline; }
/* 長い文章（個人情報の取扱いなど） */
.prose { font-size: 17px; line-height: 30px; max-width: 42em; }

/* ---------- 応募者マイページの部品 ---------- */
.stepper { list-style: none; padding: 0; margin: 0; }
.stepper li { display: grid; grid-template-columns: 28px minmax(0, 1fr) auto; gap: 12px; align-items: start; padding: 12px 0; }
.stepper li + li { border-top: 1px solid var(--line); }
.stepper .n { width: 28px; height: 28px; border-radius: 50%; display: grid; place-items: center; font: 700 13px/1 var(--font-display); background: var(--n-100); color: var(--n-600); }
.stepper .cur .n { background: var(--teal-700); color: #fff; }
.stepper .pass .n { background: var(--ok); color: #fff; }
.stepper .fail .n { background: var(--ng-fill); color: #fff; }
.stepper .t { font-weight: 700; }
.stepper .future .t, .stepper .future small { color: var(--mute); font-weight: 500; }
.stepper .fb { grid-column: 2 / -1; background: var(--n-50); border-radius: var(--radius); padding: 8px 12px; font-size: 14px; line-height: 24px; }
/* 「次にやること」は、枠の色で目立たせる */
.card.todo { border-color: var(--teal-500); }
.card.todo > h2 { color: var(--teal-700); }
/* マイページのホーム：顔写真・氏名・応募職種の見出し */
.my-head { display: flex; align-items: center; gap: 16px; margin-bottom: 24px; }
.my-head h1 { overflow-wrap: anywhere; }
@media (max-width: 480px) { .my-head { gap: 12px; } .my-head .avatar { width: 48px; height: 48px; font-size: 18px; } }
/* 次にやること。2件以上のときは番号を付ける */
.todo-list { list-style: none; margin: 0; padding: 0; counter-reset: todo; }
.todo-list.numbered .todo-item > span { counter-increment: todo; display: grid; grid-template-columns: 24px minmax(0, 1fr); gap: 8px; flex: 1 1 280px; }
.todo-list.numbered .todo-item > span::before { content: counter(todo); width: 24px; height: 24px; border-radius: 50%; display: grid; place-items: center; background: var(--teal-50); color: var(--teal-700); font: 700 12px/1 var(--font-display); margin-top: 2px; }
.todo-item { display: flex; gap: 12px; align-items: center; justify-content: space-between; padding: 12px 0; flex-wrap: wrap; }
.todo-item + .todo-item { border-top: 1px solid var(--line); }
.todo-item:last-child { padding-bottom: 0; }
.card.ivbox { border-color: var(--teal-500); }
/* マイページの面接：1次面接の回ごとの希望順位 */
.pick-list { list-style: none; margin: 0 0 16px; padding: 0; }
.pick-list li { display: flex; justify-content: space-between; align-items: center; gap: 8px 16px; padding: 12px 0; border-bottom: 1px solid var(--line); }
.pick-list li > span { display: grid; min-width: 0; }
.pick-list select { width: auto; min-width: 9em; flex: none; }
/* 最終面接の候補日時（第n希望・日付・開始時刻） */
.wish-row { display: grid; grid-template-columns: 5em minmax(0, 1fr) minmax(0, 10em); gap: 8px; align-items: center; margin-bottom: 8px; }
.wish-no { font-size: 14px; line-height: 20px; color: var(--n-700); white-space: nowrap; }
/* 候補の中から1つ選ぶ（押せる範囲を行全体にする） */
.choices { border: 0; margin: 0 0 16px; padding: 0; min-width: 0; }
.choices legend { padding: 0; margin-bottom: 8px; }
.choice { display: flex; gap: 12px; align-items: center; min-height: 48px; padding: 8px 16px; border: 1px solid var(--line-strong); border-radius: var(--radius); margin-bottom: 8px; cursor: pointer; font-weight: 400; }
.choice input { margin: 0; flex: none; }
.choice:hover { border-color: var(--teal-500); }
.choice:has(input:checked) { border-color: var(--teal-500); background: var(--teal-50); }
@media (max-width: 480px) {
  .pick-list li { flex-wrap: wrap; }
  .pick-list select { width: 100%; }
  .wish-row { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); }
  .wish-no { grid-column: 1 / -1; }
}
.ivtime { font: 700 20px/28px var(--font-display); }
.mail-log small { display: block; }

/* ---------- メニューのない1枚の画面（ログインなど） ---------- */
.auth { min-height: 100vh; display: grid; grid-template-columns: minmax(0, 400px); justify-content: center; align-content: center; gap: 24px; padding: 32px 16px; }
.auth .brand { align-items: center; padding: 0; }
.auth .brand img { height: 40px; align-self: center; }
.auth .card { margin: 0; padding: 32px; }
.auth h1 { font-size: 20px; line-height: 28px; margin-bottom: 4px; }
.auth h1 + p { margin-bottom: 24px; }
.auth-foot { text-align: center; margin: 0; }
.auth-legal { text-align: center; margin: 0; font-size: 13px; line-height: 20px; }
.auth-legal a { color: var(--n-700); }
.auth .brand small { font-size: 13px; line-height: 20px; font-weight: 500; }
input.pin { max-width: 200px; font: 700 24px/32px var(--font-display); letter-spacing: .4em; text-align: center; }
@media (max-width: 639px) { .auth .card { padding: 24px 16px; } }

/* ---------- 区画・並べ方 ---------- */
.card { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius-lg); padding: 24px; box-shadow: var(--shadow); margin-bottom: 24px; }
/* 区画どうしの間は 24px にそろえる。並べた区画は、すき間（gap）だけで離す */
.wrap > .grid { gap: 24px; margin-bottom: 24px; }
.grid > .card { margin-bottom: 0; }
.card > h2 { margin-bottom: 16px; }
.card > h2 + p.small, .card > h2 + p.mute { margin-top: -8px; margin-bottom: 16px; }
/* 開閉だけの区画（顔写真など）は、閉じているときに間延びしないようにする */
details.card { padding: 12px 24px; }
details.card > summary { margin: 0; }
details.card[open] > summary { margin-bottom: 12px; }
/* 区画の中の区画は、枠を重ねず、薄い地色にする */
.card .card { background: var(--surface-2); border-color: transparent; box-shadow: none; border-radius: var(--radius); padding: 16px; margin-bottom: 12px; }
.card .card:last-child { margin-bottom: 0; }
.card > h2:first-child, .card > h3:first-child { margin-top: 0; }
@media (max-width: 639px) { .card { padding: 16px; } }
.card > :last-child { margin-bottom: 0; }
.card > h2 + p.empty { margin: 0; }
.card > p.actions { margin-top: 16px; }
/* 最優先で対応するものの区画。枠の色と見出しの印で区別する */
.card.attention { border-color: #efc7c8; }
.card.attention > h2 { color: var(--ng); }
.card.attention > h2 small { color: var(--mute); }
.star-mark { color: var(--star); }
/* 件数のまとめ（1行に並べる。数字は入口のリンク） */
.summary { display: grid; grid-template-columns: repeat(6, minmax(0, 1fr)); background: var(--card); border: 1px solid var(--line); border-radius: var(--radius-lg); box-shadow: var(--shadow); margin-bottom: 24px; overflow: hidden; }
.summary .kpi { padding: 16px 24px; border-left: 1px solid var(--line); margin-left: -1px; }
.summary .kpi:hover { background: var(--n-25); }
.summary.s4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.summary.s5 { grid-template-columns: repeat(5, minmax(0, 1fr)); }
.summary.s3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
@media (max-width: 1279px) { .summary.s5 { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
@media (max-width: 639px) { .summary.s4, .summary.s5 { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
div.kpi b { color: var(--n-500); }
@media (max-width: 1279px) { .summary { grid-template-columns: repeat(3, minmax(0, 1fr)); } .summary .kpi { border-top: 1px solid var(--line); margin-top: -1px; } }
@media (max-width: 639px) { .summary { grid-template-columns: repeat(2, minmax(0, 1fr)); } .summary .kpi { padding: 12px 16px; } }
.grid { display: grid; gap: 16px; }
/* 列の数は画面の幅で決める（中身の長さで列の数が変わらないように） */
.g2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.g3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.g4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }
@media (max-width: 1023px) { .g3, .g4 { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 639px) { .g2, .g3 { grid-template-columns: minmax(0, 1fr); } }
/* 並んだ入力欄は、見出しの行数が違っても、入力欄の位置をそろえる */
.grid > .field { display: flex; flex-direction: column; justify-content: flex-end; margin-bottom: 0; }
.row { display: flex; gap: 12px; align-items: center; flex-wrap: wrap; }
.between { justify-content: space-between; }
.grow { flex: 1; min-width: 0; }
/* マイページの書類：ファイルを選ぶ欄とアップロードのボタン。スマホでは、ボタンを下の段に全幅で置く */
.upload-row { display: flex; gap: 8px 12px; align-items: center; }
@media (max-width: 480px) { .upload-row { flex-wrap: wrap; } .upload-row > .grow { flex-basis: 100%; } .upload-row > .btn { width: 100%; } }
.stack > * + * { margin-top: 12px; }
.nowrap { white-space: nowrap; }
.pre { white-space: pre-wrap; }

/* ---------- 余白などの小さな調整（4px の倍数だけ。画面の中に style 属性を書く代わりに使う） ---------- */
.m0 { margin: 0 !important; } .p0 { padding: 0 !important; }
.mt0 { margin-top: 0 !important; } .mt4 { margin-top: 4px !important; } .mt8 { margin-top: 8px !important; } .mt12 { margin-top: 12px !important; } .mt16 { margin-top: 16px !important; }
.mb4 { margin-bottom: 4px !important; } .mb8 { margin-bottom: 8px !important; } .mb12 { margin-bottom: 12px !important; }
.my4 { margin-top: 4px !important; margin-bottom: 4px !important; } .my8 { margin-top: 8px !important; margin-bottom: 8px !important; }
.w-auto { width: auto !important; } .wrap-text { white-space: normal; } .flat { box-shadow: none !important; } .text-ng { color: var(--ng); }
.sep { padding: 8px 0; border-top: 1px solid var(--line); }
textarea.ta-sm { min-height: 56px; } textarea.ta-md { min-height: 120px; } textarea.ta-lg { min-height: 208px; }
.ta-sm:not(textarea), .ta-md:not(textarea), .ta-lg:not(textarea) { min-height: 56px; }
/* 応募者ページの見出し：左に顔写真と氏名、右に状態 */
.profile-head { display: flex; justify-content: space-between; align-items: flex-start; gap: 16px 24px; flex-wrap: wrap; }
.profile-head h1 { margin: 0 0 4px; }
.profile-head > .row { align-items: flex-start; }
.profile-head > .row:last-child { gap: 8px; }
/* 応募者ページ：1200px 以上は左に項目の一覧を固定し、それより狭いときは上に横並び */
@media (min-width: 1200px) {
  .detail { display: grid; grid-template-columns: 160px minmax(0, 1fr); gap: 24px; align-items: start; }
  .detail > .chips { flex-direction: column; gap: 2px; overflow: visible; padding: 0; margin: 0; top: 24px; background: none; }
  .detail > .chips a { min-height: 32px; padding: 0 12px; border: 0; border-radius: var(--radius); background: none; }
  .detail > .chips { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius-lg); padding: 8px; box-shadow: var(--shadow); }
  .detail > .chips a { color: var(--n-700); }
  .detail > .chips a:hover { background: var(--teal-50); color: var(--teal-700); }
  .detail [id] { scroll-margin-top: 24px; }
}
.danger-zone { border-color: #efc7c8; }
.danger-zone h2, .danger-zone > summary { color: var(--ng); }
.audit-list li { display: flex; gap: 12px; align-items: baseline; flex-wrap: wrap; }
.audit-list time { color: var(--mute); font-variant-numeric: tabular-nums; min-width: 8em; }
.doc-table th { width: 9em; }
.field-date { max-width: 260px; }
.field-narrow { max-width: 220px; }
textarea.ta-xl { min-height: 300px; }
.wd-row { gap: 4px 12px; flex-wrap: wrap; }
.crit-table { min-width: 680px; }
.crit-table th:first-child { width: 15em; } .crit-table th:nth-child(2), .crit-table th:nth-child(3) { width: 6.5em; }

/* ---------- ボタン・入力 ---------- */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 44px; padding: 8px 20px; border-radius: 11px; border: 1px solid var(--line-strong); background: var(--card); color: var(--ink); font: 700 14px/20px var(--font); text-decoration: none; cursor: pointer; white-space: nowrap; transition: background-color .12s var(--ease), border-color .12s var(--ease); }
.btn:hover { background: var(--n-50); border-color: var(--n-300); }
.btn:active { background: var(--n-100); }
.btn-pri { background: var(--teal-700); border-color: var(--teal-700); color: #fff; }
.btn-pri:hover, .btn-pri:active { background: var(--teal-800); border-color: var(--teal-800); }
.btn-ng { color: var(--ng); border-color: #efc7c8; }
.btn-ng:hover { background: var(--ng-soft); border-color: var(--ng); }
.btn-danger { background: var(--ng-fill); border-color: var(--ng-fill); color: #fff; }
.btn-danger:hover { background: var(--ng); border-color: var(--ng); }
.btn-sm { min-height: 36px; padding: 6px 12px; border-radius: var(--radius); font-size: 13px; }
.btn-block { width: 100%; }
.btn[disabled] { opacity: .5; cursor: default; }
@media (pointer: coarse) { .btn-sm { min-height: 44px; padding: 8px 16px; } }
label { display: block; font-weight: 500; font-size: 13px; line-height: 20px; color: var(--n-700); margin-bottom: 4px; }
label .opt { font-weight: 400; color: var(--mute); }
input[type=text], input[type=email], input[type=tel], input[type=password], input[type=number], input[type=url], input[type=datetime-local], input[type=date], input[type=time], input[type=search], select, textarea {
  width: 100%; min-height: 44px; padding: 8px 12px; border: 1px solid var(--line-strong); border-radius: var(--radius); background: var(--card); color: var(--ink); font: 400 14px/24px var(--font);
  transition: border-color .12s var(--ease), box-shadow .12s var(--ease);
}
input:hover, select:hover, textarea:hover { border-color: var(--n-300); }
input:focus, select:focus, textarea:focus { outline: 2px solid var(--teal-500); outline-offset: 0; border-color: var(--teal-500); }
::placeholder { color: var(--n-500); opacity: 1; }
input[readonly], textarea[readonly] { background: var(--n-50); }
input[type=checkbox], input[type=radio] { accent-color: var(--teal-700); width: 16px; height: 16px; }
select { appearance: none; -webkit-appearance: none; padding-right: 36px; background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath d='M1 1.5l5 5 5-5' fill='none' stroke='%236e7373' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E"); background-repeat: no-repeat; background-position: right 12px center; }
textarea { min-height: 96px; resize: vertical; }
/* 日付・時刻の入力欄：ほかの入力欄と同じ高さ・文字にそろえ、カレンダーの印を押しやすくする */
input[type=date], input[type=datetime-local], input[type=time] { color-scheme: light; font-variant-numeric: tabular-nums; -webkit-appearance: none; appearance: none; text-align: left; }
input[type=date] { min-width: 168px; } input[type=datetime-local] { min-width: 232px; } input[type=time] { min-width: 120px; }
input::-webkit-datetime-edit { padding: 0; line-height: 24px; }
input::-webkit-datetime-edit-fields-wrapper { padding: 0; }
input::-webkit-date-and-time-value { text-align: left; min-height: 24px; }
input::-webkit-calendar-picker-indicator { cursor: pointer; padding: 6px; margin: -6px -6px -6px 4px; border-radius: 6px; opacity: .64; }
input::-webkit-calendar-picker-indicator:hover { opacity: 1; background-color: var(--n-100); }
input[type=number] { font-variant-numeric: tabular-nums; }
select { text-overflow: ellipsis; cursor: pointer; }
select:disabled, input:disabled, textarea:disabled { background: var(--n-50); color: var(--mute); cursor: not-allowed; }
/* 候補日時など、日時の入力欄を並べるときは、欄の幅を保って折り返す */
.grid:has(> input[type=datetime-local]) { grid-template-columns: repeat(auto-fill, minmax(232px, 1fr)); gap: 12px 16px; }
input[type=file] { width: 100%; font: inherit; font-size: 13px; color: var(--mute); }
input[type=file]::file-selector-button { font: 700 13px/20px var(--font); color: var(--ink); padding: 8px 16px; margin-right: 12px; border: 1px solid var(--line-strong); border-radius: var(--radius); background: var(--card); cursor: pointer; }
input[type=file]::file-selector-button:hover { background: var(--n-50); }
input.num-in { min-width: 72px; padding-left: 8px; padding-right: 4px; text-align: center; font-variant-numeric: tabular-nums; }
/* フォームの中は、上から 16px ずつ離す（項目ごとに余白を書かない） */
.field { margin: 0; }
form:not(.row):not(.inline):not(.filters) > * + *, .field + .field { margin-top: 16px; }
form > input[type=hidden] + * { margin-top: 0 !important; }
form:not(.row):not(.inline):not(.filters) > label + * { margin-top: 0; }
form:not(.row):not(.inline):not(.filters):not(.upload-row) > .btn, form:not(.row):not(.inline):not(.filters):not(.upload-row) > .row:last-child { margin-top: 24px; }
.check { display: flex; gap: 8px; align-items: flex-start; font-weight: 400; font-size: 14px; line-height: 24px; color: var(--ink); }
.check input { margin: 4px 0 0; flex: none; }
.hp { position: absolute; left: -9999px; }
/* 画面の見出し：左に題名、右にその画面の主な操作 */
.page-head { display: flex; justify-content: space-between; align-items: center; gap: 16px 24px; flex-wrap: wrap; margin-bottom: 24px; }
.page-head h1 { margin: 0; }
/* 絞り込み：1段目に条件、2段目に「★のみ」と実行ボタン */
.filters { display: grid; grid-template-columns: minmax(0, 1.6fr) repeat(5, minmax(0, 1fr)); gap: 16px; align-items: end; }
.filters label { margin-bottom: 8px; }
.filters > .check { grid-column: 1 / span 5; align-self: center; margin: 0; }
.filters > .btn { grid-column: 6; }
@media (max-width: 1279px) {
  .filters { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .filters > .check { grid-column: 1 / span 2; } .filters > .btn { grid-column: 3; }
}
/* 検索欄には虫めがねの印を入れる。いま効いている条件は、下に1行でまとめて見せる */
input[type=search] { padding-left: 40px; background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' viewBox='0 0 24 24' fill='none' stroke='%236e7373' stroke-width='2.2' stroke-linecap='round'%3E%3Ccircle cx='11' cy='11' r='7'/%3E%3Cpath d='m20 20-3.6-3.6'/%3E%3C/svg%3E"); background-repeat: no-repeat; background-position: 14px center; }
.filter-active { grid-column: 1 / -1; display: flex; align-items: center; flex-wrap: wrap; gap: 8px; margin: 0; padding-top: 16px; border-top: 1px solid var(--line); font-size: 13px; line-height: 24px; }
.filter-active a { margin-left: 8px; }
@media (max-width: 639px) {
  .filters { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
  .filters > :first-child { grid-column: 1 / -1; }
  .filters > .check { grid-column: 1; } .filters > .btn { grid-column: 2; }
}
.copybox { display: flex; gap: 8px; }
.copybox input { font-size: 13px; }

/* ---------- 状態の表示 ---------- */
.badge { display: inline-flex; align-items: center; min-height: 24px; padding: 0 10px; border-radius: 999px; font: 700 12px/16px var(--font); background: var(--n-100); color: var(--n-700); white-space: nowrap; vertical-align: top; }
.b-pri { background: var(--teal-50); color: var(--teal-700); }
/* 状態を表す印には、色だけに頼らないよう、文字の前に小さな丸を付ける */
.badge.b-pri::before, .badge.b-ok::before, .badge.b-ng::before, .badge.b-warn::before { content: ""; width: 6px; height: 6px; border-radius: 50%; background: currentColor; margin-right: 6px; flex: none; }
.badge.lg-new::before, .dot::before { content: none; }
/* ランク：A（最上位）から D まで。文字で分かるので丸は付けない */
.badge.rank { min-width: 24px; justify-content: center; padding: 0 6px; font-family: var(--font-display); }
.rank-a { background: var(--teal-700); color: #fff; } .rank-b { background: var(--teal-100); color: var(--teal-800); }
.rank-c { background: var(--warn-soft); color: var(--warn); } .rank-d { background: var(--n-100); color: var(--n-700); }
.score { display: inline-flex; align-items: center; gap: 2px; white-space: nowrap; font-variant-numeric: tabular-nums; }
.score b { font-family: var(--font-display); }
.score .badge { margin-left: 4px; }
.b-ok { background: var(--ok-soft); color: var(--ok); }
.b-ng { background: var(--ng-soft); color: var(--ng); }
.b-warn { background: var(--warn-soft); color: var(--warn); }
.flash { background: var(--ok-soft); color: var(--ok); border: 1px solid #b9e3cf; padding: 12px 16px; border-radius: var(--radius); margin-bottom: 24px; font-weight: 700; }
.flash.err { background: var(--ng-soft); color: var(--ng); border-color: #efc7c8; }
.note { background: var(--teal-50); border: 1px solid var(--teal-100); border-radius: var(--radius); padding: 12px 16px; margin-bottom: 16px; }
.note.warn { background: var(--warn-soft); border-color: #efdcae; color: var(--warn); }
.note.ng { background: var(--ng-soft); border-color: #efc7c8; color: var(--ng); }
.card > .note:last-child, .note > :last-child { margin-bottom: 0; }
.days { font-weight: 700; font-variant-numeric: tabular-nums; }
.days.red { color: var(--ng); } .days.amber { color: var(--warn); }
.gap { color: var(--ng); font-size: 12px; font-weight: 700; letter-spacing: 1px; cursor: help; }
.star { background: none; border: 0; cursor: pointer; font-size: 20px; line-height: 24px; color: var(--n-300); padding: 8px; min-width: 40px; min-height: 40px; border-radius: var(--radius); transition: color .12s var(--ease), background-color .12s var(--ease); }
.star:hover { background: var(--n-50); color: var(--star); }
.star.on { color: var(--star); }
.avatar-sm { width: 32px; height: 32px; border-radius: 50%; background: var(--teal-50); color: var(--teal-700); display: inline-grid; place-items: center; font: 700 13px/1 var(--font); flex: none; }
.who-cell { display: flex; align-items: flex-start; gap: 12px; min-width: 0; }
.who-cell > div { min-width: 0; }
.avatar { width: 64px; height: 64px; border-radius: 50%; object-fit: cover; background: var(--n-100); color: var(--mute); display: inline-grid; place-items: center; font: 700 24px/1 var(--font-display); flex: none; }

/* ---------- 一覧・表 ---------- */
.list { list-style: none; margin: 0; padding: 0; }
.list > li { padding: 12px 0; }
.list > li + li { border-top: 1px solid var(--line); }
.list > li.row { align-items: flex-start; flex-wrap: nowrap; }
.list > li.row > .days, .list > li.row > .badge { flex: none; }
.list > li:first-child { padding-top: 0; } .list > li:last-child { padding-bottom: 0; }
.kv { display: grid; grid-template-columns: max-content minmax(0, 1fr); gap: 8px 24px; margin: 0; }
.kv dt { color: var(--n-700); font-weight: 500; white-space: nowrap; }
.kv dd { margin: 0; }
/* マイページ・公開ページのスマホ表示：見出しと内容を縦に並べ、内容の幅を確保する */
@media (max-width: 480px) { body:not(.admin) .kv { grid-template-columns: minmax(0, 1fr); gap: 0; } body:not(.admin) .kv dd { margin-bottom: 12px; } body:not(.admin) .kv dd:last-child { margin-bottom: 0; } }
.kpi { text-decoration: none; color: inherit; display: block; transition: border-color .12s var(--ease); }
.kpi:hover { border-color: var(--teal-500); }
.kpi b { display: block; font: 700 24px/32px var(--font-display); }
.kpi span { font-size: 13px; line-height: 20px; color: var(--mute); font-weight: 500; }
.kpi.alert b { color: var(--ng); }
.kpi.warn b { color: var(--warn); }
.tbl-wrap { overflow-x: auto; }
table { border-collapse: collapse; width: 100%; font-size: 14px; line-height: 24px; }
th, td { text-align: left; padding: 12px; border-bottom: 1px solid var(--line); vertical-align: top; }
th { background: var(--n-50); color: var(--n-700); font-weight: 500; font-size: 12px; line-height: 16px; white-space: nowrap; border-bottom-color: var(--line-strong); }
tbody tr { transition: background-color .12s var(--ease); }
tbody tr:hover > td { background: var(--teal-50); }
tr:last-child > td { border-bottom: 0; }
td.num, th.num { text-align: right; font-variant-numeric: tabular-nums; white-space: nowrap; }
td.nowrap { white-space: nowrap; }
th a.sort { color: inherit; text-decoration: none; display: inline-flex; align-items: center; gap: 4px; border-radius: 4px; cursor: pointer; }
th a.sort:hover { color: var(--teal-700); }
th a.sort { padding: 2px 4px; margin: -2px -4px; }
th a.sort:hover { background: var(--n-100); }
th a.sort .arrow { font-size: 9px; opacity: .4; }
th a.sort.on { color: var(--teal-700); font-weight: 700; background: var(--teal-50); }
th a.sort.on .arrow { opacity: 1; }
.apps { display: none; }
.apps-table { padding: 0; overflow: hidden; }
.apps-table > p { padding: 12px 24px; margin: 0; }
.apps-table > p:first-child { border-bottom: 1px solid var(--line); }
/* 列の幅を決めておく（文字が1字ずつ折り返さないように）。画面が狭いときは、表を横に送る */
.apps-table table { min-width: 1120px; table-layout: fixed; }
.apps-table th { white-space: normal; }
.apps-table th:nth-child(1) { width: 56px; } .apps-table th:nth-child(2) { width: 208px; } .apps-table th:nth-child(3) { width: 104px; }
.apps-table th:nth-child(5) { width: 200px; } .apps-table th:nth-child(6) { width: 160px; }
.apps-table th:nth-child(7) { width: 168px; } .apps-table th:nth-child(8) { width: 88px; }
.who-cell a, .who-cell small { display: block; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.who-cell br { display: none; }
.who-cell .gap { display: block; line-height: 12px; }
.apps-table td.small { font-size: 14px; line-height: 24px; }
.apps-table .star { margin: -8px 0; }
.apps-table th:first-child, .apps-table td:first-child { padding-left: 16px; }
.apps-table th:last-child, .apps-table td:last-child { padding-right: 24px; }
@media (max-width: 760px) {
  .apps-table { display: none; }
  .apps { display: block; }
}
.app-card { display: grid; grid-template-columns: auto 1fr; gap: 4px 8px; }
.app-card a.name { font-weight: 700; text-decoration: none; }
.chips { scrollbar-width: none; display: flex; gap: 8px; overflow-x: auto; padding: 8px 0; margin-bottom: 8px; position: sticky; top: 0; background: var(--bg); z-index: 10; }
.chips a { flex: none; display: inline-flex; align-items: center; min-height: 36px; padding: 0 16px; border-radius: 999px; background: var(--card); border: 1px solid var(--line-strong); text-decoration: none; font-size: 13px; font-weight: 500; color: var(--n-600); transition: border-color .12s var(--ease), color .12s var(--ease); }
.chips a:hover { border-color: var(--teal-500); color: var(--teal-700); }
section[id] { scroll-margin-top: 64px; }
@media (max-width: 1023px) { .chips { top: 56px; } section[id] { scroll-margin-top: 120px; } }
.scores { display: grid; grid-template-columns: repeat(auto-fit, minmax(192px, 1fr)); gap: 12px 16px; }
.scorebox { text-align: center; padding: 12px; border-radius: var(--radius); background: var(--n-50); }
.scorebox b { display: block; font: 700 24px/32px var(--font-display); }
details > summary { cursor: pointer; font-weight: 700; padding: 8px 4px 8px 24px; position: relative; list-style: none; border-radius: var(--radius-sm); transition: color .12s var(--ease); }
details > summary::-webkit-details-marker { display: none; }
details > summary::before { content: ""; position: absolute; left: 6px; top: 50%; width: 6px; height: 6px; border-right: 2px solid var(--n-500); border-bottom: 2px solid var(--n-500); transform: translateY(-60%) rotate(-45deg); transition: transform .2s var(--ease); }
details[open] > summary::before { transform: translateY(-75%) rotate(45deg); }
details > summary:hover { color: var(--teal-700); }
details[open] > summary { margin-bottom: 8px; }
summary > .row { display: flex; width: 100%; }

/* ---------- メッセージ ---------- */
.thread { max-height: 56vh; overflow-y: auto; display: flex; flex-direction: column; gap: 12px; padding: 4px; }
.msg { max-width: 86%; padding: 12px 16px; border-radius: var(--radius-lg); background: var(--n-100); }
.msg .meta { display: block; font-size: 12px; line-height: 16px; color: var(--mute); margin-top: 4px; }
.msg.mine { align-self: flex-end; background: var(--teal-700); color: #fff; }
.msg.mine .meta, .msg.mine a { color: var(--teal-100); }
.msg.sys { align-self: center; background: var(--warn-soft); color: var(--warn); font-size: 13px; line-height: 20px; max-width: 96%; }

/* ---------- 面接調整 ---------- */
.sc-table { font-size: 13px; line-height: 20px; }
.sc-table th, .sc-table td { border: 1px solid var(--line); padding: 8px; }
.sc-table tr:last-child > td { border-bottom: 1px solid var(--line); }
.sc-table tr.sc-end > td, .sc-table tr.sc-end > th { background: var(--n-50); color: var(--mute); }
.sc-table td.sc-note { min-width: 224px; }
.sc-table td.sc-st { min-width: 10em; }
.sc-table td.sc-inv { min-width: 7em; }
.sc-table details > summary { font-weight: 500; color: var(--teal-700); }
.sc-p { white-space: nowrap; }
.sc-p + .sc-p { margin-top: 4px; }
.sc-p form { margin-left: 4px; }
.sc-sub { font-size: 12px; line-height: 16px; color: var(--mute); font-weight: 400; white-space: nowrap; }
.sc-box { background: var(--n-50); border: 1px solid var(--line); border-radius: var(--radius); padding: 12px; margin: 8px 0; min-width: 304px; }
.sc-late { color: var(--ng); font-weight: 700; }
.sc-matrix th { text-align: center; white-space: nowrap; font-weight: 500; }
.sc-matrix tbody th { text-align: left; position: sticky; left: 0; z-index: 1; background: var(--n-50); }
.sc-matrix td { min-width: 92px; text-align: center; }
/* 凡例どおり：灰＝実施済み、黄＝確定、赤枠＝返事待ち */
.sc-matrix td.sc-done, .sc-key.sc-done { background: #e1e4e4; }
.sc-matrix td.sc-conf, .sc-key.sc-conf { background: #fbe9a8; outline: 2px solid var(--ng-fill); outline-offset: -2px; }
.sc-matrix td.sc-wait, .sc-key.sc-wait { outline: 2px solid var(--ng-fill); outline-offset: -2px; }
.sc-key { display: inline-block; padding: 0 8px; border-radius: 4px; font-size: 12px; }
.seg { display: inline-flex; flex-wrap: wrap; gap: 4px; padding: 4px; background: var(--n-100); border-radius: var(--radius); }
.seg a { padding: 6px 12px; border-radius: 8px; font-size: 13px; line-height: 20px; font-weight: 500; color: var(--n-700); text-decoration: none; white-space: nowrap; transition: background-color .12s var(--ease), color .12s var(--ease); }
.seg a:hover { background: var(--n-50); color: var(--ink); }
.seg a.on { background: var(--card); color: var(--teal-700); font-weight: 700; box-shadow: var(--shadow); }
.job-title { display: flex; flex-direction: column; min-width: 0; }
.job-title small { font-weight: 400; }
.job-badges { gap: 8px; flex: none; }
.job-item > summary > .row { align-items: flex-start; }
.job-item > summary::before { top: 20px; }
a.badge { text-decoration: none; }
a.badge:hover { filter: brightness(.96); }
@media (max-width: 639px) { .job-item > summary > .row { flex-direction: column; } .job-badges { flex-wrap: wrap; } }
.log-bar { display: flex; flex-wrap: wrap; align-items: center; gap: 12px 16px; margin-bottom: 16px; }
.log-search { margin-left: auto; flex-wrap: nowrap; }
.log-search input { width: 224px; }
.log-search select { width: auto; max-width: 320px; }
.log-key { margin: 0 0 12px; }
.pager { margin-top: 16px; justify-content: center; }
.sc-box input.grow { min-width: 160px; }
@media (max-width: 639px) { .log-search { margin-left: 0; width: 100%; } .log-search input, .log-search select { width: auto; max-width: none; flex: 1; min-width: 0; } }
.iv-group + .iv-group { border-top: 1px solid var(--line); margin-top: 16px; padding-top: 16px; }
.iv-group > .list { margin-top: 8px; }
.iv-group .badge { white-space: normal; padding: 4px 10px; border-radius: 12px; }
.iv-row { display: flex; align-items: center; gap: 8px 12px; flex-wrap: wrap; min-width: 0; }
.action-bar { position: sticky; bottom: 0; z-index: 5; background: var(--card); border-top: 1px solid var(--line); margin-top: 16px; padding: 12px 0 0; }
.out-table { min-width: 960px; }
.out-table .col-check { width: 56px; } .out-table .col-who { width: 200px; } .out-table .col-res { width: 168px; } .out-table .col-to { width: 112px; } .out-table .col-date { width: 136px; }
@media (max-width: 639px) { .list > li.row.stack { flex-wrap: wrap; } }
@media (max-width: 639px) { .action-bar { bottom: calc(64px + env(safe-area-inset-bottom)); padding-bottom: 12px; } }
.quick-result { gap: 8px; flex-wrap: nowrap; margin: 4px 0 0; }
.quick-result select { width: auto; min-height: 36px; padding: 4px 32px 4px 8px; font-size: 13px; }

/* ---------- 評価シート ---------- */
.sheet-scroll { max-height: 78vh; overflow: auto; }
.sheet-table { font-size: 12px; line-height: 20px; border-collapse: separate; border-spacing: 0; }
.sheet-table th, .sheet-table td { white-space: nowrap; max-width: 160px; overflow: hidden; text-overflow: ellipsis; vertical-align: top; border: 0; border-bottom: 1px solid var(--line); padding: 6px 8px; }
.sheet-table thead th { position: sticky; top: 0; background: var(--n-50); z-index: 3; }
.sheet-table th.name { position: sticky; left: 0; background: var(--card); z-index: 2; text-align: left; box-shadow: 1px 0 0 var(--line); }
.sheet-table thead th.name { z-index: 4; background: var(--n-50); }
.sheet-table td.w2 { max-width: 224px; white-space: normal; min-width: 160px; }
.sheet-table td.w3 { max-width: 304px; white-space: normal; min-width: 224px; }
.sheet-table td.w4 { max-width: 384px; white-space: normal; min-width: 280px; }
.sheet-table td.num { text-align: right; }

/* ---------- 行動ログ（行の地色と種類の表示で区別する） ---------- */
.log-table { width: 100%; border-collapse: separate; border-spacing: 0; }
.log-table th { border-bottom: 1px solid var(--line-strong); }
.log-table td.lg-at { white-space: nowrap; font-variant-numeric: tabular-nums; }
.log-table td.lg-who, .log-table td.lg-kind, .log-table td.lg-dev { white-space: nowrap; }
.log-table td.lg-detail { min-width: 224px; }
.log-table tr.lv-key td { font-weight: 500; }
.log-table tr.tone-msg td { background: #fdf6e6; }
.log-table tr.tone-doc td { background: #f0f9f4; }
.log-table tr.tone-alert td { background: var(--ng-soft); }
.log-table tr.lv-view td, .log-table tr.lv-warn td { color: var(--mute); font-size: 13px; line-height: 20px; padding-top: 8px; padding-bottom: 8px; }
.lg-msg { background: var(--star); color: #fff; } .lg-doc { background: var(--ok); color: #fff; } .lg-alert { background: var(--ng-fill); color: #fff; }
.lg-act { background: var(--teal-50); color: var(--teal-700); } .lg-view { background: var(--n-100); color: var(--n-600); } .lg-warn { background: var(--card); color: var(--ng); border: 1px solid #efc7c8; }
.lg-new { min-height: 16px; font-size: 10px; padding: 0 6px; }

/* ---------- 確認ダイアログ ---------- */
dialog.confirm { border: 0; border-radius: var(--radius-lg); padding: 24px; width: min(440px, calc(100vw - 32px)); background: var(--card); color: var(--ink); box-shadow: var(--shadow-lg); }
dialog.confirm::backdrop { background: rgba(12, 20, 22, .48); }
dialog.confirm p { margin: 0 0 24px; white-space: pre-line; font-size: 15px; line-height: 24px; }
dialog.confirm .row { justify-content: flex-end; }
@media (max-width: 639px) { dialog.confirm .row { flex-direction: column-reverse; align-items: stretch; } }

/* ---------- 印刷・PDF（一覧をそのまま紙に出す。メニューや操作のボタンは出さない） ---------- */
/* 分析：グラフ（1色。数字は文字で添える） */
.summary div.kpi.plain b { color: var(--ink); }
.stat-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 24px; margin-bottom: 24px; }
.stat-grid > .card { margin-bottom: 0; min-width: 0; }
.stat-grid > .span2 { grid-column: 1 / -1; }
.stat-table td { vertical-align: middle; }
@media (max-width: 1023px) { .stat-grid { grid-template-columns: minmax(0, 1fr); } }
.vbars { display: flex; align-items: flex-end; height: 216px; margin-bottom: 16px; }
.vb { flex: 1 1 0; min-width: 0; height: 100%; display: flex; flex-direction: column; align-items: center; justify-content: flex-end; gap: 4px; padding: 0 2px; }
.vb b { font: 600 12px/16px var(--font-display); color: var(--ink); min-height: 16px; }
.vb svg { width: 100%; max-width: 40px; flex: 1 1 auto; display: block; }
.vb rect, .hb-bar rect { fill: var(--teal-700); }
.vb:hover rect, .hb:hover rect { fill: var(--teal-800); }
.vb small { align-self: stretch; text-align: center; font-size: 12px; line-height: 16px; color: var(--mute); border-top: 1px solid var(--line-strong); margin: 0 -2px; padding-top: 4px; white-space: nowrap; }
.hbars { display: grid; gap: 8px; margin-bottom: 16px; }
.hb { display: grid; grid-template-columns: minmax(96px, 30%) minmax(0, 1fr) auto; align-items: center; gap: 12px; font-size: 13px; line-height: 20px; }
.hb-label { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.hb-bar { width: 100%; height: 16px; display: block; background: var(--n-50); border-radius: 3px; }
.hb-val { white-space: nowrap; text-align: right; min-width: 88px; }
.hb-val b { font-family: var(--font-display); }
@media (max-width: 639px) { .vb small { font-size: 10px; letter-spacing: -.02em; } }
@media (max-width: 639px) { .hb { grid-template-columns: minmax(0, 1fr) auto; gap: 4px 12px; } .hb-bar { grid-column: 1 / -1; grid-row: 2; } }
.stat-table { font-size: 13px; line-height: 20px; }
.stat-table th, .stat-table td { padding: 8px 12px; border-bottom: 1px solid var(--line); }
.stat-table tbody tr:last-child > * { border-bottom: 0; }
.stat-table tbody th { background: none; color: var(--ink); font-size: 13px; line-height: 20px; font-weight: 400; white-space: normal; min-width: 10em; }
.stat-table .num { text-align: right; font-variant-numeric: tabular-nums; white-space: nowrap; }
.stat-table .tb { display: inline-flex; align-items: center; gap: 8px; }
.stat-table .tb .hb-bar { width: 64px; height: 12px; }
.stat-table .tb b { font-family: var(--font-display); min-width: 2ch; }

@media print {
  @page { size: A4 landscape; margin: 12mm; }
  body { background: #fff; font-size: 10pt; line-height: 1.5; }
  .side, .app-top, .tabbar, .demo-bar, .flash, .chips, .page-head .row, .menu-toggle, .star, .filters > :not(.filter-active), .filter-active a, .seg, .log-search, .pager { display: none !important; }
  .app { display: block; padding: 0; }
  .wrap { max-width: none; padding: 0; }
  .card, .summary { box-shadow: none; border: 0; border-radius: 0; padding: 0; margin-bottom: 12pt; }
  .filters { display: block; }
  .filter-active { border: 0; padding: 0; }
  .apps { display: none !important; }
  .apps-table { display: block !important; overflow: visible; }
  .apps-table table { min-width: 0; table-layout: auto; }
  .tbl-wrap { overflow: visible; }
  table { font-size: 9pt; line-height: 1.4; }
  th, td { padding: 4pt 6pt; }
  thead { display: table-header-group; }
  tr { break-inside: avoid; }
  a { color: inherit; text-decoration: none; }
  .badge { border: 1px solid currentColor; background: none !important; min-height: 0; padding: 0 4pt; }
  .avatar-sm { display: none; }
  .stat-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12pt; }
  .stat-grid > .card { break-inside: avoid; }
  .vb rect, .hb-bar rect { fill: #3e4040; }
  .hb-bar { background: none; border: 1px solid #c2c5c5; }
}

@media (prefers-reduced-motion: reduce) { *, *::before, *::after { transition: none !important; scroll-behavior: auto !important; } }

/* 閲覧のみのアカウント：変更のフォームと、開けない画面へのリンクを隠す（実際の制限はサーバー側） */
.ro main form[method="post"], .ro main a[href*=".csv"], .ro main a[href="/admin/applicants/new"], .ro main a[href^="/admin/settings"] { display: none !important; }
.ro .ro-bar { border-left: 4px solid var(--teal-600, #0f766e); }
