:root {
  --bg: #eef3f6;
  --panel: #ffffff;
  --ink: #101828;
  --muted: #667085;
  --line: #d9e2e7;
  --primary: #0f766e;
  --blue: #2563eb;
  --cyan: #0891b2;
  --amber: #b7791f;
  --red: #be123c;
  --green: #15803d;
  --sidebar: #101828;
  --sidebar-soft: #17233a;
  --shadow: 0 14px 36px rgba(16, 24, 40, 0.10);
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  background:
    linear-gradient(135deg, rgba(15, 118, 110, 0.06) 0 25%, transparent 25% 50%, rgba(37, 99, 235, 0.05) 50% 75%, transparent 75%) 0 0 / 42px 42px,
    linear-gradient(180deg, #f8fafc 0%, var(--bg) 58%, #e7eef2 100%);
  color: var(--ink);
  font-family: Inter, "Microsoft YaHei", system-ui, -apple-system, BlinkMacSystemFont, sans-serif;
}

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

button {
  cursor: pointer;
}

.hidden {
  display: none !important;
}

.auth {
  min-height: 100vh;
  display: grid;
  place-items: center;
  padding: 24px;
  background:
    linear-gradient(135deg, rgba(15, 118, 110, 0.08) 0 25%, transparent 25% 50%, rgba(37, 99, 235, 0.07) 50% 75%, transparent 75%) 0 0 / 46px 46px,
    #f4f7fa;
}

.auth-panel {
  width: min(452px, 100%);
  padding: 28px;
  border: 1px solid rgba(217, 226, 231, 0.88);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.88);
  box-shadow: 0 24px 70px rgba(16, 24, 40, 0.16);
  backdrop-filter: blur(16px);
}

.brand-row,
.sidebar-brand,
.topbar,
.row,
.actions {
  display: flex;
  align-items: center;
}

.brand-row {
  gap: 14px;
  margin-bottom: 24px;
}

.brand-mark {
  width: 48px;
  height: 48px;
  display: grid;
  place-items: center;
  border-radius: 8px;
  background: linear-gradient(135deg, var(--primary), var(--blue));
  color: #fff;
  font-weight: 900;
  font-size: 24px;
  box-shadow: 0 12px 24px rgba(15, 118, 110, 0.24);
}

h1,
h2,
h3,
p {
  margin: 0;
}

h1 {
  font-size: 24px;
}

h2 {
  font-size: 26px;
}

h3 {
  margin-bottom: 14px;
  font-size: 17px;
}

.brand-row p,
.muted,
.eyebrow {
  color: var(--muted);
}

.segment {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
  margin-bottom: 16px;
  padding: 6px;
  border-radius: 8px;
  background: #e8eef2;
}

.segment.single {
  grid-template-columns: 1fr;
}

.segment button,
.ghost,
.nav,
.primary,
.danger,
.success,
.consume,
.plain {
  min-height: 38px;
  border: 1px solid transparent;
  border-radius: 6px;
  padding: 0 14px;
  font-weight: 800;
}

.segment button,
.ghost,
.plain {
  background: #f1f5f9;
  color: #334155;
}

.segment button.active,
.primary {
  background: linear-gradient(135deg, var(--primary), var(--blue));
  color: #fff;
  box-shadow: 0 10px 22px rgba(15, 118, 110, 0.16);
}

.danger {
  background: #ffe4e6;
  color: var(--red);
}

.success {
  background: #dcfce7;
  color: var(--green);
}

input,
select,
textarea {
  width: 100%;
  min-height: 40px;
  margin-bottom: 10px;
  border: 1px solid var(--line);
  border-radius: 6px;
  padding: 9px 11px;
  background: #fff;
  color: var(--ink);
}

input:focus,
select:focus,
textarea:focus {
  outline: 2px solid rgba(15, 118, 110, 0.16);
  border-color: rgba(15, 118, 110, 0.45);
}

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

.layout {
  min-height: 100vh;
  display: grid;
  grid-template-columns: 272px 1fr;
}

