/* 포스 구성 모달(js/modal-force.js). 카드·스크림·바닥은 공통 껍데기가 맡는다. */

/* 왼쪽 미지정 명단은 고정 폭, 오른쪽 포스 카드가 남는 폭을 나눠 쓴다. 두 영역이 같이
   스크롤되면 100명 중 한 명을 옮길 때마다 명단을 다시 찾아 올라가야 한다 — 스크롤은
   각 영역 안에서 따로 생긴다. */
.fc {
  display: grid;
  grid-template-columns: 268px minmax(0, 1fr);
  gap: 16px;
  align-items: start;
  min-height: 380px;
}

.fc-pool {
  position: sticky;
  top: 0;
  border: 1px solid var(--edge-soft);
  border-radius: var(--radius-slot);
  background: rgba(255, 255, 255, 0.022);
  overflow: hidden;
}
.fc-pool-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  padding: 9px 8px 9px 11px;
  border-bottom: 1px solid var(--edge-soft);
}
.fc-pool-title { font-size: 12.5px; font-weight: 600; color: var(--sub); }
.fc-pool-n { color: var(--ink); font-weight: 500; }
.fc-pool-list { list-style: none; margin: 0; padding: 4px; max-height: 46vh; overflow: auto; }

.fc-forces {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(232px, 1fr));
  gap: 10px;
}

.fc-card {
  border: 1px solid var(--edge-soft);
  border-radius: var(--radius-slot);
  background: rgba(255, 255, 255, 0.022);
  overflow: hidden;
  transition: border-color 160ms ease, background 160ms ease;
}
/* 지금 사람을 담고 있는 포스. 명단을 연타하는 동안 어디로 들어가는지가 한눈에 보여야
   하므로 이 화면에서 가장 강한 신호를 여기에 쓴다. */
.fc-card.is-active {
  border-color: rgba(107, 227, 245, 0.45);
  background: rgba(107, 227, 245, 0.05);
}

.fc-card-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  padding: 7px 10px 7px 4px;
  border-bottom: 1px solid var(--edge-soft);
}
.fc-card-pick {
  display: flex;
  align-items: baseline;
  gap: 7px;
  padding: 3px 7px;
  border: 0;
  border-radius: 7px;
  background: none;
}
.fc-card-pick:hover { background: rgba(255, 255, 255, 0.05); }
.fc-card-name { font-size: 13px; font-weight: 600; }
.fc-card.is-active .fc-card-name { color: var(--ether); }
.fc-card-count { font-size: 12.5px; font-weight: 500; }
.fc-card-of { color: var(--sub); font-weight: 400; }
/* 색은 app.css 의 `.fc-card-classes b` 한 규칙이 맡는다. 좁은 카드라 줄바꿈을 허용한다. */
.fc-card-classes { margin: 0; display: flex; flex-wrap: wrap; justify-content: flex-end; gap: 2px 7px; font-size: 11.5px; }
.fc-card-classes b { font-weight: 600; }
.fc-card-classes .mono { font-weight: 500; }

.fc-card-list, .fc-pool-list { list-style: none; }
.fc-card-list { margin: 0; padding: 4px; display: grid; gap: 1px; }
/* 안쪽 .fc-name 의 말줄임이 동작하려면 이 li 도 줄어들 수 있어야 한다 — 기본 min-width:auto
   면 내용 폭이 바닥이 돼서 이름이 카드를 밀고 나간다. */
.fc-person { min-width: 0; }

/* 명단 한 줄. 역할 글자 · 이름(서버) · 직업 · 전투력. 누르면 담기거나 빠진다 —
   담기와 빼기를 같은 모양으로 둔 것은 의도다. 왼쪽에 있으면 담기고 오른쪽에 있으면
   빠지므로, 어느 쪽에 있는지가 곧 그 클릭의 뜻이다. */
.fc-pick {
  display: grid;
  grid-template-columns: 17px minmax(0, 1fr) auto 52px;
  column-gap: 7px;
  align-items: baseline;
  width: 100%;
  padding: 5px 7px;
  border: 0;
  border-radius: 7px;
  background: none;
  text-align: left;
}
.fc-pick:hover { background: rgba(255, 255, 255, 0.06); }

.fc-mark { font-size: 11.5px; font-weight: 600; color: var(--cls, var(--cls-etc)); }

.fc-name {
  min-width: 0;
  font-size: 12.5px;
  font-weight: 600;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.fc-server { margin-left: 1px; font-weight: 400; color: var(--sub); }
/* 좁은 카드에서 제일 먼저 자리를 내주는 열. 이름과 전투력이 먼저다. */
.fc-class { font-size: 11.5px; color: var(--sub); white-space: nowrap; }
.fc-cp { text-align: right; font-size: 12px; letter-spacing: -0.02em; color: var(--quiet); }

.fc-empty {
  padding: 10px 9px;
  color: var(--sub);
  font-size: 12px;
  line-height: 1.45;
}

@media (max-width: 860px) {
  .fc { grid-template-columns: minmax(0, 1fr); }
  .fc-pool { position: static; }
  .fc-pool-list { max-height: 30vh; }
  .fc-pick { grid-template-columns: 17px minmax(0, 1fr) 52px; }
  .fc-class { display: none; }
}

/* 같은 사람의 다른 캐릭터가 이미 활성 포스에 있어 담을 수 없는 줄. 목록에서 빼지 않고
   흐리게만 둔다 — 사라지면 "왜 이 사람이 없지" 를 다시 찾게 되고, 활성 포스를 바꾸면
   바로 담을 수 있게 되는 상태라 영구히 못 담는 것도 아니다. 이유는 title 에 있다. */
.fc-person.is-blocked .fc-pick { cursor: default; }
.fc-person.is-blocked .fc-mark,
.fc-person.is-blocked .fc-name,
.fc-person.is-blocked .fc-class,
.fc-person.is-blocked .fc-cp { color: var(--sub); }
.fc-person.is-blocked .fc-pick:hover { background: none; }
