:root {
  --bg: #f4f6f8;
  --surface: #ffffff;
  --surface-soft: #eef3f5;
  --line: #dce2e7;
  --text: #18212b;
  --muted: #697581;
  --brand: #08766d;
  --brand-dark: #075e57;
  --blue: #2563eb;
  --amber: #a85a00;
  --red: #b42318;
  --green: #137a45;
}

* { box-sizing: border-box; }

html { background: #e9edf0; }

body {
  margin: 0;
  min-height: 100vh;
  background: var(--bg);
  color: var(--text);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Arial, "Microsoft YaHei", sans-serif;
  letter-spacing: 0;
}

button, input, select, textarea { font: inherit; letter-spacing: 0; }

button, a.button {
  min-height: 40px;
  border: 0;
  border-radius: 6px;
  padding: 9px 14px;
  text-decoration: none;
  cursor: pointer;
}

button:disabled { opacity: .55; cursor: not-allowed; }

button.primary, a.primary { background: var(--brand); color: #fff; }
button.primary:active { background: var(--brand-dark); }
button.secondary, a.secondary { background: #e8edf1; color: var(--text); }
button.outline { background: #fff; color: var(--brand); border: 1px solid #8dc2bd; }
button.warning { background: #fff1dd; color: var(--amber); }
.block { display: flex; width: 100%; align-items: center; justify-content: center; }
.compact { min-height: 34px; padding: 6px 10px; }

input, select, textarea {
  width: 100%;
  border: 1px solid #cfd7de;
  border-radius: 6px;
  background: #fff;
  color: var(--text);
  padding: 11px 12px;
  outline: none;
}

input:focus, select:focus, textarea:focus {
  border-color: var(--brand);
  box-shadow: 0 0 0 2px rgba(8, 118, 109, .1);
}

.invite-nickname-suggested { color: var(--muted); }
.invite-nickname-suggested:focus { color: var(--text); }

textarea { min-height: 88px; resize: vertical; }

.app-shell {
  width: min(100%, 520px);
  min-height: 100vh;
  margin: 0 auto;
  background: var(--bg);
  box-shadow: 0 0 24px rgba(17, 32, 45, .06);
}

.topbar {
  position: sticky;
  top: 0;
  z-index: 10;
  padding: calc(10px + env(safe-area-inset-top)) 14px 10px;
  background: rgba(255, 255, 255, .96);
  border-bottom: 1px solid var(--line);
  backdrop-filter: blur(12px);
}

.topbar-row { display: flex; align-items: center; gap: 10px; min-height: 40px; }
.topbar-title { min-width: 0; }
.topbar h1 { margin: 0; font-size: 19px; line-height: 1.25; word-break: break-word; }
.topbar-sub { margin-top: 3px; color: var(--muted); font-size: 12px; word-break: break-word; }

.icon-button {
  display: grid;
  width: 36px;
  min-width: 36px;
  min-height: 36px;
  place-items: center;
  padding: 0;
  border: 1px solid var(--line);
  background: #fff;
  color: var(--text);
  font-size: 30px;
  line-height: 1;
}

.content {
  display: grid;
  gap: 16px;
  padding: 14px 14px calc(78px + env(safe-area-inset-bottom));
}

.tabs {
  position: fixed;
  z-index: 12;
  left: 50%;
  bottom: 0;
  transform: translateX(-50%);
  width: min(100%, 520px);
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  padding: 5px 8px calc(5px + env(safe-area-inset-bottom));
  border-top: 1px solid var(--line);
  background: rgba(255, 255, 255, .98);
}

.tab {
  position: relative;
  min-width: 0;
  min-height: 46px;
  padding: 8px 4px;
  background: transparent;
  color: var(--muted);
  border-radius: 0;
  font-size: 13px;
}

.tab.active { color: var(--brand); font-weight: 700; }
.tab.active::before {
  content: "";
  position: absolute;
  top: 1px;
  left: 50%;
  width: 24px;
  height: 3px;
  border-radius: 3px;
  transform: translateX(-50%);
  background: var(--brand);
}

.tab b {
  position: absolute;
  top: 2px;
  left: calc(50% + 11px);
  min-width: 18px;
  height: 18px;
  padding: 0 4px;
  border-radius: 9px;
  background: var(--red);
  color: #fff;
  font-size: 10px;
  line-height: 18px;
}

.login-page, .invite-page {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 24px;
  padding: calc(28px + env(safe-area-inset-top)) 24px calc(28px + env(safe-area-inset-bottom));
  background: #fff;
}

.login-brand { display: flex; align-items: center; gap: 14px; }
.brand-mark {
  display: grid;
  flex: 0 0 54px;
  width: 54px;
  height: 54px;
  place-items: center;
  border-radius: 8px;
  background: var(--brand);
  color: #fff;
  font-size: 20px;
  font-weight: 800;
}
.login-brand h1, .invite-brand h1 { margin: 0; font-size: 27px; }
.login-brand p { margin: 5px 0 0; color: var(--muted); }
.login-form, .invite-form { display: grid; gap: 14px; }

.field { display: grid; gap: 7px; }
.field label { color: #4d5965; font-size: 13px; font-weight: 600; }

.dashboard-hero {
  margin: -14px -14px 0;
  padding: 22px 18px;
  background: #153b3a;
  color: #fff;
}
.dashboard-hero p { margin: 0 0 8px; color: #aee0db; font-size: 13px; }
.dashboard-hero h2 { margin: 0; max-width: 440px; font-size: 22px; line-height: 1.35; }
.hero-meta { margin-top: 11px; color: #c8d7d6; font-size: 12px; }

.metric-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
.metric {
  min-width: 0;
  min-height: 112px;
  padding: 13px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface);
}
.metric.accent { border-top: 3px solid var(--blue); }
.metric.warm { border-top: 3px solid #d97706; }
.metric > span { display: block; color: var(--muted); font-size: 12px; }
.metric strong { display: block; margin-top: 9px; font-size: 21px; line-height: 1.25; word-break: break-word; }
.metric small { display: block; margin-top: 7px; color: var(--muted); font-size: 11px; line-height: 1.35; }

.dashboard-notice {
  padding: 11px 13px;
  border-left: 3px solid var(--blue);
  background: #eef6f7;
  color: #52616d;
  font-size: 12px;
  line-height: 1.6;
}
.dashboard-scope-tabs, .customer-subtabs {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 4px;
  padding: 4px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #edf1f3;
}
.dashboard-scope-tabs button, .customer-subtabs button {
  min-width: 0;
  min-height: 38px;
  padding: 7px 8px;
  border: 0;
  background: transparent;
  color: var(--muted);
  font-size: 13px;
}
.dashboard-scope-tabs button.active, .customer-subtabs button.active {
  background: #fff;
  color: var(--brand);
  box-shadow: 0 1px 4px rgba(30, 54, 64, .12);
}
.dashboard-scope-tabs > span {
  grid-column: 1 / -1;
  padding: 3px 4px 1px;
  color: var(--muted);
  font-size: 10px;
  text-align: center;
}

.page-section {
  padding: 2px 0 14px;
  border-bottom: 1px solid var(--line);
}
.page-section:last-child { border-bottom: 0; }
.section-head { display: flex; justify-content: space-between; gap: 12px; align-items: baseline; margin-bottom: 10px; }
.section-head h2 { margin: 0; font-size: 17px; }
.section-head > span { color: var(--muted); font-size: 12px; text-align: right; }

.metric-strip {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
}
.metric-strip > div { min-width: 0; padding: 13px 10px; border-right: 1px solid var(--line); }
.metric-strip > div:last-child { border-right: 0; }
.metric-strip span { display: block; color: var(--muted); font-size: 11px; }
.metric-strip strong { display: block; margin-top: 6px; font-size: 15px; word-break: break-word; }

.alert-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); border: 1px solid #efd6c0; border-radius: 8px; background: #fffaf5; }
.alert-grid div { min-width: 0; padding: 12px 6px; text-align: center; }
.alert-grid strong { display: block; color: var(--amber); font-size: 19px; }
.alert-grid span { display: block; margin-top: 4px; color: var(--muted); font-size: 10px; }

.trend-chart {
  height: 184px;
  display: grid;
  grid-template-columns: repeat(7, minmax(0, 1fr));
  align-items: end;
  gap: 6px;
  padding: 12px 8px 8px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
}
.trend-column { height: 100%; display: grid; grid-template-rows: 30px 1fr 20px; align-items: end; text-align: center; min-width: 0; }
.trend-column > span { overflow: hidden; color: var(--muted); font-size: 9px; text-overflow: ellipsis; }
.trend-column i { display: block; width: min(22px, 72%); min-height: 4px; margin: 0 auto; border-radius: 3px 3px 0 0; background: var(--blue); }
.trend-column small { color: var(--muted); font-size: 9px; white-space: nowrap; }

.data-list { border-top: 1px solid var(--line); }
.data-row {
  width: 100%;
  min-width: 0;
  min-height: 58px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  padding: 10px 2px;
  border: 0;
  border-bottom: 1px solid var(--line);
  border-radius: 0;
  background: transparent;
  color: var(--text);
  text-align: left;
}
.data-row > div, .data-row > span { min-width: 0; }
.data-row strong { display: block; font-size: 14px; word-break: break-word; }
.data-row small { display: block; margin-top: 4px; color: var(--muted); font-size: 11px; line-height: 1.4; word-break: break-word; }
.data-row .row-value { flex: 0 0 112px; text-align: right; }
.data-row.stacked { display: block; }
.data-row.stacked p { margin: 8px 0 0; font-size: 13px; line-height: 1.55; word-break: break-word; }
.customer-jump { cursor: pointer; }

.focus-group + .focus-group { margin-top: 14px; }
.focus-group h3 { margin: 0 0 4px; color: var(--muted); font-size: 12px; }

.rule-summary { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; }
.rule-summary div { min-width: 0; padding: 11px; border-left: 3px solid #91a1ae; background: #fff; }
.rule-summary span { display: block; color: var(--muted); font-size: 11px; }
.rule-summary strong { display: block; margin-top: 5px; font-size: 15px; word-break: break-word; }
.rule-notes { margin-top: 9px; border-top: 1px solid var(--line); }
.rule-notes p { margin: 0; padding: 9px 2px; border-bottom: 1px solid var(--line); color: var(--muted); font-size: 11px; line-height: 1.55; }
.rule-notes p:last-child { border-bottom: 0; }

.ranking-head {
  display: flex;
  justify-content: space-between;
  align-items: end;
  gap: 14px;
  padding: 6px 0 2px;
}
.ranking-head > div { min-width: 0; }
.ranking-head span, .ranking-head small { color: var(--muted); font-size: 11px; }
.ranking-head h2 { margin: 4px 0 0; font-size: 21px; line-height: 1.35; word-break: break-word; }
.ranking-head small { flex: 0 0 auto; padding-bottom: 3px; text-align: right; }
.ranking-summary strong { font-size: 14px; }
.ranking-list { display: grid; gap: 9px; }
.ranking-row {
  min-width: 0;
  display: grid;
  grid-template-columns: 30px 32px minmax(0, 1fr) auto;
  align-items: center;
  gap: 9px;
  padding: 12px 10px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
}
.ranking-row.is-current { border-color: #70aaa5; box-shadow: inset 3px 0 0 var(--brand); }
.ranking-position {
  display: grid;
  width: 28px;
  height: 28px;
  place-items: center;
  border-radius: 50%;
  background: #e8edf1;
  color: #52616d;
  font-size: 12px;
  font-weight: 800;
}
.ranking-position.top-1 { background: #f4c95d; color: #5f4300; }
.ranking-position.top-2 { background: #d7dee4; color: #35414b; }
.ranking-position.top-3 { background: #d89b6a; color: #4d2910; }
.ranking-main { min-width: 0; }
.ranking-name { display: flex; align-items: center; gap: 6px; min-width: 0; }
.ranking-name strong { overflow: hidden; font-size: 14px; text-overflow: ellipsis; white-space: nowrap; }
.ranking-name span { flex: 0 0 auto; padding: 2px 5px; border-radius: 4px; background: #dff3f0; color: var(--brand-dark); font-size: 9px; font-weight: 700; }
.ranking-main > small { display: block; margin-top: 3px; color: var(--muted); font-size: 10px; }
.ranking-progress { height: 4px; margin-top: 8px; overflow: hidden; border-radius: 2px; background: #e8edf1; }
.ranking-progress i { display: block; height: 100%; border-radius: inherit; background: var(--blue); }
.ranking-periods { display: flex; flex-wrap: wrap; gap: 4px 10px; margin-top: 7px; }
.ranking-periods span { color: var(--muted); font-size: 9px; white-space: nowrap; }
.ranking-periods b { color: #44515d; font-weight: 700; }
.ranking-amount { min-width: 86px; text-align: right; }
.ranking-amount small { display: block; color: var(--muted); font-size: 9px; }
.ranking-amount strong { display: block; margin-top: 4px; color: var(--brand-dark); font-size: 14px; white-space: nowrap; }

.searchbar { display: grid; grid-template-columns: 1fr auto; gap: 8px; }
.section-count { margin-top: -2px; color: var(--muted); font-size: 11px; }
.customer-list, .order-list, .record-list { display: grid; gap: 10px; }
.customer-card, .record-card {
  min-width: 0;
  padding: 13px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
}
.customer-main { display: flex; gap: 11px; min-width: 0; }
.customer-info { flex: 1; min-width: 0; }
.customer-info p, .record-card p { margin: 5px 0 0; color: var(--muted); font-size: 12px; line-height: 1.45; word-break: break-word; }
.name-line { display: flex; justify-content: space-between; align-items: flex-start; gap: 8px; }
.name-line strong { min-width: 0; font-size: 15px; word-break: break-word; }
.status { display: inline-flex; flex: 0 0 auto; align-items: center; min-height: 23px; padding: 3px 8px; border-radius: 12px; background: #edf1f4; color: #4b5864; font-size: 11px; }
.status.warning { background: #fff0d9; color: var(--amber); }
.card-actions { display: flex; flex-wrap: wrap; gap: 7px; margin-top: 11px; }
.card-actions > button, .card-actions > a { flex: 1; min-width: 82px; }
.team-member-card { border-left: 3px solid #8fa6a5; }

.avatar {
  position: relative;
  overflow: hidden;
  display: block;
  flex: 0 0 44px;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  object-fit: cover;
  background: #dcebea;
}
.avatar-fallback { display: grid; place-items: center; color: var(--brand); font-weight: 800; }
.avatar-image { display: grid; place-items: center; color: var(--brand); font-weight: 800; }
.avatar-image > img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.avatar.large { flex-basis: 58px; width: 58px; height: 58px; font-size: 20px; }
.avatar.small { flex-basis: 32px; width: 32px; height: 32px; font-size: 12px; }

.profile-summary {
  display: flex;
  align-items: center;
  gap: 13px;
  min-width: 0;
  padding: 4px 0 16px;
  border-bottom: 1px solid var(--line);
}
.profile-summary > div { flex: 1; min-width: 0; }
.profile-summary h2 { margin: 0; font-size: 20px; word-break: break-word; }
.profile-summary p { margin: 5px 0 0; color: var(--muted); font-size: 12px; line-height: 1.45; word-break: break-word; }
.customer-summary button { flex: 0 0 auto; }

.form-section { display: grid; gap: 13px; }
.form-section .section-head { margin-bottom: 0; }

.binding-state {
  min-height: 58vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
}
.binding-icon, .success-mark {
  display: grid;
  width: 58px;
  height: 58px;
  place-items: center;
  border-radius: 50%;
  background: #dcedeb;
  color: var(--brand);
  font-weight: 800;
}
.binding-state h2 { margin: 18px 0 7px; font-size: 20px; }
.binding-state p, .error-page p { max-width: 340px; margin: 0; color: var(--muted); font-size: 13px; line-height: 1.7; }

.chat-identity { display: flex; align-items: center; gap: 10px; padding-bottom: 12px; border-bottom: 1px solid var(--line); }
.chat-identity > div { min-width: 0; }
.chat-identity strong { display: block; word-break: break-word; }
.chat-identity small { display: block; margin-top: 4px; color: var(--muted); font-size: 11px; }
.conversation-list { background: #fff; border-top: 1px solid var(--line); }
.conversation {
  position: relative;
  width: 100%;
  min-width: 0;
  min-height: 70px;
  display: flex;
  align-items: center;
  gap: 11px;
  padding: 11px 2px;
  border-bottom: 1px solid var(--line);
  border-radius: 0;
  background: #fff;
  color: var(--text);
  text-align: left;
}
.conversation-body { flex: 1; min-width: 0; }
.conversation-title { display: flex; justify-content: space-between; gap: 8px; }
.conversation-title strong { min-width: 0; overflow: hidden; font-size: 14px; text-overflow: ellipsis; white-space: nowrap; }
.conversation-title small { flex: 0 0 auto; color: var(--muted); font-size: 10px; }
.conversation-preview { display: block; margin-top: 6px; overflow: hidden; color: var(--muted); font-size: 12px; text-overflow: ellipsis; white-space: nowrap; }
.unread-badge { display: grid; min-width: 20px; height: 20px; place-items: center; padding: 0 5px; border-radius: 10px; background: var(--red); color: #fff; font-size: 10px; }

.chat-content { display: block; padding-bottom: calc(70px + env(safe-area-inset-bottom)); }
.chat-page { min-height: calc(100vh - 138px - env(safe-area-inset-top) - env(safe-area-inset-bottom)); }
.chat-messages {
  height: calc(100vh - 206px - env(safe-area-inset-top) - env(safe-area-inset-bottom));
  overflow-y: auto;
  display: flex;
  flex-direction: column;
  gap: 12px;
  padding: 4px 0 12px;
}
.message { display: flex; align-items: flex-start; gap: 8px; }
.message.mine { justify-content: flex-end; }
.message-main { max-width: 78%; min-width: 0; }
.message-main > small { display: block; margin: 0 0 4px 2px; color: var(--muted); font-size: 10px; }
.message-main time { display: block; margin-top: 3px; color: #8a949d; font-size: 9px; }
.message.mine time { text-align: right; }
.message-bubble { padding: 9px 11px; border-radius: 8px; background: #fff; border: 1px solid var(--line); font-size: 14px; line-height: 1.55; word-break: break-word; }
.message.mine .message-bubble { border-color: #8bc8c2; background: #dff3f0; }
.chat-image { display: block; width: min(220px, 100%); max-height: 260px; border-radius: 6px; object-fit: contain; }
.recalled { color: var(--muted); font-size: 12px; }
.system-message { align-self: center; max-width: 88%; padding: 4px 9px; border-radius: 10px; background: #e6eaed; color: var(--muted); font-size: 10px; text-align: center; }
.chat-composer { position: sticky; bottom: calc(58px + env(safe-area-inset-bottom)); display: grid; grid-template-columns: 1fr auto; gap: 8px; padding: 8px 0; background: var(--bg); }
.chat-composer textarea { min-height: 42px; max-height: 96px; padding: 10px; resize: none; }

.platform-binding {
  display: grid;
  gap: 4px;
  padding: 13px;
  border-left: 4px solid var(--blue);
  background: #fff;
}
.platform-binding > span, .platform-binding small { color: var(--muted); font-size: 11px; }
.platform-binding strong { font-size: 14px; word-break: break-word; }
.menu-list { border-top: 1px solid var(--line); background: #fff; }
.menu-row { width: 100%; min-height: 62px; display: flex; justify-content: space-between; align-items: center; gap: 10px; padding: 10px 2px; border-bottom: 1px solid var(--line); border-radius: 0; background: #fff; color: var(--text); text-align: left; }
.menu-row span { min-width: 0; }
.menu-row strong { display: block; font-size: 14px; }
.menu-row small { display: block; margin-top: 4px; color: var(--muted); font-size: 11px; word-break: break-word; }
.menu-row b { color: #8b959e; font-size: 24px; font-weight: 400; }

.promotion-body { display: grid; justify-items: center; gap: 12px; }
.promotion-body > img { width: 196px; height: 196px; border: 1px solid var(--line); border-radius: 6px; }
.promotion-body > p { width: 100%; margin: 0; color: var(--muted); font-size: 11px; line-height: 1.5; text-align: center; word-break: break-all; }
.promotion-stats { width: 196px; display: grid; grid-template-columns: repeat(2, 1fr); border: 1px solid var(--line); border-radius: 6px; }
.promotion-stats div { padding: 8px; text-align: center; }
.promotion-stats div + div { border-left: 1px solid var(--line); }
.promotion-stats strong, .promotion-stats span { display: block; }
.promotion-stats span { margin-top: 2px; color: var(--muted); font-size: 10px; }
.binding-tip { padding: 14px; background: #fff8e8; color: var(--amber); font-size: 13px; line-height: 1.6; }
.logout-button { width: 100%; background: transparent; color: var(--red); border: 1px solid #e2b7b4; }

.record-head { display: flex; justify-content: space-between; align-items: flex-start; gap: 8px; }
.record-head strong { min-width: 0; word-break: break-word; }
.record-values { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; margin: 10px 0 6px; }
.record-values span { color: var(--muted); font-size: 11px; }
.record-values b { display: block; margin-top: 3px; color: var(--text); font-size: 15px; word-break: break-word; }
.record-card > small { color: var(--muted); font-size: 11px; }

.team-tree { display: grid; gap: 8px; }
.team-node { margin-left: calc(var(--depth) * 14px); display: flex; justify-content: space-between; align-items: center; gap: 10px; padding: 11px; border-left: 3px solid var(--brand); background: #fff; }
.team-node > div { min-width: 0; }
.team-node strong, .team-node small { display: block; word-break: break-word; }
.team-node small { margin-top: 4px; color: var(--muted); font-size: 11px; }
.team-node > span { flex: 0 0 auto; color: var(--muted); font-size: 11px; }

.invite-page { justify-content: flex-start; background: #f4f7f7; }
.invite-brand { margin: -28px -24px 0; padding: calc(54px + env(safe-area-inset-top)) 24px 28px; background: #153b3a; color: #fff; }
.invite-brand .brand-mark { margin-bottom: 22px; background: #fff; color: var(--brand); }
.invite-brand p { margin: 0 0 8px; color: #aee0db; }
.invite-brand h1 { line-height: 1.35; }
.invite-brand > span:last-child { display: block; margin-top: 12px; color: #c8d7d6; font-size: 12px; }
.invite-form { padding: 4px 0; }
.text-button { align-self: center; min-height: 36px; background: transparent; color: var(--brand); }
.success-page, .error-page { align-items: center; justify-content: center; text-align: center; }
.success-page h1, .error-page h1 { margin: 0; font-size: 25px; }
.success-page p { margin: -12px 0 0; color: var(--muted); }
.success-mark { background: #dff2e8; color: var(--green); font-size: 25px; }

.empty-state, .loading-state { padding: 36px 14px; color: var(--muted); text-align: center; font-size: 13px; line-height: 1.6; }
.error-state { color: var(--red); }
.toast {
  position: fixed;
  z-index: 30;
  top: calc(14px + env(safe-area-inset-top));
  left: 50%;
  width: max-content;
  max-width: min(430px, calc(100vw - 28px));
  transform: translateX(-50%);
  padding: 10px 13px;
  border-radius: 6px;
  background: #18212b;
  color: #fff;
  font-size: 13px;
  line-height: 1.45;
  text-align: center;
  box-shadow: 0 8px 24px rgba(0, 0, 0, .2);
}

@media (max-width: 360px) {
  .content { padding-left: 11px; padding-right: 11px; }
  .dashboard-hero { margin-left: -11px; margin-right: -11px; }
  .metric strong { font-size: 18px; }
  .metric-strip { grid-template-columns: 1fr; }
  .metric-strip > div { border-right: 0; border-bottom: 1px solid var(--line); }
  .metric-strip > div:last-child { border-bottom: 0; }
  .alert-grid { grid-template-columns: repeat(2, 1fr); }
  .alert-grid div:nth-child(-n+2) { border-bottom: 1px solid #efd6c0; }
  .data-row .row-value { flex-basis: 92px; }
  .card-actions > button, .card-actions > a { min-width: 72px; padding-left: 8px; padding-right: 8px; }
  .ranking-row { grid-template-columns: 28px 32px minmax(0, 1fr); }
  .ranking-amount { grid-column: 3; grid-row: 2; min-width: 0; display: flex; align-items: baseline; justify-content: space-between; margin-top: -3px; text-align: left; }
  .ranking-amount strong { margin-top: 0; }
}

@media (min-width: 521px) {
  body { padding: 0 0 24px; }
  .tabs { bottom: 24px; }
}
