/* =============================================================================
 *  ACT-R インターン ── 追加スタイル（styles.css は研修アプリと共通）
 * ============================================================================= */

.ix-mark { background: linear-gradient(135deg, #0f172a, #334155); }
.ix-sub { font-size: 11px; font-weight: 800; letter-spacing: .14em; color: var(--ink-soft); }

/* ---------- 下部ナビ ---------- */
body.has-nav { padding-bottom: calc(76px + env(safe-area-inset-bottom)); }
.ix-nav {
  position: fixed; left: 0; right: 0; bottom: 0; z-index: 30;
  display: grid; grid-template-columns: repeat(5, 1fr);
  background: rgba(255, 255, 255, .94);
  backdrop-filter: saturate(180%) blur(12px);
  border-top: 1px solid var(--line);
  padding: 6px 4px calc(6px + env(safe-area-inset-bottom));
}
.ix-nav button {
  border: 0; background: none; cursor: pointer;
  display: flex; flex-direction: column; align-items: center; gap: 2px;
  font-size: 10.5px; font-weight: 700; color: var(--ink-soft);
  padding: 4px 0; border-radius: 12px; font-family: inherit;
}
.ix-nav button span { font-size: 20px; line-height: 1.1; filter: grayscale(1); opacity: .6; }
.ix-nav button.on { color: var(--ink); background: #eef2f8; }
.ix-nav button.on span { filter: none; opacity: 1; }

/* ---------- 役職バッジ ---------- */
.rbadge {
  display: inline-block; white-space: nowrap;
  padding: 3px 10px; border-radius: 999px;
  font-size: 12.5px; font-weight: 800;
  color: #fff; background: var(--rc);
}
.rbadge.sm { font-size: 11px; padding: 2px 8px; }

/* ---------- マイページ ---------- */
.ix-hero {
  position: relative; overflow: hidden;
  border-radius: var(--radius); padding: 22px 20px 18px; margin-bottom: 16px;
  color: #fff;
  background: linear-gradient(135deg, var(--rc), color-mix(in srgb, var(--rc) 55%, #0f172a));
  box-shadow: var(--shadow);
}
.ix-hero-en { font-size: 11px; font-weight: 800; letter-spacing: .2em; opacity: .75; }
.ix-hero-name { font-size: 26px; font-weight: 800; margin-top: 2px; }
.ix-hero-role { font-size: 15px; font-weight: 700; opacity: .92; }
.ix-hero-meta {
  display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; margin-top: 16px;
}
.ix-hero-meta > div {
  background: rgba(255, 255, 255, .16); border-radius: 12px; padding: 8px 10px;
}
.ix-hero-meta small { display: block; font-size: 11px; opacity: .85; }
.ix-hero-meta b { font-size: 18px; }
.ix-hero-meta b span { font-size: 12px; margin-left: 1px; }
.ix-hero-since { font-size: 12px; opacity: .8; margin-top: 10px; }

.ix-sec-h {
  display: flex; align-items: center; gap: 8px; flex-wrap: wrap;
  font-weight: 800; font-size: 16px; margin-bottom: 10px;
}
.ix-big { margin-left: auto; font-size: 26px; }
.ix-big small { font-size: 13px; margin-left: 2px; color: var(--ink-soft); }
.ix-arrow { color: var(--ink-soft); }
.ix-cnts { display: grid; grid-template-columns: repeat(6, 1fr); gap: 6px; }
.ix-cnt { text-align: center; background: #f3f6fb; border-radius: 12px; padding: 8px 2px; }
.ix-cnt b { display: block; font-size: 19px; }
.ix-cnt small { font-size: 10.5px; color: var(--ink-soft); }
.ix-cnt.neg b { color: var(--bad); }
@media (max-width: 420px) { .ix-cnts { grid-template-columns: repeat(3, 1fr); } }

.ix-h3 { font-weight: 800; font-size: 13.5px; margin: 16px 0 8px; color: var(--ink-soft); }
.ix-h4 { font-weight: 700; font-size: 12.5px; margin: 10px 0 4px; color: var(--ink-soft); }
.ix-note { font-size: 12.5px; color: var(--ink-soft); margin: 6px 0; }
.ix-note .up { color: var(--good); }

.ix-cond { padding: 10px 12px; background: #f6f8fb; border-radius: 12px; margin-bottom: 8px; }
.ix-cond.ok { background: #ecfdf3; }
.ix-cond-top { display: flex; justify-content: space-between; align-items: baseline; gap: 8px; font-size: 14px; }
.ix-cond-top b { font-size: 17px; }
.ix-cond-top small { font-size: 12px; color: var(--ink-soft); font-weight: 600; }
.ix-cond-rest { font-size: 12px; color: var(--ink-soft); margin-top: 4px; text-align: right; }
.ix-cond-rest b { color: var(--accent); }
.pbar { height: 8px; border-radius: 99px; background: #e3e9f3; overflow: hidden; margin-top: 6px; }
.pbar > i { display: block; height: 100%; border-radius: 99px; background: linear-gradient(90deg, var(--accent), var(--accent-2)); }
.ix-cond.ok .pbar > i { background: var(--good); }

.ix-check { list-style: none; margin: 0; padding: 0; }
.ix-check li { display: flex; gap: 8px; padding: 7px 0; border-bottom: 1px dashed var(--line); font-size: 14px; }
.ix-check li:last-child { border-bottom: 0; }
.ix-check li.done { color: var(--ink-soft); }
.ix-status { border-radius: 12px; padding: 10px 12px; font-weight: 800; font-size: 14px; margin: 8px 0; }
.ix-status.ready { background: #fff7e6; color: #b45309; }
.ix-status.go { background: #ecfdf3; color: var(--good); }

.ix-rec { display: flex; align-items: center; gap: 10px; padding: 8px 0; border-bottom: 1px solid var(--line); font-size: 13.5px; }
.ix-rec:last-child { border-bottom: 0; }
.ix-rec .d { width: 44px; color: var(--ink-soft); font-weight: 700; }
.ix-rec .t { flex: 1; }
.ix-link { display: block; margin: 14px auto 0; border: 0; background: none; color: var(--ink-soft); text-decoration: underline; font-size: 13px; cursor: pointer; font-family: inherit; }

/* 名前選択 */
.ix-search {
  width: 100%; font-size: 16px; padding: 12px 14px; border-radius: 12px;
  border: 1px solid var(--line); background: var(--surface); margin-bottom: 12px; font-family: inherit;
}
.ix-pick { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 8px; }
.ix-pick button {
  display: flex; flex-direction: column; align-items: flex-start; gap: 4px;
  border: 1px solid var(--line); background: var(--surface); border-radius: 14px;
  padding: 10px 12px; cursor: pointer; font-family: inherit; font-size: 15px; color: var(--ink); text-align: left;
}
.ix-pick button:hover { border-color: var(--accent); }

/* ---------- ランキング ---------- */
.ix-seg { display: flex; background: #e9eef6; border-radius: 12px; padding: 3px; margin-bottom: 8px; }
.ix-seg button {
  flex: 1; border: 0; background: none; padding: 8px 4px; border-radius: 10px;
  font-weight: 700; font-size: 13px; color: var(--ink-soft); cursor: pointer; font-family: inherit;
}
.ix-seg button.on { background: var(--surface); color: var(--ink); box-shadow: var(--shadow-sm); }
.ix-chips { display: flex; gap: 6px; overflow-x: auto; padding: 4px 0 10px; scrollbar-width: none; }
.ix-chips::-webkit-scrollbar { display: none; }
.ix-chips button {
  flex: none; border: 1px solid var(--line); background: var(--surface); border-radius: 999px;
  padding: 6px 12px; font-size: 12.5px; font-weight: 700; cursor: pointer; font-family: inherit; color: var(--ink);
}
.ix-chips button.on { background: var(--rc, #0f172a); border-color: var(--rc, #0f172a); color: #fff; }
.ix-rklist { padding: 6px 12px; }
.ix-rk { display: flex; align-items: center; gap: 10px; padding: 10px 4px; border-bottom: 1px solid var(--line); }
.ix-rk:last-child { border-bottom: 0; }
.ix-rk .no { width: 32px; text-align: center; font-weight: 800; color: var(--ink-soft); font-size: 15px; }
.ix-rk.top .no { font-size: 22px; }
.ix-rk .nm { flex: 1; display: flex; align-items: center; gap: 8px; flex-wrap: wrap; min-width: 0; }
.ix-rk .v { font-weight: 800; font-size: 17px; }
.ix-rk .v small { font-size: 11px; color: var(--ink-soft); margin-left: 2px; }
.ix-rk.me { background: #eef4ff; border-radius: 12px; }

/* ---------- 役職 ---------- */
.ix-role { border-top: 5px solid var(--rc); }
.ix-role-top { display: flex; justify-content: space-between; font-size: 11px; font-weight: 800; letter-spacing: .12em; }
.ix-role-lv { color: var(--rc); }
.ix-role-en { color: var(--ink-soft); }
.ix-role h3 { font-size: 21px; margin: 4px 0 4px; }
.ix-role-pay { font-size: 14px; margin-bottom: 6px; }
.ix-role-pay b { font-size: 22px; color: var(--rc); }
.ix-ul { margin: 0; padding-left: 20px; font-size: 14px; }
.ix-ul li { margin: 3px 0; }
.ix-up { margin-top: 14px; background: #f6f8fb; border-radius: 12px; padding: 10px 12px; }
.ix-up.exec { background: #fff7e6; }
.ix-up-h { font-weight: 800; font-size: 14px; }
.ix-ladder { text-align: center; color: #b8c2d3; font-size: 18px; margin: -6px 0 6px; }
.dx-tier-v.neg { color: var(--bad); }

/* ---------- 重要事項 ---------- */
.ix-rule h3 { display: flex; align-items: center; gap: 10px; }
.ix-rule h3 span {
  flex: none; width: 26px; height: 26px; border-radius: 8px; display: grid; place-items: center;
  background: #fde8e8; color: var(--bad); font-size: 14px;
}

/* =============================================================================
 *  管理画面
 * ============================================================================= */
.ad-tabs { display: flex; gap: 6px; margin-bottom: 14px; }
.ad-tabs button {
  flex: 1; border: 1px solid var(--line); background: var(--surface); padding: 10px; border-radius: 12px;
  font-weight: 800; cursor: pointer; font-family: inherit; font-size: 14px; color: var(--ink);
}
.ad-tabs button.on { background: #0f172a; color: #fff; border-color: #0f172a; }
.ad-row { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; margin-bottom: 10px; }
.ad-in, .ad-sel {
  font-size: 15px; padding: 9px 11px; border-radius: 10px; border: 1px solid var(--line);
  background: var(--surface); font-family: inherit; color: var(--ink);
}
.ad-in.grow { flex: 1; min-width: 140px; }
.ad-table-wrap { overflow-x: auto; margin: 0 -4px; }
.ad-table { width: 100%; border-collapse: collapse; font-size: 13.5px; }
.ad-table th { font-size: 11.5px; color: var(--ink-soft); text-align: center; padding: 6px 2px; white-space: nowrap; position: sticky; top: 0; background: var(--surface); }
.ad-table th:first-child, .ad-table td:first-child { text-align: left; }
.ad-table td { padding: 5px 2px; border-top: 1px solid var(--line); text-align: center; }
.ad-table td.nm { white-space: nowrap; padding-right: 8px; }
.ad-table td.pt { font-weight: 800; width: 48px; }
.ad-num {
  width: 46px; font-size: 16px; padding: 6px 2px; text-align: center; border-radius: 8px;
  border: 1px solid var(--line); font-family: inherit;
}
.ad-num.has { background: #eef4ff; border-color: #bcd0ff; font-weight: 800; }
.ad-num.neg.has { background: #fde8e8; border-color: #f5b5b5; }
.ad-save-bar {
  position: sticky; bottom: calc(10px + env(safe-area-inset-bottom)); margin-top: 12px;
  display: flex; gap: 10px; align-items: center; justify-content: flex-end;
  background: rgba(255,255,255,.95); padding: 10px; border-radius: 14px; box-shadow: var(--shadow);
}
.ad-msg { font-size: 13px; color: var(--ink-soft); margin-right: auto; }
.ad-mem {
  display: flex; align-items: center; gap: 10px; width: 100%; text-align: left;
  border: 0; border-bottom: 1px solid var(--line); background: none; padding: 11px 4px; cursor: pointer; font-family: inherit; color: var(--ink); font-size: 15px;
}
.ad-mem:last-child { border-bottom: 0; }
.ad-mem .nm { flex: 1; font-weight: 700; }
.ad-mem .st { font-size: 11.5px; font-weight: 800; border-radius: 999px; padding: 2px 8px; }
.ad-mem .st.ready { background: #fff7e6; color: #b45309; }
.ad-mem .st.go { background: #ecfdf3; color: var(--good); }
.ad-mem .st.off { background: #eef2f8; color: var(--ink-soft); }
.ad-mem .pt { font-size: 12.5px; color: var(--ink-soft); }
.ad-chk { display: flex; gap: 10px; align-items: flex-start; padding: 8px 0; border-bottom: 1px dashed var(--line); font-size: 14px; cursor: pointer; }
.ad-chk input { width: 20px; height: 20px; flex: none; margin-top: 1px; }
.ad-chk .t { flex: 1; }
.ad-chk .x { border: 0; background: none; color: var(--bad); cursor: pointer; font-size: 18px; }
.btn.danger { background: var(--bad); }
.btn.good { background: var(--good); }

.back-btn { white-space: nowrap; }
.ad-dot { display: inline-block; width: 9px; height: 9px; border-radius: 50%; margin-right: 6px; vertical-align: 1px; }
.ad-table td.nm, .ad-table th:first-child { position: sticky; left: 0; background: var(--surface); z-index: 1; max-width: 110px; overflow: hidden; text-overflow: ellipsis; }
