/* VISION・目標(NAK-1581)。フラット単一サーフェス: 区画は罫線と文字の強弱だけ。角丸0・影なし・カードなし。
   数値は tabular-nums。読ませる文(回答・設問)だけ行長を和文40字に抑える */
.gl { max-width: 1120px; }
.gl .num, .gl .gl-rt td.num { font-variant-numeric: tabular-nums; }
.gl .sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.gl-tabs { margin-bottom: 18px; padding-bottom: 2px; border-bottom: 1px solid var(--line); }

/* 進み具合(1行の台帳) */
.gl-status { display: flex; flex-wrap: wrap; gap: 6px 0; padding: 8px 0 10px; border-bottom: 1px solid var(--line); font-size: 13px; }
.gl-status > span { padding-right: 18px; margin-right: 18px; border-right: 1px solid var(--line2); white-space: nowrap; }
.gl-status > span:last-child { border-right: 0; }
.gl-status b { font-size: 11px; font-weight: 700; color: var(--sub); margin-right: 7px; }
.gl-status i { font-style: normal; font-weight: 700; }
.gl-saved { color: var(--sub); margin-left: auto; }
.gl-notice { margin: 12px 0 0; padding: 8px 0 8px 12px; border-left: 3px solid var(--warn); color: var(--warn); font-size: 13px; }

/* 区画見出しは .d-sec(罫線+小見出し)を継ぐ */
.gl-sec { margin-top: 8px; }
.gl-sec .d-sec { margin-top: 30px; }
.gl-sec .d-sec .gl-count { font-size: 15px; font-weight: 700; color: var(--txt); }
.gl-opt { font-weight: 600; color: var(--text3); margin-left: 8px; }
.gl-help { font-size: 13px; color: var(--sub); margin: 10px 0 0; max-inline-size: 40em; }

.gl-role { width: 280px; max-width: 100%; margin-top: 10px; }
.gl-role .combo, .gl-role input[type="text"] { width: 100%; }
/* 基準の3択は文字タブ。選択中は黒い下線 */
.gl .seg button { min-height: 36px; }
.gl-levels button { display: inline-flex; flex-direction: column; align-items: flex-start; gap: 1px; padding: 8px 0 7px; line-height: 1.3; }
.gl-levels button small { font-size: 11px; font-weight: 500; color: var(--text3); }
.gl-levels button.on small { color: var(--sub); }

