:root {
  color-scheme: light;
  --bg: #f7f8fa;
  --surface: #ffffff;
  --surface-soft: #f2f4f6;
  --surface-hover: #eef6ff;
  --line: #e5e8eb;
  --text: #191f28;
  --sub: #6b7684;
  --muted: #8b95a1;
  --primary: #3182f6;
  --primary-weak: #e8f3ff;
  --danger: #f04452;
  --danger-weak: #fff0f1;
  --warn: #f59f00;
  --warn-weak: #fff7e6;
  --success: #00a661;
  --success-weak: #e9f9f0;
  --shadow: 0 8px 30px rgba(25, 31, 40, 0.08);
  font-family: Inter, Pretendard, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

* { box-sizing: border-box; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
}

button, input, textarea, select { font: inherit; }
button { border: 0; cursor: pointer; }

.login-shell {
  min-height: 100vh;
  display: grid;
  place-items: center;
  padding: 24px;
  background:
    radial-gradient(circle at 18% 8%, rgba(49, 130, 246, 0.14), transparent 28%),
    linear-gradient(180deg, #ffffff 0%, var(--bg) 100%);
}

.login-card {
  width: min(440px, 100%);
  border-radius: 24px;
  background: var(--surface);
  padding: 34px;
  box-shadow: var(--shadow);
}

.brand-mark {
  color: var(--primary);
  font-size: 16px;
  font-weight: 900;
}

.login-card h1 {
  margin: 28px 0 10px;
  font-size: 34px;
  line-height: 1.18;
  letter-spacing: 0;
}

.login-card p {
  margin: 0 0 28px;
  color: var(--sub);
  line-height: 1.55;
}

.login-card label {
  display: block;
  margin: 16px 0 8px;
  color: var(--text);
  font-size: 13px;
  font-weight: 700;
}

.login-card input {
  width: 100%;
}

.password-field {
  position: relative;
  width: 100%;
}

.password-field input {
  padding-right: 52px;
}

.password-toggle {
  position: absolute;
  right: 8px;
  top: 50%;
  width: 38px;
  height: 38px;
  transform: translateY(-50%);
  border-radius: 12px;
  background: transparent;
  color: var(--muted);
}

.password-toggle:hover {
  background: var(--surface-soft);
  color: var(--text);
}

.password-toggle .material-symbols-outlined {
  font-size: 22px;
  line-height: 1;
}

.password-toggle.visible {
  color: var(--primary);
}

.login-note {
  margin-top: 16px;
  color: var(--muted);
  font-size: 12px;
  text-align: center;
}

.app {
  min-height: 100vh;
  display: grid;
  grid-template-columns: 248px minmax(0, 1fr);
}

.sidebar {
  position: sticky;
  top: 0;
  z-index: 6;
  height: 100vh;
  background: var(--surface);
  border-right: 1px solid var(--line);
  display: flex;
  flex-direction: column;
  padding: 24px 14px 18px;
}

.brand {
  display: flex;
  align-items: baseline;
  gap: 6px;
  padding: 0 10px 8px;
  font-size: 19px;
}

.brand span {
  font-weight: 900;
}

.brand strong {
  color: var(--primary);
  font-size: 13px;
}

.sidebar-caption {
  padding: 0 10px 22px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
}

.mini-profile {
  width: 100%;
  display: grid;
  grid-template-columns: 40px 1fr;
  gap: 11px;
  align-items: center;
  padding: 12px;
  border-radius: 18px;
  background: var(--surface-soft);
  color: var(--text);
  text-align: left;
}

.avatar {
  width: 40px;
  height: 40px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  background: var(--primary);
  color: #fff;
  font-weight: 900;
}

.avatar.image {
  object-fit: cover;
}

.profile-button:hover {
  background: #e6e8eb;
}

.mini-profile strong {
  display: block;
  font-size: 14px;
}

.mini-profile span {
  display: block;
  overflow: hidden;
  color: var(--sub);
  font-size: 12px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.nav {
  display: grid;
  gap: 8px;
  align-content: start;
  flex: 1;
  overflow-y: auto;
  padding-right: 2px;
}

.nav-group {
  display: grid;
  gap: 4px;
}

.nav-group-trigger {
  width: 100%;
  min-height: 42px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  border-radius: 14px;
  background: transparent;
  color: var(--muted);
  padding: 0 10px;
  font-size: 13px;
  font-weight: 900;
  letter-spacing: 0;
  text-align: left;
}

.nav-group-trigger:hover {
  background: var(--surface-soft);
  color: var(--text);
}

.nav-group.open .nav-group-trigger {
  color: var(--text);
}

.nav-group-arrow {
  color: var(--muted);
  font-size: 14px;
  transition: transform 0.14s ease;
}

.nav-group.open .nav-group-arrow {
  transform: rotate(180deg);
}

.nav-tabs {
  display: grid;
  gap: 4px;
  padding: 0 0 8px 8px;
}

.nav-tabs[hidden] {
  display: none;
}

.nav-tab {
  width: 100%;
  min-height: 44px;
  padding: 0 14px;
  border-radius: 14px;
  color: var(--sub);
  background: transparent;
  font-weight: 700;
  text-align: left;
  transition: background 0.14s ease, color 0.14s ease;
}

.nav-tab:hover {
  color: var(--text);
  background: var(--surface-soft);
}

.nav-tab.active {
  color: var(--primary);
  background: var(--primary-weak);
}

.sidebar-footer {
  position: relative;
  padding-top: 18px;
}

.main {
  min-width: 0;
}

.topbar {
  position: sticky;
  top: 0;
  z-index: 6;
  min-height: 86px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 20px 32px;
  background: rgba(247, 248, 250, 0.88);
  backdrop-filter: blur(18px);
  border-bottom: 1px solid rgba(229, 232, 235, 0.7);
}

.title {
  font-size: 28px;
  font-weight: 900;
  line-height: 1.2;
}

.title-sub {
  margin-top: 5px;
  color: var(--sub);
  font-size: 14px;
}

.topbar-actions {
  position: relative;
  display: flex;
  justify-content: flex-end;
}

.notification-button {
  position: relative;
  width: 44px;
  height: 44px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  background: var(--surface);
  color: var(--text);
  box-shadow: 0 1px 0 rgba(25, 31, 40, 0.06);
}

.notification-button .material-symbols-outlined {
  font-size: 23px;
  line-height: 1;
}

.notification-button b {
  position: absolute;
  right: -2px;
  top: -3px;
  min-width: 18px;
  height: 18px;
  display: grid;
  place-items: center;
  border-radius: 999px;
  background: var(--danger);
  color: #fff;
  padding: 0 5px;
  font-size: 11px;
  line-height: 1;
}

.notification-dropdown {
  position: absolute;
  right: 0;
  top: 54px;
  z-index: 4;
  width: 320px;
  border: 1px solid var(--line);
  border-radius: 22px;
  background: var(--surface);
  padding: 10px;
  box-shadow: var(--shadow);
}

.notification-head {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  padding: 8px 8px 12px;
  border-bottom: 1px solid var(--line);
}

.notification-head strong {
  font-size: 15px;
}

.notification-head span {
  color: var(--sub);
  font-size: 12px;
  font-weight: 800;
}

.notification-item {
  width: 100%;
  display: grid;
  gap: 4px;
  border-radius: 16px;
  background: transparent;
  padding: 13px 10px;
  color: var(--text);
  text-align: left;
}

.notification-item:hover {
  background: var(--surface-soft);
}

.notification-item span {
  color: var(--sub);
  font-size: 12px;
  font-weight: 800;
}

.notification-item strong {
  font-size: 15px;
}

.notification-empty {
  padding: 18px 10px 10px;
  color: var(--sub);
  font-size: 13px;
}

.account-dropdown {
  position: absolute;
  bottom: 78px;
  left: 0;
  width: 280px;
  border: 1px solid var(--line);
  border-radius: 22px;
  background: var(--surface);
  padding: 12px;
  box-shadow: var(--shadow);
}

.account-menu-head {
  display: grid;
  grid-template-columns: 40px 1fr;
  gap: 11px;
  align-items: center;
  padding: 8px 8px 12px;
  border-bottom: 1px solid var(--line);
}

.account-menu-head strong,
.account-menu-head span {
  display: block;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.account-menu-head strong {
  font-size: 14px;
}

.account-menu-head span {
  margin-top: 2px;
  color: var(--sub);
  font-size: 12px;
}

.account-menu-row {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  padding: 12px 8px 0;
  color: var(--sub);
  font-size: 12px;
}

.account-menu-row strong {
  overflow: hidden;
  color: var(--text);
  text-overflow: ellipsis;
  white-space: nowrap;
}

.dropdown-action {
  width: 100%;
  min-height: 42px;
  margin-top: 8px;
  border-radius: 14px;
  background: transparent;
  color: var(--text);
  padding: 0 10px;
  font-weight: 800;
  text-align: left;
}

.dropdown-action:hover {
  background: var(--surface-soft);
}

.menu-backdrop {
  position: fixed;
  inset: 0;
  z-index: 3;
  background: transparent;
}

.content {
  max-width: 1280px;
  padding: 26px 32px 52px;
}

.cards {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 14px;
  margin-bottom: 18px;
}

.metric-card {
  min-height: 132px;
  padding: 20px;
  border-radius: 24px;
  background: var(--surface);
  box-shadow: 0 1px 0 rgba(25, 31, 40, 0.04);
  color: inherit;
  text-align: left;
  transition: transform 0.14s ease, box-shadow 0.14s ease;
}

.metric-card:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow);
}

.metric-card .label {
  color: var(--sub);
  font-size: 14px;
  font-weight: 800;
}

.metric-card .value {
  margin-top: 10px;
  font-size: 38px;
  font-weight: 900;
}

.metric-card p {
  margin: 10px 0 0;
  color: var(--muted);
  font-size: 13px;
}

.metric-card.urgent .value { color: var(--danger); }
.metric-card.watch .value { color: var(--warn); }
.metric-card.good .value { color: var(--primary); }
.metric-card.money .value { color: var(--success); }

.panel {
  padding: 22px;
  margin-bottom: 14px;
  border-radius: 24px;
  background: var(--surface);
}

.panel h2 {
  margin: 0 0 9px;
  font-size: 19px;
  line-height: 1.35;
}

.panel p {
  margin: 0;
  color: var(--sub);
  line-height: 1.6;
}

.hero-panel {
  background: #191f28;
  color: #fff;
}

.hero-panel p {
  color: #d1d6db;
}

.dashboard-grid {
  display: grid;
  grid-template-columns: 1.25fr 1fr 1fr;
  gap: 14px;
}

.section-head {
  display: flex;
  justify-content: space-between;
  gap: 18px;
  align-items: center;
}

.section-head h2 {
  margin: 0 0 6px;
}

.section-head p {
  margin: 0;
}

.dashboard-controls {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 8px;
}

.slim-panel {
  margin-bottom: 14px;
}

.segmented {
  display: inline-flex;
  gap: 4px;
  padding: 4px;
  border-radius: 999px;
  background: var(--surface-soft);
}

.segmented button {
  min-height: 34px;
  border-radius: 999px;
  background: transparent;
  color: var(--sub);
  padding: 0 12px;
  font-weight: 800;
}

.segmented button.active {
  background: var(--surface);
  color: var(--text);
  box-shadow: 0 1px 6px rgba(25, 31, 40, 0.08);
}

.chart-card {
  margin-top: 14px;
}

.metric-strip {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
  margin-top: 18px;
}

.metric-summary {
  min-width: 0;
  border-radius: 16px;
  background: var(--surface-soft);
  padding: 13px 14px;
}

.metric-summary-head,
.mini-chart-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 8px;
}

.metric-summary-head > span,
.metric-summary small {
  display: block;
  color: var(--sub);
  font-size: 12px;
  line-height: 1.35;
}

.metric-tabs {
  display: inline-flex;
  flex-shrink: 0;
  gap: 3px;
  padding: 3px;
  border-radius: 999px;
  background: var(--surface);
}

.metric-tabs button {
  min-height: 24px;
  border-radius: 999px;
  background: transparent;
  color: var(--sub);
  padding: 0 8px;
  font-size: 11px;
  font-weight: 900;
}

.metric-tabs button.active {
  background: var(--primary);
  color: #fff;
}

.metric-summary strong {
  display: block;
  margin: 5px 0;
  font-size: 21px;
  line-height: 1.2;
}

.metric-exact {
  display: block;
  margin: -1px 0 5px;
  color: var(--muted);
  font-size: 12px;
  font-style: normal;
  font-weight: 800;
}

.chart-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 14px;
  margin-top: 18px;
}

