:root {
  --bg: #f4f5f8;
  --surface: #ffffff;
  --surface-2: #f1f3f6;
  --border: #e3e6eb;
  --text: #171a20;
  --muted: #6b7280;
  --accent: #4f46e5;
  --accent-hover: #4338ca;
  --accent-weak: #eef0ff;
  --on-accent: #ffffff;
  --ok: #15803d;
  --ok-weak: #e7f6ec;
  --warn: #b45309;
  --warn-weak: #fff4e0;
  --danger: #dc2626;
  --danger-weak: #fdecec;
  --shadow: 0 1px 2px rgba(16, 24, 40, .04), 0 1px 3px rgba(16, 24, 40, .06);
  --radius: 14px;
  --radius-sm: 9px;
  color-scheme: light;
}
@media (prefers-color-scheme: dark) {
  :root {
    --bg: #0e1015;
    --surface: #161920;
    --surface-2: #1e222b;
    --border: #2a2f3a;
    --text: #e8eaf0;
    --muted: #9aa2b1;
    --accent: #8b93ff;
    --accent-hover: #a3a9ff;
    --accent-weak: #22254a;
    --on-accent: #0e1015;
    --ok: #4ade80;
    --ok-weak: #11281a;
    --warn: #fbbf24;
    --warn-weak: #2c2310;
    --danger: #f87171;
    --danger-weak: #2e1616;
    --shadow: none;
    color-scheme: dark;
  }
}

* { box-sizing: border-box; }
[hidden] { display: none !important; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: "Pretendard Variable", Pretendard, -apple-system, BlinkMacSystemFont, "Apple SD Gothic Neo", "Malgun Gothic", sans-serif;
  font-size: 15px;
  line-height: 1.5;
  word-break: keep-all;
}
h1, h2, h3 { margin: 0; line-height: 1.3; }
h1 { font-size: 22px; font-weight: 700; letter-spacing: -.01em; }
h2 { font-size: 17px; font-weight: 700; }
h3 { font-size: 15px; font-weight: 650; }
p { margin: 0; }
button, input, select, textarea { font: inherit; color: inherit; }
.muted { color: var(--muted); }
.small { font-size: 13px; }
.mono { font-variant-numeric: tabular-nums; }
.boot { padding: 80px 16px; text-align: center; color: var(--muted); }

/* ---------- 레이아웃 */
.container { max-width: 1080px; margin: 0 auto; padding: 24px 16px 64px; }
.topbar {
  position: sticky; top: 0; z-index: 10;
  background: color-mix(in srgb, var(--surface) 88%, transparent);
  backdrop-filter: saturate(1.4) blur(10px);
  border-bottom: 1px solid var(--border);
}
.topbar-inner, .tabs-inner { max-width: 1080px; margin: 0 auto; padding: 0 16px; }
.topbar-inner { display: flex; align-items: center; justify-content: space-between; gap: 12px; height: 60px; }
.brand { display: flex; align-items: center; gap: 10px; min-width: 0; }
.brand-mark {
  display: grid; place-items: center; flex: none;
  width: 34px; height: 34px; border-radius: 10px;
  background: var(--accent); color: var(--on-accent); font-size: 17px;
}
.brand-name { font-weight: 700; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.brand-sub { font-size: 12px; color: var(--muted); white-space: nowrap; }
.me { display: flex; align-items: center; gap: 8px; flex: none; }
.me-name { font-weight: 600; font-size: 14px; }
.tabs-inner { display: flex; gap: 4px; overflow-x: auto; scrollbar-width: none; }
.tabs-inner::-webkit-scrollbar { display: none; }
.tab {
  flex: none; padding: 10px 12px; border: 0; background: none; cursor: pointer;
  color: var(--muted); font-weight: 600; border-bottom: 2px solid transparent;
}
.tab:hover { color: var(--text); }
.tab.active { color: var(--accent); border-bottom-color: var(--accent); }

.page-head { display: flex; align-items: flex-end; justify-content: space-between; gap: 16px; margin-bottom: 20px; flex-wrap: wrap; }
.page-head p { margin-top: 4px; }
.head-actions { display: flex; gap: 8px; flex-wrap: wrap; }
.count-pill {
  display: inline-block; vertical-align: middle; margin-left: 4px; padding: 1px 9px;
  border-radius: 99px; background: var(--accent-weak); color: var(--accent); font-size: 14px;
}

.card { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); box-shadow: var(--shadow); }
.section { padding: 20px; margin-bottom: 16px; }
.section > h2 { display: flex; align-items: center; gap: 8px; margin-bottom: 6px; }
.section > p { margin-bottom: 14px; }
.stack { display: grid; gap: 12px; }
.row { display: flex; gap: 8px; align-items: center; }
.row.wrap { flex-wrap: wrap; }
.grid-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
@media (max-width: 560px) { .grid-2 { grid-template-columns: 1fr; } }
.hint { margin-top: 14px; color: var(--muted); font-size: 13px; text-align: center; }