/* VISION の設問と回答欄 */
.gl-q { margin-top: 20px; }
.gl-q label { display: block; font-size: 15px; font-weight: 700; line-height: 1.6; margin-bottom: 6px; max-inline-size: 40em; }
.gl textarea { display: block; width: 100%; max-width: 760px; min-height: 108px; padding: 10px 12px; border: 1px solid var(--line2); border-radius: 0; background: var(--surface); color: var(--txt); font: inherit; font-size: 15px; line-height: 1.8; resize: vertical; }
.gl textarea:focus { outline: 0; border-color: #727b63; box-shadow: 0 0 0 2px #edf0e6; }
.gl textarea:focus-visible { outline: 2px solid #22251f; outline-offset: 2px; }

/* 基準の比較表。選んだ基準の列は太字+上辺2px黒罫 */
.gl-cmphead { display: flex; justify-content: space-between; align-items: baseline; gap: 12px; flex-wrap: wrap; margin-top: 16px; }
.gl-cmphead .gl-help { margin: 0; }
.gl-cmpwrap { margin-top: 8px; }
.gl-cmp { width: 100%; border-collapse: collapse; font-size: 13px; min-width: 560px; }
.gl-cmp th, .gl-cmp td { padding: 9px 12px; text-align: left; vertical-align: top; border-bottom: 1px solid var(--line); }
.gl-cmp thead th { position: sticky; top: 0; background: var(--table-head); font-size: 12px; font-weight: 700; color: var(--sub); border-bottom: 1px solid var(--line2); }
.gl-cmp thead th.on { color: var(--txt); box-shadow: inset 0 2px 0 #141414; }
.gl-cmp tbody th { font-weight: 600; width: 22%; }
.gl-cmp td.on { font-weight: 700; }
.gl-cmp td { width: 26%; }

/* 目標の一覧。行=チェック・名前・目標値。選択中は名前を太く */
.gl-goals { border-top: 1px solid var(--line); }
.gl-goal { display: grid; grid-template-columns: 18px 1fr minmax(0, 1.4fr); gap: 12px; align-items: center; min-height: 44px; padding: 8px 0; border-bottom: 1px solid var(--line); cursor: pointer; }
.gl-goal input { width: 18px; height: 18px; margin: 0; accent-color: #141414; }
.gl-goal .gl-gt { font-weight: 500; }
.gl-goal.on .gl-gt { font-weight: 700; }
.gl-goal .gl-gv { font-size: 13px; }
.gl-goal .gl-gv i { font-style: normal; color: var(--text3); }
.gl-goal:hover { background: var(--hover); }
.gl-goal:has(input:focus-visible) { outline: 2px solid #22251f; outline-offset: -2px; }

/* キャリア(任意) */
.gl-career { display: grid; gap: 12px; max-width: 760px; margin-top: 12px; }
.gl-career .combo { max-width: 360px; }

/* 不足の表示と操作列 */
.gl-err { margin-top: 20px; padding: 8px 0 8px 12px; border-left: 3px solid var(--danger); color: var(--danger); font-size: 13px; white-space: pre-line; }
.gl-actions { display: flex; align-items: center; gap: 8px; margin-top: 24px; padding-top: 16px; border-top: 1px solid var(--line2); }
.gl-actions.gl-top { margin-top: 0; padding-top: 0; border-top: 0; margin-bottom: 14px; }
.gl-note { font-size: 12px; color: var(--sub); margin-right: auto; }
.gl-actions .btn.primary { min-height: 40px; padding: 8px 24px; }

/* 確認・提出済み・レポート */
.gl-done { margin: 4px 0 14px; font-size: 13px; }
.gl-done .badge { font-size: 13px; margin-right: 8px; }
.gl-ledger { max-width: 420px; }
.gl-rt { width: 100%; border-collapse: collapse; font-size: 13px; }
.gl-rt th, .gl-rt td { padding: 9px 12px; text-align: left; vertical-align: top; border-bottom: 1px solid var(--line); }
.gl-rt thead th { background: var(--table-head); font-size: 12px; color: var(--sub); }
.gl-rt .gl-grp th { background: none; font-size: 12px; font-weight: 700; color: var(--sub); padding-top: 14px; border-bottom: 1px solid var(--line2); }
.gl-rt .gl-target { font-weight: 700; }
.gl-rt .gl-lv { color: var(--sub); white-space: nowrap; width: 1%; }
.gl-c { padding: 14px 0; border-bottom: 1px solid var(--line); }
.gl-cq { font-size: 14px; font-weight: 700; line-height: 1.6; max-inline-size: 40em; }
.gl-ans { margin-top: 6px; font-size: 15px; line-height: 1.9; white-space: pre-wrap; overflow-wrap: break-word; max-inline-size: 40em; }
.gl-report .gl-rh { padding: 6px 0 14px; border-bottom: 2px solid #141414; }
.gl-report .gl-rh h2 { font-size: 22px; }
.gl-rmeta { margin-top: 4px; font-size: 13px; color: var(--sub); }
.gl-sep { display: inline-block; width: 1px; height: 11px; background: var(--line2); margin: 0 10px; vertical-align: -1px; }

/* メンバーの目標 */
.gl-mtool .search input { width: 220px; }
.gl-store { width: 220px; }
.gl-mcount { font-size: 12px; color: var(--sub); }
.gl-mt { width: 100%; }
.gl-mt .gl-mname { font-weight: 600; }
.gl-mt td.act { width: 1%; white-space: nowrap; text-align: right; }

@media (max-width: 760px) {
  .gl-status > span { padding-right: 12px; margin-right: 12px; }
  .gl-saved { flex-basis: 100%; margin-left: 0; }
  .gl-goal { grid-template-columns: 18px 1fr; }
  .gl-goal .gl-gv { grid-column: 2; }
  .gl-actions { flex-wrap: wrap; }
  .gl-note { flex-basis: 100%; margin-bottom: 4px; }
  .gl-actions .btn.primary { margin-left: auto; }
  .gl-mtool .search input, .gl-store { width: 100%; }
  .gl textarea { font-size: 16px; }
}
@media (prefers-reduced-motion: reduce) { .gl * { transition: none !important; scroll-behavior: auto !important; } }
/* 申請・届出のオーバーレイの中(入力はそのまま。操作列は下の段 .apov-foot に出す) */
.apov-body .gl-status { margin-top: 4px; }
.apov-body .gl-sec:first-of-type .d-sec { margin-top: 18px; }
.apov-foot .gl-actions { margin-top: 0; padding: 14px 0 20px; border-top: 1px solid var(--line2); }
.apov-body .gl-done { margin-top: 4px; }
@media (max-width: 760px) { .apov-foot .gl-actions { padding-bottom: calc(14px + env(safe-area-inset-bottom)); } }
@media print {
  .side, .top, #kpi-menu-toggle, .gl-tabs, .gl-actions, .gl-mtool, .toast, .overlay:not(.apov-wrap) { display: none !important; }
  .shell { display: block; } .main { padding: 0; }
  /* オーバーレイのレポートを印刷する時は本文を消し、オーバーレイを面に広げる */
  body.apov-lock { overflow: visible; }
  body.apov-lock .shell { display: none; }
  .apov-wrap { position: static; }
  .apov-wrap .scrim { display: none; }
  .apov { position: static; width: auto; max-width: none; max-height: none; height: auto; box-shadow: none; border-top: 0; animation: none; }
  .apov-head { padding: 0 0 8px; } .apov-close, .apov-foot, .apov-eyebrow { display: none; }
  .apov-body { overflow: visible; max-height: none; padding: 0; }
  .gl { max-width: none; }
  .gl-report .gl-rh { break-after: avoid; } .gl-c { break-inside: avoid; } .gl-rt tr { break-inside: avoid; }
  .gl-cmp thead th { position: static; }
}