.sidebar {
  position: sticky;
  top: 0;
  height: 100vh;
  padding: 20px;
  color: #dbeafe;
  background:
    linear-gradient(180deg, rgba(23, 35, 58, 0.98), rgba(16, 24, 40, 1)),
    var(--sidebar);
  box-shadow: 18px 0 44px rgba(16, 24, 40, 0.18);
}

.sidebar-brand {
  gap: 12px;
  margin-bottom: 24px;
  padding-bottom: 18px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.sidebar-brand span {
  display: block;
  margin-top: 3px;
  color: #98a9c2;
  font-size: 12px;
}

nav {
  display: grid;
  gap: 8px;
}

.nav {
  width: 100%;
  display: flex;
  align-items: center;
  gap: 12px;
  text-align: left;
  background: transparent;
  color: #aab9ce;
  border-color: transparent;
  transition: transform 0.18s ease, background 0.18s ease, color 0.18s ease;
}

.nav span {
  width: 28px;
  height: 28px;
  display: grid;
  place-items: center;
  border-radius: 6px;
  color: #d9ecff;
  background: rgba(255, 255, 255, 0.08);
  font-size: 13px;
}

.nav.active,
.nav:hover {
  background: rgba(255, 255, 255, 0.10);
  color: #ffffff;
  transform: translateX(3px);
}

.nav.active span,
.nav:hover span {
  background: linear-gradient(135deg, var(--primary), var(--blue));
}

.nav-badge {
  min-width: 20px;
  height: 20px;
  margin-left: auto;
  padding: 0 6px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 10px;
  background: #ef4444;
  color: #fff;
  font-size: 11px;
  line-height: 1;
  box-shadow: 0 4px 10px rgba(239, 68, 68, 0.3);
}

.sidebar-account-actions {
  position: absolute;
  left: 20px;
  right: 20px;
  bottom: 20px;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
}

.sidebar-account-actions button {
  white-space: nowrap;
}

#logoutBtn {
  border-color: #dc2626;
  background: #dc2626;
  color: #ffffff;
}

#logoutBtn:hover {
  border-color: #b91c1c;
  background: #b91c1c;
}

.main {
  min-width: 0;
  padding: 24px 28px;
}

.topbar {
  position: sticky;
  top: 0;
  z-index: 5;
  justify-content: space-between;
  margin-bottom: 22px;
  padding: 16px 18px;
  border: 1px solid rgba(217, 226, 231, 0.86);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.86);
  box-shadow: var(--shadow);
  backdrop-filter: blur(16px);
}

.eyebrow {
  margin-bottom: 4px;
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 0;
}

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

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

.dashboard-grid {
  grid-template-columns: minmax(0, 1.4fr) minmax(340px, 0.8fr);
}

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

.card {
  position: relative;
  overflow: hidden;
  padding: 18px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--panel);
  box-shadow: 0 12px 30px rgba(16, 24, 40, 0.07);
}

.card::before {
  content: "";
  position: absolute;
  inset: 0 0 auto 0;
  height: 3px;
  background: linear-gradient(90deg, var(--primary), var(--cyan), var(--blue));
  opacity: 0;
  transition: opacity 0.2s ease;
}

.card:hover::before {
  opacity: 1;
}

.stat-card {
  min-height: 138px;
}

.stat-value {
  margin-top: 10px;
  font-size: 32px;
  font-weight: 900;
  letter-spacing: 0;
}

.stat-card .trend {
  margin-top: 12px;
  color: var(--green);
  font-size: 13px;
  font-weight: 800;
}

.stat-card .meter {
  height: 8px;
  margin-top: 18px;
  overflow: hidden;
  border-radius: 999px;
  background: #e8eef1;
}

.stat-card .meter span {
  display: block;
  height: 100%;
  border-radius: inherit;
  background: linear-gradient(90deg, var(--primary), var(--blue));
}

.table-wrap {
  overflow-x: auto;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  box-shadow: 0 10px 24px rgba(16, 24, 40, 0.05);
  scrollbar-width: thin;
  scrollbar-color: #94a3b8 #eef2f7;
}

.table-wrap::-webkit-scrollbar {
  height: 8px;
}

.table-wrap::-webkit-scrollbar-track {
  background: #eef2f7;
  border-radius: 999px;
}

