:root {
  --bg: #f7f8fb;
  --page: #ffffff;
  --card: #ffffff;
  --ink: #15161a;
  --muted: #767b87;
  --soft: #f5f6f8;
  --line: #e9ebef;
  --line-strong: #dfe3ea;
  --brand: #6b5cff;
  --brand-dark: #4b3cff;
  --brand-soft: #f1efff;
  --danger: #ef4444;
  --ok: #16a34a;
  --shadow: 0 12px 30px rgba(22, 28, 45, .06);
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  background: var(--page);
  color: var(--ink);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, "Noto Sans SC", sans-serif;
}
a { color: inherit; text-decoration: none; }
button, input, textarea, select { font: inherit; }

.topbar {
  position: sticky;
  top: 0;
  z-index: 30;
  display: flex;
  align-items: center;
  gap: 30px;
  min-height: 64px;
  padding: 0 48px;
  background: rgba(255, 255, 255, .92);
  backdrop-filter: blur(18px);
  border-bottom: 1px solid var(--line);
}
.brand {
  display: flex;
  align-items: center;
  gap: 10px;
  font-weight: 900;
  color: #16171b;
}
.brand-mark {
  display: grid;
  place-items: center;
  width: 32px;
  height: 32px;
  border-radius: 10px;
  color: #fff;
  background: linear-gradient(135deg, #101115, #6b5cff);
}
nav {
  display: flex;
  align-items: center;
  gap: 26px;
  color: #565b66;
  font-size: 14px;
  white-space: nowrap;
}
nav a:hover { color: var(--ink); }
.userbar {
  margin-left: auto;
  display: flex;
  align-items: center;
  gap: 12px;
  color: #565b66;
  font-size: 14px;
}

.btn {
  border: 0;
  border-radius: 999px;
  padding: 9px 16px;
  font-weight: 800;
  cursor: pointer;
  white-space: nowrap;
  transition: transform .15s ease, border-color .15s ease, background .15s ease, color .15s ease;
}
.btn:hover { transform: translateY(-1px); }
.btn.primary {
  color: #fff;
  background: #15161a;
  box-shadow: 0 10px 24px rgba(21, 22, 26, .18);
}
.btn.ghost {
  color: #22242a;
  background: #fff;
  border: 1px solid var(--line-strong);
}
.link-btn {
  border: 0;
  background: transparent;
  color: var(--brand-dark);
  font-weight: 800;
  cursor: pointer;
  padding: 0 0 16px;
}
.pill {
  display: inline-flex;
  align-items: center;
  border-radius: 999px;
  padding: 5px 10px;
  background: var(--brand-soft);
  color: var(--brand-dark);
  font-size: 12px;
  font-weight: 900;
}

.rh-page {
  background: #fff;
}
body.front-page-body {
  min-height: 100vh;
  overflow-x: hidden;
  background: #fff;
}
.front-page-body .topbar {
  padding: 0 32px;
}
.front-page-body .rh-page {
  width: 100%;
  min-height: calc(100vh - 64px);
}
.front-page-body .rh-hero {
  width: 100%;
  max-width: none;
  margin: 0;
  padding: 34px 32px 10px;
}
.front-page-body .section {
  width: 100%;
  max-width: none;
  margin: 0 0 34px;
  padding: 0 32px;
}
.front-page-body .rh-app-row {
  grid-template-columns: repeat(auto-fill, minmax(230px, 1fr));
}
.front-page-body .task-list,
.front-page-body .wallet-layout,
.front-page-body .detail-layout {
  width: 100%;
}
body.profile-page-body {
  background: #f6f7fb;
}
.profile-page-body .rh-page {
  background: #f6f7fb;
}
.profile-page-body .profile-page {
  min-height: calc(100vh - 64px);
}
.profile-page-body .profile-page-section {
  display: grid;
  gap: 18px;
  margin: 0;
  padding: 28px 32px 40px;
}
.profile-page-head {
  align-items: center;
  padding: 24px;
  background: linear-gradient(135deg, #ffffff, #f3f5ff);
  border: 1px solid var(--line);
  border-radius: 24px;
  box-shadow: var(--shadow);
}
.profile-page-head h1 {
  margin: 4px 0 8px;
  font-size: 32px;
  line-height: 1.18;
  letter-spacing: -.03em;
}
.section-kicker {
  display: inline-flex;
  color: var(--brand-dark);
  font-size: 12px;
  font-weight: 950;
  letter-spacing: .1em;
  text-transform: uppercase;
}
.admin-page {
  padding-top: 0;
}
body.admin-page-body {
  min-height: 100vh;
  overflow-x: hidden;
  background: #f6f7fb;
}
.admin-page-body .topbar {
  padding: 0 28px;
  background: rgba(255, 255, 255, .96);
}
.admin-page-body .rh-page.admin-page {
  width: 100%;
  min-height: calc(100vh - 64px);
  background: #f6f7fb;
}
.admin-page-body .admin-page > .section {
  display: flex;
  flex-direction: column;
  gap: 16px;
  width: 100%;
  max-width: none;
  min-height: calc(100vh - 64px);
  margin: 0;
  padding: 20px;
}
.admin-page-body .admin-head {
  flex: 0 0 auto;
  margin-bottom: 0;
  border-radius: 20px;
}
.admin-page-body .admin-console {
  flex: 1;
  min-height: 0;
}
.admin-page-body .admin-workbench {
  height: 100%;
  min-height: 0;
  grid-template-columns: 300px minmax(0, 1fr);
}
.admin-page-body .admin-sidebar {
  height: 100%;
  min-height: 0;
  overflow: auto;
}
.admin-page-body .admin-main {
  min-height: 0;
  overflow: auto;
}
.rh-hero {
  position: relative;
  max-width: 1200px;
  margin: 0 auto;
  padding: 34px 24px 10px;
}
.rh-titlebar {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 24px;
  padding: 30px 2px 16px;
}
.rh-titlebar h1 {
  margin: 0 0 10px;
  font-size: 30px;
  line-height: 1.16;
  font-weight: 950;
  letter-spacing: -.03em;
}
.rh-titlebar p {
  margin: 0;
  color: var(--muted);
  font-size: 15px;
}
.rh-total {
  flex: 0 0 auto;
  color: #4c5059;
  font-size: 15px;
  font-weight: 800;
}
.rh-total span { color: #11131a; }

.section {
  max-width: 1200px;
  margin: 0 auto 34px;
  padding: 0 24px;
}
.market-section { padding-top: 0; }
.rh-filterbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  margin-bottom: 18px;
}
.market-actions {
  display: flex;
  align-items: center;
  gap: 10px;
}
.search,
.sort-select {
  height: 40px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: #fff;
  outline: none;
}
.search {
  width: min(260px, 32vw);
  padding: 0 15px;
}
.sort-select {
  padding: 0 13px;
  color: #4b5563;
}
.search:focus,
.sort-select:focus { border-color: #c7c1ff; }
.category-tabs {
  display: flex;
  align-items: center;
  gap: 10px;
  overflow: auto;
  padding: 2px 0;
  scrollbar-width: none;
}
.category-tabs::-webkit-scrollbar { display: none; }
.cat-chip {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  border: 1px solid transparent;
  background: transparent;
  border-radius: 999px;
  padding: 8px 11px;
  color: #4f5664;
  font-size: 14px;
  font-weight: 800;
  cursor: pointer;
  white-space: nowrap;
}
.cat-chip em {
  font-style: normal;
  color: #9aa0aa;
  font-size: 12px;
}
.cat-chip.active {
  color: #11131a;
  background: #f1f2f5;
  border-color: #eceef2;
}
.cat-chip.active em { color: #6d7380; }

.app-grid.market-grid {
  display: block;
}
.app-section {
  margin: 0 0 34px;
}
.app-section h2 {
  margin: 0 0 16px;
  font-size: 22px;
  line-height: 1.25;
  font-weight: 950;
  letter-spacing: -.02em;
}
.rh-app-row {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 22px 18px;
}
.app-card {
  min-width: 0;
  background: var(--card);
  border: 1px solid transparent;
  border-radius: 16px;
  overflow: hidden;
  cursor: pointer;
  transition: transform .16s ease, border-color .16s ease, box-shadow .16s ease;
}
.app-card:hover {
  transform: translateY(-2px);
  border-color: var(--line-strong);
  box-shadow: 0 14px 34px rgba(21, 22, 26, .08);
}
.cover-wrap {
  position: relative;
  aspect-ratio: 1.42 / 1;
  overflow: hidden;
  border-radius: 14px;
  background: #eef0f4;
}
.cover-wrap img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.app-body {
  padding: 10px 2px 2px;
}
.app-body h3 {
  margin: 0 0 8px;
  min-height: 42px;
  color: #15161a;
  font-size: 15px;
  line-height: 1.42;
  font-weight: 850;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
.app-category {
  color: #5e6470;
  font-size: 13px;
  font-weight: 700;
}
.app-body p { display: none; }
.rh-price {
  margin-top: 10px;
  color: #7b8290;
  font-size: 12px;
  font-weight: 800;
}
.price-row { display: none; }
.empty-state {
  padding: 42px;
  text-align: center;
  color: var(--muted);
  background: #fafbfc;
  border: 1px dashed var(--line-strong);
  border-radius: 18px;
}

body.front-page-body:not(.profile-page-body) {
  background: #05070b;
  color: #f8fafc;
}
body.front-page-body:not(.profile-page-body) .topbar {
  min-height: 58px;
  padding: 0 16px;
  background: rgba(6, 8, 13, .92);
  border-bottom-color: rgba(255, 255, 255, .08);
}
body.front-page-body:not(.profile-page-body) .brand,
body.front-page-body:not(.profile-page-body) nav,
body.front-page-body:not(.profile-page-body) nav a,
body.front-page-body:not(.profile-page-body) .userbar {
  color: rgba(255, 255, 255, .82);
}
body.front-page-body:not(.profile-page-body) nav a:hover {
  color: #fff;
}
body.front-page-body:not(.profile-page-body) .btn.ghost {
  color: #fff;
  background: rgba(255, 255, 255, .08);
  border-color: rgba(255, 255, 255, .16);
}
body.front-page-body:not(.profile-page-body) .pill {
  color: #0f172a;
  background: #facc15;
}
body.front-page-body:not(.profile-page-body) .rh-page {
  background:
    radial-gradient(circle at 12% 0%, rgba(255, 56, 116, .15), transparent 30%),
    radial-gradient(circle at 92% 8%, rgba(75, 60, 255, .18), transparent 28%),
    #05070b;
}
body.front-page-body:not(.profile-page-body) .rh-hero {
  padding: 20px 10px 6px;
}
body.front-page-body:not(.profile-page-body) .rh-titlebar {
  padding: 18px 0 10px;
}
body.front-page-body:not(.profile-page-body) .rh-titlebar h1 {
  color: #fff;
  font-size: 28px;
}
body.front-page-body:not(.profile-page-body) .rh-titlebar p,
body.front-page-body:not(.profile-page-body) .rh-total {
  color: rgba(255, 255, 255, .58);
}
body.front-page-body:not(.profile-page-body) .rh-total span {
  color: #fff;
}
body.front-page-body:not(.profile-page-body) .section {
  padding: 0 10px;
}
body.front-page-body:not(.profile-page-body) .market-section {
  margin-bottom: 26px;
}
body.front-page-body:not(.profile-page-body) .rh-filterbar {
  margin-bottom: 10px;
  padding: 8px 0 10px;
}
body.front-page-body:not(.profile-page-body) .cat-chip {
  color: rgba(255, 255, 255, .72);
  background: rgba(255, 255, 255, .06);
  border-color: rgba(255, 255, 255, .08);
}
body.front-page-body:not(.profile-page-body) .cat-chip em {
  color: rgba(255, 255, 255, .46);
}
body.front-page-body:not(.profile-page-body) .cat-chip.active {
  color: #0f172a;
  background: #facc15;
  border-color: #facc15;
}
body.front-page-body:not(.profile-page-body) .cat-chip.active em {
  color: rgba(15, 23, 42, .58);
}
body.front-page-body:not(.profile-page-body) .search,
body.front-page-body:not(.profile-page-body) .sort-select {
  color: #fff;
  background: rgba(255, 255, 255, .08);
  border-color: rgba(255, 255, 255, .14);
}
body.front-page-body:not(.profile-page-body) .search::placeholder {
  color: rgba(255, 255, 255, .45);
}
body.front-page-body:not(.profile-page-body) .sort-select option {
  color: #111827;
}
body.front-page-body:not(.profile-page-body) .poster-section {
  margin: 0 0 14px;
}
body.front-page-body:not(.profile-page-body) .poster-section h2 {
  margin: 0 0 8px;
  color: #fff;
  font-size: 18px;
  letter-spacing: 0;
}
body.front-page-body:not(.profile-page-body) .poster-wall {
  grid-template-columns: repeat(auto-fill, minmax(156px, 1fr));
  gap: 8px;
}
body.front-page-body:not(.profile-page-body) .poster-card {
  position: relative;
  display: block;
  min-height: 0;
  background: #0f172a;
  border: 1px solid rgba(255, 255, 255, .08);
  border-radius: 4px;
  box-shadow: none;
  transform: translateZ(0);
}
body.front-page-body:not(.profile-page-body) .poster-card:hover {
  z-index: 2;
  transform: translateY(-3px) scale(1.015);
  border-color: rgba(250, 204, 21, .7);
  box-shadow: 0 18px 36px rgba(0, 0, 0, .36);
}
body.front-page-body:not(.profile-page-body) .poster-cover {
  position: relative;
  aspect-ratio: 3 / 4;
  border-radius: 4px;
  background: #111827;
}
body.front-page-body:not(.profile-page-body) .poster-cover::before,
body.front-page-body:not(.profile-page-body) .poster-cover::after {
  content: '';
  position: absolute;
  inset: 0;
  z-index: 1;
  pointer-events: none;
}
body.front-page-body:not(.profile-page-body) .poster-cover::before {
  background: linear-gradient(180deg, rgba(0, 0, 0, .08) 0%, rgba(0, 0, 0, .18) 42%, rgba(0, 0, 0, .9) 100%);
}
body.front-page-body:not(.profile-page-body) .poster-cover::after {
  border: 1px solid rgba(255, 255, 255, .08);
  box-shadow: inset 0 -80px 80px rgba(0, 0, 0, .45);
}
body.front-page-body:not(.profile-page-body) .poster-cover img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transform: scale(1.001);
  transition: transform .22s ease;
}
body.front-page-body:not(.profile-page-body) .poster-card:hover .poster-cover img {
  transform: scale(1.045);
}
.poster-badge {
  position: absolute;
  top: 0;
  left: 0;
  z-index: 3;
  padding: 5px 7px;
  color: #fff;
  background: #ff2f68;
  border-radius: 0 0 5px 0;
  font-size: 12px;
  line-height: 1;
  font-weight: 950;
}
.poster-info {
  position: absolute;
  left: 9px;
  right: 9px;
  bottom: 28px;
  z-index: 3;
  color: #fff;
}
.poster-title {
  display: -webkit-box;
  overflow: hidden;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  color: #fff;
  text-shadow: 0 2px 12px rgba(0, 0, 0, .75);
  font-size: 15px;
  line-height: 1.28;
  font-weight: 950;
}
.poster-desc {
  display: -webkit-box;
  overflow: hidden;
  margin-top: 4px;
  -webkit-line-clamp: 1;
  -webkit-box-orient: vertical;
  color: rgba(255, 255, 255, .78);
  font-size: 11px;
  line-height: 1.3;
}
.poster-price {
  display: inline-flex;
  margin-top: 6px;
  padding: 3px 6px;
  color: #0f172a;
  background: rgba(250, 204, 21, .95);
  border-radius: 999px;
  font-size: 11px;
  font-weight: 950;
}
.poster-meta {
  position: absolute;
  left: 8px;
  right: 8px;
  bottom: 7px;
  z-index: 3;
  display: flex;
  align-items: center;
  gap: 6px;
  min-width: 0;
  color: rgba(255, 255, 255, .72);
  font-size: 10px;
  line-height: 1;
  white-space: nowrap;
}
.poster-meta span {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
}
.poster-meta span + span::before {
  content: '·';
  margin-right: 6px;
  color: rgba(255, 255, 255, .42);
}
.poster-author {
  max-width: 36%;
  color: rgba(255, 255, 255, .86);
}
body.front-page-body:not(.profile-page-body) .app-body,
body.front-page-body:not(.profile-page-body) .app-category,
body.front-page-body:not(.profile-page-body) .rh-price {
  display: none;
}
body.front-page-body:not(.profile-page-body) .empty-state {
  color: rgba(255, 255, 255, .68);
  background: rgba(255, 255, 255, .06);
  border-color: rgba(255, 255, 255, .14);
}
body.front-page-body:not(.profile-page-body) .section-head h2,
body.front-page-body:not(.profile-page-body) .section-head p {
  color: #fff;
}

@media (max-width: 760px) {
  body.front-page-body:not(.profile-page-body) .topbar {
    flex-wrap: wrap;
    gap: 10px;
    padding: 10px 12px;
  }
  body.front-page-body:not(.profile-page-body) nav {
    order: 3;
    width: 100%;
    gap: 16px;
    overflow-x: auto;
  }
  body.front-page-body:not(.profile-page-body) .rh-hero,
  body.front-page-body:not(.profile-page-body) .section {
    padding-left: 8px;
    padding-right: 8px;
  }
  body.front-page-body:not(.profile-page-body) .rh-titlebar {
    align-items: flex-start;
    flex-direction: column;
    gap: 8px;
  }
  body.front-page-body:not(.profile-page-body) .rh-filterbar {
    align-items: stretch;
    flex-direction: column;
  }
  body.front-page-body:not(.profile-page-body) .market-actions {
    width: 100%;
  }
  body.front-page-body:not(.profile-page-body) .search {
    width: 100%;
    flex: 1;
  }
  body.front-page-body:not(.profile-page-body) .poster-wall {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 8px;
  }
  .poster-title {
    font-size: 14px;
  }
  .poster-desc,
  .poster-price {
    font-size: 10px;
  }
  .poster-meta {
    gap: 4px;
    font-size: 9px;
  }
  .poster-meta span:nth-child(3) {
    display: none;
  }
}

.detail-layout {
  display: grid;
  grid-template-columns: 1fr 420px;
  gap: 24px;
}
.detail-info,
.runner,
.examples,
.task-list,
.admin-list,
.wallet-card,
.admin-order-panel {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 22px;
  padding: 22px;
  box-shadow: var(--shadow);
}
.app-detail-card img {
  width: 100%;
  max-height: 390px;
  object-fit: cover;
  border-radius: 18px;
  margin-bottom: 18px;
}
.detail-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 12px;
}
.tag {
  display: inline-flex;
  padding: 6px 10px;
  border-radius: 999px;
  background: #f1f5f9;
  color: #475569;
  font-size: 12px;
  font-weight: 800;
}
.tag.hot { background: #fff1f2; color: #e11d48; }
.app-detail-card h2 {
  font-size: 30px;
  margin: 0 0 10px;
  letter-spacing: -.03em;
}
.app-detail-card p {
  color: #5b6472;
  line-height: 1.8;
}
.detail-stats {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 10px;
  margin-top: 18px;
}
.detail-stats span {
  background: #f8fafc;
  border: 1px solid var(--line);
  border-radius: 14px;
  padding: 12px;
  text-align: center;
  font-weight: 900;
  color: #475569;
}
.runner {
  position: sticky;
  top: 86px;
  align-self: start;
}
.runner h3,
.wallet-card h3,
.admin-order-panel h3 { margin: 0 0 14px; }
.field {
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin-bottom: 14px;
}
.field label {
  font-weight: 900;
  font-size: 14px;
}
.field input,
.field textarea,
.field select,
.modal-card input,
.admin-form input,
.admin-form select,
.field-row input,
.field-row select,
.user-admin-row input {
  border: 1px solid var(--line);
  border-radius: 14px;
  background: #f8fafc;
  outline: none;
}
.field input,
.field textarea,
.field select {
  width: 100%;
  padding: 12px 14px;
}
.field textarea {
  min-height: 110px;
  resize: vertical;
}
.run-btn { width: 100%; margin-top: 4px; }
.status {
  margin-top: 14px;
  color: var(--muted);
  font-size: 14px;
}
.outputs {
  display: grid;
  gap: 12px;
  margin-top: 16px;
}
.outputs img,
.outputs video {
  width: 100%;
  border-radius: 16px;
  border: 1px solid var(--line);
}
.examples { margin-top: 18px; }
.example-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 12px;
}
.example-grid span {
  background: #f8fafc;
  border: 1px solid var(--line);
  border-radius: 14px;
  padding: 14px;
  text-align: center;
  color: #475569;
}

.section-head {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 18px;
  margin-bottom: 16px;
}
.section-head h2,
.section h2 {
  margin: 0 0 8px;
  font-size: 24px;
}
.section-head p,
.section p {
  margin: 0;
  color: var(--muted);
}
.task-item,
.admin-item {
  display: grid;
  grid-template-columns: 1fr;
  gap: 14px;
  border-bottom: 1px solid var(--line);
  padding: 14px 0;
}
.task-item { grid-template-columns: 1fr auto; }
.task-item:last-child,
.admin-item:last-child { border-bottom: 0; }
.task-meta {
  color: var(--muted);
  font-size: 13px;
}

.wallet-layout {
  display: grid;
  grid-template-columns: 1.1fr 1fr 1fr;
  gap: 18px;
}
.plan-list,
.mini-list,
.admin-users {
  display: grid;
  gap: 10px;
}
.plan-card {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 6px;
  width: 100%;
  border: 1px solid var(--line);
  border-radius: 16px;
  background: #f8fafc;
  padding: 14px;
  cursor: pointer;
  text-align: left;
}
.plan-card:hover {
  border-color: #c7c1ff;
  background: var(--brand-soft);
}
.plan-card strong { font-size: 16px; }
.plan-card span { font-weight: 900; color: var(--brand-dark); }
.plan-card small,
.mini-item span,
.user-admin-main span {
  color: var(--muted);
  font-size: 13px;
}
.mini-item,
.user-admin-row {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: #f8fafc;
  padding: 12px;
}
.mini-item strong,
.user-admin-main strong {
  display: block;
  margin-bottom: 4px;
}
.user-admin-row { align-items: center; }

.profile-panel {
  display: grid;
  gap: 18px;
}
.profile-empty {
  display: grid;
  gap: 10px;
  align-items: start;
  padding: 28px;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 24px;
  box-shadow: var(--shadow);
}
.profile-empty strong {
  font-size: 20px;
}
.profile-empty p {
  max-width: 560px;
}
.profile-grid {
  display: grid;
  grid-template-columns: minmax(280px, 1.2fr) minmax(220px, .55fr) minmax(360px, 1.1fr);
  gap: 18px;
  align-items: stretch;
}
.profile-record-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 18px;
}
.profile-card {
  min-width: 0;
  padding: 20px;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 24px;
  box-shadow: var(--shadow);
}
.profile-kicker {
  display: inline-flex;
  margin-bottom: 8px;
  color: var(--brand-dark);
  font-size: 12px;
  font-weight: 900;
  letter-spacing: .08em;
  text-transform: uppercase;
}
.profile-identity h3 {
  margin: 0 0 8px;
  font-size: 24px;
  line-height: 1.2;
  word-break: break-all;
}
.profile-identity p,
.profile-balance-card p {
  margin: 0;
  color: var(--muted);
}
.profile-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 18px;
}
.profile-balance-card {
  display: flex;
  flex-direction: column;
  justify-content: center;
  background: linear-gradient(135deg, #15161a, #4b3cff);
  color: #fff;
}
.profile-balance-card .profile-kicker,
.profile-balance-card p {
  color: rgba(255, 255, 255, .72);
}
.profile-balance-card strong {
  display: block;
  margin: 4px 0 8px;
  font-size: 46px;
  line-height: 1;
  font-weight: 950;
}
.profile-stats {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 10px;
}
.profile-stats div {
  min-width: 0;
  padding: 14px;
  background: #f8fafc;
  border: 1px solid var(--line);
  border-radius: 16px;
}
.profile-stats span {
  display: block;
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
}
.profile-stats strong {
  display: block;
  margin-top: 8px;
  font-size: 22px;
  line-height: 1;
}
.profile-card-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  margin-bottom: 14px;
}
.profile-card-head h3 {
  margin: 0;
  font-size: 18px;
}
.profile-card-head a {
  color: var(--brand-dark);
  font-size: 13px;
  font-weight: 900;
}
.profile-list {
  display: grid;
  gap: 10px;
}
.profile-list p {
  margin: 0;
  color: var(--muted);
}
.profile-list-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 12px;
  background: #f8fafc;
  border: 1px solid var(--line);
  border-radius: 16px;
}
.profile-list-item strong,
.profile-list-item span {
  display: block;
}
.profile-list-item strong {
  margin-bottom: 5px;
  font-size: 14px;
}
.profile-list-item span {
  color: var(--muted);
  font-size: 12px;
  line-height: 1.45;
}