/* ---------- 버튼 · 입력 */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 6px;
  height: 40px; padding: 0 16px; border-radius: var(--radius-sm);
  border: 1px solid var(--border); background: var(--surface); cursor: pointer;
  font-weight: 600; white-space: nowrap; transition: background .15s, border-color .15s;
}
.btn:hover { background: var(--surface-2); }
.btn:disabled { opacity: .55; cursor: default; }
.btn.primary { background: var(--accent); border-color: var(--accent); color: var(--on-accent); }
.btn.primary:hover { background: var(--accent-hover); border-color: var(--accent-hover); }
.btn.danger-solid { background: var(--danger); border-color: var(--danger); color: #fff; }
.btn.ghost { background: transparent; }
.btn.ghost:hover { background: var(--surface-2); }
.btn.danger { color: var(--danger); }
.btn.sm { height: 32px; padding: 0 10px; font-size: 13px; border-radius: 8px; }
.btn.block { width: 100%; }
.icon-btn { border: 0; background: none; cursor: pointer; color: var(--muted); font-size: 18px; width: 32px; height: 32px; border-radius: 8px; }
.icon-btn:hover { background: var(--surface-2); color: var(--text); }

.input, .field input, .field select, .field textarea {
  width: 100%; height: 42px; padding: 0 12px;
  border: 1px solid var(--border); border-radius: var(--radius-sm);
  background: var(--surface); outline: none;
}
.field textarea { height: auto; min-height: 150px; padding: 10px 12px; resize: vertical; line-height: 1.6; }
.input:focus, .field input:focus, .field select:focus, .field textarea:focus {
  border-color: var(--accent); box-shadow: 0 0 0 3px var(--accent-weak);
}
.field { display: grid; gap: 6px; }
.field > span { font-size: 13px; font-weight: 600; color: var(--muted); }
.field.inline { min-width: 150px; flex: 1; }
.form-error { color: var(--danger); font-size: 13px; min-height: 0; }
.form-error:empty { display: none; }
.check { display: flex; align-items: center; gap: 8px; padding: 12px; border-radius: var(--radius-sm); background: var(--surface-2); cursor: pointer; font-weight: 600; }
.check input { width: 18px; height: 18px; accent-color: var(--accent); }

.badge {
  display: inline-block; margin-left: 6px; padding: 1px 7px; border-radius: 6px;
  font-size: 11px; font-weight: 700; background: var(--accent-weak); color: var(--accent); vertical-align: 1px;
}
.badge.me { background: var(--surface-2); color: var(--muted); }
.badge.leader { background: var(--accent); color: var(--on-accent); }
.badge.ok { background: var(--ok-weak); color: var(--ok); margin: 0; }
.badge.warn { background: var(--warn-weak); color: var(--warn); margin: 0; }
.role-badge { padding: 3px 9px; border-radius: 99px; font-size: 12px; font-weight: 700; background: var(--surface-2); color: var(--muted); }
.role-master, .role-admin { background: var(--accent-weak); color: var(--accent); }
.chip {
  display: inline-flex; align-items: center; padding: 3px 10px; border-radius: 99px;
  background: var(--surface-2); font-size: 13px; font-weight: 500;
}
.chip.me { background: var(--accent-weak); color: var(--accent); font-weight: 700; }
.chip.gone { text-decoration: line-through; color: var(--muted); }

.filters { display: flex; gap: 6px; flex-wrap: wrap; margin-bottom: 16px; }
.filter {
  height: 34px; padding: 0 14px; border-radius: 99px; border: 1px solid var(--border);
  background: var(--surface); cursor: pointer; font-weight: 600; font-size: 14px; color: var(--muted);
}
.filter.active { background: var(--text); border-color: var(--text); color: var(--surface); }

.empty { padding: 48px 16px; text-align: center; color: var(--muted); }
.empty b { display: block; color: var(--text); font-size: 16px; margin-bottom: 4px; }
.loading { padding: 32px; text-align: center; color: var(--muted); }

/* ---------- 설정 안내 배너 */
.setup { padding: 18px 20px; margin-bottom: 20px; border-color: color-mix(in srgb, var(--accent) 35%, var(--border)); background: var(--accent-weak); }
.setup h2 { font-size: 16px; margin-bottom: 8px; }
.setup ol { margin: 0; padding-left: 20px; }
.setup li { margin: 3px 0; }
.setup li.done { color: var(--muted); text-decoration: line-through; }

/* ---------- 필드보스 */
.upcoming { padding: 6px 0; margin-bottom: 20px; }
.up-row { display: grid; grid-template-columns: 12px 1fr auto auto; align-items: center; gap: 12px; padding: 10px 18px; }
.up-row + .up-row { border-top: 1px solid var(--border); }
.upcoming.editable .up-row { grid-template-columns: 12px 1fr auto auto auto; padding-right: 10px; }
.up-row .up-fixed { font-size: 12px; color: var(--accent); white-space: nowrap; margin-left: 4px; }
.up-row .up-edit { width: 30px; height: 30px; font-size: 14px; }
.up-row .when { font-variant-numeric: tabular-nums; font-weight: 600; }
.up-row .left { font-variant-numeric: tabular-nums; color: var(--muted); font-size: 13px; min-width: 88px; text-align: right; }
.up-empty { padding: 14px 18px; color: var(--muted); font-size: 14px; }
.dot { width: 10px; height: 10px; border-radius: 50%; background: var(--muted); }
.dot.wait { background: var(--accent); }
.dot.soon { background: var(--warn); box-shadow: 0 0 0 4px var(--warn-weak); }
.dot.up { background: var(--ok); box-shadow: 0 0 0 4px var(--ok-weak); }

.boss-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); gap: 14px; }
.boss { padding: 18px; display: flex; flex-direction: column; gap: 12px; transition: border-color .2s; }
.boss-top { display: flex; align-items: center; justify-content: space-between; gap: 8px; }
.boss-state .big { font-size: 28px; font-weight: 750; letter-spacing: -.01em; font-variant-numeric: tabular-nums; }
.boss-state .sub { font-size: 13px; color: var(--muted); margin-top: 2px; font-variant-numeric: tabular-nums; }
.boss-state .big small { font-size: 14px; font-weight: 600; color: var(--muted); margin-right: 6px; letter-spacing: 0; }
.boss-state .sub { font-size: 14px; font-weight: 600; }
.boss[data-state="up"] .sub b { color: var(--ok); }
.boss[data-state="soon"] .sub { color: var(--warn); }
.boss[data-state="unknown"] .big { color: var(--muted); font-size: 22px; }
.boss[data-state="soon"] { border-color: var(--warn); }
.boss[data-state="soon"] .big { color: var(--warn); }
.boss[data-state="up"] { border-color: var(--ok); }
.boss[data-state="up"] .big { color: var(--ok); }
.progress { height: 6px; border-radius: 99px; background: var(--surface-2); overflow: hidden; }
.progress > div { height: 100%; width: 0; background: var(--accent); border-radius: inherit; transition: width .5s linear; }
.boss[data-state="soon"] .progress > div { background: var(--warn); }
.boss[data-state="up"] .progress > div { background: var(--ok); }
.boss-meta { font-size: 13px; color: var(--muted); min-height: 20px; margin-top: auto; }
.boss-fixed { font-size: 13px; color: var(--accent); }
.boss-fixed:empty { display: none; }