.table-wrap::-webkit-scrollbar-thumb {
  border-radius: 999px;
  background: linear-gradient(90deg, var(--primary), var(--blue));
}

.card .table-wrap table {
  min-width: 620px;
}

table {
  width: 100%;
  border-collapse: collapse;
  min-width: 1040px;
}

th,
td {
  padding: 13px 12px;
  border-bottom: 1px solid #edf2f4;
  text-align: left;
  vertical-align: top;
  font-size: 14px;
}

th {
  position: sticky;
  top: 0;
  z-index: 1;
  background: #f8fafc;
  color: #475569;
  font-size: 13px;
  font-weight: 900;
}

tbody tr {
  transition: background 0.16s ease;
}

tbody tr:hover {
  background: #f8fbfc;
}

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

.actions {
  gap: 8px;
  flex-wrap: wrap;
}

.link-btn {
  border: 0;
  padding: 0;
  background: transparent;
  color: #0f172a;
  font-weight: 900;
  cursor: pointer;
}

.link-btn:hover {
  color: var(--primary);
  text-decoration: underline;
}

.account-name-link {
  font-size: 15px;
  font-weight: 900;
}

.inline-input {
  width: 98px;
  margin: 0;
}

.wide-input {
  width: 184px;
  margin: 0;
}

.upload-user-cell {
  min-width: 260px;
}

.upload-tags,
.upload-details {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 6px 10px;
  margin-top: 7px;
}

.upload-tags .tag {
  margin-top: 0;
}

.upload-details {
  color: var(--muted);
  font-size: 12px;
}

.upload-remark {
  margin-top: 8px;
  line-height: 1.5;
  overflow-wrap: anywhere;
}

.order-cell {
  min-width: 230px;
}

.order-rank {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 24px minmax(0, 1fr);
  gap: 6px;
  align-items: center;
  margin: 9px 0;
  padding: 8px;
  border: 1px solid #d8eee8;
  border-radius: 8px;
  background: #f4fbfa;
}

.order-rank span {
  color: #10243f;
  font-size: 12px;
  font-weight: 900;
  line-height: 1.35;
}

.order-rank b {
  display: grid;
  place-items: center;
  width: 24px;
  height: 24px;
  border-radius: 999px;
  color: #ffffff;
  background: linear-gradient(135deg, var(--primary), var(--blue));
}

.money-grid {
  display: grid;
  gap: 6px;
  min-width: 128px;
}

.money-grid span {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  padding: 7px 8px;
  border-radius: 6px;
  background: #f8fafc;
  color: var(--muted);
  font-size: 12px;
}

.order-query-card {
  margin-bottom: 16px;
}

.order-page-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 16px;
}

.order-page-head h3,
.order-page-head p {
  margin: 0;
}

.order-page-head p {
  margin-top: 5px;
}

.order-query-grid {
  display: grid;
  grid-template-columns: repeat(5, minmax(150px, 1fr));
  gap: 12px;
}

.order-query-actions {
  display: flex;
  justify-content: flex-end;
  margin-top: 14px;
}

.order-table-wrap {
  max-height: calc(100vh - 330px);
  min-height: 260px;
  overflow: auto;
}

.order-table {
  min-width: 2250px;
}

.order-table th,
.order-table td {
  white-space: nowrap;
}

.order-table th:first-child,
.order-table .order-operation-cell {
  position: sticky;
  left: 0;
  z-index: 2;
  min-width: 250px;
  width: 250px;
  background: #ffffff;
  box-shadow: 8px 0 14px rgba(15, 23, 42, 0.07);
}

.order-table th:first-child {
  z-index: 3;
  background: #f8fafc;
}

.order-actions {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 7px;
}

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

.order-complete-complaint {
  grid-column: 1 / -1;
}

.order-actions button {
  min-height: 30px;
  padding: 0 9px;
  font-size: 12px;
}

.order-actions .order-copy-button {
  grid-column: span 2;
  white-space: nowrap;
}

.transfer-deduction-list {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
}

.transfer-section {
  display: grid;
  gap: 8px;
  margin-top: 16px;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #f8fafc;
}