.mini-chart {
  position: relative;
  min-width: 0;
  border-radius: 18px;
  background: var(--surface-soft);
  padding: 16px;
  cursor: grab;
  user-select: none;
  touch-action: none;
  transition: opacity 140ms ease, transform 180ms ease, box-shadow 140ms ease;
}

.mini-chart.dragging-source {
  display: none;
}

.metric-dragging {
  cursor: grabbing;
  user-select: none;
}

.metric-drag-preview {
  position: fixed;
  left: 0;
  top: 0;
  z-index: 20;
  margin: 0;
  opacity: 0.92;
  pointer-events: none;
  cursor: grabbing;
  box-shadow: 0 18px 42px rgba(25, 31, 40, 0.2);
  transition: none !important;
  will-change: transform;
  transform: translate3d(-9999px, -9999px, 0);
}

.mini-chart.drag-over {
  transform: translateY(-3px);
  box-shadow: 0 0 0 2px var(--primary);
}

.metric-placeholder {
  min-width: 0;
  border: 2px dashed rgba(49, 130, 246, 0.34);
  border-radius: 18px;
  background: rgba(49, 130, 246, 0.08);
  transition: transform 180ms ease, background 140ms ease, border-color 140ms ease;
}

.mini-chart-head strong {
  display: block;
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.mini-chart p {
  min-height: 34px;
  margin: 0 0 12px;
  font-size: 12px;
}

.bars {
  height: 112px;
  display: flex;
  align-items: flex-end;
  gap: 6px;
}

.bar {
  flex: 1;
  min-width: 5px;
  border-radius: 999px 999px 0 0;
  background: var(--primary);
  padding: 0;
  transition: opacity 140ms ease, transform 140ms ease;
}

.bar:hover,
.bar:focus-visible {
  opacity: 0.82;
  transform: translateY(-2px);
  outline: none;
}

.line-chart {
  width: 100%;
  height: 112px;
  overflow: visible;
}

.line-chart polyline {
  fill: none;
  stroke: var(--primary);
  stroke-width: 4;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.line-chart circle {
  fill: var(--surface);
  stroke: var(--primary);
  stroke-width: 3;
  cursor: pointer;
  outline: none;
}

.line-chart circle:hover,
.line-chart circle:focus-visible {
  fill: var(--primary-weak);
}

.chart-tooltip {
  position: absolute;
  z-index: 5;
  width: max-content;
  max-width: min(220px, calc(100% - 24px));
  transform: translate(-50%, -100%);
  border-radius: 16px;
  background: #191f28;
  color: #fff;
  padding: 10px 12px;
  box-shadow: 0 10px 28px rgba(25, 31, 40, 0.24);
  pointer-events: none;
}

.chart-tooltip::after {
  content: "";
  position: absolute;
  left: 50%;
  bottom: -6px;
  width: 12px;
  height: 12px;
  transform: translateX(-50%) rotate(45deg);
  border-radius: 2px;
  background: #191f28;
}

.chart-tooltip span,
.chart-tooltip small {
  display: block;
  color: #d1d6db;
  font-size: 12px;
  line-height: 1.35;
}

.chart-tooltip strong {
  display: block;
  margin: 2px 0;
  color: #fff;
  font-size: 18px;
  line-height: 1.25;
}

.chart-foot {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  gap: 8px;
  margin-top: 10px;
  color: var(--muted);
  font-size: 12px;
}

.chart-foot b {
  color: var(--text);
}

.chart-foot span:last-child {
  text-align: right;
}

.quick {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.toolbar, .inline-form {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  align-items: center;
  margin-bottom: 14px;
  padding: 12px;
  border-radius: 20px;
  background: var(--surface);
}

.ops-form {
  display: grid;
  grid-template-columns: repeat(3, minmax(160px, 1fr)) auto;
}

.ops-form input,
.ops-form select {
  width: 100%;
}

.compact-form {
  display: grid;
  grid-template-columns: minmax(180px, 320px) auto;
}

.point-ledger-filter {
  display: grid;
  grid-template-columns: minmax(110px, 160px) minmax(220px, 1fr) auto auto;
}

.point-ledger-filter input {
  width: 100%;
}

input, textarea, select {
  min-height: 46px;
  border: 0;
  border-radius: 14px;
  background: var(--surface-soft);
  color: var(--text);
  padding: 0 15px;
  outline: none;
}

textarea {
  width: 100%;
  min-height: 150px;
  padding: 14px 15px;
  resize: vertical;
}

input:focus, textarea:focus, select:focus {
  box-shadow: inset 0 0 0 2px var(--primary);
}

.wide {
  width: 100%;
  margin-top: 20px;
}

.primary {
  min-height: 46px;
  border-radius: 14px;
  background: var(--primary);
  color: #fff;
  padding: 0 18px;
  font-weight: 800;
}

.primary:hover {
  background: #1b64da;
}

.ghost {
  min-height: 40px;
  border-radius: 14px;
  background: var(--surface-soft);
  color: var(--text);
  padding: 0 14px;
  font-weight: 700;
}

.ghost:hover {
  background: #e6e8eb;
}

.danger-text {
  color: var(--danger);
}

.rows {
  overflow: hidden;
  border-radius: 24px;
  background: var(--surface);
}

.row {
  padding: 18px 20px;
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 16px;
  border-bottom: 1px solid var(--line);
}

.row-main.with-thumb {
  min-width: 0;
  display: grid;
  grid-template-columns: 58px minmax(0, 1fr);
  gap: 14px;
  align-items: center;
}

.thumb {
  width: 58px;
  height: 58px;
  border-radius: 14px;
  object-fit: cover;
  background: var(--surface-soft);
}

.thumb.placeholder {
  display: grid;
  place-items: center;
  color: var(--sub);
  font-weight: 900;
}

.row:last-child {
  border-bottom: 0;
}

.point-ledger-row {
  grid-template-columns: minmax(170px, 1.1fr) minmax(220px, 1.6fr) minmax(100px, 0.7fr) minmax(100px, 0.7fr) minmax(120px, 0.8fr);
  align-items: center;
}

.point-ledger-head {
  display: grid;
  grid-template-columns: minmax(170px, 1.1fr) minmax(220px, 1.6fr) minmax(100px, 0.7fr) minmax(100px, 0.7fr) minmax(120px, 0.8fr);
  gap: 16px;
  padding: 13px 20px;
  border-bottom: 1px solid var(--line);
  background: var(--surface-soft);
  color: var(--muted);
  font-size: 12px;
  font-weight: 900;
}

.point-ledger-head span:nth-child(n + 3) {
  text-align: right;
}

.ledger-member,
.ledger-description,
.ledger-balance {
  min-width: 0;
  display: grid;
  gap: 4px;
}

.ledger-member strong,
.ledger-description strong,
.ledger-balance strong {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.ledger-member span,
.ledger-member small,
.ledger-balance span,
.ledger-balance small {
  color: var(--muted);
  font-size: 12px;
}

.ledger-description span {
  justify-self: start;
}

.ledger-money {
  min-height: 40px;
  display: grid;
  align-items: center;
  justify-content: end;
  border-radius: 14px;
  padding: 0 12px;
  background: var(--surface-soft);
  color: var(--muted);
  font-weight: 900;
  font-variant-numeric: tabular-nums;
}

.ledger-in {
  background: var(--success-weak);
  color: var(--success);
}

.ledger-out {
  background: var(--danger-weak);
  color: var(--danger);
}

.ledger-balance {
  text-align: right;
}

.ledger-balance strong {
  font-variant-numeric: tabular-nums;
}

.row h3 {
  margin: 0;
  font-size: 16px;
  line-height: 1.35;
}

.row p {
  margin: 7px 0 0;
  color: var(--sub);
  line-height: 1.45;
}

.meta {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  align-items: center;
  margin-top: 10px;
  color: var(--muted);
  font-size: 12px;
}

.muted {
  color: var(--muted);
}

.chip {
  display: inline-flex;
  align-items: center;
  min-height: 26px;
  border-radius: 999px;
  padding: 0 10px;
  font-size: 12px;
  font-weight: 800;
}

.chip.ok {
  background: var(--success-weak);
  color: var(--success);
}

.chip.warn {
  background: var(--warn-weak);
  color: #ad6b00;
}

.chip.danger {
  background: var(--danger-weak);
  color: var(--danger);
}

.chip.neutral {
  background: var(--surface-soft);
  color: var(--sub);
}

.metric-pill {
  color: var(--sub);
  font-weight: 800;
}

.content-metrics {
  display: flex;
  align-items: end;
  gap: 12px;
  margin-top: 12px;
  color: var(--muted);
  font-size: 12px;
}

.sparkline {
  height: 48px;
  min-width: 154px;
  display: flex;
  align-items: flex-end;
  gap: 5px;
}

.sparkline span {
  width: 14px;
  border-radius: 999px 999px 0 0;
  background: var(--primary);
}

.type-tabs {
  display: flex;
  gap: 6px;
  overflow-x: auto;
  margin-bottom: 14px;
  padding: 8px;
  border-radius: 20px;
  background: var(--surface);
}

.type-tabs button {
  min-height: 38px;
  flex: 0 0 auto;
  border-radius: 999px;
  background: transparent;
  color: var(--sub);
  padding: 0 14px;
  font-weight: 800;
}

.type-tabs button.active {
  background: var(--primary);
  color: #fff;
}

.actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 7px;
  align-content: start;
}

.alert {
  margin-bottom: 14px;
  border-radius: 18px;
  background: var(--success-weak);
  color: var(--success);
  padding: 14px 16px;
  font-weight: 700;
}

.alert.danger, .error {
  background: var(--danger-weak);
  color: var(--danger);
}

.empty {
  color: var(--sub);
}

.skeleton {
  color: var(--sub);
}

.pager {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 10px;
  margin-top: 18px;
}

@media (max-width: 980px) {
  .app {
    grid-template-columns: 188px minmax(0, 1fr);
  }
  .sidebar {
    padding: 18px 10px 14px;
  }
  .brand {
    font-size: 17px;
  }
  .nav {
    gap: 6px;
  }
  .nav-tab {
    min-height: 42px;
    padding: 0 11px;
    font-size: 13px;
  }
  .mini-profile {
    grid-template-columns: 34px 1fr;
    gap: 8px;
    padding: 10px;
  }
  .mini-profile .avatar {
    width: 34px;
    height: 34px;
  }
  .cards,
  .dashboard-grid,
  .metric-strip,
  .chart-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .topbar {
    padding: 18px;
  }
  .content {
    padding: 18px;
  }
  .row {
    grid-template-columns: 1fr;
  }
  .point-ledger-filter,
  .point-ledger-row,
  .point-ledger-head {
    grid-template-columns: 1fr;
  }
  .point-ledger-head {
    display: none;
  }
  .ledger-money,
  .ledger-balance {
    justify-content: start;
    text-align: left;
  }
  .ops-form {
    grid-template-columns: 1fr 1fr;
  }
  .actions {
    justify-content: flex-start;
  }
  .section-head {
    align-items: flex-start;
    flex-direction: column;
  }
}

@media (max-width: 620px) {
  .app {
    grid-template-columns: 156px minmax(0, 1fr);
  }
  .sidebar {
    padding: 16px 8px 12px;
  }
  .brand {
    display: grid;
    gap: 0;
    padding: 0 8px 8px;
  }
  .sidebar-caption,
  .nav-group-trigger {
    padding-left: 8px;
    padding-right: 8px;
  }
  .nav-tab {
    border-radius: 12px;
    font-size: 12px;
  }
  .mini-profile {
    display: none;
  }
  .topbar {
    align-items: flex-start;
    flex-direction: column;
    gap: 12px;
  }
  .account-dropdown {
    width: min(280px, calc(100vw - 178px));
  }
  .cards,
  .dashboard-grid,
  .metric-strip,
  .chart-grid {
    grid-template-columns: 1fr;
  }
  .ops-form {
    grid-template-columns: 1fr;
  }
  .compact-form {
    grid-template-columns: 1fr;
  }
  .login-card {
    padding: 26px 20px;
  }
}