@media (max-width: 1180px) {
  .profile-grid,
  .profile-record-grid {
    grid-template-columns: 1fr;
  }
  .profile-stats {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}

@media (max-width: 760px) {
  .profile-empty,
  .profile-card {
    padding: 16px;
    border-radius: 18px;
  }
  .profile-actions,
  .profile-list-item,
  .profile-card-head {
    align-items: stretch;
    flex-direction: column;
  }
  .profile-stats {
    grid-template-columns: 1fr 1fr;
  }
  .profile-balance-card strong {
    font-size: 38px;
  }
}

.user-admin-main { min-width: 260px; }
.user-admin-row input {
  height: 38px;
  padding: 0 10px;
  min-width: 0;
}
.order-admin { align-items: center; }

.admin-form {
  display: grid;
  grid-template-columns: 1.4fr 1.5fr 100px 80px 120px 90px 86px 86px 86px 76px auto auto;
  gap: 10px;
  align-items: center;
}
.admin-form input,
.admin-form select {
  padding: 10px;
  min-width: 0;
}
.admin-check {
  font-size: 13px;
  color: #475569;
  white-space: nowrap;
}
.admin-check input {
  width: auto;
  margin-right: 5px;
}
.field-editor {
  grid-column: 1 / -1;
  margin-top: 14px;
  background: #f8fafc;
  border: 1px solid var(--line);
  border-radius: 18px;
  padding: 14px;
}
.field-editor-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 12px;
}
.field-rows {
  display: grid;
  gap: 10px;
  margin-bottom: 12px;
}
.field-row {
  display: grid;
  grid-template-columns: 90px 120px 90px 120px 1fr 74px 74px 86px auto;
  gap: 8px;
  align-items: center;
}
.field-row input,
.field-row select {
  width: 100%;
  padding: 9px;
  background: #fff;
}
.field-row label {
  font-size: 13px;
  color: #475569;
}
.field-row label input {
  width: auto;
  margin-right: 4px;
}