.transfer-new-hitters {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
}

.order-complaint-cell {
  min-width: 220px;
  max-width: 320px;
  white-space: normal !important;
  overflow-wrap: anywhere;
}

.order-upload-cell {
  min-width: 150px;
}

.order-upload-list {
  display: grid;
  gap: 5px;
}

.order-upload-group {
  display: flex;
  align-items: center;
  gap: 4px;
}

.order-upload-group > span {
  width: 44px;
  overflow: hidden;
  color: var(--muted);
  font-size: 12px;
  text-overflow: ellipsis;
}

.order-upload-images {
  display: flex;
  gap: 4px;
}

.order-upload-button {
  width: 30px;
  height: 30px;
  min-width: 30px;
  min-height: 30px;
  max-width: 30px;
  max-height: 30px;
}

.order-upload-preview {
  display: block;
  width: 30px;
  height: 30px;
  min-width: 30px;
  min-height: 30px;
  max-width: 30px;
  max-height: 30px;
  border-radius: 5px;
  object-fit: cover;
}

.order-title-link {
  font-size: 14px;
}

.modal-panel.order-history-modal {
  width: min(1300px, 100%);
}

.order-history-detail {
  min-width: 520px;
  white-space: normal;
  line-height: 1.6;
}

.order-hitter-list {
  display: grid;
  gap: 5px;
  min-width: 90px;
}

.order-hitter-list span {
  display: flex;
  align-items: center;
  gap: 7px;
  white-space: nowrap;
}

.order-hitter-list strong {
  color: #0f172a;
}

.order-hitter-list em {
  color: #15803d;
  font-style: normal;
  font-weight: 800;
}

