/* 보스 선택 화면 (BUILD 20261123-select1) */
#boss-select {
  position: fixed;
  inset: 0;
  z-index: 40;
  display: grid;
  grid-template-rows: auto 1fr auto;
  color: var(--ivory);
  background: #07080c;
  font-family: "Noto Sans KR", system-ui, sans-serif;
  overflow: hidden;
  --g: #e4b34d;
}
#boss-select.hidden { display: none !important; }
#boss-select .bs-bg {
  position: absolute;
  inset: 0;
  pointer-events: none;
  background:
    radial-gradient(900px 620px at 30% 46%, rgba(224, 180, 90, 0.13), transparent 62%),
    radial-gradient(760px 520px at 85% 85%, rgba(226, 61, 61, 0.16), transparent 60%),
    repeating-linear-gradient(115deg, rgba(255,255,255,0.018) 0 2px, transparent 2px 14px),
    linear-gradient(180deg, #0b0c11 0%, #07080c 60%, #040406 100%);
}
#boss-select > * { position: relative; }

.bs-top {
  display: flex;
  align-items: center;
  gap: 18px;
  padding: 22px 40px 0;
}
.bs-back {
  width: 42px;
  height: 42px;
  display: grid;
  place-items: center;
  background: rgba(10, 11, 16, 0.7);
  color: var(--ivory);
  border: 1px solid var(--line);
  padding: 0;
}
.bs-back:hover { border-color: var(--brass); color: var(--brass); }
.bs-title { display: flex; align-items: baseline; gap: 14px; }
.bs-title em {
  font-family: "Barlow Condensed", sans-serif;
  font-style: normal;
  font-weight: 700;
  font-size: 34px;
  letter-spacing: 0.14em;
  color: var(--brass);
}
.bs-title b {
  font-family: "Black Han Sans", sans-serif;
  font-weight: 400;
  font-size: 22px;
  letter-spacing: 0.1em;
  color: rgba(244, 239, 228, 0.82);
}

.bs-main {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(360px, 460px);
  gap: 48px;
  align-items: center;
  justify-content: center;
  padding: 12px 64px 8px;
  min-height: 0;
  max-width: 1320px;
  width: 100%;
  margin: 0 auto;
  box-sizing: border-box;
}
.bs-stage {
  height: 100%;
  min-height: 0;
  display: flex;
  align-items: center;
  justify-content: flex-end;
}
.bs-portrait {
  position: relative;
  height: min(100%, 760px);
  max-height: calc(100vh - 330px);
  aspect-ratio: 2 / 3;
  border: 2px solid var(--g);
  box-shadow: 0 0 0 1px rgba(0,0,0,.8), 0 0 42px color-mix(in srgb, var(--g) 35%, transparent), 0 24px 60px rgba(0,0,0,.7);
  background: #0c0d12;
  overflow: hidden;
  animation: bs-in 0.32s cubic-bezier(.2,.8,.2,1) both;
}
.bs-portrait img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  user-select: none;
}
.bs-portrait::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, transparent 62%, rgba(0,0,0,.55) 100%);
  pointer-events: none;
}
@keyframes bs-in {
  from { opacity: 0; transform: translateX(-26px) scale(.98); }
  to { opacity: 1; transform: none; }
}

