:root {
  /* 보부트레이더스: 클럽하우스 그린 + 스톤 화이트 + 샴페인 브라스 */
  --bg: #f5f4ef;
  --surface: #ffffff;
  --text: #171c19;
  --muted: #676c66;
  --line: #e4e2da;
  --brand: #14382b;
  --brand-ink: #ffffff;
  --brand-soft: #eaf0ec;
  --accent: #8a6a2c;
  --gold: #b0904f;
  --gold-soft: #f4efe3;
  --warn: #9a560f;
  --warn-soft: #fbf2e2;
  --danger: #b0362b;
  --radius: 12px;
  --shadow: 0 1px 2px rgba(20, 30, 25, .04), 0 6px 20px rgba(20, 30, 25, .05);
}
@media (prefers-color-scheme: dark) {
  :root {
    --bg: #0e1311; --surface: #151b18; --text: #ebe8e0; --muted: #9a9e97; --line: #26302b;
    --brand: #8cc5a5; --brand-ink: #0d1511; --brand-soft: #17241e; --accent: #cdb07a; --gold: #cdb07a; --gold-soft: #262217;
    --warn: #e2a45a; --warn-soft: #2a2215; --danger: #ef7d70;
    --shadow: 0 1px 2px rgba(0, 0, 0, .3), 0 6px 20px rgba(0, 0, 0, .25);
  }
}
* { box-sizing: border-box; }
body {
  margin: 0; background: var(--bg); color: var(--text);
  font-family: "Pretendard", "Apple SD Gothic Neo", "Malgun Gothic", system-ui, sans-serif;
  line-height: 1.55; word-break: keep-all;
}
a { color: var(--brand); text-decoration: none; }
a:hover { text-decoration: underline; }
h1 { font-size: 1.6rem; margin: 1.2rem 0 .8rem; }
h2 { font-size: 1.2rem; margin: 1.4rem 0 .7rem; }
h3 { font-size: 1.05rem; margin: .8rem 0 .4rem; }
.wrap { max-width: 1120px; margin: 0 auto; padding: 0 16px; }
.muted { color: var(--muted); }
.small { font-size: .85rem; }
.inline { display: inline; margin: 0; }

/* nav */
.topbar { background: var(--surface); border-bottom: 1px solid var(--line); position: sticky; top: 0; z-index: 5; }
.nav { display: flex; align-items: center; justify-content: space-between; height: 60px; gap: 12px; }
.brand { font-weight: 800; font-size: 1.15rem; color: var(--text); white-space: nowrap; }
.nav nav { display: flex; align-items: center; gap: 14px; overflow-x: auto; }
.nav nav a, .nav nav .link { color: var(--text); font-size: .95rem; white-space: nowrap; }
.nav nav a.on { color: var(--brand); font-weight: 700; }
.link { background: none; border: 0; padding: 0; cursor: pointer; font: inherit; }

/* buttons */
.btn {
  display: inline-block; background: var(--brand); color: var(--brand-ink) !important; border: 1px solid var(--brand);
  padding: .6rem 1.1rem; border-radius: 10px; font: inherit; font-weight: 600; cursor: pointer; text-align: center;
}
.btn:hover { filter: brightness(1.07); text-decoration: none; }
.btn.ghost { background: transparent; color: var(--brand) !important; }
.btn.sm { padding: .3rem .7rem; font-size: .85rem; border-radius: 8px; }
.btn.block { display: block; width: 100%; margin-top: .5rem; }

/* flash */
.flash { margin-top: 16px; padding: .8rem 1rem; background: var(--brand-soft); border-radius: var(--radius); border: 1px solid var(--line); }
.errors { padding: .8rem 1rem; background: var(--warn-soft); color: var(--danger); border-radius: var(--radius); margin-bottom: 1rem; }

/* hero */
.hero { display: grid; grid-template-columns: 1.4fr 1fr; gap: 28px; align-items: center; padding: 36px 0 12px; }
.hero h1 { font-size: 2rem; line-height: 1.3; }
.hero p { color: var(--muted); font-size: 1.05rem; }
.cta { display: flex; gap: 10px; flex-wrap: wrap; margin-top: 1rem; }
.quick { background: var(--surface); border: 1px solid var(--line); border-radius: 16px; padding: 20px; }
.quick h2 { margin-top: 0; }

/* stats */
.stats { display: grid; grid-template-columns: repeat(auto-fit, minmax(120px, 1fr)); gap: 12px; margin: 20px 0; }
.stats div { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 14px; text-align: center; }
.stats b { display: block; font-size: 1.6rem; color: var(--brand); }
.stats span { color: var(--muted); font-size: .9rem; }

