:root {
  --background: #f7f7f8;
  --foreground: #09090b;
  --card: #ffffff;
  --card-foreground: #09090b;
  --popover: #ffffff;
  --primary: #09090b;
  --primary-foreground: #fafafa;
  --secondary: #f4f4f5;
  --secondary-foreground: #18181b;
  --muted: #f4f4f5;
  --muted-foreground: #71717a;
  --accent: #f4f4f5;
  --accent-foreground: #18181b;
  --destructive: #b91c1c;
  --destructive-soft: #fef2f2;
  --success: #166534;
  --success-soft: #f0fdf4;
  --border: #e4e4e7;
  --input: #d4d4d8;
  --ring: rgba(24, 24, 27, 0.16);
  --sidebar: #09090b;
  --sidebar-muted: #a1a1aa;
  --radius: 10px;
  --shadow-sm: 0 1px 2px rgba(0, 0, 0, 0.04);
  --shadow-md: 0 10px 30px rgba(15, 15, 15, 0.08);
}

* {
  box-sizing: border-box;
}

html {
  background: var(--background);
}

body {
  margin: 0;
  min-height: 100vh;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.9), rgba(247, 247, 248, 0.95) 280px),
    var(--background);
  color: var(--foreground);
  font-family: -apple-system, BlinkMacSystemFont, "SF Pro Display", "SF Pro Text", "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", "Segoe UI", sans-serif;
  font-size: 14px;
  line-height: 1.5;
  letter-spacing: 0;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

a {
  color: inherit;
  text-decoration: none;
}

button,
input,
select,
textarea {
  font: inherit;
}

button {
  border: 0;
}

img {
  max-width: 100%;
}

::selection {
  background: #18181b;
  color: #ffffff;
}

.login-shell {
  min-height: 100vh;
  display: grid;
  place-items: center;
  padding: 24px;
  background: #09090b;
}

.login-panel {
  width: min(460px, 100%);
  background: var(--card);
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 18px;
  padding: 36px;
  box-shadow: 0 24px 80px rgba(0, 0, 0, 0.36);
}

.brand-mark {
  width: 132px;
  min-height: 62px;
  display: grid;
  place-items: center;
  background: var(--foreground);
  color: var(--primary-foreground);
  border-radius: 14px;
  font-weight: 800;
  font-size: 13px;
  line-height: 1.15;
  text-align: center;
  margin-bottom: 24px;
  padding: 12px;
  box-shadow: var(--shadow-sm);
}

.brand-logo {
  display: block;
  max-width: 180px;
  max-height: 62px;
  object-fit: contain;
  margin-bottom: 24px;
}

.login-panel h1,
.page-head h1 {
  margin: 0;
  color: var(--foreground);
  font-weight: 800;
  letter-spacing: 0;
}

.login-panel h1 {
  font-size: 34px;
  line-height: 1.15;
}

.login-panel p,
.eyebrow,
.timestamp,
.panel-head span,
.empty {
  color: var(--muted-foreground);
}

.login-panel p {
  margin: 10px 0 26px;
}

.login-panel button.primary {
  width: 100%;
  min-height: 52px;
  font-size: 16px;
}

.login-footer {
  display: grid;
  gap: 4px;
  margin-top: 18px;
  color: var(--muted-foreground);
  font-size: 12px;
  text-align: center;
}

.sidebar {
  position: fixed;
  inset: 0 auto 0 0;
  width: 264px;
  background: var(--sidebar);
  color: #ffffff;
  display: flex;
  flex-direction: column;
  border-right: 1px solid rgba(255, 255, 255, 0.08);
}