/* ---------- 참여 기록 */
.day { font-size: 13px; color: var(--muted); font-weight: 700; margin: 22px 2px 8px; }
.day:first-child { margin-top: 0; }
.event { padding: 16px 18px; margin-bottom: 10px; }
.event-head { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.event-head h3 { font-size: 16px; }
.event-head .time { color: var(--muted); font-size: 14px; font-variant-numeric: tabular-nums; }
.event-head .count { margin-left: auto; font-weight: 700; font-size: 14px; }
.tag { padding: 2px 8px; border-radius: 6px; font-size: 12px; font-weight: 700; }
.tag-boss { background: var(--accent-weak); color: var(--accent); }
.tag-war { background: var(--danger-weak); color: var(--danger); }
.chips { display: flex; flex-wrap: wrap; gap: 6px; margin: 12px 0; }
.event-foot { display: flex; align-items: center; justify-content: space-between; gap: 8px; flex-wrap: wrap; }
.actions, .row-actions { display: flex; gap: 6px; justify-content: flex-end; }

/* ---------- 표 */
.table-card { overflow: hidden; margin-bottom: 16px; }
.table-tools { display: flex; align-items: center; gap: 8px; padding: 14px; border-bottom: 1px solid var(--border); }
.table-tools .input { max-width: 320px; }
.table-tools.between { justify-content: space-between; }
.table-wrap { overflow-x: auto; }
.table { width: 100%; border-collapse: collapse; font-size: 14px; }
.table th {
  text-align: left; font-size: 12px; font-weight: 700; color: var(--muted);
  padding: 10px 14px; background: var(--surface-2); white-space: nowrap;
}
.table td { padding: 11px 14px; border-top: 1px solid var(--border); white-space: nowrap; }
.table tr.is-me td { background: color-mix(in srgb, var(--accent-weak) 55%, transparent); }
.table tr.dim td { color: var(--muted); }
.table .num { text-align: right; font-variant-numeric: tabular-nums; }
.table .strong { font-weight: 700; }
.table .nick { font-weight: 600; }
.empty-cell { text-align: center; color: var(--muted); padding: 36px 14px !important; }
.boss-table td { padding: 8px 10px; }
.boss-table .input { height: 36px; min-width: 90px; }
.add-row { padding-top: 14px; }
.add-row .input { flex: 1; min-width: 120px; }
.pad { padding: 12px 14px; }

/* ---------- 정산 */
.stats-controls { padding: 16px 18px; margin-bottom: 16px; }
.stats-controls .filters { margin-bottom: 12px; }
.stats-controls .row { margin-bottom: 10px; align-items: flex-end; }
.kpis { display: grid; grid-template-columns: repeat(auto-fit, minmax(140px, 1fr)); gap: 12px; margin-bottom: 16px; }
@media (max-width: 640px) { .kpis { grid-template-columns: repeat(2, 1fr); } }
.kpi { padding: 14px 16px; }
.kpi span { display: block; font-size: 13px; color: var(--muted); }
.kpi b { font-size: 22px; font-variant-numeric: tabular-nums; }
.share { position: relative; min-width: 90px; height: 22px; border-radius: 6px; background: var(--surface-2); overflow: hidden; }
.share-bar { position: absolute; inset: 0 auto 0 0; background: var(--accent-weak); }
.share span { position: relative; display: block; line-height: 22px; padding: 0 6px; font-size: 13px; }

/* ---------- 로그인 */
.login-wrap { min-height: 100vh; display: grid; place-items: center; padding: 24px 16px; }
.login { width: 100%; max-width: 400px; padding: 28px 24px; }
.login .brand { flex-direction: column; text-align: center; gap: 12px; margin-bottom: 24px; }
.login .brand-mark { width: 52px; height: 52px; font-size: 26px; border-radius: 14px; }
.seg { display: grid; grid-auto-flow: column; grid-auto-columns: 1fr; gap: 4px; padding: 4px; border-radius: 11px; background: var(--surface-2); margin-bottom: 18px; }
.seg-btn { height: 36px; border: 0; border-radius: 8px; background: none; cursor: pointer; font-weight: 600; font-size: 14px; color: var(--muted); }
.seg-btn.active { background: var(--surface); color: var(--text); box-shadow: var(--shadow); }
.login form { display: grid; gap: 14px; }
.login input[name="secret"] { height: 48px; font-size: 17px; letter-spacing: .04em; }

/* ---------- 모달 */
dialog {
  width: min(520px, calc(100vw - 24px)); max-height: calc(100vh - 32px);
  padding: 0; border: 1px solid var(--border); border-radius: 18px;
  background: var(--surface); color: var(--text); box-shadow: 0 20px 60px rgba(0, 0, 0, .25);
}
dialog::backdrop { background: rgba(10, 12, 20, .5); backdrop-filter: blur(2px); }
.modal { display: flex; flex-direction: column; max-height: calc(100vh - 34px); }
.modal-head { display: flex; align-items: center; justify-content: space-between; padding: 18px 20px 4px; }
.modal-body { padding: 12px 20px; overflow-y: auto; display: grid; gap: 14px; }
.modal .form-error { padding: 0 20px; }
.modal-foot { display: flex; justify-content: flex-end; gap: 8px; padding: 12px 20px 18px; }
.modal-body p { color: var(--muted); font-size: 14px; }

.picker { border: 1px solid var(--border); border-radius: var(--radius-sm); overflow: hidden; }
.picker-tools { display: flex; gap: 6px; padding: 8px; border-bottom: 1px solid var(--border); background: var(--surface-2); }
.picker-tools input { flex: 1; height: 32px; padding: 0 10px; border: 1px solid var(--border); border-radius: 8px; background: var(--surface); outline: none; min-width: 0; }
.picker-list { max-height: 260px; overflow-y: auto; display: grid; grid-template-columns: repeat(auto-fill, minmax(140px, 1fr)); gap: 2px; padding: 6px; }
.pick { display: flex; align-items: center; gap: 8px; padding: 7px 8px; border-radius: 7px; cursor: pointer; font-size: 14px; min-width: 0; }
.pick:hover { background: var(--surface-2); }
.pick input { width: 16px; height: 16px; accent-color: var(--accent); flex: none; }
.pick span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.pick small { color: var(--muted); margin-left: auto; font-size: 12px; white-space: nowrap; }
.pick:has(input:checked) { background: var(--accent-weak); }

.code-list { display: grid; gap: 6px; }
.code-row { display: grid; grid-template-columns: 1fr auto auto; align-items: center; gap: 10px; padding: 8px 10px; border-radius: var(--radius-sm); background: var(--surface-2); }
.code-row code { font-size: 15px; font-weight: 700; letter-spacing: .06em; }

/* ---------- 토스트 */
#toast {
  position: fixed; left: 50%; bottom: 24px; transform: translate(-50%, 20px); z-index: 100;
  max-width: calc(100vw - 32px); padding: 11px 18px; border-radius: 12px;
  background: var(--text); color: var(--surface); font-weight: 600; font-size: 14px;
  opacity: 0; pointer-events: none; transition: opacity .2s, transform .2s;
}
#toast.show { opacity: 1; transform: translate(-50%, 0); }
#toast.error { background: var(--danger); color: #fff; }

@media (max-width: 560px) {
  .container { padding-top: 18px; }
  .me-name { display: none; }
  .brand-sub { display: none; }
  .up-row { padding: 10px 14px; gap: 2px 10px; }
  .up-row .dot, .up-row > span:nth-child(2) { grid-row: 1 / span 2; }
  .up-row .when { grid-column: 3; white-space: nowrap; text-align: right; }
  .up-row .left { grid-column: 3; grid-row: 2; min-width: 0; font-size: 12px; }
  .up-row .up-edit { grid-column: 4; grid-row: 1 / span 2; }
  .upcoming .up-row, .upcoming.editable .up-row { grid-template-columns: 12px 1fr auto auto; }
  .page-head > .btn, .head-actions { width: 100%; }
  .head-actions .btn { flex: 1; }
}

