/* KCI 프로그램 — 디자인 토큰 (KCI Dashboard.html 기준) */
:root {
  --navy: #0F1E3C; --navy-2: #173064; --navy-0: #0B1732;
  --blue: #1D5BFF; --blue-soft: #E8EFFF; --blue-light: #7FA6FF;
  --red: #E4002B; --red-dark: #B0001F; --red-soft: #FDE8EC; --red-border: #F3C1CB;
  --green: #15803D; --green-soft: #E8F7EE;
  --teal: #0F9D8A; --purple: #7C3AED; --amber: #F59E0B;
  --text: #0B1220; --text-2: #1F2937; --text-3: #374151; --muted: #4B5563; --muted-2: #6B7280;
  --bg: #EEF1F6; --bg-2: #F7F9FC; --line: #D3DAE6; --line-2: #DFE4EC; --line-3: #E6EAF0; --dash: #B7C3D8;
  --radius: 16px;
  /* 디자인 조정 모드에서 바꾸는 값 */
  --fs-base: 14.5px; --fs-row: 14px; --fs-hint: 13px; --fs-badge: 12.5px; --fs-btn: 13.5px;
  --row-py: 14px; --row-px: 28px; --row-gap: 14px; --card-pad: 26px 28px; --cardh-pad: 22px 28px 14px; --badge-pad: 3px 8px; --main-max: 1400px; --main-pad: 44px 40px 96px; --zoom: 1;
}
* { box-sizing: border-box; }
[hidden] { display: none !important; }
.badge.st-pending { background: #FFF4D6; color: #8A5A00; } .badge.st-ok { background: #DCFCE7; color: #15803D; } .badge.st-bad { background: #FDE2E7; color: #B0001F; }
.login .alert { background: #EAF1FF; color: #1D5BFF; border-radius: 10px; padding: 10px 12px; font-size: 13.5px; } .login .alert.red { background: #FDE2E7; color: #B0001F; }
html, body { margin: 0; }
body { background: var(--bg); color: var(--text); font-family: Pretendard, "Pretendard Variable", -apple-system, "Apple SD Gothic Neo", "Malgun Gothic", system-ui, sans-serif; line-height: 1.5; word-break: keep-all; font-size: var(--fs-base); -webkit-font-smoothing: antialiased; }
a { color: var(--blue); text-decoration: none; } a:hover { color: var(--navy); }
button { font-family: inherit; cursor: pointer; white-space: nowrap; border: 0; background: none; color: inherit; font-size:14px; }
button:disabled { cursor: not-allowed; }
input, select, textarea { font-family: inherit; font-size:14px; color: var(--text); }
h1, h2, h3, h4, p { margin: 0; }
.num { font-variant-numeric: tabular-nums; }

/* ---------- 레이아웃 */
#app { min-height: 100vh; display: flex; flex-direction: column; }
.hdr { height: 64px; background: var(--navy); display: flex; align-items: center; padding: 0 24px; gap: 28px; position: sticky; top: 0; z-index: 10; }
.hdr .brand { display: flex; align-items: center; gap: 10px; flex: none; padding: 0; text-align: left; }
.hdr .logo { width: 34px; height: 34px; display: flex; align-items: center; justify-content: center; }
.hdr .logo img { width: 32px; height: auto; display: block; }
.hdr .brand-t { display: flex; flex-direction: column; line-height: 1.1; }
.hdr .brand-t b { color: #fff; font-weight: 700; font-size:17.5px; letter-spacing: -0.01em; }
.hdr .brand-t span { color: rgba(255,255,255,.88); font-size:12px; }
.hdr nav { display: flex; gap: 4px; flex: 1; }
.hdr nav button { border-radius: 999px; padding: 9px 16px; font-size:14px; font-weight: 600; color: rgba(255,255,255,.85); }
.hdr nav button.on { background: rgba(255,255,255,.2); color: #fff; }
.hdr .user { display: flex; align-items: center; gap: 8px; flex: none; }
.hdr .user-btn { display: flex; align-items: center; gap: 8px; border: 1px solid rgba(255,255,255,.3); background: rgba(255,255,255,.1); color: #fff; border-radius: 999px; padding: 5px 12px 5px 6px; font-size:14px; font-weight: 600; }
.hdr .user-btn .av { width: 26px; height: 26px; border-radius: 50%; background: #fff; display: flex; align-items: center; justify-content: center; overflow: hidden; flex: none; }
.hdr .user-btn .av img { width: 22px; height: 22px; object-fit: contain; display: block; }
.hdr .user-btn .av img.kl { width: 22px; height: 22px; }
.hdr .user-btn .role { color: rgba(255,255,255,.65); font-weight: 400; border-left: 1px solid rgba(255,255,255,.2); padding-left: 8px; }
.hdr .ghost { border: 1px solid rgba(255,255,255,.3); background: rgba(255,255,255,.1); color: #fff; border-radius: 999px; padding: 7px 14px; font-size:14px; font-weight: 600; }
main { flex: 1; width: 100%; max-width: var(--main-max); margin: 0 auto; padding: var(--main-pad); zoom: var(--zoom); }
.screen { display: flex; flex-direction: column; gap: 32px; }
.page-head { display: flex; justify-content: space-between; align-items: flex-end; gap: 16px; flex-wrap: wrap; }
.page-head h1 { font-size:27px; font-weight: 800; letter-spacing: -0.02em; }
.page-head p { margin-top: 6px; color: var(--muted); font-size:14.5px; }
footer { text-align: center; color: var(--muted-2); font-size:13px; padding: 0 24px 28px; }

/* ---------- 카드·표 */
.card { background: #fff; border: 1px solid var(--line); border-radius: var(--radius); box-shadow: 0 1px 2px rgba(15,30,60,.04); }
.card.pad { padding: var(--card-pad); }
.card-h { padding: var(--cardh-pad); display: flex; justify-content: space-between; align-items: center; gap: 10px; }
.card-h h2, h2.t { font-size:17px; font-weight: 800; }
.card-h .sub { font-size:13.5px; color: var(--muted); white-space: nowrap; }
.grid-2 { display: grid; grid-template-columns: repeat(auto-fit, minmax(520px, 1fr)); gap: 28px; align-items: start; }
.grid-2.equal { align-items: stretch; } .grid-2.equal > .card { display: flex; flex-direction: column; } .grid-2.equal > .card > .fill { flex: 1; }
.stack { display: flex; flex-direction: column; gap: 20px; }
.row-head { display: grid; gap: 0 var(--row-gap); padding: 10px var(--row-px); font-size:12.5px; font-weight: 700; color: var(--muted-2); border-bottom: 1px solid var(--line-2); }
.row { display: grid; gap: 0 var(--row-gap); align-items: center; padding: var(--row-py) var(--row-px); border-bottom: 1px solid var(--line-3); font-size: var(--fs-row); }
.row:last-child { border-bottom: 0; }
.row.click { cursor: pointer; } .row.click:hover { background: var(--bg-2); }
.r { text-align: right; } .c { text-align: center; }
.toolbar { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }
.card.todo { border-color: #C9D7FF; }
.card.todo > .card-h { background: #F1F5FF; border-bottom: 1px solid #DCE5FF; border-radius: var(--radius) var(--radius) 0 0; }
.card.todo > .card-h h2::before { content: ''; display: inline-block; width: 9px; height: 9px; border-radius: 50%; background: var(--blue, #1D5BFF); margin-right: 8px; vertical-align: 1px; }
.card.done > .card-h { background: #F7F8FA; border-bottom: 1px solid var(--line-2); border-radius: var(--radius) var(--radius) 0 0; }
.card.done > .card-h h2 { color: #4B5563; }
.card.done > .card-h h2::before { content: ''; display: inline-block; width: 9px; height: 9px; border-radius: 50%; background: #9CA3AF; margin-right: 8px; vertical-align: 1px; }
.card-h .sub b { color: #111827; }
.empty { padding: 28px 24px; text-align: center; color: var(--muted-2); font-size:14px; }

/* ---------- 배지·버튼·필 */
.badge.tc { justify-self: start; width: max-content; }
.badge { display: inline-block; font-size: var(--fs-badge); font-weight: 700; border-radius: 6px; padding: var(--badge-pad); white-space: nowrap; }
.b-ok { background: var(--green-soft); color: var(--green); }
.b-info { background: var(--blue-soft); color: var(--blue); }
.b-bad { background: var(--red-soft); color: var(--red-dark); }
.b-none { background: var(--line-3); color: var(--muted); }
.b-na { background: var(--line-3); color: var(--muted-2); }
.b-navy { background: var(--navy); color: #fff; }
.b-warn { background: #FFF4E5; color: #B45309; }
.btn { border-radius: 9px; padding: 8px 14px; font-size: var(--fs-btn); font-weight: 700; border: 1px solid var(--line); background: #fff; color: var(--text-2); }
.btn.lg { border-radius: 11px; padding: 12px 18px; font-size:14px; }
.btn.xl { border-radius: 11px; padding: 14px; font-size:14.5px; width: 100%; }
.btn.primary { background: var(--blue); border-color: var(--blue); color: #fff; }
.btn.navy { background: var(--navy); border-color: var(--navy); color: #fff; }
.btn.danger { background: var(--red); border-color: var(--red); color: #fff; }
.btn.danger-o { background: #fff; border-color: var(--red-border); color: var(--red); }
.btn.ok { background: var(--green-soft); border-color: var(--green-soft); color: var(--green); }
.btn.link { border: 0; background: none; color: var(--blue); font-weight: 600; padding: 0 4px; }
.btn.quiet { border: 0; background: none; color: var(--muted); font-weight: 500; font-size:13px; padding: 0 4px; }
.btn:disabled { background: var(--line); border-color: var(--line); color: var(--muted-2); }
.pill { border: 1px solid var(--line); background: #fff; border-radius: 999px; padding: 8px 16px; font-size:14px; font-weight: 600; color: var(--text-2); }
.pill.on { background: var(--navy); border-color: var(--navy); color: #fff; }
.seg { display: flex; background: #fff; border: 1px solid var(--line); border-radius: 999px; padding: 4px; gap: 2px; }
.seg button { border-radius: 999px; padding: 9px 18px; font-size:14px; font-weight: 600; color: var(--text-2); }
.seg button.on { background: var(--navy); color: #fff; }
.seg.mini { background: var(--bg); border: 0; padding: 3px; }
.seg.mini button { padding: 5px 12px; font-size:13px; font-weight: 700; color: var(--muted); }
.seg.mini button.on { background: #fff; color: var(--navy); }
.chips { display: flex; flex-wrap: wrap; gap: 8px; }
.chip { display: flex; align-items: center; gap: 7px; border: 1px solid var(--line); border-radius: 999px; padding: 6px 12px 6px 8px; font-size:13.5px; font-weight: 600; background: #fff; color: var(--text-2); }
.chip.on { background: var(--navy); border-color: var(--navy); color: #fff; }
.chip .dot { width: 8px; height: 8px; border-radius: 50%; background: var(--line); }

/* ---------- 폼 */
label.f { display: flex; flex-direction: column; gap: 6px; font-size:13.5px; font-weight: 600; color: var(--text-2); }
.in, select.in, textarea.in { border: 1px solid var(--line); border-radius: 10px; padding: 12px 14px; font-size:14px; background: #fff; width: 100%; }
.in[readonly] { background: var(--bg); font-weight: 700; }
textarea.in { min-height: 84px; resize: vertical; line-height: 1.5; }
.f-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.f-grid.c3 { grid-template-columns: 1fr 1fr 1fr; }
.chk { display: flex; align-items: center; gap: 8px; font-size:14px; color: var(--text-2); font-weight: 500; }
.chk input { width: 16px; height: 16px; accent-color: var(--blue); margin: 0; }
.opt-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 6px; }
.opt { border: 1px solid var(--line); border-radius: 10px; padding: 10px 12px; font-size:14px; font-weight: 600; text-align: left; background: #fff; color: var(--text); }
.opt small { display: block; font-size:12.5px; font-weight: 500; opacity: .7; margin-top: 2px; }
.opt.on { background: var(--navy); border-color: var(--navy); color: #fff; }
.actions { display: flex; gap: 8px; justify-content: flex-end; }
.hint { font-size: var(--fs-hint); color: var(--muted); line-height: 1.55; }
.help { background: var(--blue-soft); border-radius: 12px; padding: 12px 16px; font-size:14px; line-height: 1.7; color: var(--text-2); }
.help b { color: var(--navy); }
.help ul { margin: 4px 0 0; padding-left: 18px; }
.help li { margin: 2px 0; }
.help li::marker { color: var(--blue); }
.note { background: var(--bg); border-radius: 12px; padding: 14px 16px; display: flex; flex-direction: column; gap: 6px; font-size:14px; }
.note .kv { display: flex; justify-content: space-between; gap: 12px; } .note .kv span:first-child { color: var(--muted); } .note .kv span:last-child { font-weight: 700; text-align: right; }
.alert { border-radius: 12px; padding: 12px 16px; font-size:14px; line-height: 1.5; }
.alert.red { background: var(--red-soft); color: var(--red-dark); border: 1px solid var(--red-border); }
.alert.blue { background: var(--blue-soft); color: var(--navy); }
.alert.amber { background: #FFF4E5; color: #92400E; }

/* ---------- 대시보드 히어로 */
.hero { position: relative; overflow: hidden; background: linear-gradient(115deg, var(--navy-0) 0%, var(--navy) 55%, var(--navy-2) 100%); color: #fff; border-radius: 20px; padding: 36px 40px; display: grid; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); gap: 36px; }
.hero .wm { position: absolute; right: -30px; top: -70px; width: 480px; opacity: .1; pointer-events: none; }
.hero .k { font-size:13.5px; color: rgba(255,255,255,.78); font-weight: 600; letter-spacing: .04em; }
.hero .big { font-size:62.5px; font-weight: 800; letter-spacing: -0.04em; line-height: 1; }
.hero .bar { display: flex; height: 8px; border-radius: 4px; overflow: hidden; gap: 2px; }
.hero .legend { display: flex; gap: 18px; flex-wrap: wrap; font-size:13.5px; color: rgba(255,255,255,.88); }
.hero .legend i { display: inline-block; width: 8px; height: 8px; border-radius: 2px; margin-right: 6px; }
.hero .kpis { display: flex; gap: 28px; padding-top: 18px; border-top: 1px solid rgba(255,255,255,.12); flex-wrap: wrap; } .hero .kpis > div { text-align: center; }
.hero .kpis .k { font-size:13px; color: rgba(255,255,255,.88); } .hero .kpis b { display: block; font-size:22.5px; font-weight: 800; margin-top: 2px; }
.top3 { display: flex; align-items: center; gap: 14px; border: 1px solid rgba(255,255,255,.18); background: rgba(255,255,255,.1); border-radius: 12px; padding: 12px 16px; color: #fff; text-align: left; width: 100%; }
.top3:hover { background: rgba(255,255,255,.12); }
.top3.static { cursor: default; } .top3.static:hover { background: rgba(255,255,255,.06); }
.top3.sm { padding: 8px 12px; gap: 10px; } .top3.sm .rk { font-size:18px; width: 24px; } .top3.sm .nm b { font-size:14.5px; } .top3.sm .nm span { font-size:12.5px; } .top3.sm .sc { font-size:19px; } .top3.sm .g { font-size:11px; padding: 2px 6px; }
.top3 .rk { font-size:24.5px; font-weight: 800; letter-spacing: -0.03em; color: rgba(255,255,255,.78); width: 30px; }
.top3 .emb img { filter: drop-shadow(0 1px 3px rgba(0,0,0,.35)); }
.top3 .nm { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 1px; } .top3 .nm b { font-size:15.5px; font-weight: 700; line-height: 1.2; overflow-wrap: anywhere; } .top3 .nm span { font-size:13px; color: rgba(255,255,255,.88); }
.top3 .sc { font-size:24.5px; font-weight: 800; letter-spacing: -0.02em; }
.top3 .g { font-size:12.5px; font-weight: 800; border-radius: 6px; padding: 3px 8px; }

/* ---------- 구단 카드 */
.club-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(340px, 1fr)); gap: 20px; }
.club-card { position: relative; overflow: hidden; text-align: left; background: #fff; border: 1px solid var(--line); border-radius: var(--radius); padding: 18px 18px 18px 16px; display: flex; align-items: center; gap: 14px; transition: transform .15s, box-shadow .15s; width: 100%; }
.club-card:hover { transform: translateY(-2px); box-shadow: 0 8px 24px rgba(15,30,60,.08); }
.club-card.static { cursor: default; } .club-card.static:hover { transform: none; box-shadow: none; }
.club-card.own { background: var(--blue-soft); border-color: #B9CCFF; box-shadow: inset 0 0 0 1px #B9CCFF; }
.club-card.own .wm { opacity: .1; }
.club-card .wm { position: absolute; right: 14px; top: -10px; font-size:71.5px; font-weight: 800; letter-spacing: -0.05em; color: var(--navy); opacity: .05; line-height: 1; pointer-events: none; }
.ring { position: relative; flex: none; border-radius: 50%; display: flex; align-items: center; justify-content: center; }
.emb { position: relative; flex: none; display: inline-flex; align-items: center; justify-content: center; }
.emb img { width: 100%; height: 100%; object-fit: contain; display: block; filter: drop-shadow(0 1px 2px rgba(15,30,60,.12)); }
.emb.txt { color: #fff; font-weight: 800; border-radius: 50%; }
.club-card .nm { flex: 1 1 auto; min-width: 0; overflow: hidden; display: flex; flex-direction: column; gap: 3px; padding-right: 10px; }
.club-card .nm .t { display: flex; align-items: flex-start; gap: 8px; min-width: 0; } .club-card .nm .t small { font-size:12.5px; font-weight: 700; color: var(--muted-2); } .club-card .nm .t b { flex: 1 1 auto; min-width: 0; font-size:15.5px; font-weight: 700; line-height: 1.25; white-space: normal; word-break: keep-all; overflow-wrap: anywhere; }
.club-card .nm .s { font-size:13px; color: var(--muted); display: flex; flex-wrap: wrap; gap: 4px 10px; align-items: center; } .club-card .nm .d { font-size:13px; font-weight: 600; }
.club-card .sc { display: flex; flex-direction: column; align-items: flex-end; gap: 6px; position: relative; flex: 0 0 auto; min-width: 64px; margin-left: 8px; } .club-card .sc b { font-size:29px; font-weight: 800; letter-spacing: -0.03em; line-height: 1; }
.g-S { background: #1D5BFF; color: #fff; } .g-A { background: #7FA6FF; color: #fff; } .g-B { background: #6B7280; color: #fff; } .g-C { background: #F26B84; color: #fff; } .g-D { background: #B0001F; color: #fff; }
.up { color: var(--green); } .down { color: var(--red-dark); } .flat { color: var(--muted-2); }

/* ---------- 구단 상세 */
.detail-head { display: flex; justify-content: space-between; align-items: center; gap: 24px; flex-wrap: wrap; }
.detail-head .who { display: flex; align-items: center; gap: 18px; }
.detail-head h1 { font-size:27px; font-weight: 800; letter-spacing: -0.02em; }
.tag { font-size:12.5px; font-weight: 700; color: var(--text-2); background: var(--line-2); border-radius: 6px; padding: 3px 8px; }
.gbox { width: 64px; height: 64px; border-radius: 14px; display: flex; flex-direction: column; align-items: center; justify-content: center; } .gbox b { font-size:29px; font-weight: 800; line-height: 1; } .gbox span { font-size:12px; font-weight: 700; opacity: .8; }
.cat-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 10px; padding-top: 20px; border-top: 1px solid var(--line-2); }
.cat { display: flex; flex-direction: column; gap: 8px; min-width: 0; }
.cat .k { display: flex; align-items: center; gap: 6px; font-size:13.5px; font-weight: 600; color: var(--muted); white-space: nowrap; } .cat .k i { width: 8px; height: 8px; border-radius: 2px; display: inline-block; }
.cat .v { display: flex; align-items: baseline; gap: 3px; } .cat .v b { font-size:24.5px; font-weight: 800; letter-spacing: -0.02em; line-height: 1; } .cat .v span { font-size:13.5px; color: var(--muted-2); }
.meter { height: 6px; border-radius: 2px; background: var(--line-2); overflow: hidden; display: block; } .meter i { display: block; height: 100%; border-radius: 2px; }
.meter.h6 { height: 8px; }
.radar-wrap { position: relative; width: 100%; max-width: 380px; margin: 8px auto 0; }
.radar-wrap svg { width: 100%; height: auto; display: block; }
.radar-wrap .lbl { position: absolute; font-weight: 600; color: var(--text-3); white-space: nowrap; line-height: 1; }
.legend-row { display: flex; gap: 16px; justify-content: center; font-size:13px; color: var(--muted); margin-top: 4px; }
.legend-row span { display: flex; align-items: center; gap: 6px; white-space: nowrap; }
.file-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); gap: 12px; padding: 8px 24px 24px; }
.file { border: 1px solid var(--line); border-radius: 12px; padding: 14px 16px; display: flex; align-items: center; gap: 12px; }
.file .ext { width: 36px; height: 36px; border-radius: 8px; background: var(--bg); display: flex; align-items: center; justify-content: center; font-size:11px; font-weight: 800; color: var(--text-2); flex: none; }
.file .nm { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 2px; } .file .nm b { font-size:14px; font-weight: 600; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; } .file .nm span { font-size:13px; color: var(--muted); }

/* ---------- 관리자 */
.admin { display: grid; grid-template-columns: 224px minmax(0, 1fr); gap: 28px; align-items: start; }
.admin .page-head { grid-column: 1 / -1; }
.side { background: #fff; border: 1px solid var(--line); border-radius: var(--radius); padding: 8px; display: flex; flex-direction: column; gap: 2px; position: sticky; top: 80px; }
.side button { display: flex; justify-content: space-between; align-items: center; border-radius: 10px; padding: 13px 16px; font-size:14.5px; font-weight: 600; text-align: left; color: var(--text-2); }
.side button.on { background: var(--navy); color: #fff; }
.side button .n { font-size:12.5px; font-weight: 800; border-radius: 999px; padding: 2px 8px; background: var(--line-2); color: var(--muted); }
.side button.on .n { background: rgba(255,255,255,.18); color: #fff; }
.stat-row { display: flex; gap: 18px; font-size:14px; color: var(--muted); flex-wrap: wrap; } .stat-row b { font-weight: 800; color: var(--text); }
.club-mini { display: flex; align-items: center; gap: 8px; font-weight: 700; min-width: 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.club-mini .emb { flex: none; }
.timeline { display: flex; flex-direction: column; gap: 8px; }
.timeline .ev { display: grid; grid-template-columns: 120px 1fr; gap: 12px; font-size:13.5px; } .timeline .ev span:first-child { color: var(--muted-2); }

/* ---------- 구단 담당자 */
.steps { background: #fff; border: 1px solid var(--line); border-radius: var(--radius); padding: 28px 32px; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); overflow: hidden; }
.step { display: flex; flex-direction: column; gap: 14px; align-items: center; text-align: center; position: relative; min-width: 0; }
.step .ln { display: flex; align-items: center; justify-content: center; width: 100%; position: relative; }
.step .ln i { position: absolute; left: 50%; right: -50%; top: 50%; height: 3px; border-radius: 2px; transform: translateY(-50%); background: var(--line-2); }
.step .ln i.done { background: var(--blue); } .step .ln i.hide { display: none; }
.step .n { position: relative; width: 36px; height: 36px; border-radius: 50%; display: flex; align-items: center; justify-content: center; font-size:15px; font-weight: 800; background: var(--line-2); color: var(--muted-2); }
.step .n.done { background: var(--blue); color: #fff; } .step .n.active { background: var(--navy); color: #fff; }
.step .lb { font-size:14px; font-weight: 600; color: var(--muted-2); } .step .lb.on { color: var(--text); }
.step .sb { font-size:20px; font-weight: 800; letter-spacing: -0.01em; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.dday { display: flex; align-items: center; gap: 12px; background: #fff; border: 1px solid var(--red-border); border-radius: 12px; padding: 10px 16px; white-space: nowrap; }
.dday b { font-size:24.5px; font-weight: 800; letter-spacing: -0.03em; color: var(--red); line-height: 1; }
.dday div { display: flex; flex-direction: column; font-size:13px; color: var(--muted); line-height: 1.35; } .dday div span:first-child { font-weight: 700; color: var(--text); }
.drop { border: 2px dashed var(--dash); border-radius: var(--radius); padding: 28px; display: flex; flex-direction: column; align-items: center; gap: 8px; background: var(--bg-2); text-align: center; cursor: pointer; }
.drop.over { border-color: var(--blue); background: var(--blue-soft); }
.drop .ic { width: 44px; height: 44px; border-radius: 12px; background: var(--blue-soft); color: var(--blue); display: flex; align-items: center; justify-content: center; font-size:20px; font-weight: 800; }
.drop b { font-size:15px; font-weight: 700; } .drop span { font-size:13.5px; color: var(--muted); }
.sign { height: 88px; border: 1px dashed var(--dash); border-radius: 10px; background: var(--bg-2); display: flex; align-items: center; justify-content: center; font-size:14.5px; color: var(--muted-2); width: 100%; }
.sign.done { background: #fff; font-size:29px; color: var(--navy); font-weight: 700; font-style: italic; }
.dim { opacity: .45; pointer-events: none; }

/* ---------- 연도별 */
.hist { position: relative; display: grid; grid-template-columns: 36px minmax(0, 1fr) 110px; gap: 0 10px; }
.hist .y { position: relative; height: 260px; } .hist .y span { position: absolute; right: 0; transform: translateY(-50%); font-size:12.5px; color: var(--muted-2); }
.hist .plot { position: relative; } .hist .plot svg { width: 100%; height: 260px; display: block; }
.hist .dot { position: absolute; width: 9px; height: 9px; border-radius: 50%; background: #fff; border: 2.5px solid; transform: translate(-50%, -50%); }
.hist .end { position: absolute; left: 100%; transform: translate(10px, -50%); font-size:13px; font-weight: 800; white-space: nowrap; }
.hist .x { display: flex; justify-content: space-between; padding-top: 10px; font-size:13px; color: var(--muted); font-weight: 600; grid-column: 2; }
.cell { display: block; text-align: center; font-weight: 700; border-radius: 6px; padding: 5px 0; }

/* ---------- 모달·토스트 */
.modal-bg { position: fixed; inset: 0; background: rgba(11,23,50,.45); display: flex; align-items: center; justify-content: center; z-index: 50; padding: 24px; }
.modal { background: #fff; border-radius: 16px; width: 100%; max-width: 560px; max-height: 90vh; overflow: auto; padding: 26px 28px; display: flex; flex-direction: column; gap: 16px; }
.modal.wide { max-width: 760px; }
.modal h2 { font-size:18px; font-weight: 800; }
.toast { position: fixed; left: 50%; bottom: 28px; transform: translateX(-50%); background: var(--navy); color: #fff; border-radius: 10px; padding: 10px 16px; font-size:14px; font-weight: 600; z-index: 60; box-shadow: 0 8px 24px rgba(15,30,60,.25); }
.toast.err { background: var(--red-dark); }
.login { min-height: 100vh; display: flex; align-items: center; justify-content: center; background: linear-gradient(115deg, var(--navy-0), var(--navy) 55%, var(--navy-2)); padding: 24px; }
.login .box { background: #fff; border-radius: 18px; padding: 34px 36px; width: 100%; max-width: 440px; display: flex; flex-direction: column; gap: 18px; }
.login .box h1 { font-size:22.5px; font-weight: 800; letter-spacing: -0.02em; }
.role-opt { border: 1px solid var(--line); border-radius: 12px; padding: 12px 14px; text-align: left; display: flex; flex-direction: column; gap: 3px; background: #fff; }
.role-opt b { font-size:14.5px; } .role-opt span { font-size:13px; color: var(--muted); }
.role-opt.on { border-color: var(--navy); background: var(--navy); color: #fff; } .role-opt.on span { color: rgba(255,255,255,.65); }
.kv-list { display: flex; flex-direction: column; gap: 8px; font-size:14px; } .kv-list div { display: grid; grid-template-columns: 130px 1fr; gap: 12px; } .kv-list div span:first-child { color: var(--muted); }
code.f { font-family: ui-monospace, Consolas, monospace; font-size:13px; background: var(--bg); border-radius: 6px; padding: 2px 6px; }
.log { font-family: ui-monospace, Consolas, monospace; font-size:13px; background: var(--bg); border-radius: 10px; padding: 12px 14px; line-height: 1.6; white-space: pre-wrap; }
.state-flow { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; font-size:13px; }
.state-flow .s { border: 1px solid var(--line); border-radius: 999px; padding: 4px 10px; font-weight: 600; color: var(--muted); }
.state-flow .s.on { background: var(--navy); border-color: var(--navy); color: #fff; }
.state-flow .s.was { background: var(--blue-soft); border-color: var(--blue-soft); color: var(--blue); }

@media (max-width: 900px) {
  main { padding: 24px 16px 64px; }
  .hdr { gap: 12px; padding: 0 14px; } .hdr nav button { padding: 8px 10px; }
  .admin { grid-template-columns: 1fr; } .side { position: static; flex-direction: row; flex-wrap: wrap; }
  .cat-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .grid-2 { grid-template-columns: 1fr; }
  .steps { grid-template-columns: 1fr; gap: 16px; } .step .ln i { display: none; }
}
