/* 글로리아 관리자 — 홈페이지와 같은 톤(잉크/아이보리/바이올렛) */
@import url("https://cdn.jsdelivr.net/gh/orioncactus/pretendard@v1.3.9/dist/web/variable/pretendardvariable-dynamic-subset.min.css");

:root {
  --paper: #ffffff;
  --ivory: #f8f6f2;
  --panel: #1c1b1a;
  --ink: #1a1a1a;
  --ink-2: #626262;
  --ink-3: #9b9b9b;
  --line: #e7e3dc;
  --accent: #7a5af8;
  --accent-deep: #5b3fd6;
  --accent-soft: #f1edff;
  --danger: #d24545;
  --font: "Pretendard Variable", Pretendard, -apple-system, "Malgun Gothic", sans-serif;
}

* { box-sizing: border-box; }
body {
  margin: 0; background: var(--ivory); color: var(--ink);
  font-family: var(--font); font-size: 14px; line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}
h1, h2, p { margin: 0; }
button { font-family: inherit; cursor: pointer; }
a { color: inherit; text-decoration: none; }
[hidden] { display: none !important; }

.brand {
  font-weight: 700; font-size: 15px; letter-spacing: 0.34em; color: var(--ink);
}
.brand span { color: var(--ink-3); font-size: 11px; letter-spacing: 0.2em; }