.bs-panel {
  align-self: center;
  padding: 26px 28px 24px;
  background: linear-gradient(160deg, rgba(22, 25, 34, 0.94), rgba(11, 12, 17, 0.94));
  border: 1px solid rgba(224, 180, 90, 0.28);
  border-left: 4px solid var(--g);
  box-shadow: 0 24px 60px rgba(0,0,0,.6);
  animation: bs-panel-in 0.32s ease both;
}
@keyframes bs-panel-in {
  from { opacity: 0; transform: translateX(18px); }
  to { opacity: 1; transform: none; }
}
.bs-head { display: flex; gap: 8px; align-items: center; }
.bs-grade, .bs-elem {
  font-family: "Barlow Condensed", sans-serif;
  font-weight: 700;
  font-size: 18px;
  letter-spacing: 0.08em;
  padding: 2px 12px;
  border: 1px solid var(--g);
  color: var(--g);
  background: rgba(0,0,0,.35);
}
.bs-elem { border-color: rgba(244,239,228,.4); color: var(--ivory); font-family: "Noto Sans KR", sans-serif; font-size: 14px; }
.bs-name {
  margin: 10px 0 4px;
  font-family: "Black Han Sans", sans-serif;
  font-weight: 400;
  font-size: 58px;
  line-height: 1.05;
  letter-spacing: 0.04em;
  text-shadow: 0 3px 0 rgba(0,0,0,.6), 0 0 26px color-mix(in srgb, var(--g) 30%, transparent);
}
.bs-line {
  margin: 0 0 14px;
  color: rgba(244, 239, 228, 0.7);
  font-size: 15px;
  letter-spacing: 0.04em;
}
.bs-atks { display: flex; gap: 8px; align-items: center; margin: 14px 0 18px; }
.bs-atk {
  width: 36px;
  height: 36px;
  display: grid;
  place-items: center;
  font-weight: 700;
  font-size: 16px;
  background: #1d222d;
  border: 1px solid rgba(244,239,228,.35);
  clip-path: polygon(25% 0, 75% 0, 100% 50%, 75% 100%, 25% 100%, 0 50%);
}
.bs-atk.sp { background: rgba(226, 61, 61, 0.28); border-color: var(--blood); color: #ffd0c8; }
.bs-atk.off { opacity: .22; }
.bs-special {
  margin-left: 6px;
  padding: 5px 12px;
  font-weight: 700;
  font-size: 14px;
  letter-spacing: 0.08em;
  color: #ffd0c8;
  border: 1px solid rgba(226, 61, 61, 0.6);
  background: rgba(226, 61, 61, 0.14);
}
.bs-stats { display: grid; gap: 9px; }
.bs-stat {
  display: grid;
  grid-template-columns: 44px 1fr 48px;
  align-items: center;
  gap: 12px;
}
.bs-stat b {
  font-family: "Barlow Condensed", "Noto Sans KR", sans-serif;
  font-size: 16px;
  letter-spacing: 0.06em;
  color: rgba(244, 239, 228, 0.78);
}
.bs-stat em {
  font-style: normal;
  font-family: "Barlow Condensed", sans-serif;
  font-weight: 700;
  font-size: 20px;
  text-align: right;
}
.bs-bar {
  height: 10px;
  background: rgba(255,255,255,.07);
  border: 1px solid rgba(255,255,255,.08);
  overflow: hidden;
}
.bs-bar i {
  display: block;
  height: 100%;
  background: linear-gradient(90deg, #8d6a2e, var(--brass));
  transition: width .3s ease;
}
.bs-s-hp .bs-bar i { background: linear-gradient(90deg, #7c1d1d, var(--blood)); }
.bs-s-mp .bs-bar i { background: linear-gradient(90deg, #1d4a7c, #5fa8ef); }
.bs-army { margin-top: 18px; display: flex; align-items: center; gap: 12px; }
.bs-army > b {
  font-size: 15px;
  letter-spacing: 0.06em;
  color: rgba(244, 239, 228, 0.78);
  width: 44px;
}
.bs-army-row { display: flex; gap: 8px; flex-wrap: wrap; }
.bs-army-chip {
  display: inline-flex;
  align-items: baseline;
  gap: 4px;
  padding: 4px 10px;
  border: 1px solid var(--g);
  background: rgba(0,0,0,.35);
}
.bs-army-chip b {
  font-family: "Barlow Condensed", sans-serif;
  font-size: 17px;
  color: var(--g);
}
.bs-army-chip em { font-style: normal; font-weight: 700; font-size: 15px; }

.bs-foot {
  display: flex;
  align-items: flex-end;
  justify-content: center;
  gap: 36px;
  padding: 10px 40px 28px;
}
.bs-cards { display: flex; gap: 16px; }
.bs-card {
  position: relative;
  width: 132px;
  height: 176px;
  padding: 0;
  border: 2px solid rgba(244,239,228,.16);
  background: #0e1016;
  color: var(--ivory);
  overflow: hidden;
  cursor: pointer;
  transform: translateY(0);
  transition: transform .16s ease, border-color .16s ease, box-shadow .16s ease, filter .16s ease;
  filter: saturate(.75) brightness(.78);
}
.bs-card:hover { transform: translateY(-6px); filter: none; border-color: rgba(244,239,228,.5); }
.bs-card.on {
  transform: translateY(-12px);
  filter: none;
  border-color: var(--g);
  box-shadow: 0 0 0 1px rgba(0,0,0,.8), 0 0 26px color-mix(in srgb, var(--g) 55%, transparent), 0 14px 30px rgba(0,0,0,.6);
}
.bs-card.on::before {
  content: "";
  position: absolute;
  left: 50%;
  top: -1px;
  width: 0;
  height: 0;
  transform: translateX(-50%);
  border: 8px solid transparent;
  border-top-color: var(--g);
  z-index: 2;
}
.bs-card-art { position: absolute; inset: 0; }
.bs-card-art img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: 50% 12%;
  display: block;
  user-select: none;
}
.bs-card::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, transparent 52%, rgba(0,0,0,.88) 100%);
  pointer-events: none;
}
.bs-card-grade {
  position: absolute;
  top: 6px;
  left: 6px;
  z-index: 1;
  font-family: "Barlow Condensed", sans-serif;
  font-weight: 700;
  font-size: 14px;
  padding: 0 6px;
  color: var(--g);
  background: rgba(0,0,0,.65);
  border: 1px solid var(--g);
}
.bs-card-name {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 9px;
  z-index: 1;
  text-align: center;
  font-family: "Black Han Sans", sans-serif;
  font-size: 19px;
  letter-spacing: 0.06em;
  text-shadow: 0 2px 4px #000;
}
.bs-card.locked { cursor: default; filter: grayscale(1) brightness(.45); }
.bs-card.locked.on { filter: grayscale(1) brightness(.6); border-color: rgba(244,239,228,.4); box-shadow: none; }
.bs-card-lock {
  position: absolute;
  inset: 0;
  z-index: 2;
  display: grid;
  place-items: center;
  color: rgba(244,239,228,.85);
}
.bs-go {
  min-width: 190px;
  height: 64px;
  border: 0;
  background: var(--brass);
  color: var(--ink);
  font-family: "Black Han Sans", sans-serif;
  font-size: 26px;
  letter-spacing: 0.2em;
  clip-path: polygon(10% 0, 100% 0, 90% 100%, 0 100%);
  margin-bottom: 4px;
  transition: background .15s ease, transform .15s ease;
}
.bs-go:hover:not(:disabled) { background: #f0cb7a; transform: translateY(-2px); }
.bs-go:disabled { background: #3a3832; color: #77736a; cursor: default; }

@media (prefers-reduced-motion: reduce) {
  .bs-portrait, .bs-panel { animation: none; }
  .bs-card, .bs-bar i, .bs-go { transition: none; }
}