.modal {
  border: 0;
  border-radius: 22px;
  padding: 0;
  box-shadow: 0 30px 100px rgba(15, 23, 42, .35);
}
.modal::backdrop { background: rgba(15, 23, 42, .45); }
.modal-card {
  width: min(420px, 92vw);
  padding: 26px;
  position: relative;
}
.modal-close {
  position: absolute;
  right: 18px;
  top: 14px;
  border: 0;
  background: transparent;
  font-size: 26px;
  cursor: pointer;
}
.modal-card input {
  width: 100%;
  padding: 13px 15px;
  margin-bottom: 12px;
}
.modal-actions {
  display: flex;
  gap: 12px;
}
.error {
  color: var(--danger);
  font-size: 14px;
  margin-top: 12px;
}

@media (max-width: 1100px) {
  .rh-app-row { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .detail-layout { grid-template-columns: 1fr; }
  .runner { position: static; }
  .wallet-layout { grid-template-columns: 1fr; }
  .admin-form { grid-template-columns: repeat(4, minmax(0, 1fr)); }
}

@media (max-width: 760px) {
  .topbar {
    padding: 12px 16px;
    gap: 12px;
    flex-wrap: wrap;
  }
  nav {
    width: 100%;
    gap: 16px;
    overflow-x: auto;
  }
  .userbar {
    width: 100%;
    margin-left: 0;
    justify-content: flex-start;
  }
  .rh-hero { padding: 18px 14px 6px; }
  .rh-titlebar {
    align-items: flex-start;
    flex-direction: column;
    gap: 10px;
    padding-top: 22px;
  }
  .rh-titlebar h1 { font-size: 28px; }
  .section { padding: 0 14px; }
  .rh-filterbar {
    align-items: flex-start;
    flex-direction: column;
  }
  .market-actions {
    width: 100%;
    flex-direction: column;
    align-items: stretch;
  }
  .search,
  .sort-select { width: 100%; }
  .rh-app-row { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 18px 12px; }
  .app-body h3 { font-size: 14px; min-height: 40px; }
  .detail-stats { grid-template-columns: 1fr 1fr; }
  .example-grid { grid-template-columns: 1fr 1fr; }
  .task-item,
  .mini-item,
  .user-admin-row { flex-direction: column; display: flex; }
  .admin-form,
  .field-row { grid-template-columns: 1fr; }
}

@media (max-width: 760px) {
  .front-page-body .topbar {
    padding: 12px 16px;
  }
  .front-page-body .rh-hero {
    padding: 18px 14px 6px;
  }
  .front-page-body .section {
    padding: 0 14px;
  }
  .front-page-body .rh-app-row {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 18px 12px;
  }
}

@media (max-width: 430px) {
  .rh-app-row { grid-template-columns: 1fr; }
  .front-page-body .rh-app-row { grid-template-columns: 1fr; }
}

/* Admin console cleanup */
.section-kicker {
  display: inline-flex;
  margin-bottom: 8px;
  color: var(--brand-dark);
  font-size: 12px;
  font-weight: 900;
  letter-spacing: .08em;
  text-transform: uppercase;
}
.admin-head {
  align-items: center;
  padding: 24px 26px;
  background: linear-gradient(135deg, #f8f7ff, #fff);
  border: 1px solid var(--line);
  border-radius: 24px;
  box-shadow: var(--shadow);
}
.admin-console {
  display: grid;
  gap: 22px;
}
.admin-summary-grid {
  display: grid;
  grid-template-columns: repeat(6, minmax(0, 1fr));
  gap: 12px;
}
.admin-stat-card {
  min-height: 118px;
  padding: 18px;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 20px;
  box-shadow: 0 10px 24px rgba(22, 28, 45, .045);
}
.admin-stat-card span {
  display: block;
  color: #737987;
  font-size: 13px;
  font-weight: 800;
}
.admin-stat-card strong {
  display: block;
  margin: 10px 0 6px;
  color: #14161c;
  font-size: 26px;
  line-height: 1;
  font-weight: 950;
}
.admin-stat-card small {
  color: #9aa0aa;
  font-size: 12px;
}
.admin-dashboard-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.35fr) minmax(360px, .65fr);
  gap: 18px;
  align-items: start;
}
.admin-panel {
  min-width: 0;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 24px;
  padding: 20px;
  box-shadow: var(--shadow);
}
.admin-panel-wide { grid-column: 1 / -1; }
.admin-panel-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 18px;
  margin-bottom: 16px;
}
.admin-panel-head h3 {
  margin: 0 0 6px;
  font-size: 20px;
  line-height: 1.2;
}
.admin-panel-head p {
  margin: 0;
  color: var(--muted);
  font-size: 13px;
}
.admin-table-wrap {
  overflow: auto;
  border: 1px solid var(--line);
  border-radius: 18px;
  background: #fff;
}
.admin-table {
  width: 100%;
  min-width: 780px;
  border-collapse: collapse;
  font-size: 13px;
}
.admin-table th,
.admin-table td {
  padding: 12px 14px;
  border-bottom: 1px solid var(--line);
  text-align: left;
  vertical-align: middle;
}
.admin-table th {
  color: #6b7280;
  background: #f8fafc;
  font-weight: 900;
  white-space: nowrap;
}
.admin-table tr:last-child td { border-bottom: 0; }
.admin-table td span { color: var(--muted); }
.admin-badge {
  display: inline-flex;
  align-items: center;
  border-radius: 999px;
  padding: 4px 9px;
  font-size: 12px;
  font-weight: 900;
  white-space: nowrap;
}
.admin-badge.ok { color: #047857; background: #ecfdf5; }
.admin-badge.warn { color: #b45309; background: #fffbeb; }
.admin-badge.danger { color: #b91c1c; background: #fef2f2; }
.admin-muted {
  color: #9aa0aa;
  font-size: 12px;
}
.btn.compact {
  padding: 7px 11px;
  font-size: 12px;
}
.admin-mini-input,
.admin-note-input {
  height: 36px;
  width: 100%;
  min-width: 96px;
  padding: 0 10px;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: #f8fafc;
}
.admin-note-input { min-width: 150px; }
.admin-row-actions {
  display: flex;
  gap: 8px;
  white-space: nowrap;
}
.admin-empty {
  padding: 24px;
  color: var(--muted);
  text-align: center;
  background: #f8fafc;
  border: 1px dashed var(--line-strong);
  border-radius: 18px;
}
.admin-app-list {
  display: grid;
  gap: 16px;
}
.admin-app-card {
  display: grid;
  grid-template-columns: 180px minmax(0, 1fr);
  gap: 18px;
  padding: 16px;
  background: #fbfcfe;
  border: 1px solid var(--line);
  border-radius: 20px;
}
.admin-app-side {
  position: relative;
}
.admin-app-side img {
  display: block;
  width: 100%;
  aspect-ratio: 1.42 / 1;
  object-fit: cover;
  border-radius: 16px;
  background: #eef0f4;
}
.admin-app-side .admin-badge {
  position: absolute;
  left: 10px;
  top: 10px;
}
.admin-app-form {
  display: grid;
  grid-template-columns: 1fr;
  align-items: stretch;
  gap: 14px;
}
.admin-app-title-row {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
}
.admin-app-title-row strong {
  display: block;
  margin-bottom: 5px;
  font-size: 16px;
}
.admin-app-title-row span {
  color: var(--muted);
  font-size: 13px;
}
.admin-app-actions {
  display: flex;
  gap: 8px;
  white-space: nowrap;
}
.admin-form-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
}
.admin-form-grid label {
  display: flex;
  flex-direction: column;
  gap: 6px;
  color: #5f6673;
  font-size: 12px;
  font-weight: 900;
}
.admin-form-grid input,
.admin-form-grid select {
  width: 100%;
  height: 38px;
  padding: 0 11px;
  color: #15161a;
  border: 1px solid var(--line);
  border-radius: 11px;
  background: #fff;
}
.admin-form-grid .admin-featured {
  justify-content: flex-end;
  padding-bottom: 8px;
  flex-direction: row;
  align-items: center;
  color: #15161a;
}
.admin-form-grid .admin-featured input {
  width: auto;
  height: auto;
}
.admin-app-card .field-editor {
  grid-column: 1 / -1;
  margin-top: 0;
  background: #fff;
}

@media (max-width: 1100px) {
  .admin-summary-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .admin-dashboard-grid { grid-template-columns: 1fr; }
  .admin-form-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

@media (max-width: 760px) {
  .admin-head {
    align-items: flex-start;
    flex-direction: column;
    padding: 20px;
  }
  .admin-summary-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .admin-panel { padding: 16px; }
  .admin-app-card { grid-template-columns: 1fr; }
  .admin-app-title-row {
    flex-direction: column;
    align-items: stretch;
  }
  .admin-app-actions { flex-wrap: wrap; }
  .admin-form-grid { grid-template-columns: 1fr; }
}

/* Admin workbench */
.admin-console {
  display: block;
}
.admin-workbench {
  display: grid;
  grid-template-columns: 280px minmax(0, 1fr);
  gap: 18px;
  align-items: stretch;
}
.admin-sidebar,
.admin-main,
.admin-card,
.admin-drawer {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 24px;
  box-shadow: var(--shadow);
}
.admin-sidebar {
  position: sticky;
  top: 84px;
  align-self: stretch;
  padding: 16px;
}
.admin-sidebar-title {
  padding: 10px 10px 16px;
  border-bottom: 1px solid var(--line);
}
.admin-sidebar-title strong,
.admin-sidebar-title span {
  display: block;
}
.admin-sidebar-title strong {
  font-size: 17px;
}
.admin-sidebar-title span {
  margin-top: 4px;
  color: var(--muted);
  font-size: 13px;
}
.admin-nav {
  display: grid;
  gap: 8px;
  margin-top: 14px;
}
.admin-nav-item {
  width: 100%;
  padding: 13px 14px;
  text-align: left;
  color: #535b69;
  background: transparent;
  border: 0;
  border-radius: 16px;
  cursor: pointer;
}
.admin-nav-item strong,
.admin-nav-item span {
  display: block;
}
.admin-nav-item strong {
  color: #17191f;
  font-size: 14px;
}
.admin-nav-item span {
  margin-top: 4px;
  overflow: hidden;
  color: var(--muted);
  font-size: 12px;
  line-height: 1.45;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.admin-nav-item:hover,
.admin-nav-item.active {
  background: #f3f6ff;
}
.admin-nav-item.active {
  box-shadow: inset 3px 0 0 var(--primary);
}
.admin-main {
  min-width: 0;
  padding: 18px;
}
.admin-main-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  padding: 8px 8px 18px;
  border-bottom: 1px solid var(--line);
}
.admin-main-head h3 {
  margin: 4px 0 6px;
  font-size: 24px;
}
.admin-main-head p {
  margin: 0;
  color: var(--muted);
}
.admin-notice {
  margin: 16px 0 0;
  padding: 12px 14px;
  border-radius: 14px;
  font-weight: 800;
}
.admin-notice.ok {
  color: #047857;
  background: #ecfdf5;
}
.admin-notice.danger {
  color: #b91c1c;
  background: #fef2f2;
}
.admin-workspace {
  display: grid;
  gap: 18px;
  padding-top: 18px;
}
.admin-kpi-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 14px;
}
.admin-kpi {
  padding: 18px;
  text-align: left;
  background: linear-gradient(180deg, #fff, #f8fafc);
  border: 1px solid var(--line);
  border-radius: 20px;
  cursor: pointer;
}
.admin-kpi span,
.admin-kpi small,
.admin-count {
  color: var(--muted);
  font-size: 13px;
}
.admin-kpi strong {
  display: block;
  margin: 8px 0 5px;
  color: #111318;
  font-size: 28px;
}
.admin-card {
  padding: 18px;
  box-shadow: none;
}
.admin-card-head,
.admin-drawer-head,
.admin-module-toolbar,
.admin-action-row,
.admin-sticky-actions,
.admin-app-list-actions {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
}
.admin-card-head h4,
.admin-drawer-head h4,
.admin-form-section h5 {
  margin: 0 0 6px;
}
.admin-card-head p,
.admin-drawer-head p,
.admin-form-section p {
  margin: 0;
  color: var(--muted);
}
.admin-todo-list {
  display: grid;
  gap: 10px;
  margin-top: 14px;
}
.admin-todo-item {
  display: grid;
  grid-template-columns: 140px 1fr;
  gap: 12px;
  align-items: center;
  padding: 13px 14px;
  text-align: left;
  background: #f8fafc;
  border: 1px solid var(--line);
  border-radius: 15px;
  cursor: pointer;
}
.admin-todo-item span {
  color: var(--muted);
  font-size: 13px;
}
.admin-module-toolbar {
  flex-wrap: wrap;
  padding: 4px 0;
}
.admin-search,
.admin-select-label {
  display: flex;
  align-items: center;
  gap: 10px;
  color: #5f6673;
  font-size: 13px;
  font-weight: 900;
}
.admin-search input,
.admin-select-label select,
.admin-action-form input,
.admin-editor-form input,
.admin-editor-form select,
.admin-editor-form textarea,
.admin-field-editor input,
.admin-field-editor select {
  width: 100%;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: #f8fafc;
  outline: none;
}
.admin-search input,
.admin-select-label select,
.admin-action-form input,
.admin-editor-form input,
.admin-editor-form select,
.admin-field-editor input,
.admin-field-editor select {
  height: 40px;
  padding: 0 12px;
}
.admin-editor-form textarea {
  min-height: 96px;
  padding: 10px 12px;
  resize: vertical;
}
.admin-tabs {
  display: inline-flex;
  gap: 8px;
  padding: 5px;
  background: #f3f6fb;
  border-radius: 999px;
}
.admin-tab {
  padding: 8px 14px;
  color: #5f6673;
  background: transparent;
  border: 0;
  border-radius: 999px;
  cursor: pointer;
  font-weight: 900;
}
.admin-tab.active {
  color: #111318;
  background: #fff;
  box-shadow: 0 8px 18px rgba(20, 27, 40, .08);
}
.admin-split {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 360px;
  gap: 18px;
  align-items: start;
}
.admin-app-split {
  grid-template-columns: minmax(0, 1fr) 430px;
}
.admin-app-single {
  grid-template-columns: minmax(0, 1fr);
}
.admin-list-card {
  overflow: hidden;
}
.admin-table-wrap {
  overflow-x: auto;
}
.admin-table {
  width: 100%;
  border-collapse: collapse;
  min-width: 720px;
}
.admin-table th,
.admin-table td {
  padding: 13px 12px;
  text-align: left;
  border-bottom: 1px solid var(--line);
  vertical-align: middle;
}
.admin-table th {
  color: #667085;
  font-size: 12px;
  text-transform: uppercase;
  background: #f8fafc;
}
.admin-table td span {
  color: var(--muted);
}
.admin-click-table tr {
  cursor: pointer;
}
.admin-click-table tbody tr:hover,
.admin-click-table tbody tr.active {
  background: #f7f9ff;
}
.admin-drawer {
  position: sticky;
  top: 86px;
  padding: 18px;
  box-shadow: none;
}
.admin-drawer-empty {
  display: grid;
  gap: 8px;
  padding: 18px;
  color: var(--muted);
  background: #f8fafc;
  border: 1px dashed var(--line-strong);
  border-radius: 18px;
}
.admin-drawer-empty strong {
  color: #111318;
}
.admin-user-balance {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin: 18px 0;
  padding: 16px;
  background: #f8fafc;
  border-radius: 16px;
}
.admin-user-balance span {
  color: var(--muted);
}
.admin-user-balance strong {
  font-size: 26px;
}
.admin-action-form {
  display: grid;
  gap: 12px;
}
.admin-action-form label,
.admin-editor-form label,
.admin-form-grid label {
  display: flex;
  flex-direction: column;
  gap: 7px;
  color: #5f6673;
  font-size: 12px;
  font-weight: 900;
}
.admin-danger-zone {
  margin-top: 18px;
  padding: 14px;
  background: #fff7ed;
  border: 1px solid #fed7aa;
  border-radius: 16px;
}
.admin-danger-zone p {
  margin: 6px 0 12px;
  color: #9a3412;
  font-size: 13px;
}
.admin-app-master {
  display: grid;
  gap: 12px;
  margin-top: 14px;
}
.admin-app-list-item {
  display: grid;
  grid-template-columns: 96px minmax(0, 1fr) auto;
  gap: 14px;
  align-items: center;
  padding: 12px;
  background: #fbfcfe;
  border: 1px solid var(--line);
  border-radius: 18px;
}
.admin-app-list-item.active,
.admin-app-list-item:hover {
  border-color: #b9c6ff;
  background: #f7f9ff;
}
.admin-app-list-item img {
  width: 96px;
  height: 68px;
  object-fit: cover;
  border-radius: 14px;
  background: #eef0f4;
}
.admin-app-list-item strong,
.admin-app-list-item span,
.admin-app-list-item small {
  display: block;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.admin-app-list-item span,
.admin-app-list-item small {
  margin-top: 4px;
  color: var(--muted);
}
.admin-app-list-actions {
  justify-content: flex-end;
}
.admin-editor-form {
  display: grid;
  gap: 16px;
}
.admin-form-section {
  padding-top: 16px;
  border-top: 1px solid var(--line);
}
.admin-form-grid {
  display: grid;
  gap: 12px;
}
.admin-form-grid.two {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}
.admin-form-grid.three {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}
.admin-form-grid .wide {
  grid-column: 1 / -1;
}
.admin-check {
  flex-direction: row !important;
  align-items: center;
  justify-content: flex-start;
  color: #111318 !important;
}
.admin-check input {
  width: auto;
  height: auto;
}
.admin-sticky-actions {
  position: sticky;
  bottom: 0;
  padding-top: 14px;
  background: linear-gradient(180deg, rgba(255,255,255,.78), #fff 50%);
}
.admin-warning {
  display: flex;
  flex-direction: column;
  gap: 4px;
  padding: 15px 16px;
  color: #92400e;
  background: #fffbeb;
  border: 1px solid #fde68a;
  border-radius: 18px;
}
.admin-warning span {
  font-size: 13px;
}
.admin-field-editor {
  margin-top: 14px;
  padding: 0;
  background: transparent;
  border: 0;
}
.admin-field-editor .field-row {
  grid-template-columns: 1.1fr 1.1fr 120px 1.1fr 1fr 88px 88px 90px auto;
  padding: 10px;
  background: #f8fafc;
  border: 1px solid var(--line);
  border-radius: 14px;
}
.admin-fields-card .admin-empty {
  margin-top: 14px;
}

@media (max-width: 1180px) {
  .admin-workbench,
  .admin-split,
  .admin-app-split {
    grid-template-columns: 1fr;
  }
  .admin-sidebar,
  .admin-drawer {
    position: static;
  }
  .admin-nav {
    grid-template-columns: repeat(5, minmax(0, 1fr));
  }
  .admin-nav-item span {
    white-space: normal;
  }
  .admin-kpi-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 760px) {
  .admin-main,
  .admin-card,
  .admin-drawer,
  .admin-sidebar {
    padding: 14px;
    border-radius: 18px;
  }
  .admin-main-head,
  .admin-card-head,
  .admin-drawer-head,
  .admin-module-toolbar,
  .admin-action-row,
  .admin-sticky-actions,
  .admin-app-list-actions {
    align-items: stretch;
    flex-direction: column;
  }
  .admin-nav {
    grid-template-columns: 1fr;
  }
  .admin-kpi-grid,
  .admin-form-grid.two,
  .admin-form-grid.three {
    grid-template-columns: 1fr;
  }
  .admin-todo-item,
  .admin-app-list-item {
    grid-template-columns: 1fr;
  }
  .admin-app-list-item img {
    width: 100%;
    height: auto;
    aspect-ratio: 1.6 / 1;
  }
  .admin-table {
    min-width: 680px;
  }
  .admin-field-editor .field-row {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 1180px) {
  .admin-page-body .admin-workbench {
    height: auto;
    grid-template-columns: 1fr;
  }
  .admin-page-body .admin-sidebar,
  .admin-page-body .admin-main {
    height: auto;
    min-height: 0;
    overflow: visible;
  }
}

@media (max-width: 760px) {
  .admin-page-body .topbar {
    padding: 0 14px;
  }
  .admin-page-body .admin-page > .section {
    padding: 12px;
  }
}