/* ---------- 직위별 권한표 */
.perm-table td, .perm-table th { white-space: normal; }
.perm-table td:first-child { min-width: 200px; }
.perm-table .center, .boss-table .center { text-align: center; }
.perm-table input[type=checkbox] { width: 18px; height: 18px; accent-color: var(--accent); cursor: pointer; }
.perm-table input:disabled { cursor: default; opacity: .6; }

/* ---------- 정렬 가능한 표 머리글 */
.table th .sort {
  display: inline-flex; align-items: center; gap: 4px; padding: 0; border: 0; background: none;
  font: inherit; color: inherit; cursor: pointer; white-space: nowrap;
}
.table th .sort:hover { color: var(--text); }
.table th .sort.on { color: var(--accent); }
.table th .sort .arrow { font-size: 10px; opacity: .5; }
.table th .sort.on .arrow { opacity: 1; }
.event-head .by { padding: 2px 8px; border-radius: 6px; background: var(--surface-2); font-size: 13px; font-weight: 600; }

/* ---------- 참여 점수 기준 */
.score-guide { padding: 0; margin-bottom: 16px; }
.score-guide summary { display: flex; align-items: baseline; gap: 10px; flex-wrap: wrap; padding: 14px 18px; cursor: pointer; list-style: none; }
.score-guide summary::-webkit-details-marker { display: none; }
.score-guide summary::after { content: '▾'; margin-left: auto; color: var(--muted); transition: transform .15s; }
.score-guide:not([open]) summary::after { transform: rotate(-90deg); }
.score-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(120px, 1fr)); gap: 8px; padding: 0 18px; }
.score-item { display: flex; justify-content: space-between; align-items: center; padding: 9px 12px; border-radius: var(--radius-sm); background: var(--surface-2); font-size: 14px; }
.score-item b { font-variant-numeric: tabular-nums; }
.score-item.war { background: var(--danger-weak); }
.score-item.war b { color: var(--danger); }
.score-guide > p { padding: 10px 18px 14px; }
.tag-plan { background: var(--warn-weak); color: var(--warn); }