.order-hitter-list .hitter-upload-tag { margin: 0; background: #dcfce7; color: #15803d; }

.settle-hitter-block { padding: 14px; border: 1px solid #e2e8f0; border-radius: 12px; background: #f8fafc; }
.settle-upload-title { margin: 12px 0 8px; color: #64748b; font-size: 13px; font-weight: 800; }
.settle-upload-images { display: flex; flex-wrap: wrap; gap: 10px; min-height: 34px; align-items: center; }
.settle-upload-images img { width: 112px; height: 112px; border-radius: 10px; object-fit: cover; cursor: zoom-in; border: 1px solid #cbd5e1; }
.product-query-grid {
  display: grid;
  grid-template-columns: minmax(240px, 1fr) minmax(180px, 260px) auto;
  align-items: end;
  gap: 12px;
}
.product-query-grid .query-actions { display: flex; gap: 10px; align-items: center; }
.product-query-grid .query-actions button { white-space: nowrap; }

.history-detail-list {
  display: inline-flex;
  flex-wrap: wrap;
  gap: 8px 14px;
  margin-left: 5px;
  vertical-align: middle;
}

.history-detail-item {
  display: inline-flex;
  align-items: center;
  gap: 7px;
}

.history-detail-item .tag {
  margin-top: 0;
}

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

.tag {
  display: inline-flex;
  align-items: center;
  margin-top: 8px;
  min-height: 26px;
  padding: 4px 10px;
  border-radius: 999px;
  background: #eef6ff;
  color: #155e75;
  font-size: 12px;
  font-weight: 900;
}

.status {
  display: inline-flex;
  align-items: center;
  min-height: 28px;
  padding: 4px 10px;
  border-radius: 999px;
  background: #e0f2fe;
  color: #0369a1;
  font-size: 12px;
  font-weight: 900;
  white-space: nowrap;
}

.status.pending,
.status.open {
  background: #fef3c7;
  color: var(--amber);
}

.status.approved,
.status.available,
.status.done,
.status.renewed {
  background: #dcfce7;
  color: var(--green);
}

.status.rejected,
.status.disabled,
.status.canceled,
.status.not-renewed {
  background: #ffe4e6;
  color: var(--red);
}

.renewal-actions {
  margin-top: 8px;
  flex-wrap: nowrap;
}

.renewal-actions button {
  min-height: 30px;
  padding: 0 9px;
  font-size: 12px;
}

.user-filter {
  display: grid;
  grid-template-columns: minmax(220px, 1fr) minmax(180px, 240px);
  gap: 12px;
  margin-bottom: 16px;
}

.account-filter {
  display: grid;
  grid-template-columns: minmax(220px, 1fr) minmax(170px, 220px) minmax(170px, 220px) auto;
  gap: 12px;
  align-items: end;
  margin-bottom: 16px;
}

.list-toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 16px;
}

.list-toolbar h3,
.list-toolbar p {
  margin: 0;
}

.list-toolbar p {
  margin-top: 5px;
}

.history-query {
  display: flex;
  flex-wrap: wrap;
  align-items: end;
  gap: 10px;
  margin-bottom: 16px;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #f8fafc;
}

.renewal-room-field {
  display: grid;
  gap: 8px;
  color: var(--muted);
  font-weight: 800;
}

.modal-actions {
  display: flex;
  justify-content: flex-end;
  gap: 10px;
  margin-top: 18px;
}

.status.working,
.status.taking,
.status.pending-ship,
.status.pending-withdraw {
  background: #e0e7ff;
  color: #3730a3;
}

.status.rented {
  background: #ffedd5;
  color: #c2410c;
}

.status.dispatched { background: #dbeafe; color: #1d4ed8; }
.status.transferred { background: #fef3c7; color: #b45309; }
.status.returned { background: #ffe4e6; color: #be123c; }
.status.stored { background: #f3e8ff; color: #7e22ce; }
.status.completed { background: #ccfbf1; color: #0f766e; }
.status.settled { background: #e0e7ff; color: #4338ca; }
.status.received { background: #dcfce7; color: #15803d; }

.consume {
  background: #ffedd5;
  color: #c2410c;
}

.preview {
  width: 92px;
  height: 92px;
  object-fit: cover;
  border-radius: 6px;
  border: 1px solid var(--line);
}

.preview-grid {
  display: grid;
  grid-template-columns: repeat(3, 72px);
  gap: 8px;
}

.mini-grid {
  margin-top: 6px;
  grid-template-columns: repeat(2, 58px);
}

.mini-grid .preview {
  width: 58px;
  height: 58px;
}

.preview-grid .preview {
  width: 72px;
  height: 72px;
}

.preview-grid.mini-grid .preview {
  width: 58px;
  height: 58px;
}

.type-list {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 12px;
}

.preview-button {
  display: block;
  border: 0;
  padding: 0;
  border-radius: 6px;
  background: transparent;
  cursor: zoom-in;
}

.preview-button:hover .preview {
  border-color: rgba(15, 118, 110, 0.56);
  box-shadow: 0 10px 24px rgba(16, 24, 40, 0.16);
}

.plus {
  color: var(--green);
  font-weight: 900;
}

.minus {
  color: var(--red);
  font-weight: 900;
}

.modal-mask {
  position: fixed;
  inset: 0;
  z-index: 50;
  display: grid;
  place-items: center;
  padding: 28px;
  background: rgba(15, 23, 42, 0.58);
  backdrop-filter: blur(8px);
}

.image-modal {
  z-index: 60;
}

.modal-panel {
  width: min(960px, 100%);
  max-height: min(760px, calc(100vh - 56px));
  overflow: hidden;
  border: 1px solid rgba(217, 226, 231, 0.9);
  border-radius: 8px;
  background: #ffffff;
  box-shadow: 0 28px 80px rgba(15, 23, 42, 0.28);
}

.modal-panel.point-log-modal {
  width: min(1200px, 100%);
}

.modal-panel.upload-history-modal {
  width: min(1400px, 100%);
}

.modal-panel.account-edit-modal {
  width: min(1100px, 100%);
}

.modal-panel.account-history-modal {
  width: min(1400px, 100%);
}

.modal-panel.order-edit-modal {
  width: min(1200px, 100%);
}

.order-complaint-field {
  grid-column: span 2;
}

.order-hitters-field {
  grid-column: 1 / -1;
  display: grid;
  gap: 7px;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #f8fafc;
}

.order-hitters-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
}

.hitter-picker-field {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 8px;
}

.hitter-and-wage-field {
  display: grid;
  gap: 12px;
  padding: 12px;
  border: 1px solid #dbe4ea;
  border-radius: 8px;
  background: #ffffff;
}

.hitter-picker-modal {
  z-index: 60;
}

.hitter-picker-panel {
  width: min(820px, 100%);
  display: flex;
  flex-direction: column;
}

.hitter-picker-body {
  min-height: 0;
  padding-bottom: 28px;
}

.hitter-picker-filter {
  position: sticky;
  top: -16px;
  z-index: 2;
  display: grid;
  grid-template-columns: minmax(220px, 1fr) auto;
  align-items: center;
  gap: 12px;
  margin: -16px -16px 12px;
  padding: 14px 16px 4px;
  border-bottom: 1px solid var(--line);
  background: #ffffff;
}

.hitter-picker-filter input {
  margin-bottom: 10px;
}

.modal-panel.redemption-history-modal {
  width: min(1200px, 100%);
}

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

.account-history-filter {
  display: flex;
  align-items: end;
  gap: 10px;
  margin-bottom: 16px;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #f8fafc;
}

.modal-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 14px 16px;
  border-bottom: 1px solid var(--line);
  background: #f8fafc;
}

.modal-head h3 {
  margin: 0;
}

.modal-body {
  max-height: calc(100vh - 150px);
  overflow: auto;
  padding: 16px;
}

.point-log-filter {
  display: flex;
  align-items: end;
  gap: 10px;
  margin-bottom: 16px;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #f8fafc;
}

.point-log-filter label {
  display: grid;
  gap: 6px;
  color: var(--muted);
  font-size: 13px;
}

.image-viewer {
  display: grid;
  place-items: center;
  min-height: 320px;
  background: #0f172a;
  border-radius: 8px;
}

.image-viewer img {
  max-width: 100%;
  max-height: calc(100vh - 190px);
  border-radius: 6px;
  object-fit: contain;
}

.form-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
  align-items: start;
}

.field-label {
  display: grid;
  gap: 6px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
}

.form-grid textarea {
  grid-column: span 2;
}

.toast {
  position: fixed;
  top: 18px;
  right: 18px;
  z-index: 80;
  width: min(360px, calc(100vw - 36px));
  padding: 14px 16px;
  border: 1px solid #99f6e4;
  border-radius: 8px;
  background: #f0fdfa;
  box-shadow: 0 18px 42px rgba(16, 24, 40, 0.16);
}

.toast strong {
  display: block;
  margin-bottom: 6px;
}

.top-actions {
  display: flex;
  align-items: center;
  gap: 10px;
}

.live-pill {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  height: 34px;
  padding: 0 12px;
  border: 1px solid #bfdbfe;
  border-radius: 999px;
  background: #eff6ff;
  color: #1d4ed8;
  font-size: 13px;
  font-weight: 900;
}

.live-pill span {
  width: 8px;
  height: 8px;
  border-radius: 999px;
  background: #22c55e;
  box-shadow: 0 0 0 6px rgba(34, 197, 94, 0.14);
}

.fade-in {
  animation: fade-in 0.28s ease both;
}

@keyframes fade-in {
  from {
    opacity: 0;
    transform: translateY(8px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@media (max-width: 920px) {
  .layout {
    grid-template-columns: 1fr;
  }

  .sidebar {
    position: static;
    height: auto;
  }

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

  .topbar {
    align-items: flex-start;
    gap: 14px;
  }

  .sidebar-account-actions {
    position: static;
    margin-top: 16px;
    width: 100%;
  }

  .stats,
  .dashboard-grid,
  .two,
  .form-grid,
  .account-filter,
  .user-filter {
    grid-template-columns: 1fr;
  }

  .list-toolbar {
    align-items: stretch;
    flex-direction: column;
  }

  .order-page-head {
    align-items: stretch;
    flex-direction: column;
  }

  .order-query-grid {
    grid-template-columns: 1fr;
  }

  .order-hitters-grid {
    grid-template-columns: 1fr;
  }

  .transfer-deduction-list,
  .transfer-new-hitters {
    grid-template-columns: 1fr;
  }

  .form-grid textarea {
    grid-column: auto;
  }
}
