:root {
  --bg: #FAFBF9; --surface: #FFFFFF; --mint: #EEF7F3; --mint-2: #D3F1E6; --mint-ink: #145341;
  --accent: #2A8C72; --accent-d: #1E6B56; --ink: #1E293B; --mute: #526861; --line: #DCECE5;
  --err-bg: #FFF1EC; --err: #9A3412; --warn-bg: #FEF3C7; --warn: #92400E;
}
* { box-sizing: border-box; }
body {
  margin: 0; background: var(--bg); color: var(--ink);
  font: 400 15px/1.6 -apple-system, BlinkMacSystemFont, "Apple SD Gothic Neo", "Malgun Gothic", system-ui, sans-serif;
  word-break: keep-all;
}
a { color: inherit; }
h1 { margin: 0; font-size: 1.45rem; font-weight: 800; letter-spacing: -0.02em; }
h2 { margin: 0; font-size: 1.1rem; font-weight: 800; }
.wrap { max-width: 1100px; margin: 0 auto; padding: 0 20px; }
.muted { color: var(--mute); }

.top { background: var(--surface); border-bottom: 1px solid var(--line); }
.top-row { display: flex; align-items: center; gap: 18px; min-height: 60px; flex-wrap: wrap; }
.logo { font-weight: 800; text-decoration: none; color: var(--mint-ink); }
.top nav { display: flex; gap: 4px; flex: 1; flex-wrap: wrap; }
.top nav a { padding: 6px 12px; border-radius: 999px; text-decoration: none; color: var(--mute); font-weight: 600; font-size: 0.9rem; }
.top nav a:hover, .top nav a[aria-current="page"] { background: var(--mint); color: var(--mint-ink); }

.page { padding: 28px 0 64px; display: grid; gap: 20px; }
.page-head { display: flex; justify-content: space-between; align-items: center; gap: 12px; flex-wrap: wrap; }
.grid-3 { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 14px; }
.grid-2 { display: grid; grid-template-columns: repeat(auto-fit, minmax(320px, 1fr)); gap: 16px; }

.card { background: var(--surface); border: 1px solid var(--line); border-radius: 16px; padding: 20px; display: grid; gap: 12px; }
.metric-val { font-size: 1.9rem; font-weight: 800; letter-spacing: -0.03em; color: var(--mint-ink); }
.badge { display: inline-block; padding: 2px 10px; border-radius: 999px; font-size: 0.75rem; font-weight: 700; }
.badge-ok { background: var(--mint-2); color: var(--mint-ink); }
.badge-warn { background: var(--warn-bg); color: var(--warn); }

.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  min-height: 42px; padding: 0 18px; border: 0; border-radius: 10px;
  background: var(--accent); color: #fff; font: inherit; font-weight: 700; text-decoration: none; cursor: pointer;
}
.btn:hover { background: var(--accent-d); }
.btn-sm { min-height: 34px; padding: 0 12px; font-size: 0.85rem; }
.btn-ghost { background: #fff; color: var(--ink); border: 1px solid var(--line); }
.btn-ghost:hover { background: var(--mint); }
.btn-danger { background: #fff; color: var(--err); border: 1px solid #F3C6B5; }
.btn-danger:hover { background: var(--err-bg); }
.btn-google { background: #fff; color: #1F2937; border: 1px solid #D1D5DB; }
.btn-google:hover { background: #F9FAFB; }

label { display: grid; gap: 6px; font-size: 0.85rem; font-weight: 700; }
input, select, textarea {
  width: 100%; min-height: 40px; padding: 8px 12px; border-radius: 10px;
  border: 1px solid var(--line); background: var(--bg); color: var(--ink); font: inherit; font-weight: 400;
}
textarea { min-height: 100px; resize: vertical; }

.table-wrap { overflow-x: auto; background: var(--surface); border: 1px solid var(--line); border-radius: 14px; }
table { width: 100%; border-collapse: collapse; font-size: 0.9rem; }
th { padding: 10px 14px; text-align: left; font-size: 0.8rem; color: var(--mute); background: var(--mint); white-space: nowrap; }
td { padding: 11px 14px; border-top: 1px solid var(--line); vertical-align: middle; }
.inline-form { display: inline-flex; align-items: center; gap: 6px; flex-wrap: wrap; }
.inline-form select { width: auto; min-height: 32px; padding: 4px 8px; }

.alert { padding: 10px 14px; border-radius: 10px; font-size: 0.9rem; font-weight: 600; }
.alert-ok { background: var(--mint); color: var(--mint-ink); }
.alert-err { background: var(--err-bg); color: var(--err); }
.auth { min-height: 100vh; display: grid; place-items: center; padding: 24px 16px; }
.auth .card { width: min(440px, 100%); padding: 28px; }