/* ---------- 공지 */
.tab.has-dot { position: relative; }
.tab.has-dot::after { content: ''; position: absolute; top: 8px; right: 3px; width: 7px; height: 7px; border-radius: 50%; background: var(--danger); }
.link-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); gap: 12px; margin-bottom: 16px; }
.link-card { display: flex; align-items: center; gap: 14px; padding: 16px 18px; color: inherit; text-decoration: none; transition: border-color .15s, transform .15s; }
.link-card:hover { transform: translateY(-1px); }
.link-card > span:nth-child(2) { display: grid; gap: 2px; min-width: 0; }
.link-icon { display: grid; place-items: center; flex: none; width: 42px; height: 42px; border-radius: 12px; font-size: 20px; }
.link-go { margin-left: auto; font-size: 13px; font-weight: 700; white-space: nowrap; }
.link-card.kakao .link-icon { background: #fee500; }
.link-card.kakao:hover { border-color: #e6cf00; }
.link-card.kakao .link-go { color: #8a7a00; }
.link-card.discord .link-icon { background: #5865f2; }
.link-card.discord:hover { border-color: #5865f2; }
.link-card.discord .link-go { color: #5865f2; }
@media (prefers-color-scheme: dark) {
  .link-card.kakao .link-go { color: #fee500; }
  .link-card.discord .link-go { color: #8b95ff; }
}
.notice { padding: 20px 22px; }
.notice-body { white-space: pre-wrap; word-break: break-word; line-height: 1.75; font-size: 15px; }
.notice-body a { color: var(--accent); }
.notice-meta { margin-top: 16px; padding-top: 12px; border-top: 1px solid var(--border); }
.notice .empty { padding: 32px 8px; }

/* ---------- 업데이트 내역 */
.changelog { padding: 16px 20px; margin-bottom: 10px; }
.changelog-head { display: flex; align-items: center; justify-content: space-between; gap: 10px; }
.changelog-head h2 { font-size: 16px; }
.changelog ul { margin: 10px 0 0; padding-left: 20px; display: grid; gap: 4px; }
.changelog li { line-height: 1.6; }
.changelog li::marker { color: var(--accent); }
.changelog a { color: var(--accent); }
.steps { margin: 0; padding-left: 20px; display: grid; gap: 6px; font-size: 14px; }
.modal-body, .picker-list { overflow-x: hidden; }
dialog { overflow-x: hidden; }

/* 알림 시간 선택 */
.lead-chips { display: flex; flex-wrap: wrap; gap: 8px; }
.lead-chip { position: relative; cursor: pointer; }
.lead-chip input { position: absolute; opacity: 0; pointer-events: none; }
.lead-chip span { display: inline-block; padding: 8px 14px; border-radius: 99px; border: 1px solid var(--border); font-weight: 600; font-size: 14px; color: var(--muted); background: var(--surface); }
.lead-chip input:checked + span { background: var(--accent); border-color: var(--accent); color: var(--on-accent); }
.lead-chip input:focus-visible + span { box-shadow: 0 0 0 3px var(--accent-weak); }

/* 알림 방식 선택 */
.mode-options { display: grid; gap: 8px; }
.mode-option { display: flex; align-items: flex-start; gap: 10px; padding: 12px; border: 1px solid var(--border); border-radius: var(--radius-sm); cursor: pointer; }
.mode-option input { margin-top: 3px; width: 17px; height: 17px; accent-color: var(--accent); flex: none; }
.mode-option span { display: grid; gap: 2px; }
.mode-option small { color: var(--muted); font-size: 13px; }
.mode-option:has(input:checked) { border-color: var(--accent); background: var(--accent-weak); }

/* ---------- 공홈 */
.filter.has-dot { position: relative; }
.filter.has-dot::after { content: ''; position: absolute; top: 2px; right: 2px; width: 7px; height: 7px; border-radius: 50%; background: var(--danger); }
.official-list { overflow: hidden; margin-bottom: 12px; }
.official-item { display: flex; align-items: center; gap: 10px; padding: 14px 18px; color: inherit; text-decoration: none; }
.official-item + .official-item { border-top: 1px solid var(--border); }
.official-item:hover { background: var(--surface-2); }
.official-title { flex: 1; min-width: 0; font-weight: 600; line-height: 1.45; }
.official-title .new { display: inline-block; margin-left: 6px; padding: 0 5px; border-radius: 4px; background: var(--danger); color: #fff; font-size: 10px; font-weight: 800; vertical-align: 2px; }
.official-date { flex: none; color: var(--muted); font-size: 13px; font-variant-numeric: tabular-nums; }
.tag-official { flex: none; background: var(--surface-2); color: var(--muted); }
@media (max-width: 560px) {
  .official-item { flex-wrap: wrap; row-gap: 4px; padding: 12px 14px; }
  .official-title { flex-basis: 100%; order: 3; }
}
@media (max-width: 560px) {
  .tabs-inner { gap: 0; padding: 0 6px; }
  .tab { padding: 10px 7px; font-size: 14px; letter-spacing: -0.02em; }
  .tab.has-dot::after { top: 7px; right: 1px; }
}

/* ---------- 아이템 지급 */
.wrap-tools { flex-wrap: wrap; }
.wrap-tools .input { flex: 1; min-width: 200px; }
.inline-filters { margin: 0; }
.grant-table td { vertical-align: middle; }
.grant-note { white-space: normal !important; min-width: 140px; color: var(--muted); font-size: 13px; }
.link-btn { padding: 0; border: 0; background: none; cursor: pointer; font: inherit; color: inherit; text-align: left; }
.link-btn:hover { color: var(--accent); text-decoration: underline; }
.tag-free { background: var(--ok-weak); color: var(--ok); }
.tag-dia { background: var(--accent-weak); color: var(--accent); white-space: nowrap; }
.price-input { width: 150px; flex: none; }
.item-list { display: grid; gap: 6px; }
.item-row { display: grid; grid-template-columns: 1fr auto auto auto; align-items: center; gap: 8px; }
.item-row .input { height: 36px; }
.kpi b small { display: block; font-size: 13px; font-weight: 600; color: var(--muted); }
@media (max-width: 560px) {
  /* 지급 기록: 휴대폰에서는 표 대신 카드 모양 */
  .grant-table thead { display: none; }
  .grant-table, .grant-table tbody { display: block; }
  .grant-table tr { display: grid; grid-template-columns: 1fr auto; gap: 4px 10px; padding: 12px 14px; border-top: 1px solid var(--border); }
  .grant-table tr:first-child { border-top: 0; }
  .grant-table td { border: 0; padding: 0; white-space: normal; }
  .grant-table td:nth-child(2) { grid-column: 1; grid-row: 1; font-size: 15px; }
  .grant-table td:nth-child(4) { grid-column: 2; grid-row: 1; justify-self: end; }
  .grant-table td:nth-child(3) { grid-column: 1; grid-row: 2; }
  .grant-table td:nth-child(1) { grid-column: 2; grid-row: 2; justify-self: end; font-size: 13px; }
  .grant-table td:nth-child(5) { grid-column: 1 / -1; min-width: 0; }
  .grant-table td:nth-child(6) { grid-column: 1 / -1; }
  .grant-table td:nth-child(6) .row-actions { justify-content: flex-start; }
  .grant-table td:nth-child(5):has(.muted:only-child), .grant-table td:nth-child(6):empty { display: none; }
  .grant-table .empty-cell { grid-column: 1 / -1; }
}

/* ---------- 상품 */
.product-posts { padding: 16px 18px; margin-bottom: 16px; }
.product-posts h2 { font-size: 15px; margin-bottom: 6px; }
.product-post { border-top: 1px solid var(--border); }
.product-post:first-of-type { border-top: 0; }
.product-post summary { display: flex; justify-content: space-between; align-items: center; gap: 10px; padding: 10px 0; cursor: pointer; list-style: none; }
.product-post summary::-webkit-details-marker { display: none; }
.post-title { font-weight: 600; }
.post-ended .post-title { color: var(--muted); }
.post-body { white-space: pre-wrap; font-size: 14px; color: var(--muted); padding: 0 0 12px; line-height: 1.7; }
.product-posts > .btn { margin-top: 6px; }
.product-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); gap: 14px; }
.product { padding: 18px; display: flex; flex-direction: column; gap: 8px; }
.product.ended { opacity: .65; }
.product-head { display: flex; justify-content: space-between; align-items: flex-start; gap: 10px; }
.product-head h2 { font-size: 16px; }
.product-head .badge { margin: 0; flex: none; }
.product-period, .product-meta { font-size: 14px; }
.components { margin: 0; padding: 10px 12px 10px 28px; border-radius: var(--radius-sm); background: var(--surface-2); font-size: 13px; display: grid; gap: 3px; }
.product-foot { display: flex; justify-content: space-between; align-items: center; gap: 8px; flex-wrap: wrap; margin-top: auto; padding-top: 6px; }
.product-foot a { text-decoration: none; }
.product-foot a:hover { text-decoration: underline; }

/* ---------- 길드 보스 */
.guild-boss { display: flex; align-items: center; gap: 14px; padding: 16px 18px; margin-bottom: 14px;
  background: linear-gradient(135deg, var(--accent-weak), var(--surface)); border-color: color-mix(in srgb, var(--accent) 30%, var(--border)); }
.gb-icon { display: grid; place-items: center; flex: none; width: 46px; height: 46px; border-radius: 12px; background: var(--surface); font-size: 24px; }
.gb-main { flex: 1; min-width: 0; display: grid; gap: 4px; }
.gb-title { display: flex; align-items: baseline; gap: 8px; flex-wrap: wrap; }
.gb-title b { font-size: 16px; }
.gb-state { display: flex; align-items: baseline; gap: 10px; flex-wrap: wrap; font-variant-numeric: tabular-nums; }
.gb-when { font-size: 20px; font-weight: 750; }
.gb-left { color: var(--muted); font-size: 14px; font-weight: 600; }
.guild-boss[data-state="soon"] { border-color: var(--warn); }
.guild-boss[data-state="soon"] .gb-left { color: var(--warn); }
.guild-boss[data-state="live"] { border-color: var(--ok); }
.gb-live { font-size: 20px; color: var(--ok); }

/* 길드 보스 기록 */
.tag-guild { background: var(--ok-weak); color: var(--ok); }
.score-item.guild { background: var(--ok-weak); }
.score-item.guild b { color: var(--ok); }

/* ---------- 파티 */
.party-summary { padding: 14px 18px; margin-bottom: 16px; display: grid; gap: 10px; }
.between-row { justify-content: space-between; }
.size-input { width: 76px; height: 32px; }
.unassigned summary { cursor: pointer; font-weight: 600; }
.party-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(320px, 1fr)); gap: 14px; }
.party { padding: 16px 18px; display: flex; flex-direction: column; gap: 8px; }
.party-head { display: flex; justify-content: space-between; align-items: center; gap: 8px; }
.party-head h2 { font-size: 17px; }
.party-head .badge { margin: 0; }
.pm-list { list-style: none; margin: 0; padding: 0; display: grid; }
.pm-row { display: grid; grid-template-columns: 1fr auto; gap: 2px 10px; padding: 8px 0; border-top: 1px solid var(--border); }
.pm-row:first-child { border-top: 0; }
.pm-name { min-width: 0; }
.pm-name .badge { vertical-align: 1px; }
.pm-meta { grid-column: 1; }
.pm-row .pw { grid-column: 2; grid-row: 1 / span 2; align-self: center; text-align: right; }
.pw { font-size: 13px; font-weight: 700; font-variant-numeric: tabular-nums; white-space: nowrap; }
.pw small { font-weight: 500; color: var(--muted); }
.pw.stale, .pw.stale small { color: var(--warn); }
.party-foot { display: flex; justify-content: space-between; align-items: center; margin-top: auto; padding-top: 6px; }
.party-picker { grid-template-columns: 1fr; max-height: 340px; }
.party-picker .pick { align-items: flex-start; }
.party-picker .pick input { margin-top: 3px; }
.pick-main { display: grid; gap: 1px; min-width: 0; }
.pick-main small { margin: 0; }
.pick-other { color: var(--accent) !important; }

/* ---------- 참가 신청 · 자동 편성 */
.signup { margin: 4px 0 12px; padding: 10px 12px; border-radius: var(--radius-sm); background: var(--surface-2); display: grid; gap: 8px; }
.signup-head { display: flex; justify-content: space-between; align-items: center; gap: 8px; flex-wrap: wrap; }
.signup-chips { margin: 0; }
.signup-chips .chip { background: var(--surface); }
.party-board { padding: 12px 16px; margin-bottom: 10px; background: var(--accent-weak); border-color: color-mix(in srgb, var(--accent) 30%, var(--border)); }
.weapon-settings summary { cursor: pointer; font-weight: 600; font-size: 14px; }
.weapon-settings form { margin-top: 10px; }
.auto-preview { display: grid; gap: 8px; }
.auto-warn { padding: 8px 10px; border-radius: var(--radius-sm); background: var(--warn-weak); color: var(--warn) !important; font-size: 13px; }
.auto-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); gap: 8px; }
.auto-party { padding: 10px 12px; border: 1px solid var(--border); border-radius: var(--radius-sm); }
.auto-head { display: flex; justify-content: space-between; align-items: baseline; gap: 6px; flex-wrap: wrap; margin-bottom: 4px; }
.auto-party ol { margin: 0; padding-left: 0; list-style: none; display: grid; gap: 2px; font-size: 13px; }
.event-pick { display: grid; gap: 6px; }
.event-pick-btn { justify-content: space-between; height: auto; padding: 10px 14px; text-align: left; white-space: normal; }

/* ---------- 참가 모집 */
.recruit { padding: 16px 18px; margin-bottom: 10px; display: grid; gap: 10px; }
.recruit.open { border-color: color-mix(in srgb, var(--ok) 45%, var(--border)); background: linear-gradient(135deg, var(--ok-weak), var(--surface)); }
.recruit-head { display: flex; justify-content: space-between; align-items: center; gap: 12px; flex-wrap: wrap; }
.recruit-head b { font-size: 16px; }
.recruit .live { color: var(--ok); font-weight: 700; }
.big-btn { height: 44px; padding: 0 22px; font-size: 15px; }
.recruit-chips { margin: 0; }
.recruit-chips .chip { background: var(--surface); }
.recruit-actions { display: flex; gap: 6px; flex-wrap: wrap; padding-top: 8px; border-top: 1px solid var(--border); }

/* 정산 제외 */
.table tr.excluded td { color: var(--muted); background: color-mix(in srgb, var(--warn-weak) 40%, transparent); }
.table tr.excluded .badge { margin-left: 6px; }
.min-war { align-items: center; gap: 6px; }
.min-war .size-input { width: 70px; }

/* 전투력만 바꾸고 레벨을 잊지 않도록 */
.level-field .level-nudge { display: none; color: var(--warn); font-size: 12px; font-weight: 600; }
.level-field.nudge .level-nudge { display: block; }
.level-field.nudge input { border-color: var(--warn); background: var(--warn-weak); }

/* ---------- 드랍 확인 요청 */
.loot-banner { padding: 14px 16px; margin-bottom: 16px; display: grid; gap: 10px; border-color: color-mix(in srgb, var(--warn) 40%, var(--border)); }
.loot-banner h2 { font-size: 16px; display: flex; align-items: center; gap: 8px; }
.loot { margin-top: 10px; padding: 10px 12px; border-radius: var(--radius-sm); background: var(--surface-2); display: grid; gap: 8px; }
.loot-banner .loot { margin-top: 0; }
.loot.ask { background: var(--warn-weak); outline: 1.5px solid color-mix(in srgb, var(--warn) 55%, transparent); }
.loot.closed { opacity: .7; }
.loot-head { display: flex; align-items: baseline; gap: 8px; flex-wrap: wrap; }
.loot-found { color: var(--ok); }
.loot-none { color: var(--warn); }
.loot-chips { margin: 0; }
.loot-chips .chip { background: var(--surface); }
.loot-chips .chip.got { background: var(--ok-weak); color: var(--ok); font-weight: 700; }
.loot-chips .chip.nope { color: var(--muted); }
.loot-chips .chip.wait { color: var(--warn); }
.loot-chips .chip.me { outline: 1.5px solid var(--accent); }
.loot-actions { display: flex; align-items: center; gap: 6px; flex-wrap: wrap; }
.loot-actions .spacer { flex: 1; }
.loot-ask { padding: 10px 12px; border-radius: var(--radius-sm); background: var(--surface); border: 1px solid color-mix(in srgb, var(--warn) 45%, var(--border)); display: grid; gap: 8px; }
.loot-ask p { margin: 0; font-size: 15px; }
.loot-ask-btns { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.loot-ask-btns .btn { height: 46px; font-size: 15px; font-weight: 700; }
.btn.loot-yes { background: var(--ok); border-color: var(--ok); color: #fff; }
.btn.loot-no { background: var(--surface-2); }
@media (prefers-color-scheme: dark) { .btn.loot-yes { color: #0e1015; } }
.loot-mine { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; font-size: 14px; }

.btn.loot-yes:hover { filter: brightness(1.08); }

/* 상품 소식: 날짜별 묶음 */
.post-day + .post-day { margin-top: 6px; }
.post-day h3 { font-size: 13px; font-weight: 700; color: var(--muted); padding: 8px 0 2px; border-bottom: 1px solid var(--border); }
.post-day .product-post:first-of-type { border-top: 0; }
.post-day.old > summary { list-style: none; cursor: pointer; }
.post-day.old > summary::-webkit-details-marker { display: none; }
.post-day.old > summary h3 { color: var(--text); font-weight: 600; }
.post-day.old[open] > summary h3 { color: var(--muted); }
.post-day.old > summary h3::before { content: '▸ '; }
.post-day.old[open] > summary h3::before { content: '▾ '; }

/* ---------- 파티 모집 */
.ppost-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: 12px; }
.ppost { padding: 16px 18px; display: grid; gap: 8px; align-content: start; }
.ppost.open { border-color: color-mix(in srgb, var(--ok) 45%, var(--border)); }
.ppost.closed { opacity: .85; }
.ppost-head { display: flex; justify-content: space-between; align-items: center; gap: 8px; flex-wrap: wrap; }
.ppost-head h2 { font-size: 17px; }
.ppost-note { margin: 0; padding: 8px 10px; border-radius: var(--radius-sm); background: var(--surface-2); font-size: 14px; white-space: pre-wrap; }
.ppost .pm-row { grid-template-columns: 1fr auto auto; }
.ppost .pm-row .icon-btn { grid-column: 3; grid-row: 1 / span 2; align-self: center; width: 26px; height: 26px; font-size: 13px; }
.ppost .empty-slot { display: block; text-align: center; }
.ppost-foot { display: flex; align-items: center; gap: 6px; flex-wrap: wrap; padding-top: 8px; border-top: 1px solid var(--border); }
.ppost-foot .spacer { flex: 1; }
.party-types { padding: 12px 16px; margin-bottom: 12px; }

/* 정산 전투력 배율 */
.rate-form { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 14px; }
.rate-form .form-error { flex-basis: 100%; margin: 0; }
.rate-item { display: inline-flex; align-items: center; gap: 6px; }
.rate-power { width: 110px; }
.rate-input { width: 80px; }

/* 은은한 강조 버튼 (예: 내 전투력 업데이트) */
.btn.soft-warn { background: var(--warn-weak); border-color: color-mix(in srgb, var(--warn) 35%, var(--border)); color: var(--warn); font-weight: 700; }
.btn.soft-warn:hover { background: color-mix(in srgb, var(--warn) 18%, var(--surface)); }

/* 필드보스 젠 방식 */
.spawn-fields { display: inline-flex; gap: 6px; align-items: center; }
.spawn-fields[hidden] { display: none; }
.boss-table .spawn-fields .input[name=time] { min-width: 110px; }
.boss-table select.input[name=mode] { min-width: 120px; }

/* 공지 변경 표시 */
.notice-changed { display: flex; justify-content: space-between; align-items: center; gap: 8px; flex-wrap: wrap;
  margin-bottom: 14px; padding: 10px 12px; border-radius: var(--radius-sm); background: var(--accent-weak); }
.notice-body.diff .dl { padding: 0 8px; border-radius: 4px; }
.notice-body.diff .dl-add { background: var(--ok-weak); box-shadow: inset 3px 0 0 var(--ok); }
.notice-body.diff .dl-del { background: var(--danger-weak); color: var(--muted); text-decoration: line-through; box-shadow: inset 3px 0 0 var(--danger); }

/* 내 성장 기록 */
:root { --chart-line: #4f46e5; }
@media (prefers-color-scheme: dark) { :root { --chart-line: #7c83f5; } }
.growth-hero { display: flex; gap: 10px; flex-wrap: wrap; }
.growth-hero > div { flex: 1; min-width: 140px; display: grid; gap: 2px; padding: 10px 12px; border-radius: var(--radius-sm); background: var(--surface-2); }
.growth-hero b { font-size: 20px; font-variant-numeric: tabular-nums; }
.growth-chart { position: relative; margin: 4px 0; }
.growth-chart svg { width: 100%; height: auto; display: block; touch-action: pan-y; }
.gc-grid { stroke: var(--border); stroke-width: 1; }
.gc-label { fill: var(--muted); font-size: 11px; font-variant-numeric: tabular-nums; }
.gc-line { fill: none; stroke: var(--chart-line); stroke-width: 2; stroke-linejoin: round; stroke-linecap: round; }
.gc-dot { fill: var(--chart-line); stroke: var(--surface); stroke-width: 2; }
.gc-hot { stroke-width: 2.5; }
.gc-cross { stroke: var(--muted); stroke-width: 1; stroke-dasharray: 3 3; }
.gc-hit { fill: transparent; cursor: crosshair; }
.gc-tip { position: absolute; transform: translate(-50%, calc(-100% - 12px)); pointer-events: none; display: grid; gap: 1px;
  padding: 6px 10px; border-radius: 8px; background: var(--surface); border: 1px solid var(--border); box-shadow: var(--shadow);
  font-size: 12px; white-space: nowrap; color: var(--text); }
.gc-tip b { font-size: 13px; }
.growth-list { display: grid; max-height: 260px; overflow-y: auto; border-top: 1px solid var(--border); }
.growth-row { display: grid; grid-template-columns: 1.6fr 1fr 0.7fr 1fr; gap: 8px; align-items: center; padding: 7px 2px; border-bottom: 1px solid var(--border); font-variant-numeric: tabular-nums; }
.growth-row.head { position: sticky; top: 0; background: var(--surface); }

/* 창 안에서 끝까지 스크롤해도 뒤 페이지로 넘어가지 않게 */
dialog, .modal-body, .growth-list, .picker-list { overscroll-behavior: contain; }

/* ---------- 스킬북 신청 */
.skill-mine { margin: 0 0 12px; }
.skill-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); gap: 12px; align-items: start; }
.skill { padding: 16px 18px; display: grid; gap: 8px; }
.skill.mine { border-color: color-mix(in srgb, var(--ok) 45%, var(--border)); }
.skill-head { display: flex; justify-content: space-between; align-items: center; gap: 8px; flex-wrap: wrap; }
.skill-head h2 { font-size: 17px; }
.skill .pm-row { grid-template-columns: 1fr auto auto; }
.skill .pm-row > .btn { grid-column: 3; grid-row: 1 / span 2; align-self: center; }
.skill .empty-slot { display: block; text-align: center; }
.skill-rank { display: inline-block; min-width: 22px; color: var(--muted); font-size: 13px; font-variant-numeric: tabular-nums; }
.skill-foot { display: flex; align-items: center; gap: 6px; flex-wrap: wrap; padding-top: 8px; border-top: 1px solid var(--border); }
.skill-foot .spacer { flex: 1; }
.ok-text { color: var(--ok); font-weight: 700; }
.skill-note { font-size: 13px; font-weight: 500; margin-left: 4px; }
.skill-search { width: 100%; max-width: 320px; margin-bottom: 12px; }
.skill-history { padding: 6px 18px; margin-bottom: 8px; }
.skill-history .pm-row > .btn { grid-column: 2; grid-row: 1 / span 2; align-self: center; }
.skill-bar { display: flex; justify-content: space-between; align-items: center; gap: 8px 16px; flex-wrap: wrap; margin-bottom: 12px; }
.skill-bar p { margin: 0; }

/* ---------- 제작자 탭: 다이아 시세 */
.dia-card { padding: 18px 20px; display: grid; gap: 10px; }
.dia-card h2 { font-size: 17px; }
.dia-form { display: flex; flex-wrap: wrap; align-items: flex-end; gap: 10px; }
.dia-form .field { margin: 0; flex: 1 1 140px; }
.dia-form .form-error { flex-basis: 100%; margin: 0; }
.dia-form .form-error:empty { display: none; }
.dia-summary { display: flex; flex-wrap: wrap; gap: 6px 16px; padding: 10px 12px; border-radius: var(--radius-sm); background: var(--surface-2); font-size: 14px; font-variant-numeric: tabular-nums; }
.dia-tools { display: flex; justify-content: space-between; align-items: center; gap: 8px; }
.dia-table td { font-variant-numeric: tabular-nums; }
.dia-table td:first-child, .dia-table th:first-child { width: 36px; padding-right: 0; }
.dia-empty { margin: 0; }

/* ---------- 공홈 탭: 쿠폰 */
.coupon-tools { display: flex; justify-content: flex-end; gap: 6px; margin-bottom: 12px; }
.coupon-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); gap: 12px; align-items: start; }
.coupon { padding: 14px 16px; display: grid; gap: 6px; }
.coupon p { margin: 0; }
.coupon.expired { opacity: .6; }
.coupon-head { display: flex; align-items: center; gap: 8px; }
.coupon-head .spacer, .coupon-foot .spacer { flex: 1; }
.coupon-head .badge { margin: 0; }
.coupon-code { font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; font-size: 16px; font-weight: 700; letter-spacing: .02em; padding: 4px 8px; border-radius: var(--radius-sm); background: var(--surface-2); word-break: break-all; }
.coupon.expired .coupon-code { text-decoration: line-through; }
.coupon-rewards { margin: 0; padding: 8px 10px 8px 26px; border-radius: var(--radius-sm); background: var(--surface-2); font-size: 13px; display: grid; gap: 2px; }
.coupon-foot { display: flex; align-items: center; gap: 6px; flex-wrap: wrap; }
.coupon-old { margin-top: 16px; }
.coupon-old > summary { cursor: pointer; margin-bottom: 10px; }

/* ---------- 감성: 보스 목록형 화면 (보스가 많아서 카드 대신 목록) */
.focus { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; padding: 12px 14px; margin-bottom: 16px; }
.focus-title { font-size: 13px; font-weight: 700; color: var(--muted); margin-right: 4px; }
.focus-item {
  display: inline-flex; align-items: center; gap: 8px; height: 34px; padding: 0 12px;
  border: 1px solid var(--border); border-radius: 999px; background: var(--surface-2); cursor: pointer; font-size: 14px;
}
.focus-item .t { font-size: 13px; color: var(--muted); font-variant-numeric: tabular-nums; }
.focus-item.up { border-color: var(--ok); background: var(--ok-weak); }
.focus-item.up .t { color: var(--ok); }
.focus-item.soon { border-color: var(--warn); background: var(--warn-weak); }
.focus-item.soon .t { color: var(--warn); }
.boss-toolbar { display: flex; flex-wrap: wrap; align-items: center; gap: 10px; margin-bottom: 12px; }
.boss-toolbar .input { flex: 1; min-width: 180px; max-width: 320px; }
.boss-toolbar .seg { margin: 0; width: 220px; }
.filter .cnt { font-size: 12px; opacity: .6; margin-left: 2px; }
.bgrid { display: grid; gap: 18px; align-items: start; }
@media (min-width: 980px) { .bgrid { grid-template-columns: 1fr 1fr; } }
.bgroup { display: flex; align-items: baseline; gap: 8px; margin: 4px 2px 8px; }
.blist { overflow: hidden; }
.brow {
  display: grid; grid-template-columns: 10px minmax(0, 1fr) 200px auto; align-items: center; gap: 14px;
  padding: 9px 12px 9px 16px; border-top: 1px solid var(--border);
}
.brow:first-child { border-top: 0; }
.brow[data-state="up"] { background: color-mix(in srgb, var(--ok-weak) 70%, transparent); }
.brow[data-state="soon"] { background: color-mix(in srgb, var(--warn-weak) 70%, transparent); }
.bname { display: grid; gap: 1px; min-width: 0; padding: 0; border: 0; background: none; text-align: left; cursor: pointer; }
.bname b { font-size: 15px; font-weight: 650; }
.bname:hover b { color: var(--accent); }
.bname small { font-size: 12.5px; color: var(--muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.bname small.fixed { color: var(--accent); }
.tag-abs {
  margin-left: 6px; padding: 1px 6px; border-radius: 6px; font-size: 11px; font-weight: 700; vertical-align: 2px;
  background: var(--danger-weak); color: var(--danger);
}
.bnext { display: grid; text-align: right; font-variant-numeric: tabular-nums; }
.bnext b { font-size: 15px; font-weight: 650; }
.bnext small { font-size: 12.5px; color: var(--muted); }
.brow[data-state="up"] .bnext b, .brow[data-state="up"] .bnext small { color: var(--ok); }
.brow[data-state="soon"] .bnext b, .brow[data-state="soon"] .bnext small { color: var(--warn); }
.brow[data-state="unknown"] .bnext b { color: var(--muted); font-weight: 500; }
.bact { display: flex; align-items: center; gap: 2px; }
.bact .btn { margin-right: 4px; }
.info { display: grid; grid-template-columns: auto 1fr; gap: 6px 14px; margin: 0 0 16px; font-size: 14px; }
.info dt { color: var(--muted); }
.info dd { margin: 0; }
@media (max-width: 560px) {
  .brow { grid-template-columns: 10px minmax(0, 1fr) auto auto; gap: 10px; padding: 9px 10px 9px 14px; }
  .bact .icon-btn { display: none; }
  .bact .btn { margin: 0; }
  .bnext b { font-size: 14px; }
  .boss-toolbar { flex-wrap: nowrap; gap: 8px; }
  .boss-toolbar .input { min-width: 0; max-width: none; }
  .boss-toolbar .seg { width: auto; flex: none; }
  .boss-toolbar .seg-btn { padding: 0 10px; font-size: 13px; }
  .boss-page-head p { display: none; }
  .filters.region { flex-wrap: nowrap; overflow-x: auto; scrollbar-width: none; margin: 0 -16px 12px; padding: 0 16px; }
  .filters.region::-webkit-scrollbar { display: none; }
  .filters.region .filter { flex: none; }
}
