* { box-sizing: border-box; }
body {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Helvetica, Arial, sans-serif;
  background: #F4F2EE;
  color: #332E28;
  margin: 0;
  padding: 0;
}
.wrap { max-width: 980px; margin: 0 auto; padding: 24px 16px 60px; }
.topbar {
  display: flex; align-items: center; justify-content: space-between;
  padding: 14px 20px; background: #fff; border-bottom: 1px solid #E4E1D8;
}
.topbar a { color: #332E28; text-decoration: none; font-size: 14px; margin-left: 16px; }
.topbar .brand { font-weight: 600; font-size: 15px; }
card, .card {
  background: #fff; border: 1px solid #E4E1D8; border-radius: 10px; padding: 20px; margin-bottom: 16px;
}
h1 { font-size: 20px; margin: 0 0 16px; }
h2 { font-size: 16px; margin: 0 0 12px; }
label { display: block; font-size: 12px; color: #6B655C; margin-bottom: 4px; }
input[type=text], input[type=email], input[type=tel], input[type=number], input[type=date], input[type=password], select, textarea {
  width: 100%; padding: 8px 10px; border: 1px solid #D8D4C8; border-radius: 6px; font-size: 14px; margin-bottom: 12px; font-family: inherit;
}
button, .btn {
  background: #9184D9; color: #fff; border: none; border-radius: 6px; padding: 9px 16px;
  font-size: 13px; cursor: pointer; text-decoration: none; display: inline-block;
}
button.secondary, .btn.secondary { background: #fff; color: #332E28; border: 1px solid #D8D4C8; }
button.danger, .btn.danger { background: #B4453A; }
table { width: 100%; border-collapse: collapse; font-size: 13px; }
th { text-align: left; color: #6B655C; font-weight: 500; padding: 8px 6px; border-bottom: 1px solid #E4E1D8; }
td { padding: 8px 6px; border-bottom: 1px solid #F0EEE6; }
tr.clickable { cursor: pointer; }
tr.clickable:hover { background: #FAF9F5; }
.badge { display: inline-block; padding: 3px 10px; border-radius: 6px; font-size: 12px; }
.badge.green { background: #E4F0E1; color: #2C5A21; }
.badge.amber { background: #FBEFDC; color: #8A5A0B; }
.badge.red { background: #F8E2E0; color: #963029; }
.badge.gray { background: #EFEDE6; color: #6B655C; }
.stat-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px,1fr)); gap: 12px; margin-bottom: 20px; }
.stat { background: #fff; border: 1px solid #E4E1D8; border-radius: 10px; padding: 14px 16px; }
.stat .label { font-size: 12px; color: #6B655C; }
.stat .value { font-size: 22px; font-weight: 600; margin-top: 4px; }
.flex { display: flex; gap: 10px; align-items: center; }
.flex-between { display: flex; justify-content: space-between; align-items: center; }
.grid2 { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.muted { color: #6B655C; font-size: 12px; }
.error { background: #F8E2E0; color: #963029; padding: 10px 14px; border-radius: 6px; margin-bottom: 14px; font-size: 13px; }
.notice { background: #FBEFDC; color: #8A5A0B; padding: 10px 14px; border-radius: 6px; margin-bottom: 14px; font-size: 13px; }