.system-title {
  padding: 24px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.sidebar-logo {
  display: block;
  max-width: 160px;
  max-height: 48px;
  object-fit: contain;
  margin-bottom: 14px;
  background: #ffffff;
  border-radius: 10px;
  padding: 7px;
}

.system-title strong,
.system-title span {
  display: block;
}

.system-title strong {
  font-size: 16px;
  font-weight: 700;
}

.system-title span {
  margin-top: 6px;
  color: var(--sidebar-muted);
  font-size: 12px;
}

nav {
  padding: 16px;
  display: grid;
  gap: 12px;
  overflow-y: auto;
  min-height: 0;
}

nav a,
.logout-form button {
  color: #e4e4e7;
  border: 1px solid transparent;
  border-radius: 9px;
  padding: 11px 12px;
  background: transparent;
  text-align: left;
  cursor: pointer;
  transition: background 0.16s ease, color 0.16s ease, border-color 0.16s ease;
}

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

.nav-group > span {
  padding: 0 12px 2px;
  color: #71717a;
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0;
}

.nav-group a {
  min-height: 39px;
}

.nav-group a:not(.active) {
  color: #c4c4cc;
}

.nav-group a::before {
  content: "";
  width: 4px;
  height: 4px;
  border-radius: 999px;
  background: currentColor;
  opacity: 0.46;
  display: inline-block;
  margin-right: 8px;
  vertical-align: middle;
}

.nav-group.open > span {
  color: #d4d4d8;
}

nav a.active {
  color: #ffffff;
  background: rgba(255, 255, 255, 0.12);
  border-color: rgba(255, 255, 255, 0.08);
}

nav a:hover,
.logout-form button:hover {
  color: #ffffff;
  background: rgba(255, 255, 255, 0.1);
}

.logout-form {
  margin-top: auto;
  padding: 16px;
}

.logout-form button {
  width: 100%;
}

.sidebar-contact {
  display: grid;
  gap: 4px;
  padding: 0 16px 16px;
  color: var(--sidebar-muted);
  font-size: 11px;
  line-height: 1.5;
}

.workspace {
  margin-left: 264px;
  padding: 30px;
}

.workspace-accountbar {
  min-height: 46px;
  margin-bottom: 18px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  padding: 8px 10px 8px 14px;
  background: rgba(255, 255, 255, 0.78);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: var(--shadow-sm);
  backdrop-filter: blur(14px);
}

.workspace-accountbar div {
  display: flex;
  align-items: baseline;
  gap: 8px;
  min-width: 0;
}

.workspace-accountbar span {
  color: var(--muted-foreground);
  font-size: 12px;
  font-weight: 700;
}

.workspace-accountbar strong {
  color: var(--foreground);
  font-size: 13px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.workspace-accountbar form {
  margin: 0;
  flex: 0 0 auto;
}

.workspace-accountbar button {
  min-height: 32px;
  padding: 0 12px;
  border: 1px solid var(--border);
  border-radius: 8px;
  background: var(--card);
  color: var(--destructive);
  font-weight: 700;
  cursor: pointer;
}

.workspace-accountbar button:hover {
  border-color: #fecaca;
  background: var(--destructive-soft);
}

.page-head,
.panel-head,
.portal-head {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 18px;
}

.page-head,
.portal-head {
  margin-bottom: 22px;
}

.page-head h1,
.portal-head h1 {
  font-size: 30px;
  line-height: 1.18;
}

.page-head > span {
  max-width: 460px;
  color: var(--muted-foreground);
  font-size: 13px;
  text-align: right;
}

.eyebrow {
  margin: 0 0 6px;
  text-transform: uppercase;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.06em;
}

.timestamp {
  font-size: 12px;
}

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

.metrics div,
.portal-metrics div,
.panel,
.flash {
  background: rgba(255, 255, 255, 0.92);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: var(--shadow-sm);
}

.metrics div,
.portal-metrics div {
  padding: 18px;
  transition: border-color 0.16s ease, box-shadow 0.16s ease, transform 0.16s ease;
}

.metrics div:hover,
.portal-metrics div:hover {
  border-color: #d4d4d8;
  box-shadow: var(--shadow-md);
  transform: translateY(-1px);
}

.metrics span,
.portal-metrics span {
  display: block;
  color: var(--muted-foreground);
  font-size: 12px;
  margin-bottom: 8px;
}

.metrics strong,
.portal-metrics strong {
  display: block;
  color: var(--foreground);
  font-size: 28px;
  font-weight: 800;
  line-height: 1.1;
}

.chart-panel {
  margin-bottom: 18px;
  overflow: hidden;
}

.chart-head {
  align-items: center;
  padding-bottom: 14px;
  border-bottom: 1px solid var(--border);
}

.chart-toggle {
  display: inline-flex;
  gap: 4px;
  padding: 4px;
  background: var(--secondary);
  border: 1px solid var(--border);
  border-radius: 9px;
}

.chart-toggle button {
  min-height: 30px;
  padding: 5px 10px;
  border-radius: 7px;
  box-shadow: none;
  background: transparent;
  color: var(--muted-foreground);
  font-size: 12px;
  font-weight: 700;
}

.chart-toggle button.active {
  background: var(--card);
  color: var(--foreground);
  border-color: var(--border);
  box-shadow: var(--shadow-sm);
}

.cashflow-chart {
  position: relative;
  padding-top: 10px;
}

.cashflow-chart svg {
  display: block;
  width: 100%;
  height: 260px;
}

.chart-grid {
  stroke: #e4e4e7;
  stroke-width: 1;
}

.chart-line {
  fill: none;
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-width: 1.35;
}

.chart-line-inbound {
  stroke: #09090b;
}

.chart-line-outbound {
  stroke: #a1a1aa;
}

.chart-label {
  fill: var(--muted-foreground);
  font-size: 10px;
}

.chart-legend {
  position: absolute;
  top: 12px;
  right: 2px;
  display: inline-flex;
  gap: 14px;
  color: var(--muted-foreground);
  font-size: 12px;
}

.chart-legend span {
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

.chart-legend i {
  width: 18px;
  height: 1px;
  display: inline-block;
}

.legend-inbound {
  background: #09090b;
}

.legend-outbound {
  background: #a1a1aa;
}

.chart-summary {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
  padding-top: 8px;
}

.chart-summary div {
  padding: 12px 14px;
  background: var(--secondary);
  border: 1px solid var(--border);
  border-radius: 9px;
}

.chart-summary span {
  display: block;
  margin-bottom: 5px;
  color: var(--muted-foreground);
  font-size: 12px;
}

.chart-summary strong {
  font-size: 17px;
  line-height: 1.25;
}

.store-balance-card {
  background: var(--foreground);
  color: #ffffff;
  border-radius: 16px;
  padding: 24px;
  margin-bottom: 18px;
  box-shadow: 0 18px 48px rgba(9, 9, 11, 0.22);
}

.store-balance-card span,
.store-balance-card small {
  display: block;
  color: #d4d4d8;
}

.store-balance-card strong {
  display: block;
  font-size: 36px;
  font-weight: 800;
  margin: 8px 0;
  letter-spacing: 0;
}

.panel {
  padding: 20px;
  margin-bottom: 18px;
}

.sub-panel {
  margin-top: 16px;
  padding: 16px;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: #fafafa;
}

.panel-head {
  margin-bottom: 16px;
}

.panel-head h2 {
  margin: 0;
  font-size: 18px;
  line-height: 1.3;
}

.alert-panel {
  border-color: #fecaca;
  background: var(--destructive-soft);
}

.review-reason-box {
  margin: 14px 0 18px;
  padding: 14px 16px;
  border: 1px solid #fecaca;
  border-radius: var(--radius-sm);
  background: #fff;
  color: var(--destructive);
}

.review-reason-box strong {
  display: block;
  margin-bottom: 6px;
  font-size: 13px;
}

.review-reason-box p,
.review-reason {
  margin: 0;
  line-height: 1.7;
  white-space: normal;
}

.form-note {
  margin: 10px 0 0;
  color: var(--muted-foreground);
  font-size: 12px;
  line-height: 1.6;
}

.button-link {
  min-height: 36px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 7px 12px;
  background: #ffffff;
  color: var(--foreground);
  font-size: 12px;
  font-weight: 700;
  box-shadow: var(--shadow-sm);
}

.account-information-tool {
  overflow: hidden;
}

.account-information-picker {
  max-width: 560px;
  margin-bottom: 14px;
}

.account-information-picker label {
  display: grid;
  gap: 7px;
  color: var(--muted-foreground);
  font-size: 12px;
  font-weight: 700;
}

.account-information-picker select {
  min-height: 44px;
  width: 100%;
  border: 1px solid var(--input);
  border-radius: 8px;
  padding: 0 12px;
  background: #ffffff;
  color: var(--foreground);
}

.account-information-actions {
  justify-content: flex-end;
  margin-bottom: 14px;
}

.account-information-empty {
  padding: 48px 18px;
  border: 1px dashed var(--border);
  border-radius: 8px;
  color: var(--muted-foreground);
  text-align: center;
}

.account-information-document {
  position: relative;
  width: min(100%, 820px);
  min-height: 980px;
  margin: 0 auto;
  padding: 56px 64px;
  overflow: hidden;
  border: 1px solid #d4d4d8;
  border-radius: 4px;
  background: #ffffff;
  box-shadow: 0 14px 35px rgba(15, 23, 42, 0.08);
}

.account-information-document::before {
  content: "";
  position: absolute;
  inset: -1px -1px auto;
  height: 7px;
  background: #18181b;
}

.account-document-mark {
  font-size: 18px;
  font-weight: 800;
}

.account-information-document header {
  margin: 92px 0 58px;
  text-align: center;
}

.account-information-document header p {
  margin: 0 0 6px;
  color: var(--muted-foreground);
  font-size: 13px;
}

.account-information-document header h2 {
  margin: 0;
  font-size: 38px;
  line-height: 1.25;
}

.account-information-document header span {
  display: block;
  margin-top: 8px;
  color: #a1a1aa;
  font: 12px/1.4 Arial, sans-serif;
  letter-spacing: 0;
}

.account-information-document dl {
  margin: 0;
  border-top: 2px solid #18181b;
}

.account-information-document dl div {
  display: grid;
  grid-template-columns: 150px minmax(0, 1fr);
  gap: 28px;
  min-height: 86px;
  align-items: center;
  border-bottom: 1px solid var(--border);
}

.account-information-document dt {
  color: var(--muted-foreground);
  font-weight: 700;
}

.account-information-document dd {
  margin: 0;
  overflow-wrap: anywhere;
  font-size: 17px;
  font-weight: 700;
}

.account-information-document footer {
  margin-top: 58px;
  padding: 22px;
  border: 1px solid var(--border);
  border-radius: 4px;
  background: #fafafa;
  color: #52525b;
  font-size: 12px;
}

.account-information-document footer p {
  margin: 0 0 10px;
  line-height: 1.7;
}

.account-information-document footer span {
  color: var(--muted-foreground);
}

.grid {
  display: grid;
  gap: 14px;
}

.grid.two {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.grid.three {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.stack {
  display: grid;
  gap: 14px;
}

.form-grid,
.channel-config-form {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
}

.wide,
.full,
.channel-config-form .full {
  grid-column: 1 / -1;
}

label {
  display: grid;
  gap: 7px;
  color: var(--muted-foreground);
  font-size: 12px;
  font-weight: 600;
}

input,
select,
textarea {
  width: 100%;
  min-height: 42px;
  border: 1px solid var(--input);
  border-radius: 9px;
  background: #ffffff;
  color: var(--foreground);
  padding: 9px 11px;
  outline: none;
  transition: border-color 0.16s ease, box-shadow 0.16s ease, background 0.16s ease;
}

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

input::placeholder,
textarea::placeholder {
  color: #a1a1aa;
}

input:focus,
select:focus,
textarea:focus {
  border-color: var(--foreground);
  box-shadow: 0 0 0 3px var(--ring);
}

input[readonly],
input:disabled,
select:disabled,
textarea:disabled {
  background: var(--secondary);
  color: var(--muted-foreground);
  cursor: not-allowed;
}

.check-line {
  display: flex;
  align-items: center;
  gap: 10px;
  color: var(--foreground);
  min-height: 42px;
}

.check-line input {
  width: 16px;
  min-height: 16px;
  accent-color: var(--foreground);
}

button,
.primary,
.danger-button,
.table-actions a,
.actions-row a {
  min-height: 40px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  border-radius: 9px;
  border: 1px solid var(--border);
  padding: 9px 14px;
  background: #ffffff;
  color: var(--foreground);
  font-weight: 700;
  cursor: pointer;
  box-shadow: var(--shadow-sm);
  transition: background 0.16s ease, border-color 0.16s ease, box-shadow 0.16s ease, transform 0.16s ease;
}

button:hover,
.table-actions a:hover,
.actions-row a:hover {
  background: var(--accent);
  border-color: #d4d4d8;
}

button:active,
.primary:active,
.danger-button:active,
.table-actions a:active,
.actions-row a:active {
  transform: translateY(1px);
}

.primary {
  background: var(--primary);
  border-color: var(--primary);
  color: var(--primary-foreground);
}

.primary:hover {
  background: #27272a;
  border-color: #27272a;
}

.danger-button {
  background: var(--destructive);
  border-color: var(--destructive);
  color: #ffffff;
}

.danger-button:hover {
  background: #991b1b;
  border-color: #991b1b;
}

.actions-row,
.table-actions {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px;
}

.inline-form {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin: 0;
}

.merchant-search-form {
  display: flex;
  width: 100%;
  flex-wrap: wrap;
  margin-bottom: 16px;
}

.merchant-search-form input[type="search"] {
  flex: 1 1 320px;
  min-width: 0;
  max-width: 560px;
}

.flash {
  padding: 12px 14px;
  margin-bottom: 14px;
  color: var(--foreground);
}

.flash.success {
  color: var(--success);
  border-color: #bbf7d0;
  background: var(--success-soft);
}

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

.muted-text {
  color: var(--muted-foreground);
  font-size: 12px;
}

.flash.danger {
  border-color: #fecaca;
  background: var(--destructive-soft);
}

.table-wrap {
  width: 100%;
  overflow-x: auto;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: #ffffff;
}

table {
  width: 100%;
  min-width: 760px;
  border-collapse: separate;
  border-spacing: 0;
  font-size: 13px;
}

th,
td {
  padding: 12px 14px;
  border-bottom: 1px solid var(--border);
  text-align: left;
  vertical-align: top;
}

th {
  color: var(--muted-foreground);
  background: #fafafa;
  font-size: 12px;
  font-weight: 700;
  white-space: nowrap;
}

td {
  color: #27272a;
}

tbody tr {
  transition: background 0.16s ease;
}

tbody tr:hover {
  background: #fafafa;
}

tr:last-child td {
  border-bottom: 0;
}

.compact-table {
  min-width: 520px;
}

.channel-binding-info {
  display: grid;
  gap: 4px;
  min-width: 280px;
  line-height: 1.45;
}

.channel-binding-info strong {
  color: var(--foreground);
  font-size: 13px;
}

.channel-binding-info span {
  color: var(--muted-foreground);
  font-size: 12px;
  white-space: normal;
}

.table-logo {
  max-width: 84px;
  max-height: 34px;
  object-fit: contain;
  background: #ffffff;
}

.tag {
  display: inline-flex;
  align-items: center;
  min-height: 24px;
  border-radius: 999px;
  border: 1px solid var(--border);
  background: var(--secondary);
  color: #3f3f46;
  padding: 3px 9px;
  font-size: 12px;
  font-weight: 700;
  white-space: nowrap;
}

.scene-archive {
  display: grid;
  gap: 8px;
  min-width: 180px;
  max-width: 280px;
}

.scene-archive span {
  color: var(--foreground);
  line-height: 1.5;
  white-space: normal;
}

.scene-images {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.scene-images a {
  width: 54px;
  height: 54px;
  display: block;
  overflow: hidden;
  border: 1px solid var(--border);
  border-radius: 8px;
  background: var(--secondary);
}

.scene-images img {
  width: 100%;
  height: 100%;
  display: block;
  object-fit: cover;
}

.raw-box,
pre {
  overflow: auto;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: #0a0a0a;
  color: #f4f4f5;
  padding: 14px;
  font-family: "SFMono-Regular", Consolas, "Liberation Mono", monospace;
  font-size: 12px;
  line-height: 1.6;
}

.detail-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px 16px;
}

.detail-grid div {
  border-bottom: 1px solid var(--border);
  padding-bottom: 9px;
}

.empty {
  padding: 22px;
  text-align: center;
}

details {
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: #ffffff;
  padding: 12px 14px;
}

summary {
  cursor: pointer;
  font-weight: 700;
}

::-webkit-scrollbar {
  width: 10px;
  height: 10px;
}

::-webkit-scrollbar-thumb {
  background: #d4d4d8;
  border: 2px solid transparent;
  border-radius: 999px;
  background-clip: content-box;
}

::-webkit-scrollbar-track {
  background: transparent;
}

.store-mobile {
  background: #f4f4f5;
}

.store-mobile .workspace {
  margin-left: 0;
  padding: 18px;
  padding-bottom: 120px;
}

.store-mobile .sidebar {
  inset: auto 12px 12px 12px;
  width: auto;
  min-height: 72px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.94);
  color: var(--foreground);
  display: block;
  box-shadow: 0 12px 36px rgba(0, 0, 0, 0.12);
  backdrop-filter: blur(18px);
}

.store-mobile .system-title,
.store-mobile .logout-form,
.store-mobile .sidebar-contact {
  display: none;
}

.store-mobile nav {
  height: 72px;
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  align-items: center;
  padding: 8px;
  gap: 4px;
}

.store-mobile nav a {
  min-height: 54px;
  display: grid;
  place-items: center;
  color: var(--foreground);
  border-radius: 999px;
  padding: 8px;
  text-align: center;
  font-weight: 700;
}

.store-mobile nav a.active,
.store-mobile nav a:hover {
  background: #e4e4e7;
  color: var(--foreground);
  border-color: transparent;
}

.store-mobile .page-head,
.store-mobile .portal-head {
  display: block;
  margin: 20px 0 18px;
}

.store-mobile .page-head h1,
.store-mobile .portal-head h1 {
  font-size: 34px;
}

.store-mobile .metrics,
.store-mobile .portal-metrics,
.store-mobile .grid.two,
.store-mobile .grid.three,
.store-mobile .form-grid,
.store-mobile .channel-config-form,
.store-mobile .detail-grid {
  grid-template-columns: 1fr;
}

.store-mobile .panel {
  border-radius: 18px;
  padding: 18px;
}

.store-mobile .chart-head {
  display: grid;
  gap: 12px;
}

.store-mobile .chart-summary {
  grid-template-columns: 1fr;
}

.store-mobile .table-wrap {
  border-radius: 18px;
}

@media (max-width: 1100px) {
  .metrics,
  .portal-metrics {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .grid.three {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 760px) {
  .sidebar {
    position: static;
    width: auto;
  }

  .workspace {
    margin-left: 0;
    padding: 18px;
  }

  nav {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .nav-group {
    display: contents;
  }

  .nav-group > span {
    display: none;
  }

  .page-head,
  .panel-head,
  .portal-head {
    display: block;
  }

  .timestamp,
  .panel-head span {
    display: block;
    margin-top: 8px;
  }

  .metrics,
  .portal-metrics,
  .grid.two,
  .grid.three,
  .form-grid,
  .channel-config-form,
  .detail-grid {
    grid-template-columns: 1fr;
  }

  .chart-head {
    display: grid;
    gap: 12px;
  }

  .chart-toggle {
    width: 100%;
  }

  .chart-toggle button {
    flex: 1;
  }

  .merchant-search-form input[type="search"] {
    flex-basis: 100%;
    max-width: none;
  }

  .cashflow-chart svg {
    height: 220px;
  }

  .account-information-actions {
    display: grid;
    grid-template-columns: 1fr;
  }

  .account-information-document {
    min-height: 0;
    padding: 34px 24px;
  }

  .account-information-document header {
    margin: 54px 0 36px;
  }

  .account-information-document header h2 {
    font-size: 30px;
  }

  .account-information-document dl div {
    grid-template-columns: 1fr;
    gap: 7px;
    min-height: 92px;
    align-content: center;
  }

  .account-information-document footer {
    margin-top: 36px;
  }

  .chart-legend {
    position: static;
    margin: 4px 0 0 30px;
  }

  .chart-summary {
    grid-template-columns: 1fr;
  }

  .login-panel {
    padding: 28px;
  }
}