/* ---- 버튼 ---- */
.btn {
  display: inline-flex; align-items: center; justify-content: center;
  height: 38px; padding: 0 18px; border: 1px solid transparent; border-radius: 999px;
  font-size: 13px; font-weight: 600; transition: background .2s, border-color .2s, color .2s;
}
.btn--primary { background: var(--accent); color: #fff; }
.btn--primary:hover { background: var(--accent-deep); }
.btn--ghost { background: transparent; border-color: var(--line); color: var(--ink-2); }
.btn--ghost:hover { border-color: var(--ink); color: var(--ink); }
.btn:disabled { opacity: .5; cursor: not-allowed; }

/* ---- 입력 ---- */
.input, select, textarea {
  height: 38px; padding: 0 12px; border: 1px solid var(--line); border-radius: 10px;
  background: var(--paper); font-family: inherit; font-size: 13px; color: var(--ink);
  outline: none; transition: border-color .2s, box-shadow .2s;
}
.input:focus, select:focus, textarea:focus {
  border-color: var(--accent); box-shadow: 0 0 0 3px var(--accent-soft);
}

/* ---- 로그인 ---- */
.login { min-height: 100vh; display: grid; place-items: center; padding: 24px; }
.loginCard {
  width: 100%; max-width: 360px; background: var(--paper);
  border: 1px solid var(--line); border-radius: 18px; padding: 36px 30px 30px;
  display: grid; gap: 14px;
}
.loginCard h1 { font-size: 20px; font-weight: 600; margin: 6px 0 12px; }
.loginCard label { display: grid; gap: 6px; font-size: 12px; color: var(--ink-2); font-weight: 600; }
.loginCard .btn { margin-top: 8px; height: 44px; }
.err { color: var(--danger); font-size: 12.5px; }

/* ---- 상단바 ---- */
.topbar {
  position: sticky; top: 0; z-index: 10;
  display: flex; align-items: center; gap: 24px;
  padding: 14px 24px; background: var(--paper); border-bottom: 1px solid var(--line);
}
.tabs { display: flex; gap: 6px; }
.tab {
  height: 34px; padding: 0 16px; border: 0; border-radius: 999px;
  background: transparent; color: var(--ink-2); font-size: 13px; font-weight: 600;
}
.tab.is-on { background: var(--panel); color: #fff; }
.topbarRight { margin-left: auto; display: flex; align-items: center; gap: 14px; }
.who { font-size: 12px; color: var(--ink-3); }

/* ---- 패널 ---- */
.panel { max-width: 1320px; margin: 0 auto; padding: 26px 24px 60px; }
.panelHead {
  display: flex; align-items: center; gap: 16px; flex-wrap: wrap; margin-bottom: 18px;
}
.panelActions { margin-left: auto; display: flex; gap: 10px; }
.panelActions .input { width: 240px; }

.chips { display: flex; gap: 6px; flex-wrap: wrap; }
.chip {
  height: 32px; padding: 0 14px; border: 1px solid var(--line); border-radius: 999px;
  background: var(--paper); font-size: 12.5px; font-weight: 600; color: var(--ink-2);
}
.chip.is-on { background: var(--panel); border-color: var(--panel); color: #fff; }
.chip b { font-weight: 700; margin-left: 6px; color: inherit; opacity: .7; }

/* ---- 표 ---- */
.tableWrap {
  background: var(--paper); border: 1px solid var(--line); border-radius: 14px; overflow: auto;
}
.table { width: 100%; border-collapse: collapse; font-size: 13px; }
.table th, .table td {
  padding: 12px 14px; text-align: left; border-bottom: 1px solid var(--line);
  vertical-align: top; white-space: nowrap;
}
.table th { background: var(--ivory); font-size: 11px; letter-spacing: .06em; color: var(--ink-3); font-weight: 700; }
.table tbody tr:last-child td { border-bottom: 0; }
.table td.msg { white-space: normal; min-width: 220px; max-width: 340px; color: var(--ink-2); }
.table .right { text-align: right; }
.table td select { height: 32px; }
.table td .memo { width: 160px; height: 32px; }
.linkDel { color: var(--ink-3); font-size: 12px; background: none; border: 0; }
.linkDel:hover { color: var(--danger); }

.empty { padding: 40px 0; text-align: center; color: var(--ink-3); }
.pager { display: flex; align-items: center; justify-content: center; gap: 14px; margin-top: 18px; }
.pageInfo { font-size: 12.5px; color: var(--ink-2); }

/* ---- 일일 손익 ---- */
.h2 { font-size: 15px; font-weight: 700; margin-bottom: 14px; }
.reportGrid { display: grid; grid-template-columns: minmax(0,1fr) minmax(0,1fr); gap: 40px; }
.dateRow { display: inline-flex; align-items: center; gap: 10px; font-size: 12.5px; font-weight: 600; color: var(--ink-2); }
.hint { margin: 12px 0 16px; font-size: 12.5px; color: var(--ink-3); }
.slotGrid { display: grid; grid-template-columns: repeat(2, minmax(0,1fr)); gap: 10px; }
.slotGrid label { display: grid; gap: 5px; font-size: 11px; color: var(--ink-3); font-weight: 700; }
.slotGrid input { text-align: right; font-variant-numeric: tabular-nums; }
.saveRow { display: flex; align-items: center; gap: 14px; margin-top: 20px; }
.saveMsg { font-size: 12.5px; color: var(--ink-2); }

/* 프론트 전시와 같은 모양의 미리보기 */
.preview { border: 3px solid #000; border-radius: 6px; overflow: hidden; }
.previewRow {
  display: flex; align-items: center; justify-content: space-between; gap: 14px;
  padding: 12px 16px; background: #92cf4f; font-weight: 800; font-size: 17px; color: #000;
}
.previewRow + .previewRow { border-top: 3px solid #000; }
.previewRow strong { font-variant-numeric: tabular-nums; }

@media (max-width: 900px) {
  .reportGrid { grid-template-columns: 1fr; gap: 32px; }
  .topbar { flex-wrap: wrap; gap: 12px; }
  .panelActions { width: 100%; margin-left: 0; }
  .panelActions .input { width: 100%; }
}

/* ---- 계정 ---- */
.accountCard {
  max-width: 420px;
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: 16px;
  padding: 30px 28px;
}
.accountCard .hint { margin: 0 0 22px; }
.pwForm { display: grid; gap: 14px; }
.pwForm label {
  display: grid; gap: 6px;
  font-size: 12px; font-weight: 600; color: var(--ink-2);
}
.pwForm input {
  height: 42px; padding: 0 14px; border: 1px solid var(--line); border-radius: 10px;
  background: var(--paper); font-family: inherit; font-size: 14px; color: var(--ink);
  outline: none; transition: border-color .2s, box-shadow .2s;
}
.pwForm input:focus { border-color: var(--accent); box-shadow: 0 0 0 3px var(--accent-soft); }
.pwForm .btn { margin-top: 8px; height: 46px; }
.pwMsg { font-size: 12.5px; margin: 0; }
.pwMsg.is-err { color: var(--danger); }
.pwMsg.is-ok { color: #2f8f4e; }