/* cards */
.sec-head { display: flex; justify-content: space-between; align-items: center; gap: 12px; }
.grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); gap: 16px; }
.card {
  display: block; background: var(--surface); border: 1px solid var(--line); border-radius: 14px;
  padding: 18px; color: var(--text); transition: transform .12s, box-shadow .12s;
}
.card:hover { text-decoration: none; transform: translateY(-2px); box-shadow: 0 6px 20px rgba(0,0,0,.08); }
.card h3 { margin: .5rem 0 .2rem; }
.card p { margin: 0 0 .6rem; font-size: .9rem; }
.tags { display: flex; gap: 6px; flex-wrap: wrap; }
.tag { display: inline-block; font-size: .78rem; padding: .15rem .55rem; border-radius: 999px; background: var(--bg); border: 1px solid var(--line); color: var(--muted); }
.tag.courier { background: var(--brand-soft); color: var(--brand); border-color: transparent; font-weight: 600; }
.tag.st-open, .tag.ap-accepted { color: var(--accent); border-color: var(--accent); }
.tag.st-pending, .tag.ap-pending { color: var(--warn); border-color: var(--warn); }
.tag.st-rejected, .tag.ap-rejected { color: var(--danger); border-color: var(--danger); }
.badge { background: var(--danger); color: #fff; font-size: .72rem; padding: .1rem .45rem; border-radius: 999px; }
.nums { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; margin: 0; }
.nums div { background: var(--bg); border-radius: 8px; padding: 8px; }
.nums dt { font-size: .75rem; color: var(--muted); }
.nums dd { margin: 0; font-weight: 700; }
.nums dd.hl { color: var(--accent); }
.nums.big dd { font-size: 1.2rem; }
.empty { color: var(--muted); padding: 2rem; text-align: center; background: var(--surface); border: 1px dashed var(--line); border-radius: var(--radius); }

/* filters */
.filters { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: .5rem; }
.filters select, .filters input { flex: 1 1 140px; }

/* forms */
input, select, textarea {
  width: 100%; font: inherit; color: var(--text); background: var(--surface);
  border: 1px solid var(--line); border-radius: 8px; padding: .55rem .7rem; margin-top: .25rem;
}
input:focus, select:focus, textarea:focus { outline: 2px solid var(--brand); outline-offset: -1px; }
label { display: block; font-size: .9rem; font-weight: 600; margin-bottom: .6rem; }
label.check { display: flex; align-items: center; gap: 8px; font-weight: 500; }
label.check input { width: auto; margin: 0; }
.stack label { margin-bottom: .8rem; }
.form { display: grid; grid-template-columns: 1fr 1fr; gap: 4px 18px; }
.form .full { grid-column: 1 / -1; }

/* panels */
.panel { background: var(--surface); border: 1px solid var(--line); border-radius: 14px; padding: 20px; margin-bottom: 16px; }
.detail { display: grid; grid-template-columns: 1fr 340px; gap: 16px; align-items: start; }
.detail h1 { margin-top: .6rem; }
.side { position: sticky; top: 76px; }
.side h3 { margin-top: 0; }
.side form { margin: 0; }
.spec { width: 100%; border-collapse: collapse; margin: 16px 0; }
.spec th, .spec td { text-align: left; padding: .5rem; border-bottom: 1px solid var(--line); }
.spec th { color: var(--muted); font-weight: 500; width: 140px; }
.desc { white-space: pre-wrap; }
.note { padding: .6rem .8rem; border-radius: 8px; background: var(--brand-soft); font-size: .9rem; }
.note.warn { background: var(--warn-soft); color: var(--warn); }
.note.ok { background: var(--brand-soft); color: var(--accent); }
.safety { margin-top: 16px; background: var(--warn-soft); border-radius: 10px; padding: 12px 14px; font-size: .88rem; }
.safety b, .safety h2 { color: var(--warn); }
.safety ul { margin: .4rem 0 0; padding-left: 1.1rem; }

/* tables */
.scroll { overflow-x: auto; }
.list { width: 100%; border-collapse: collapse; }
.list th, .list td { text-align: left; padding: .7rem .6rem; border-bottom: 1px solid var(--line); vertical-align: top; }
.list th { font-size: .82rem; color: var(--muted); font-weight: 600; white-space: nowrap; }
.list td.msg { max-width: 280px; white-space: pre-wrap; font-size: .9rem; }
.list td.actions { white-space: nowrap; }

/* auth */
.auth { max-width: 440px; margin: 32px auto; }
.auth h1 { margin-top: 0; }
.roles { display: grid; grid-template-columns: repeat(auto-fit, minmax(120px, 1fr)); gap: 8px; margin-bottom: 1rem; }
.role { margin: 0; cursor: pointer; }
.role input { position: absolute; opacity: 0; width: 1px; }
.role span { display: block; border: 2px solid var(--line); border-radius: 10px; padding: 10px; height: 100%; }
.role small { display: block; color: var(--muted); font-weight: 400; }
.role input:checked + span { border-color: var(--brand); background: var(--brand-soft); }
.role input:focus-visible + span { outline: 2px solid var(--brand); }

.cols { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.steps ol li { margin-bottom: .4rem; }
.foot { margin-top: 48px; padding: 24px 0; border-top: 1px solid var(--line); color: var(--muted); font-size: .85rem; }

@media (max-width: 820px) {
  .hero, .detail, .cols, .form { grid-template-columns: 1fr; }
  .hero h1 { font-size: 1.5rem; }
  .side { position: static; }
  .nav nav { gap: 10px; }
  .nav nav a, .nav nav .link { font-size: .88rem; }
}
@media (max-width: 420px) {
  .grid { grid-template-columns: 1fr; }
  .brand .logo { display: none; }
}

