:root {
  color-scheme: light;
  font-family: -apple-system, BlinkMacSystemFont, "SF Pro Display", "Segoe UI", "Microsoft YaHei", sans-serif;
  font-size: 11px;
  background: #f5f5f7;
  color: #1d1d1f;
}

* {
  box-sizing: border-box;
}

[hidden] {
  display: none !important;
}

body {
  margin: 0;
  min-height: 100vh;
  background:
    radial-gradient(circle at 20% 0%, rgba(255, 255, 255, 0.9), transparent 36rem),
    linear-gradient(180deg, #fbfbfd 0%, #f5f5f7 42%, #ffffff 100%);
}

body.dark-mode {
  background: #080b10;
  color: #e5e7eb;
}

.auth-screen {
  min-height: 100vh;
  display: grid;
  place-items: center;
  padding: 24px;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.92), rgba(245, 247, 251, 0.88)),
    #f5f5f7;
}

.auth-shell {
  width: min(440px, 100%);
  display: grid;
  gap: 22px;
  justify-items: center;
}

.auth-brand-row {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  color: #111827;
  font-size: 14px;
  font-weight: 700;
}

.auth-logo-mark {
  width: 36px;
  height: 36px;
  display: inline-grid;
  place-items: center;
  border-radius: 12px;
  background: #1b84ff;
  color: #ffffff;
  font-size: 13px;
  font-weight: 800;
  box-shadow: 0 10px 22px rgba(27, 132, 255, 0.26);
}

.auth-card {
  width: 100%;
  display: grid;
  gap: 18px;
  padding: 34px 38px 36px;
  border: 1px solid #f1f1f4;
  border-radius: 12px;
  background: #ffffff;
  box-shadow: 0 18px 42px rgba(15, 23, 42, 0.08);
}

.auth-illustration {
  position: relative;
  width: min(220px, 72vw);
  height: 136px;
  justify-self: center;
  display: grid;
  place-items: center;
}

.auth-illustration-orbit {
  width: 164px;
  height: 92px;
  border: 1px solid #d8e5ff;
  border-radius: 18px;
  background:
    linear-gradient(90deg, rgba(27, 132, 255, 0.08) 1px, transparent 1px),
    linear-gradient(180deg, rgba(27, 132, 255, 0.08) 1px, transparent 1px);
  background-size: 18px 18px;
}

.auth-illustration-card {
  position: absolute;
  display: grid;
  gap: 2px;
  min-width: 98px;
  padding: 10px 12px;
  border: 1px solid #e6e9f0;
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.94);
  box-shadow: 0 12px 28px rgba(15, 23, 42, 0.12);
  font-style: normal;
}

.auth-illustration-card span {
  width: 22px;
  height: 3px;
  border-radius: 999px;
  background: #1b84ff;
}

.auth-illustration-card strong {
  color: #111827;
  font-size: 11px;
}

.auth-illustration-card em {
  color: #17c653;
  font-size: 11px;
  font-style: normal;
  font-weight: 700;
}

.auth-illustration-card-main {
  left: 10px;
  top: 18px;
}

.auth-illustration-card-sub {
  right: 6px;
  bottom: 14px;
}

.auth-illustration-card-sub span {
  background: #f6c000;
}

.auth-card-head {
  display: grid;
  gap: 7px;
  text-align: center;
}

.auth-card h1 {
  margin: 0;
  color: #111827;
  font-size: 22px;
  font-weight: 700;
  white-space: normal;
}

.auth-card-head p {
  margin: 0;
  color: #78829d;
  font-size: 11px;
  line-height: 1.6;
}

.auth-field {
  display: grid;
  gap: 8px;
}

.auth-field label {
  color: #252f4a;
  font-size: 11px;
  font-weight: 600;
}

.auth-field input {
  width: 100%;
  height: 42px;
  border: 1px solid #dbdfe9;
  border-radius: 8px;
  background: #ffffff;
  color: #111827;
  padding: 0 13px;
  outline: none;
  transition: border-color 0.15s ease, box-shadow 0.15s ease;
}

.auth-field input:focus {
  border-color: #1b84ff;
  box-shadow: 0 0 0 3px rgba(27, 132, 255, 0.13);
}

.auth-submit {
  width: 100%;
  height: 42px;
  margin-top: 2px;
  border-radius: 8px;
  font-weight: 700;
}

.auth-card .hint {
  min-height: 16px;
  margin: 0;
  color: #f8285a;
  text-align: center;
}

@media (max-width: 520px) {
  .auth-screen {
    padding: 18px;
  }

  .auth-shell {
    gap: 18px;
  }

  .auth-card {
    padding: 28px 22px 30px;
  }

  .auth-illustration {
    height: 118px;
  }

  .auth-card h1 {
    font-size: 20px;
  }
}

.topbar {
  min-height: 70px;
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 16px;
  padding-bottom: 0;
  border-bottom: 1px solid #f1f1f4;
  background: transparent;
}

.topbar-search {
  width: min(360px, 42vw);
  height: 36px;
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 0 12px;
  border-radius: 8px;
  background: #f5f5f7;
  color: #86868b;
}

.topbar-search-icon {
  position: relative;
  width: 14px;
  height: 14px;
  flex: 0 0 auto;
  border: 2px solid currentColor;
  border-radius: 50%;
}

.topbar-search-icon::after {
  content: "";
  position: absolute;
  right: -5px;
  bottom: -4px;
  width: 6px;
  height: 2px;
  border-radius: 999px;
  background: currentColor;
  transform: rotate(45deg);
}

.topbar-search input {
  height: 100%;
  padding: 0;
  border: 0;
  border-radius: 0;
  background: transparent;
  box-shadow: none;
}

.topbar-search input:focus {
  border-color: transparent;
  box-shadow: none;
}

.account-actions {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 12px;
  color: #4b5675;
}

.topbar-greeting {
  max-width: min(560px, 52vw);
  overflow: visible;
  white-space: nowrap;
  color: #78829d;
  font-size: 11px;
  font-weight: 500;
}

.account-actions button {
  padding: 0;
}

.topbar-tool,
.language-select {
  color: #4b5675;
}

.topbar-tool {
  position: relative;
  width: 36px;
  height: 36px;
  display: inline-grid;
  place-items: center;
  flex: 0 0 auto;
  padding: 0;
  border: 0;
  border-radius: 50%;
  background: transparent;
}

.topbar-tool:hover:not(:disabled) {
  transform: none;
  background: #eff6ff;
  color: #1b84ff;
}

.icon-search,
.icon-apps,
.icon-bell,
.icon-chat,
.icon-logout {
  position: relative;
  width: 18px;
  height: 18px;
  display: block;
  color: currentColor;
}

.icon-search::before {
  content: "";
  position: absolute;
  left: 2px;
  top: 2px;
  width: 10px;
  height: 10px;
  border: 2px solid currentColor;
  border-radius: 50%;
}

.icon-search::after {
  content: "";
  position: absolute;
  right: 2px;
  bottom: 3px;
  width: 7px;
  height: 2px;
  border-radius: 999px;
  background: currentColor;
  transform: rotate(45deg);
}

.icon-apps::before {
  content: "";
  position: absolute;
  left: 3px;
  top: 3px;
  width: 4px;
  height: 4px;
  border-radius: 1px;
  background: currentColor;
  box-shadow: 8px 0 0 currentColor, 0 8px 0 currentColor, 8px 8px 0 currentColor;
}

.icon-bell::before {
  content: "";
  position: absolute;
  left: 5px;
  top: 2px;
  width: 8px;
  height: 10px;
  border: 2px solid currentColor;
  border-bottom: 0;
  border-radius: 8px 8px 3px 3px;
}

.icon-bell::after {
  content: "";
  position: absolute;
  left: 7px;
  bottom: 2px;
  width: 4px;
  height: 2px;
  border-radius: 999px;
  background: currentColor;
}

.icon-chat::before {
  content: "";
  position: absolute;
  left: 2px;
  top: 3px;
  width: 14px;
  height: 11px;
  border: 2px solid currentColor;
  border-radius: 8px;
}

.icon-chat::after {
  content: "";
  position: absolute;
  left: 7px;
  bottom: 1px;
  width: 5px;
  height: 5px;
  border-left: 2px solid currentColor;
  border-bottom: 2px solid currentColor;
  transform: rotate(-32deg);
}

.icon-logout::before {
  content: "";
  position: absolute;
  left: 3px;
  top: 5px;
  width: 12px;
  height: 12px;
  border: 2px solid currentColor;
  border-top-color: transparent;
  border-radius: 50%;
}

.icon-logout::after {
  content: "";
  position: absolute;
  left: 8px;
  top: 2px;
  width: 2px;
  height: 8px;
  border-radius: 999px;
  background: currentColor;
}

.user-avatar {
  width: 36px;
  height: 36px;
  display: inline-grid;
  place-items: center;
  flex: 0 0 auto;
  border: 2px solid #22c55e;
  border-radius: 50%;
  background: #eff6ff;
  color: #1b84ff;
  font-weight: 800;
  text-transform: uppercase;
  cursor: pointer;
  background-position: center;
  background-size: cover;
}

.user-avatar:hover {
  background: #eff6ff;
  color: #1b84ff;
  box-shadow: 0 0 0 4px rgba(27, 132, 255, 0.1);
}

.user-menu {
  position: absolute;
  top: calc(100% + 12px);
  right: 0;
  z-index: 60;
  width: 260px;
  overflow: hidden;
  border: 1px solid #e5e7eb;
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.96);
  color: #252f4a;
  box-shadow: 0 22px 48px rgba(15, 23, 42, 0.14);
  backdrop-filter: blur(18px);
}

.user-menu::before {
  content: "";
  position: absolute;
  top: -6px;
  right: 22px;
  width: 12px;
  height: 12px;
  border-left: 1px solid #e5e7eb;
  border-top: 1px solid #e5e7eb;
  background: rgba(255, 255, 255, 0.96);
  transform: rotate(45deg);
}

.user-menu-head {
  position: relative;
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 20px 16px 18px;
  border-bottom: 1px solid #eef0f5;
}

.user-menu-avatar {
  width: 38px;
  height: 38px;
  display: inline-grid;
  place-items: center;
  flex: 0 0 auto;
  border: 2px solid #22c55e;
  border-radius: 50%;
  background: #1b84ff;
  color: #ffffff;
  font-weight: 800;
  background-position: center;
  background-size: cover;
}

.user-avatar.has-image,
.user-menu-avatar.has-image {
  color: transparent;
  text-indent: -999px;
}

.user-menu-copy {
  min-width: 0;
  display: grid;
  gap: 3px;
}

.user-menu-copy strong {
  overflow: hidden;
  color: #252f4a;
  font-size: 13px;
  font-weight: 700;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.user-menu-copy small {
  overflow: hidden;
  color: #78829d;
  font-size: 11px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.user-menu-badge {
  margin-left: auto;
  padding: 4px 9px;
  border-radius: 5px;
  background: rgba(27, 132, 255, 0.32);
  color: #73b5ff;
  font-size: 10px;
  font-weight: 700;
}

.user-menu-list {
  display: grid;
  padding: 7px 0;
}

.user-menu-item {
  width: 100%;
  min-height: 36px;
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 0 16px;
  border: 0;
  border-radius: 0;
  background: transparent;
  color: #252f4a;
  font-size: 13px;
  font-weight: 600;
  text-align: left;
}

.user-menu-item:hover {
  transform: none;
  background: #f5f8ff;
  color: #1b84ff;
}

.user-menu-icon {
  position: relative;
  width: 16px;
  height: 16px;
  flex: 0 0 16px;
  color: #4b5675;
}

.user-menu-icon::before,
.user-menu-icon::after,
.user-menu-arrow::before {
  content: "";
  position: absolute;
  box-sizing: border-box;
}

.menu-icon-profile::before {
  inset: 2px;
  border: 1.7px solid currentColor;
  border-radius: 3px;
}

.menu-icon-profile::after {
  left: 5px;
  top: 5px;
  width: 6px;
  height: 6px;
  border: 1.7px solid currentColor;
  border-radius: 50%;
}

.menu-icon-account::before {
  left: 5px;
  top: 2px;
  width: 6px;
  height: 6px;
  border: 1.7px solid currentColor;
  border-radius: 50%;
}

.menu-icon-account::after {
  left: 3px;
  bottom: 2px;
  width: 10px;
  height: 6px;
  border: 1.7px solid currentColor;
  border-radius: 8px 8px 2px 2px;
}

.menu-icon-language::before {
  inset: 1px;
  border: 1.7px solid currentColor;
  border-radius: 50%;
}

.menu-icon-language::after {
  left: 7px;
  top: 2px;
  width: 2px;
  height: 12px;
  border-radius: 999px;
  background: currentColor;
  box-shadow: -5px 5px 0 -4px currentColor, 5px 5px 0 -4px currentColor;
}

.menu-icon-dark::before {
  inset: 2px;
  border-radius: 50%;
  border: 1.7px solid currentColor;
  box-shadow: inset -5px 0 0 currentColor;
}

.user-menu-arrow {
  position: relative;
  width: 12px;
  height: 12px;
  margin-left: auto;
  color: #9ca3af;
}

.user-menu-arrow::before {
  left: 3px;
  top: 2px;
  width: 7px;
  height: 7px;
  border-right: 1.8px solid currentColor;
  border-top: 1.8px solid currentColor;
  transform: rotate(45deg);
}

.user-menu-language select {
  margin-left: auto;
  max-width: 92px;
  padding: 5px 24px 5px 9px;
  border: 1px solid #dbdfe9;
  border-radius: 7px;
  background: #ffffff;
  color: #252f4a;
  font-size: 11px;
  font-weight: 600;
}

.user-menu-switch {
  position: relative;
  width: 34px;
  height: 20px;
  margin-left: auto;
}

.user-menu-switch input {
  position: absolute;
  inset: 0;
  opacity: 0;
  cursor: pointer;
}

.user-menu-switch span {
  position: absolute;
  inset: 0;
  border-radius: 999px;
  background: #d1d5db;
  transition: background 0.18s ease;
}

.user-menu-switch span::before {
  content: "";
  position: absolute;
  top: 2px;
  left: 2px;
  width: 16px;
  height: 16px;
  border-radius: 50%;
  background: #ffffff;
  transition: transform 0.18s ease;
}

.user-menu-switch input:checked + span {
  background: #1b84ff;
}

.user-menu-switch input:checked + span::before {
  transform: translateX(14px);
}

.user-menu-logout {
  width: calc(100% - 32px);
  height: 34px;
  margin: 8px 16px 14px;
  border: 1px solid #dbdfe9;
  border-radius: 6px;
  background: transparent;
  color: #252f4a;
  font-size: 12px;
  font-weight: 700;
}

.user-menu-logout:hover:not(:disabled) {
  transform: none;
  border-color: rgba(248, 40, 90, 0.55);
  background: rgba(248, 40, 90, 0.12);
  color: #ff6b8d;
}

body.dark-mode .user-menu {
  border-color: rgba(255, 255, 255, 0.1);
  background: #09090b;
  color: #f9fafb;
  box-shadow: 0 22px 48px rgba(0, 0, 0, 0.28);
}

body.dark-mode .user-menu::before {
  border-left-color: rgba(255, 255, 255, 0.1);
  border-top-color: rgba(255, 255, 255, 0.1);
  background: #09090b;
}

body.dark-mode .user-menu-head {
  border-bottom-color: rgba(255, 255, 255, 0.08);
}

body.dark-mode .user-menu-copy strong,
body.dark-mode .user-menu-item,
body.dark-mode .user-menu-logout {
  color: #f9fafb;
}

body.dark-mode .user-menu-copy small,
body.dark-mode .user-menu-arrow {
  color: #9ca3af;
}

body.dark-mode .user-menu-icon {
  color: #d1d5db;
}

body.dark-mode .user-menu-item:hover {
  background: rgba(255, 255, 255, 0.06);
  color: #ffffff;
}

body.dark-mode .user-menu-language select {
  border-color: rgba(255, 255, 255, 0.16);
  background: #111318;
  color: #f9fafb;
}

body.dark-mode .user-menu-switch span {
  background: #3f3f46;
}

body.dark-mode .user-menu-logout {
  border-color: rgba(255, 255, 255, 0.16);
}

body.dark-mode .app-sidebar,
body.dark-mode .sidebar-footer,
body.dark-mode .topbar {
  background: #09090b;
  border-color: #1f2937;
}

body.dark-mode .sidebar-logo-copy strong,
body.dark-mode .section-title h2,
body.dark-mode .hero h1,
body.dark-mode h1,
body.dark-mode h2,
body.dark-mode h3,
body.dark-mode label {
  color: #f9fafb;
}

body.dark-mode .sidebar-logo-copy small,
body.dark-mode .topbar-greeting,
body.dark-mode .subhead,
body.dark-mode .hint,
body.dark-mode .sidebar-powered {
  color: #9ca3af;
}

body.dark-mode .topbar-search,
body.dark-mode input,
body.dark-mode select,
body.dark-mode textarea,
body.dark-mode .ads-metric-card,
body.dark-mode .panel,
body.dark-mode .side-panel,
body.dark-mode .video-list,
body.dark-mode .system-panel,
body.dark-mode .system-tabs,
body.dark-mode .user-form,
body.dark-mode .shop-form,
body.dark-mode .auth-card {
  border-color: #1f2937;
  background: #111318;
  color: #f9fafb;
}

body.dark-mode .shop-auth-guide,
body.dark-mode .shop-auth-guide button {
  border-color: #252b36;
  background: #111318;
  color: #f9fafb;
}

body.dark-mode .shop-auth-guide-main span {
  color: #9ca3af;
}

body.dark-mode .shop-auth-guide-main strong {
  color: #f9fafb;
}

body.dark-mode .system-tab {
  color: #d1d5db;
}

body.dark-mode .system-tab:hover {
  background: rgba(27, 132, 255, 0.14);
  color: #73b5ff;
}

body.dark-mode .user-avatar-upload {
  border-color: #273244;
  background: rgba(17, 24, 39, 0.74);
}

body.dark-mode .user-avatar-upload-copy strong {
  color: #f9fafb;
}

body.dark-mode .user-avatar-upload-copy small {
  color: #9ca3af;
}

body.dark-mode .system-tab.active {
  background: #0f3a78;
  color: #ffffff;
}

body.dark-mode .auth-screen {
  background: #080b10;
}

body.dark-mode .auth-brand-row,
body.dark-mode .auth-card h1,
body.dark-mode .auth-field label,
body.dark-mode .auth-illustration-card strong {
  color: #f9fafb;
}

body.dark-mode .auth-logo-mark {
  box-shadow: 0 10px 22px rgba(27, 132, 255, 0.2);
}

body.dark-mode .auth-card-head p {
  color: #99a1b7;
}

body.dark-mode .auth-illustration-orbit {
  border-color: #26334b;
  background:
    linear-gradient(90deg, rgba(83, 168, 255, 0.12) 1px, transparent 1px),
    linear-gradient(180deg, rgba(83, 168, 255, 0.12) 1px, transparent 1px);
  background-size: 18px 18px;
}

body.dark-mode .auth-illustration-card {
  border-color: #26334b;
  background: #151922;
  box-shadow: 0 12px 28px rgba(0, 0, 0, 0.28);
}

body.dark-mode .auth-field input {
  border-color: #26334b;
  background: #0d1119;
  color: #f9fafb;
}

body.dark-mode .nav-item {
  color: #d1d5db;
}

body.dark-mode .nav-item:hover:not(:disabled) {
  color: #73b5ff;
}

body.dark-mode .nav-item.active {
  background: rgba(27, 132, 255, 0.16);
  color: #73b5ff;
}

body.dark-mode table,
body.dark-mode th,
body.dark-mode td {
  border-color: #1f2937;
}

.logout-tool {
  color: #99a1b7;
}

.logout-tool:hover:not(:disabled) {
  background: #fff1f4;
  color: #f8285a;
}

.language-select {
  width: 100%;
  min-width: 112px;
  max-width: 100%;
  padding: 0.58rem 0.8rem;
  background: rgba(255, 255, 255, 0.88);
}

.icon-button {
  width: 38px;
  height: 38px;
  display: inline-grid;
  place-items: center;
  padding: 0;
  border-radius: 50%;
  font-size: 1.08rem;
  line-height: 1;
}

.app-layout {
  --sidebar-default-width: 224px;
  --sidebar-width: 224px;
  --sidebar-width-collapse: 80px;
  --sidebar-transition-duration: 0.3s;
  --sidebar-transition-timing: ease;
  --header-height: 70px;
  min-height: 100vh;
  display: grid;
  grid-template-columns: var(--sidebar-width) minmax(0, 1fr);
  transition: grid-template-columns var(--sidebar-transition-duration) var(--sidebar-transition-timing);
}

.app-layout.sidebar-collapsed {
  --sidebar-width: var(--sidebar-width-collapse);
}

.app-sidebar {
  position: sticky;
  top: 0;
  z-index: 20;
  width: var(--sidebar-width);
  height: 100vh;
  padding: 0;
  display: flex;
  flex-direction: column;
  overflow: visible;
  background: #ffffff;
  border-right: 1px solid #f1f1f4;
  transition: width var(--sidebar-transition-duration) var(--sidebar-transition-timing);
}

.app-layout.sidebar-collapsed .app-sidebar:hover {
  width: var(--sidebar-default-width);
  box-shadow: 16px 0 36px rgba(15, 23, 42, 0.08);
}

.sidebar-header {
  position: relative;
  height: var(--header-height);
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex: 0 0 auto;
  padding: 0 12px;
}

.sidebar-scroll {
  min-height: 0;
  flex: 1;
  overflow-x: hidden;
  overflow-y: auto;
  padding: 20px;
  scrollbar-width: thin;
  scrollbar-color: transparent transparent;
}

.sidebar-scroll:hover {
  scrollbar-color: #c4cada transparent;
}

.sidebar-logo {
  min-width: 0;
  display: flex;
  align-items: center;
  gap: 8px;
  color: inherit;
  text-decoration: none;
}

.sidebar-logo-mark {
  width: 32px;
  height: 32px;
  display: inline-grid;
  place-items: center;
  flex: 0 0 auto;
  border-radius: 9px;
  background: #f8285a;
  color: #fff;
  font-size: 1.18rem;
  font-weight: 800;
  letter-spacing: 0;
  box-shadow: 0 8px 18px rgba(248, 40, 90, 0.18);
}

.sidebar-logo-copy {
  min-width: 0;
  display: grid;
  gap: 3px;
}

.sidebar-logo-copy strong {
  color: #252f4a;
  font-size: 13px;
  font-weight: 700;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.sidebar-logo-copy small {
  color: #99a1b7;
  font-size: 10px;
  letter-spacing: 0;
}

.sidebar-toggle {
  position: absolute;
  top: 50%;
  left: 100%;
  width: 28px;
  height: 28px;
  display: inline-grid;
  place-items: center;
  padding: 0;
  border: 1px solid #dbdfe9;
  border-radius: 8px;
  background: #ffffff;
  color: #4b5675;
  box-shadow: 0 4px 12px rgba(15, 23, 42, 0.08);
  transform: translate(-50%, -50%);
}

.sidebar-toggle:hover:not(:disabled) {
  transform: translate(-50%, -50%);
  border-color: #bcd7ff;
  background: #f7fbff;
  color: #1b84ff;
}

.sidebar-toggle span {
  position: relative;
  width: 11px;
  height: 11px;
  display: block;
}

.sidebar-toggle span::before,
.sidebar-toggle span::after {
  content: "";
  position: absolute;
  top: 1px;
  width: 7px;
  height: 7px;
  border-top: 2px solid currentColor;
  border-left: 2px solid currentColor;
  transform: rotate(-45deg);
}

.sidebar-toggle span::before {
  left: 0;
}

.sidebar-toggle span::after {
  left: 5px;
}

.app-layout.sidebar-collapsed .sidebar-toggle span {
  transform: rotate(180deg);
}

.sidebar-nav {
  display: grid;
  gap: 3px;
}

.sidebar-footer {
  margin-top: auto;
  padding: 14px 20px 18px;
  background: #ffffff;
}

.sidebar-powered {
  display: block;
  color: #99a1b7;
  font-size: 11px;
  font-weight: 600;
  text-align: center;
  white-space: nowrap;
}

.nav-item {
  width: 100%;
  height: 32px;
  display: flex;
  align-items: center;
  gap: 9px;
  border-radius: 6px;
  padding: 0 10px;
  background: transparent;
  color: #4b5675;
  font-size: 13px;
  text-align: left;
  font-weight: 500;
  white-space: nowrap;
  transition: background 0.18s ease, color 0.18s ease;
}

.nav-item:hover:not(:disabled) {
  transform: none;
  background: transparent;
  color: #1b84ff;
}

.nav-item.active {
  background: #f1f5ff;
  color: #1b84ff;
  font-weight: 600;
}

.nav-item.active:hover:not(:disabled) {
  background: #f1f5ff;
  color: #1b84ff;
}

.nav-icon {
  position: relative;
  width: 18px;
  height: 18px;
  display: inline-block;
  flex: 0 0 18px;
  color: currentColor;
  opacity: 0.88;
}

.nav-icon::before,
.nav-icon::after {
  content: "";
  position: absolute;
  box-sizing: border-box;
}

.nav-icon-dashboard::before {
  left: 2px;
  top: 2px;
  width: 5px;
  height: 5px;
  border-radius: 2px;
  background: currentColor;
  box-shadow: 9px 0 0 currentColor, 0 9px 0 currentColor, 9px 9px 0 currentColor;
}

.nav-icon-orders::before {
  inset: 2px 3px;
  border: 1.8px solid currentColor;
  border-radius: 4px;
}

.nav-icon-orders::after {
  left: 6px;
  top: 7px;
  width: 7px;
  height: 1.6px;
  border-radius: 999px;
  background: currentColor;
  box-shadow: 0 4px 0 currentColor;
}

.nav-icon-ads::before {
  left: 2px;
  bottom: 3px;
  width: 14px;
  height: 10px;
  border-left: 1.8px solid currentColor;
  border-bottom: 1.8px solid currentColor;
  border-radius: 0 0 0 3px;
}

.nav-icon-ads::after {
  left: 5px;
  top: 5px;
  width: 10px;
  height: 7px;
  border-top: 2px solid currentColor;
  border-right: 2px solid currentColor;
  transform: skew(-18deg) rotate(-12deg);
}

.nav-icon-capture::before {
  left: 2px;
  top: 5px;
  width: 14px;
  height: 10px;
  border: 1.8px solid currentColor;
  border-radius: 4px;
}

.nav-icon-capture::after {
  left: 7px;
  top: 8px;
  width: 4px;
  height: 4px;
  border: 1.6px solid currentColor;
  border-radius: 50%;
}

.nav-icon-claims::before {
  left: 4px;
  top: 2px;
  width: 10px;
  height: 13px;
  border: 1.8px solid currentColor;
  border-radius: 6px 6px 7px 7px;
  transform: perspective(20px) rotateX(12deg);
}

.nav-icon-claims::after {
  left: 7px;
  top: 6px;
  width: 5px;
  height: 8px;
  border-right: 1.8px solid currentColor;
  border-bottom: 1.8px solid currentColor;
  transform: rotate(35deg);
}

.nav-icon-system::before {
  left: 3px;
  top: 3px;
  width: 12px;
  height: 12px;
  border: 2px solid currentColor;
  border-radius: 50%;
}

.nav-icon-system::after {
  left: 8px;
  top: 0;
  width: 2px;
  height: 18px;
  border-radius: 999px;
  background: currentColor;
  box-shadow: 0 0 0 0 currentColor;
}

.app-layout.sidebar-collapsed .app-sidebar:not(:hover) .sidebar-logo-copy,
.app-layout.sidebar-collapsed .app-sidebar:not(:hover) .nav-item [data-slot='accordion-menu-title'],
.app-layout.sidebar-collapsed .app-sidebar:not(:hover) .sidebar-footer {
  display: none;
}

.app-layout.sidebar-collapsed .app-sidebar:not(:hover) .sidebar-header {
  justify-content: center;
  padding: 0;
}

.app-layout.sidebar-collapsed .app-sidebar:not(:hover) .sidebar-scroll {
  padding-inline: 20px;
}

.app-layout.sidebar-collapsed .app-sidebar:not(:hover) .nav-item {
  justify-content: center;
  padding: 0;
}

.page-view[hidden] {
  display: none;
}

.dashboard-panel {
  margin-top: 18px;
}

.dashboard-control-bar {
  display: grid;
  gap: 14px;
  margin-bottom: 14px;
}

.dashboard-control-main {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
}

.dashboard-view-switch {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 4px;
  border: 1px solid #dbdfe9;
  border-radius: 8px;
  background: #ffffff;
}

.dashboard-view-button {
  height: 30px;
  padding: 0 13px;
  border: 0;
  border-radius: 6px;
  background: transparent;
  color: #4b5563;
  font-size: 11px;
  font-weight: 700;
  cursor: pointer;
}

.dashboard-view-button:hover {
  color: #1b4f9c;
  background: #eff6ff;
}

.dashboard-view-button.active {
  color: #ffffff;
  background: #0f3a78;
}

.dashboard-filter-row {
  display: flex;
  align-items: flex-start;
  flex-wrap: wrap;
  gap: 10px;
}

.dashboard-filter-field {
  min-width: 138px;
  display: grid;
  grid-template-rows: 14px 36px;
  align-items: start;
  gap: 6px;
}

.dashboard-filter-field > span {
  display: block;
  color: #6b7280;
  font-size: 11px;
  font-weight: 600;
  line-height: 14px;
}

.dashboard-filter-field select {
  height: 36px;
  min-width: 0;
  border-radius: 8px;
}

.dashboard-date-field {
  min-width: 198px;
}

.dashboard-date-field .section-title-actions,
.dashboard-date-field .date-range-control {
  width: 100%;
}

.dashboard-date-field .section-title-actions {
  height: 36px;
}

.dashboard-date-field .date-range-control {
  height: 36px;
  min-height: 36px;
  border-radius: 8px;
  justify-content: flex-start;
}

.orders-page {
  display: grid;
  gap: 18px;
  margin-top: 18px;
}

.order-filter-row {
  display: flex;
  align-items: flex-start;
  flex-wrap: wrap;
  gap: 10px;
}

.order-filter-field {
  min-width: 138px;
}

.order-store-filter {
  min-width: 230px;
}

.order-date-filter {
  min-width: 210px;
}

.order-date-filter .section-title-actions {
  height: 36px;
  width: 100%;
}

.order-date-filter .date-range-control {
  width: 100%;
  height: 36px;
  min-height: 36px;
  border-radius: 8px;
  justify-content: flex-start;
}

.dashboard-stat-strip {
  display: grid;
  grid-template-columns: repeat(6, minmax(0, 1fr));
  align-items: stretch;
  min-height: 154px;
  overflow: hidden;
  border: 1px solid #e5e7eb;
  border-radius: 8px;
  background: #ffffff;
  box-shadow: 0 1px 2px rgba(15, 23, 42, 0.04);
}

.dashboard-stat-item {
  min-width: 0;
  display: grid;
  justify-items: center;
  gap: 7px;
  padding: 20px 12px 18px;
  text-align: center;
  align-content: center;
}

.dashboard-stat-item + .dashboard-stat-item {
  border-left: 1px solid #e5e7eb;
}

.dashboard-stat-item strong {
  color: #000000;
  max-width: 100%;
  overflow: hidden;
  font-size: clamp(17px, 1.55vw, 25px);
  font-weight: 800;
  line-height: 1;
  letter-spacing: 0;
  text-overflow: clip;
  white-space: nowrap;
}

.dashboard-money-line {
  width: 100%;
  min-width: 0;
  display: grid;
  justify-items: center;
  gap: 5px;
  white-space: nowrap;
}

.dashboard-money-line strong,
.dashboard-money-line em {
  display: block;
  max-width: 100%;
  min-width: 0;
  overflow: visible;
  text-align: center;
  text-overflow: clip;
  white-space: nowrap;
}

.dashboard-money-line .fit-text {
  --fit-font-size: clamp(17px, 1.55vw, 25px);
  font-size: var(--fit-font-size);
}

.dashboard-cny-value {
  max-width: 100%;
  overflow: hidden;
  color: #000000;
  font-size: clamp(17px, 1.55vw, 25px);
  font-style: normal;
  font-weight: 800;
  line-height: 1;
  text-overflow: clip;
  white-space: nowrap;
}

.dashboard-stat-item span {
  color: #111827;
  font-size: 13px;
  line-height: 1.2;
  white-space: nowrap;
}

.dashboard-trend {
  min-height: 34px;
  display: grid;
  justify-items: center;
  align-content: center;
  gap: 4px;
  color: #6b7280;
  font-size: 11px;
  line-height: 1.15;
  white-space: nowrap;
}

.dashboard-trend-line {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 4px;
  font-weight: 700;
}

.dashboard-trend-arrow {
  width: 14px;
  height: 14px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  line-height: 0;
}

.dashboard-trend-arrow svg {
  display: block;
  width: 14px;
  height: 14px;
}

.dashboard-trend-arrow circle {
  fill: #16a34a;
}

.dashboard-trend-arrow path {
  fill: #ffffff;
  stroke: none;
}

.dashboard-trend-line strong {
  font-size: 11px;
  font-weight: 800;
  line-height: 1;
}

.dashboard-trend.trend-up .dashboard-trend-line {
  color: #16a34a;
}

.dashboard-trend.trend-up .dashboard-trend-arrow {
  background: transparent;
}

.dashboard-trend.trend-up .dashboard-trend-arrow circle {
  fill: #16a34a;
}

.dashboard-trend.trend-down .dashboard-trend-line {
  color: #dc2626;
}

.dashboard-trend.trend-down .dashboard-trend-arrow {
  background: transparent;
}

.dashboard-trend.trend-down .dashboard-trend-arrow circle {
  fill: #ef4444;
}

.dashboard-trend-history {
  color: #6b7280;
  font-weight: 500;
}

.dashboard-chart-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px;
  margin-top: 16px;
}

.dashboard-chart-card {
  min-width: 0;
  border: 1px solid #e5e7eb;
  border-radius: 8px;
  background: #ffffff;
  padding: 16px 16px 14px;
  box-shadow: 0 1px 2px rgba(15, 23, 42, 0.04);
}

.dashboard-chart-head {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 12px;
  margin-bottom: 10px;
}

.dashboard-chart-head h3 {
  margin: 0;
  color: #111827;
  font-size: 14px;
  font-weight: 700;
  line-height: 1.2;
}

.dashboard-chart-head span {
  color: #6b7280;
  font-size: 11px;
  line-height: 1.2;
  white-space: nowrap;
}

.dashboard-chart-canvas {
  min-height: 324px;
}

.dashboard-chart-legend {
  min-height: 20px;
  display: flex;
  align-items: center;
  justify-content: flex-start;
  gap: 12px;
  margin-bottom: 4px;
  color: #374151;
  font-size: 11px;
  line-height: 1.2;
}

.dashboard-chart-legend-item {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  min-width: 0;
}

.dashboard-chart-legend-item span {
  width: 8px;
  height: 8px;
  flex: 0 0 auto;
  border-radius: 999px;
  background: var(--series-color);
}

.dashboard-chart-svg {
  width: 100%;
  height: 286px;
  display: block;
}

.dashboard-chart-plot-bg {
  fill: #ffffff;
}

.dashboard-chart-grid-line {
  stroke: #e5e7eb;
  stroke-dasharray: 6 6;
  stroke-width: 1;
}

.dashboard-chart-axis-label,
.dashboard-chart-x-label {
  fill: #6b7280;
  font-size: 11px;
  line-height: 1;
}

.dashboard-chart-axis-label.right {
  fill: #6b7280;
}

.dashboard-chart-line {
  fill: none;
  stroke: var(--series-color);
  stroke-width: 3;
  stroke-linecap: round;
  stroke-linejoin: round;
  pointer-events: none;
}

.dashboard-chart-area {
  fill: var(--series-color);
  opacity: 0.1;
  pointer-events: none;
}

.dashboard-chart-hover-zone {
  fill: transparent;
  cursor: crosshair;
}

.dashboard-chart-hover-detail {
  opacity: 0;
  pointer-events: none;
  transition: opacity 140ms ease;
}

.dashboard-chart-hover-target:hover .dashboard-chart-hover-detail {
  opacity: 1;
}

.dashboard-chart-hover-line {
  stroke: #94a3b8;
  stroke-dasharray: 4 4;
  stroke-width: 1;
}

.dashboard-chart-hover-dot {
  fill: #ffffff;
  stroke: var(--series-color);
  stroke-width: 2.5;
}

.dashboard-chart-tooltip-bg {
  fill: #ffffff;
  stroke: #e5e7eb;
  stroke-width: 1;
  filter: drop-shadow(0 8px 18px rgba(15, 23, 42, 0.14));
}

.dashboard-chart-tooltip-title {
  fill: #111827;
  font-size: 12px;
  font-weight: 700;
}

.dashboard-chart-tooltip-row {
  fill: #374151;
  font-size: 10px;
  font-weight: 700;
}

.dashboard-chart-tooltip-value {
  fill: #111827;
  font-size: 11px;
  font-weight: 800;
}

.dashboard-chart-empty {
  min-height: 286px;
  display: grid;
  place-items: center;
  color: #6b7280;
  font-size: 12px;
}

.dashboard-chart-options {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 10px;
}

.dashboard-chart-option {
  min-height: 30px;
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 0 10px;
  border: 1px solid #dbdfe9;
  border-radius: 6px;
  background: #ffffff;
  color: #252f4a;
  font-size: 11px;
  font-weight: 600;
  line-height: 1;
  cursor: pointer;
  user-select: none;
}

.dashboard-chart-option input {
  width: 13px;
  height: 13px;
  margin: 0;
  accent-color: #1b84ff;
}

.dashboard-chart-option-dot {
  width: 7px;
  height: 7px;
  border-radius: 999px;
  background: var(--series-color);
}

.dashboard-chart-option.selected {
  border-color: #1b84ff;
  background: #f5f8ff;
  color: #1b4f9c;
}

.dashboard-chart-option.disabled {
  cursor: not-allowed;
  opacity: 0.38;
}

.dashboard-detail-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 16px;
  margin-top: 16px;
}

.dashboard-detail-card {
  min-width: 0;
  border: 1px solid #e5e7eb;
  border-radius: 8px;
  background: #ffffff;
  box-shadow: 0 1px 2px rgba(15, 23, 42, 0.04);
}

.dashboard-detail-head {
  min-height: 54px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 14px 16px;
  border-bottom: 1px solid #e5e7eb;
}

.dashboard-detail-head h3 {
  margin: 0;
  color: #111827;
  font-size: 14px;
  font-weight: 800;
}

.dashboard-detail-head span {
  color: #6b7280;
  font-size: 11px;
  font-weight: 600;
}

.dashboard-link-trend-options {
  display: flex;
  align-items: center;
  justify-content: flex-start;
  flex-wrap: wrap;
  gap: 8px;
  min-width: 0;
  margin-top: 0;
  padding: 0 16px 16px;
}

.dashboard-link-trend-options .dashboard-chart-option {
  white-space: nowrap;
}

.dashboard-link-trend-options .dashboard-chart-option span:not(.dashboard-chart-option-dot) {
  color: inherit;
  font-size: inherit;
  font-weight: inherit;
}

.dashboard-ranking-table-wrap {
  overflow-x: auto;
}

.dashboard-ranking-table {
  width: 100%;
  border-collapse: collapse;
  min-width: 1120px;
}

.dashboard-ranking-table th,
.dashboard-ranking-table td {
  padding: 13px 16px;
  border-bottom: 1px solid #eef0f4;
  color: #252f4a;
  font-size: 11px;
  text-align: left;
  white-space: nowrap;
}

.dashboard-ranking-table th {
  color: #6b7280;
  font-weight: 800;
  background: #fbfbfd;
}

.dashboard-sort-button {
  width: 100%;
  display: inline-flex;
  align-items: center;
  justify-content: flex-start;
  gap: 5px;
  padding: 0;
  border: 0;
  border-radius: 0;
  background: transparent;
  color: inherit;
  font: inherit;
  font-weight: 800;
  cursor: pointer;
}

.dashboard-ranking-table th .dashboard-sort-button:hover:not(:disabled),
.dashboard-ranking-table th .dashboard-sort-button:focus-visible {
  transform: none;
  background: transparent;
  box-shadow: none;
  color: #1b84ff;
}

.dashboard-sort-button.active {
  color: #1b4f9c;
}

.dashboard-sort-indicator {
  color: #9ca3af;
  font-size: 10px;
  line-height: 1;
}

.dashboard-sort-button.active .dashboard-sort-indicator {
  color: currentColor;
}

.dashboard-metric-cell {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  min-width: 0;
}

.dashboard-metric-cell > span {
  font-variant-numeric: tabular-nums;
}

.dashboard-mini-trend {
  --trend-color: #16a34a;
  display: inline-flex;
  flex: 0 0 29px;
  align-items: center;
  width: 29px;
  height: 10px;
}

.dashboard-mini-trend.down {
  --trend-color: #ef4444;
}

.dashboard-mini-trend svg {
  display: block;
  width: 29px;
  height: 10px;
  overflow: visible;
}

.dashboard-mini-trend path {
  fill: none;
  stroke: var(--trend-color);
  stroke-width: 1.35;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.dashboard-trend-dot {
  --trend-dot-color: #16a34a;
  display: inline-flex;
  flex: 0 0 14px;
  align-items: center;
  justify-content: center;
  width: 14px;
  height: 14px;
}

.dashboard-trend-dot.down {
  --trend-dot-color: #ef4444;
}

.dashboard-trend-dot svg {
  display: block;
  width: 14px;
  height: 14px;
}

.dashboard-trend-dot circle {
  fill: var(--trend-dot-color);
}

.dashboard-trend-dot path {
  fill: #ffffff;
  stroke: none;
}

.dashboard-ranking-table tbody tr:last-child td {
  border-bottom: 0;
}

.dashboard-store-cell {
  display: grid;
  gap: 3px;
}

.dashboard-store-cell strong {
  color: #111827;
  font-size: 12px;
}

.dashboard-store-cell span {
  color: #6b7280;
  font-size: 10px;
}

.dashboard-share-cell {
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

.dashboard-share-bar {
  width: 82px;
  height: 6px;
  overflow: hidden;
  border-radius: 999px;
  background: #eef2f7;
}

.dashboard-share-bar span {
  display: block;
  height: 100%;
  border-radius: inherit;
  background: #1b84ff;
}

.dashboard-share-cell strong {
  color: #252f4a;
  font-size: 11px;
  font-weight: 800;
  font-variant-numeric: tabular-nums;
}

.dashboard-row-action {
  height: 28px;
  padding: 0 10px;
  border: 1px solid #dbdfe9;
  border-radius: 6px;
  background: #ffffff;
  color: #1b4f9c;
  font-size: 11px;
  font-weight: 700;
  cursor: pointer;
}

.dashboard-row-action:hover {
  border-color: #1b84ff;
  background: #f5f8ff;
}

.dashboard-funnel {
  display: grid;
  gap: 14px;
  padding: 18px 16px 20px;
}

.dashboard-funnel-row {
  display: grid;
  grid-template-columns: 132px minmax(0, 1fr) 92px;
  align-items: center;
  gap: 14px;
}

.dashboard-funnel-label {
  display: grid;
  gap: 3px;
}

.dashboard-funnel-label strong {
  color: #111827;
  font-size: 12px;
  font-weight: 800;
}

.dashboard-funnel-label span {
  color: #6b7280;
  font-size: 10px;
}

.dashboard-funnel-track {
  height: 16px;
  overflow: hidden;
  border-radius: 999px;
  background: #eef2f7;
}

.dashboard-funnel-fill {
  height: 100%;
  min-width: 8px;
  border-radius: inherit;
  background: linear-gradient(90deg, #1b84ff, #16a34a);
}

.dashboard-funnel-value {
  color: #111827;
  font-size: 12px;
  font-weight: 800;
  text-align: right;
}

.dashboard-link-analysis {
  display: grid;
  gap: 16px;
}

.dashboard-link-analysis[hidden] {
  display: none;
}

.dashboard-link-metric-grid {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  align-items: stretch;
  min-height: 154px;
  overflow: hidden;
  border: 1px solid #e5e7eb;
  border-radius: 8px;
  background: #ffffff;
  box-shadow: 0 1px 2px rgba(15, 23, 42, 0.04);
}

.dashboard-link-metric-grid .dashboard-stat-item + .dashboard-stat-item {
  border-left: 1px solid #e5e7eb;
}

.dashboard-link-source-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
  padding: 16px;
}

.dashboard-link-source-card {
  min-width: 0;
  display: grid;
  gap: 12px;
  padding: 14px;
  border: 1px solid #eef0f4;
  border-radius: 8px;
  background: #fbfbfd;
}

.dashboard-link-source-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}

.dashboard-link-source-head strong {
  color: #111827;
  font-size: 13px;
  font-weight: 800;
}

.dashboard-link-source-head span {
  width: 9px;
  height: 9px;
  flex: 0 0 auto;
  border-radius: 999px;
  background: var(--source-color);
}

.dashboard-link-source-main {
  display: grid;
  gap: 5px;
}

.dashboard-link-source-main strong {
  color: #111827;
  font-size: 18px;
  font-weight: 800;
  line-height: 1;
}

.dashboard-link-source-main span {
  color: #6b7280;
  font-size: 10px;
  font-weight: 600;
}

.dashboard-link-source-stats {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
}

.dashboard-link-source-stats div {
  display: grid;
  gap: 3px;
}

.dashboard-link-source-stats span {
  color: #6b7280;
  font-size: 10px;
}

.dashboard-link-source-stats strong {
  color: #111827;
  font-size: 11px;
  font-weight: 800;
}

.dashboard-link-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.2fr) minmax(280px, 0.8fr);
  gap: 16px;
}

.dashboard-link-trend {
  min-height: 300px;
  padding: 14px 16px 8px;
}

.dashboard-link-trend-svg {
  width: 100%;
  height: 246px;
  display: block;
}

.dashboard-link-trend-line {
  fill: none;
  stroke: #1b84ff;
  stroke-width: 3;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.dashboard-link-trend-area {
  fill: #1b84ff;
  opacity: 0.1;
}

.dashboard-source-share-list {
  display: grid;
  gap: 13px;
  padding: 16px;
}

.dashboard-source-share-row {
  display: grid;
  gap: 7px;
}

.dashboard-source-share-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  color: #111827;
  font-size: 11px;
  font-weight: 800;
}

.dashboard-source-share-name {
  display: inline-flex;
  align-items: center;
  gap: 7px;
}

.dashboard-source-share-dot {
  width: 8px;
  height: 8px;
  flex: 0 0 auto;
  border-radius: 999px;
  background: var(--source-color);
}

.dashboard-source-share-label {
  min-width: 0;
}

.dashboard-source-share-track {
  height: 8px;
  overflow: hidden;
  border-radius: 999px;
  background: #eef2f7;
}

.dashboard-source-share-fill {
  height: 100%;
  border-radius: inherit;
  background: var(--source-color);
}

.dashboard-link-source-tag {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  color: #252f4a;
  font-weight: 700;
}

.dashboard-link-source-tag span {
  width: 7px;
  height: 7px;
  border-radius: 999px;
  background: var(--source-color);
}

.ads-panel {
  margin-top: 18px;
}

.ads-panel + .ads-panel {
  margin-top: 24px;
}

.table-panel {
  margin-top: 18px;
}

.ads-table-panel {
  margin-top: 24px;
}

.data-table-list {
  margin-top: 12px;
}

.ads-metric-row {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
}

.ads-metric-card {
  position: relative;
  min-height: 148px;
  padding: 42px 86px 12px 12px;
  border: 1px solid #e5e5ea;
  border-radius: 8px;
  background: #f5f5f7;
  overflow: hidden;
}

.ads-metric-label {
  position: absolute;
  top: 12px;
  left: 14px;
  color: #6e6e73;
  font-weight: 600;
}

.ads-metric-value {
  display: block;
  margin-top: 2px;
  color: #1d1d1f;
  font-size: 2.05rem;
  line-height: 1;
  text-align: center;
}

.ads-cny-value {
  display: block;
  margin-top: 5px;
  color: #6e6e73;
  font-size: 1.28rem;
  line-height: 1;
  text-align: center;
}

.ads-currency-usd {
  font-size: 1.28rem;
}

.ads-sparkline-row {
  position: absolute;
  left: 12px;
  right: 86px;
  bottom: 10px;
  width: auto;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 2px;
  margin: 0;
  color: #86868b;
  white-space: nowrap;
}

.ads-sparkline-row span {
  font-size: 8px;
  line-height: 1;
  text-align: center;
}

.ads-sparkline {
  width: 78px;
  height: 34px;
  flex: 0 0 auto;
}

.ads-sparkline polyline {
  fill: none;
  stroke: #0b3d91;
  stroke-width: 3;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.trend-down .ads-sparkline polyline {
  stroke: #a01818;
}

.ads-metric-side {
  position: absolute;
  top: 0;
  right: 0;
  width: 78px;
  height: 100%;
  display: grid;
  align-content: center;
  justify-items: center;
  gap: 6px;
  padding: 12px 10px;
  border-left: 1px solid #e5e5ea;
  background: rgba(255, 255, 255, 0.66);
  text-align: center;
}

.ads-metric-side span {
  color: #86868b;
}

.ads-metric-side b {
  color: #1d1d1f;
  font-size: 1.15rem;
}

.ads-metric-side em {
  min-width: 58px;
  border-radius: 999px;
  padding: 0.35rem 0.55rem;
  font-style: normal;
  font-weight: 700;
}

.trend-up .ads-metric-side em {
  color: #087443;
  background: #daf7e8;
}

.trend-down .ads-metric-side em {
  color: #a01818;
  background: #ffe1e1;
}

.system-panel {
  margin-top: 18px;
  padding: 18px;
  border: 1px solid rgba(0, 0, 0, 0.08);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.78);
  box-shadow: 0 22px 60px rgba(0, 0, 0, 0.08);
}

.system-tabs {
  display: inline-flex;
  gap: 4px;
  padding: 4px;
  margin-bottom: 16px;
  border: 1px solid #dbdfe9;
  border-radius: 8px;
  background: #ffffff;
}

.system-tab {
  height: 30px;
  padding: 0 14px;
  border: 0;
  border-radius: 6px;
  background: transparent;
  color: #4b5563;
  font-size: 11px;
  font-weight: 700;
  cursor: pointer;
}

.system-tab:hover {
  color: #1b4f9c;
  background: #eff6ff;
}

.system-tab.active {
  color: #ffffff;
  background: #0f3a78;
}

.system-panel-content[hidden] {
  display: none;
}

.user-form,
.shop-form {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
  padding: 16px;
  border-radius: 8px;
  background: #f5f5f7;
}

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

.user-avatar-field {
  grid-column: 1 / -1;
}

.user-avatar-upload {
  min-height: 58px;
  display: inline-flex;
  align-items: center;
  gap: 12px;
  width: 100%;
  padding: 10px 12px;
  border: 1px dashed #d8dbe5;
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.72);
  cursor: pointer;
}

.user-avatar-upload input {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  opacity: 0;
  pointer-events: none;
}

.user-avatar-preview,
.user-table-avatar {
  display: inline-grid;
  place-items: center;
  flex: 0 0 auto;
  border: 2px solid #22c55e;
  border-radius: 50%;
  background: #1b84ff;
  background-position: center;
  background-size: cover;
  color: #ffffff;
  font-weight: 800;
  text-transform: uppercase;
}

.user-avatar-preview {
  width: 42px;
  height: 42px;
}

.user-table-avatar {
  width: 30px;
  height: 30px;
  font-size: 11px;
}

.user-avatar-preview.has-image,
.user-table-avatar.has-image {
  color: transparent;
  text-indent: -999px;
}

.user-avatar-upload-copy {
  display: grid;
  gap: 3px;
  min-width: 0;
}

.user-avatar-upload-copy strong {
  color: #252f4a;
  font-size: 12px;
}

.user-avatar-upload-copy small {
  color: #6b7280;
  font-size: 11px;
}

.wide-field {
  grid-column: 1 / -1;
}

.shop-form textarea {
  width: 100%;
  resize: vertical;
}

.form-actions {
  display: flex;
  align-items: flex-end;
  gap: 8px;
}

.user-form .hint,
.shop-form .hint {
  grid-column: 1 / -1;
  margin: 0;
}

.user-list,
.shop-list {
  margin-top: 16px;
}

.shop-auth-guide {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 12px;
  padding: 12px 14px;
  border: 1px solid #e5e7eb;
  border-radius: 8px;
  background: #ffffff;
}

.shop-auth-guide-main {
  display: grid;
  gap: 5px;
  min-width: 0;
}

.shop-auth-guide-main span {
  color: #6b7280;
  font-size: 11px;
  font-weight: 700;
}

.shop-auth-guide-main strong {
  overflow: hidden;
  color: #111827;
  font-size: 11px;
  font-weight: 700;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.shop-auth-guide button {
  flex: 0 0 auto;
  height: 30px;
  padding: 0 10px;
  border: 1px solid #dbdfe9;
  border-radius: 6px;
  background: #ffffff;
  color: #252f4a;
  font-size: 11px;
  font-weight: 700;
}

.user-table-wrap,
.shop-table-wrap {
  overflow-x: auto;
  border-radius: 8px;
  background: #f5f5f7;
}

.user-table,
.shop-table {
  width: 100%;
  min-width: 860px;
  border-collapse: collapse;
}

.shop-table {
  min-width: 1120px;
}

.shop-auth-status {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 22px;
  padding: 0 8px;
  border-radius: 6px;
  color: #ffffff;
  font-size: 11px;
  font-weight: 800;
  line-height: 1;
  white-space: nowrap;
}

.shop-auth-status.unauthorized {
  background: #94a3b8;
}

.shop-auth-status.authorizing {
  background: #2563eb;
}

.shop-auth-status.authorized {
  background: #16a34a;
}

.shop-auth-status.expired {
  background: #d97706;
}

.shop-auth-status.failed {
  background: #dc2626;
}

.shop-auth-status.disabled {
  background: #64748b;
}

.user-table th,
.user-table td,
.shop-table th,
.shop-table td {
  padding: 14px 16px;
  border-bottom: 1px solid #e5e5ea;
  text-align: left;
  vertical-align: middle;
}

.user-table th,
.shop-table th {
  color: #6e6e73;
  font-size: 11px;
  font-weight: 600;
  background: rgba(255, 255, 255, 0.6);
}

.user-table tr:last-child td,
.shop-table tr:last-child td {
  border-bottom: 0;
}

.user-actions,
.shop-actions {
  display: flex;
  gap: 8px;
  flex-wrap: nowrap;
}

.user-actions button,
.shop-actions button {
  padding: 0.58rem 0.82rem;
  white-space: nowrap;
}

button,
input {
  font: inherit;
}

button {
  border: 0;
  border-radius: 999px;
  padding: 0.78rem 1.05rem;
  background: #e8e8ed;
  color: #1d1d1f;
  cursor: pointer;
  transition: transform 140ms ease, background 140ms ease, opacity 140ms ease;
}

button:hover:not(:disabled) {
  transform: translateY(-1px);
  background: #dedee3;
}

button:disabled {
  cursor: not-allowed;
  opacity: 0.45;
}

button.primary {
  background: #0071e3;
  color: white;
}

button.primary:hover:not(:disabled) {
  background: #0077ed;
}

input {
  width: 100%;
  border: 1px solid #d2d2d7;
  border-radius: 999px;
  padding: 0.78rem 1rem;
  background: rgba(255, 255, 255, 0.88);
  outline: none;
}

input:focus {
  border-color: #0071e3;
  box-shadow: 0 0 0 4px rgba(0, 113, 227, 0.12);
}

.shell {
  width: 100%;
  max-width: none;
  min-width: 0;
  margin: 0;
  padding: 18px 18px 42px;
}

.hero {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 24px;
  padding: 18px 0 24px;
}

.eyebrow {
  margin: 0 0 12px;
  color: #6e6e73;
  font-size: 0.88rem;
  letter-spacing: 0;
}

h1 {
  margin: 0;
  font-size: clamp(16.8px, 2.5vw, 44.8px);
  line-height: 1;
  letter-spacing: 0;
  white-space: nowrap;
  max-width: 100%;
  overflow-wrap: normal;
}

.subhead {
  max-width: 720px;
  margin: 18px 0 0;
  color: #6e6e73;
  font-size: 1.12rem;
  line-height: 1.55;
  white-space: pre-line;
}

.status-pill {
  flex: 0 0 auto;
  border-radius: 999px;
  padding: 0.7rem 1rem;
  background: rgba(255, 255, 255, 0.72);
  border: 1px solid rgba(0, 0, 0, 0.08);
  color: #424245;
}

.workspace {
  display: grid;
  grid-template-columns: minmax(0, 1.55fr) minmax(320px, 0.75fr);
  gap: 18px;
}

.camera-panel,
.side-panel,
.results {
  background: rgba(255, 255, 255, 0.78);
  border: 1px solid rgba(0, 0, 0, 0.08);
  border-radius: 8px;
  box-shadow: 0 22px 60px rgba(0, 0, 0, 0.08);
}

.camera-panel {
  padding: 14px;
}

.camera-wrap {
  position: relative;
  overflow: hidden;
  border-radius: 8px;
  background: #111;
  aspect-ratio: 16 / 10;
}

#preview {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

#analysisCanvas {
  display: none;
}

.camera-overlay {
  position: absolute;
  left: 16px;
  right: 16px;
  bottom: 16px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  color: white;
  text-shadow: 0 1px 12px rgba(0, 0, 0, 0.7);
}

.camera-overlay span,
.camera-overlay strong {
  overflow-wrap: anywhere;
}

.recording-dot {
  position: absolute;
  top: 16px;
  right: 16px;
  width: 14px;
  height: 14px;
  border-radius: 50%;
  background: #ff3b30;
  box-shadow: 0 0 0 0 rgba(255, 59, 48, 0.45);
  opacity: 0;
}

.recording-dot.active {
  opacity: 1;
  animation: pulse 1.2s infinite;
}

@keyframes pulse {
  70% { box-shadow: 0 0 0 18px rgba(255, 59, 48, 0); }
  100% { box-shadow: 0 0 0 0 rgba(255, 59, 48, 0); }
}

.controls {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  padding-top: 14px;
}

.camera-tools {
  display: grid;
  grid-template-columns: minmax(220px, 360px) 1fr;
  gap: 12px;
  align-items: center;
  padding-top: 12px;
}

select {
  width: 100%;
  border: 1px solid #d2d2d7;
  border-radius: 999px;
  padding: 0.78rem 1rem;
  background: rgba(255, 255, 255, 0.88);
  outline: none;
  font: inherit;
}

.side-panel {
  padding: 18px;
}

.block + .block {
  margin-top: 18px;
}

label {
  display: block;
  margin-bottom: 8px;
  color: #424245;
  font-weight: 600;
}

.input-row {
  display: flex;
  gap: 8px;
}

.input-row button {
  flex: 0 0 auto;
}

.hint {
  margin: 10px 0 0;
  color: #86868b;
  font-size: 11px;
  line-height: 1.45;
}

.metric-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
}

.metric-grid div {
  min-height: 82px;
  border-radius: 8px;
  background: #f5f5f7;
  padding: 12px;
}

.metric-grid span {
  display: block;
  color: #86868b;
  font-size: 11px;
}

.metric-grid strong {
  display: block;
  margin-top: 8px;
  font-size: 1.05rem;
  overflow-wrap: anywhere;
}

.results {
  margin-top: 18px;
  padding: 18px;
}

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

.section-title-main {
  min-width: 0;
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}

.section-title h2 {
  margin: 0;
  font-size: 1.25rem;
}

.section-title span {
  color: #6e6e73;
}

.section-title-actions {
  position: relative;
  flex: 0 0 auto;
}

.small-action {
  height: 32px;
  padding: 0 12px;
  border: 0;
  border-radius: 6px;
  font-size: 11px;
  font-weight: 700;
  white-space: nowrap;
}

.date-range-control {
  height: 34px;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 0 13px;
  border: 1px solid #dbdfe9;
  border-radius: 6px;
  background: #ffffff;
  color: #111827;
  box-shadow: 0 1px 2px rgba(15, 23, 42, 0.04);
  font-size: 11px;
  font-weight: 600;
  white-space: nowrap;
}

.date-range-control:hover:not(:disabled) {
  transform: none;
  border-color: #b8c2d6;
  background: #f9fafb;
}

.date-range-control span {
  color: inherit;
}

.date-range-icon {
  position: relative;
  width: 14px;
  height: 14px;
  flex: 0 0 auto;
  border: 1.6px solid currentColor;
  border-radius: 3px;
  color: #4b5675;
}

.date-range-icon::before,
.date-range-icon::after {
  content: "";
  position: absolute;
  box-sizing: border-box;
}

.date-range-icon::before {
  left: -1.6px;
  right: -1.6px;
  top: 3px;
  border-top: 1.6px solid currentColor;
}

.date-range-icon::after {
  left: 3px;
  top: -3px;
  width: 6px;
  height: 5px;
  border-left: 1.6px solid currentColor;
  border-right: 1.6px solid currentColor;
}

.date-range-panel {
  position: absolute;
  top: calc(100% + 8px);
  right: 0;
  z-index: 120;
  width: 590px;
  padding: 0;
  border: 1px solid #e5e7eb;
  border-radius: 8px;
  background: #ffffff;
  box-shadow: 0 16px 36px rgba(15, 23, 42, 0.12);
}

.date-range-panel[hidden] {
  display: none;
}

.range-calendar {
  overflow: hidden;
  border-radius: 8px;
}

.range-calendar-content {
  display: grid;
  grid-template-columns: 104px minmax(0, 1fr);
}

.range-calendar-shortcuts {
  display: grid;
  align-content: start;
  gap: 8px;
  padding: 12px 10px;
  border-right: 1px solid #e5e7eb;
  background: #fbfbfc;
}

.range-calendar-shortcut {
  height: 28px;
  padding: 0 10px;
  border: 1px solid #dbdfe9;
  border-radius: 4px;
  background: #ffffff;
  color: #4b5675;
  font-size: 11px;
  font-weight: 600;
  text-align: center;
}

.range-calendar-shortcut:hover:not(:disabled) {
  transform: none;
  border-color: #1b84ff;
  background: #f5f8ff;
  color: #1b84ff;
}

.range-calendar-shortcut.active {
  border-color: #13b5b1;
  background: #ecfeff;
  color: #009b97;
}

.range-calendar-months {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px;
  padding: 16px 14px 14px;
}

.range-calendar-month {
  min-width: 0;
}

.range-calendar-month-head {
  height: 28px;
  display: grid;
  grid-template-columns: 28px minmax(0, 1fr) 28px;
  align-items: center;
  margin-bottom: 10px;
}

.range-calendar-month-head strong {
  color: #111827;
  font-size: 13px;
  font-weight: 500;
  text-align: center;
}

.range-calendar-nav,
.range-calendar-nav-spacer {
  width: 28px;
  height: 28px;
}

.range-calendar-nav {
  display: inline-grid;
  place-items: center;
  padding: 0;
  border-radius: 6px;
  background: transparent;
  color: #b5bdca;
  font-size: 24px;
  line-height: 1;
}

.range-calendar-nav:hover:not(:disabled) {
  transform: none;
  background: #f5f8ff;
  color: #1b84ff;
}

.range-calendar-weekdays,
.range-calendar-days {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
}

.range-calendar-weekdays {
  margin-bottom: 4px;
}

.range-calendar-weekdays span {
  height: 24px;
  display: grid;
  place-items: center;
  color: #8b95a5;
  font-size: 11px;
  font-weight: 500;
}

.range-calendar-day {
  width: 100%;
  height: 34px;
  display: grid;
  place-items: center;
  padding: 0;
  border-radius: 0;
  background: transparent;
  color: #111827;
  font-size: 13px;
  font-weight: 500;
}

.range-calendar-day:hover:not(:disabled) {
  transform: none;
  background: #f3f7ff;
  color: #1b84ff;
}

.range-calendar-day.muted {
  color: #b5bdca;
}

.range-calendar-day.today {
  box-shadow: inset 0 0 0 1px rgba(27, 132, 255, 0.22);
}

.range-calendar-day.in-range {
  background: #eff6ff;
  color: #1b84ff;
}

.range-calendar-day.selected {
  background: #1b84ff;
  color: #ffffff;
}

.range-calendar-footer {
  display: flex;
  justify-content: flex-end;
  gap: 8px;
  padding: 12px;
  border-top: 1px solid #e5e7eb;
}

.range-calendar-reset,
.range-calendar-apply {
  height: 34px;
  padding: 0 14px;
  border-radius: 6px;
  font-size: 11px;
  font-weight: 700;
}

.range-calendar-reset {
  border: 1px solid #dbdfe9;
  background: #ffffff;
  color: #252f4a;
}

.range-calendar-reset:hover:not(:disabled) {
  transform: none;
  border-color: #b8c2d6;
  background: #f9fafb;
}

.range-calendar-apply {
  background: #1b84ff;
  color: #ffffff;
}

.range-calendar-apply:hover:not(:disabled) {
  transform: none;
  background: #056ee9;
}

.video-list {
  display: grid;
  gap: 12px;
}

.video-table-wrap {
  overflow-x: auto;
  border-radius: 8px;
  background: #f5f5f7;
}

.video-table {
  width: 100%;
  border-collapse: collapse;
  min-width: 860px;
}

.video-table th,
.video-table td {
  padding: 14px 16px;
  border-bottom: 1px solid #e5e5ea;
  text-align: left;
  vertical-align: middle;
}

.video-table th {
  color: #6e6e73;
  font-size: 11px;
  font-weight: 600;
  background: rgba(255, 255, 255, 0.6);
}

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

.order-cell {
  font-weight: 700;
  color: #1d1d1f;
  letter-spacing: 0;
  white-space: nowrap;
}

.actions-cell {
  width: 1%;
  min-width: 300px;
  white-space: nowrap;
}

.video-actions {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: nowrap;
}

.video-actions button {
  padding: 0.58rem 0.82rem;
  white-space: nowrap;
}

button.danger {
  background: #ffe5e5;
  color: #b00020;
}

button.danger:hover:not(:disabled) {
  background: #ffd7d7;
}

.data-grid-shell {
  overflow: hidden;
  border: 1px solid #e5e7eb;
  border-radius: 8px;
  background: #ffffff;
  box-shadow: 0 1px 2px rgba(15, 23, 42, 0.04);
}

.data-grid-toolbar,
.data-grid-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  min-height: 56px;
  padding: 10px 16px;
}

.data-grid-toolbar {
  border-bottom: 1px solid #e5e7eb;
}

.data-grid-footer {
  border-top: 1px solid #e5e7eb;
}

.data-grid-toolbar-group,
.data-grid-size,
.data-grid-pager,
.data-grid-pages {
  display: flex;
  align-items: center;
  gap: 8px;
}

.data-grid-toolbar-group {
  flex-wrap: wrap;
}

.data-grid-toolbar-group.right {
  justify-content: flex-end;
}

.data-grid-search {
  width: 168px;
  height: 34px;
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 0 12px;
  border: 1px solid #dbdfe9;
  border-radius: 6px;
  background: #ffffff;
  color: #78829d;
}

.data-grid-search input {
  width: 100%;
  height: 100%;
  min-width: 0;
  padding: 0;
  border: 0;
  border-radius: 0;
  background: transparent;
  color: #252f4a;
  box-shadow: none;
}

.data-grid-search input:focus {
  border-color: transparent;
  box-shadow: none;
}

.data-grid-tool {
  height: 34px;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 0 12px;
  border: 1px solid #dbdfe9;
  border-radius: 6px;
  background: #ffffff;
  color: #252f4a;
  font-size: 11px;
  font-weight: 600;
  white-space: nowrap;
}

.data-grid-tool.primary {
  border-color: #1b84ff;
  background: #1b84ff;
  color: #ffffff;
}

.data-grid-tool:hover:not(:disabled) {
  transform: none;
  border-color: #b8c2d6;
  background: #f5f8ff;
  color: #1b84ff;
}

.data-grid-tool.primary:hover:not(:disabled) {
  border-color: #056ee9;
  background: #056ee9;
  color: #ffffff;
}

.data-grid-icon {
  position: relative;
  width: 15px;
  height: 15px;
  flex: 0 0 auto;
  color: currentColor;
}

.data-grid-icon.search::before {
  content: "";
  position: absolute;
  left: 2px;
  top: 2px;
  width: 8px;
  height: 8px;
  border: 1.7px solid currentColor;
  border-radius: 50%;
}

.data-grid-icon.search::after {
  content: "";
  position: absolute;
  right: 2px;
  bottom: 2px;
  width: 6px;
  height: 1.7px;
  border-radius: 999px;
  background: currentColor;
  transform: rotate(45deg);
}

.data-grid-icon.filter::before {
  content: "";
  position: absolute;
  left: 2px;
  top: 2px;
  width: 11px;
  height: 11px;
  border: 1.7px solid currentColor;
  border-bottom: 0;
  clip-path: polygon(0 0, 100% 0, 63% 45%, 63% 100%, 37% 100%, 37% 45%);
}

.data-grid-icon.sliders::before,
.data-grid-icon.sliders::after {
  content: "";
  position: absolute;
  left: 2px;
  width: 11px;
  height: 1.6px;
  border-radius: 999px;
  background: currentColor;
}

.data-grid-icon.sliders::before {
  top: 4px;
  box-shadow: 0 7px 0 currentColor;
}

.data-grid-icon.sliders::after {
  top: 3px;
  width: 3px;
  height: 3px;
  border: 1.5px solid currentColor;
  border-radius: 50%;
  background: #ffffff;
  box-shadow: 7px 7px 0 -1.5px #ffffff, 7px 7px 0 0 currentColor;
}

.data-grid-table-scroll {
  overflow-x: auto;
}

.data-grid-table {
  width: 100%;
  min-width: 860px;
  border-collapse: collapse;
  background: #ffffff;
}

.data-grid-table th,
.data-grid-table td {
  height: 56px;
  padding: 11px 16px;
  border-right: 1px solid #e5e7eb;
  border-bottom: 1px solid #e5e7eb;
  text-align: left;
  vertical-align: middle;
}

.data-grid-table th:last-child,
.data-grid-table td:last-child {
  border-right: 0;
}

.data-grid-table tbody tr:last-child td {
  border-bottom: 0;
}

.data-grid-table th {
  height: 38px;
  background: #fbfbfc;
  color: #252f4a;
  font-size: 11px;
  font-weight: 600;
  white-space: nowrap;
}

.data-grid-sort-button {
  display: inline-flex;
  align-items: center;
  justify-content: flex-start;
  gap: 0;
  min-width: 0;
  padding: 0;
  border: 0;
  background: transparent;
  color: inherit;
  font: inherit;
  text-align: inherit;
  white-space: nowrap;
}

.data-grid-sort-button:hover,
.data-grid-sort-button.active {
  background: transparent;
  color: #1b84ff;
}

.data-grid-sort {
  position: relative;
  display: inline-block;
  width: 10px;
  height: 13px;
  margin-left: 6px;
  vertical-align: -2px;
  color: #99a1b7;
}

.data-grid-sort::before,
.data-grid-sort::after {
  content: "";
  position: absolute;
  left: 2px;
  border-left: 3px solid transparent;
  border-right: 3px solid transparent;
}

.data-grid-sort::before {
  top: 1px;
  border-bottom: 4px solid currentColor;
}

.data-grid-sort::after {
  bottom: 1px;
  border-top: 4px solid currentColor;
}

.data-grid-sort.asc::after,
.data-grid-sort.desc::before {
  opacity: 0.25;
}

.data-grid-check-cell {
  width: 46px;
  padding-right: 10px !important;
  padding-left: 16px !important;
}

.data-grid-check {
  appearance: none;
  width: 18px;
  height: 18px;
  margin: 0;
  padding: 0;
  border: 1px solid #dbdfe9;
  border-radius: 6px;
  background: #ffffff;
  cursor: pointer;
  vertical-align: middle;
}

.data-grid-check:checked {
  border-color: #1b84ff;
  background: #1b84ff;
}

.data-grid-check:checked::after {
  content: "";
  display: block;
  width: 5px;
  height: 9px;
  margin: 2px 0 0 5px;
  border: solid #ffffff;
  border-width: 0 2px 2px 0;
  transform: rotate(45deg);
}

.data-grid-table .order-cell {
  color: #252f4a;
  font-weight: 700;
}

.order-detail-table {
  min-width: 980px;
}

.order-detail-table th:first-child,
.order-detail-table td:first-child {
  width: 64px;
  text-align: center;
}

.order-detail-table th:nth-child(6),
.order-detail-table td:nth-child(6) {
  min-width: 138px;
}

.order-detail-table th:nth-child(7),
.order-detail-table td:nth-child(7) {
  white-space: nowrap;
  font-weight: 700;
}

.claims-page {
  padding-top: 18px;
}

.claims-panel .section-title {
  margin-bottom: 24px;
}

.claims-title-actions {
  display: inline-flex;
  align-items: center;
  gap: 10px;
}

.claims-title-actions button:disabled {
  background: #e5e7eb;
  color: #6b7280;
  opacity: 1;
  transform: none;
}

.claims-agent-status {
  max-width: 440px;
  overflow: hidden;
  color: #4b5675;
  font-size: 11px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.claims-table {
  min-width: 1450px;
}

.claims-table th:first-child,
.claims-table td:first-child {
  width: 64px;
  text-align: center;
}

.claims-table th:nth-child(2),
.claims-table td:nth-child(2) {
  min-width: 128px;
}

.claims-table th:nth-child(3),
.claims-table td:nth-child(3) {
  min-width: 178px;
}

.claims-table th:nth-child(4),
.claims-table td:nth-child(4),
.claims-table th:nth-child(5),
.claims-table td:nth-child(5) {
  min-width: 150px;
}

.claims-table th:nth-child(8),
.claims-table td:nth-child(8) {
  min-width: 240px;
}

.claim-status-tag,
.claim-video-tags span {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 22px;
  padding: 0 8px;
  border-radius: 6px;
  color: #ffffff;
  font-size: 11px;
  font-weight: 800;
  line-height: 1;
  white-space: nowrap;
}

.claim-status-tag.pending {
  background: #64748b;
}

.claim-status-tag.submitted {
  background: #16a34a;
}

.claim-status-tag.not-submitted {
  background: #94a3b8;
}

.claim-status-tag.direct {
  background: #d97706;
}

.claim-status-tag.ticket {
  background: #2563eb;
}

.claim-video-tags {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 6px;
}

.claim-video-cell {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  min-width: 0;
}

.claim-open-button {
  flex: 0 0 auto;
  height: 28px;
  padding: 0 10px;
  border: 1px solid #dbdfe9;
  border-radius: 6px;
  background: #ffffff;
  color: #252f4a;
  font-size: 11px;
  font-weight: 700;
  white-space: nowrap;
}

.claim-open-button:hover:not(:disabled) {
  border-color: #1b84ff;
  background: #f5f8ff;
  color: #1b84ff;
}

.claim-video-tags span {
  background: #059669;
}

.claim-muted {
  color: #99a1b7;
  font-size: 11px;
}

.order-status-tags {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 6px;
}

.order-status-tag {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 22px;
  padding: 0 8px;
  border-radius: 6px;
  color: #ffffff;
  font-size: 11px;
  font-weight: 800;
  line-height: 1;
  white-space: nowrap;
}

.order-status-tag.pending-shipment {
  background: #60a5fa;
}

.order-status-tag.in-transit {
  background: #1d4ed8;
}

.order-status-tag.completed {
  background: #047857;
}

.order-status-tag.return-refund {
  background: #f59e0b;
}

.order-status-tag.refund-only {
  background: #dc2626;
}

.order-status-tag.appealable {
  background: #d97706;
}

.order-status-tag.appealing {
  background: #fbbf24;
}

.order-status-tag.appeal-success {
  background: #16a34a;
}

.data-grid-table .actions-cell {
  width: 1%;
  min-width: 248px;
}

.data-grid-table .video-actions,
.data-grid-table .user-actions,
.data-grid-table .shop-actions,
.data-grid-table .data-grid-actions {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  flex-wrap: nowrap;
}

.data-grid-table .video-actions button,
.data-grid-table .user-actions button,
.data-grid-table .shop-actions button,
.data-grid-table .data-grid-actions button {
  height: 30px;
  padding: 0 10px;
  border: 1px solid #dbdfe9;
  border-radius: 6px;
  background: #ffffff;
  color: #252f4a;
  font-size: 11px;
  font-weight: 600;
  white-space: nowrap;
}

.data-grid-table .video-actions button:hover:not(:disabled),
.data-grid-table .user-actions button:hover:not(:disabled),
.data-grid-table .shop-actions button:hover:not(:disabled),
.data-grid-table .data-grid-actions button:hover:not(:disabled) {
  transform: none;
  border-color: #1b84ff;
  background: #f5f8ff;
  color: #1b84ff;
}

.data-grid-table .video-actions button.danger,
.data-grid-table .user-actions button.danger,
.data-grid-table .shop-actions button.danger {
  border-color: #ffd6de;
  background: #fff1f4;
  color: #f8285a;
}

.data-grid-table .video-actions button.danger:hover:not(:disabled),
.data-grid-table .user-actions button.danger:hover:not(:disabled),
.data-grid-table .shop-actions button.danger:hover:not(:disabled) {
  border-color: #f8285a;
  background: #ffe5eb;
  color: #d91545;
}

.data-grid-table .shop-actions button.shop-auth-button {
  border-color: #bfdbfe;
  background: #eff6ff;
  color: #1d4ed8;
}

.data-grid-table .shop-actions button.shop-auth-button:hover:not(:disabled) {
  border-color: #1b84ff;
  background: #e0f2fe;
  color: #0f3a78;
}

.data-grid-size {
  color: #4b5675;
  font-size: 11px;
}

.data-grid-size select {
  width: 48px;
  height: 30px;
  padding: 0 8px;
  border: 1px solid #dbdfe9;
  border-radius: 6px;
  background: #ffffff;
  color: #252f4a;
  font-size: 11px;
}

.data-grid-info {
  color: #78829d;
  font-size: 11px;
  white-space: nowrap;
}

.data-grid-page {
  width: 28px;
  height: 28px;
  display: inline-grid;
  place-items: center;
  padding: 0;
  border-radius: 6px;
  background: transparent;
  color: #4b5675;
  font-size: 11px;
  font-weight: 600;
}

.data-grid-page:hover:not(:disabled) {
  transform: none;
  background: #f5f8ff;
  color: #1b84ff;
}

.data-grid-page.active {
  background: #eff6ff;
  color: #1b84ff;
}

.data-grid-ellipsis {
  color: #78829d;
  font-weight: 700;
  letter-spacing: 1px;
}

.data-grid-empty {
  height: 78px !important;
  color: #78829d;
  font-weight: 500;
  text-align: center !important;
}

body.dark-mode .data-grid-shell {
  border-color: #1f2937;
  background: #09090b;
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.28);
}

body.dark-mode .dashboard-stat-strip {
  border-color: #1f2937;
  background: #09090b;
}

body.dark-mode .dashboard-view-switch,
body.dark-mode .dashboard-detail-card,
body.dark-mode .dashboard-ranking-table th,
body.dark-mode .dashboard-row-action {
  border-color: #20283a;
  background: #10141d;
}

body.dark-mode .dashboard-view-button {
  color: #d1d5db;
}

body.dark-mode .dashboard-view-button:hover {
  color: #73b5ff;
  background: rgba(27, 132, 255, 0.14);
}

body.dark-mode .dashboard-view-button.active {
  color: #ffffff;
  background: #124a93;
}

body.dark-mode .dashboard-filter-field span,
body.dark-mode .dashboard-detail-head span,
body.dark-mode .dashboard-store-cell span,
body.dark-mode .dashboard-funnel-label span {
  color: #9ca3af;
}

body.dark-mode .dashboard-detail-head,
body.dark-mode .dashboard-ranking-table th,
body.dark-mode .dashboard-ranking-table td {
  border-color: #20283a;
}

body.dark-mode .dashboard-detail-head h3,
body.dark-mode .dashboard-ranking-table td,
body.dark-mode .dashboard-store-cell strong,
body.dark-mode .dashboard-share-cell strong,
body.dark-mode .dashboard-funnel-label strong,
body.dark-mode .dashboard-funnel-value {
  color: #f9fafb;
}

body.dark-mode .dashboard-share-bar,
body.dark-mode .dashboard-funnel-track,
body.dark-mode .dashboard-source-share-track {
  background: #1f2937;
}

body.dark-mode .dashboard-row-action {
  color: #93c5fd;
}

body.dark-mode .dashboard-sort-button {
  color: #d1d5db;
}

body.dark-mode .dashboard-ranking-table th .dashboard-sort-button:hover:not(:disabled),
body.dark-mode .dashboard-ranking-table th .dashboard-sort-button:focus-visible,
body.dark-mode .dashboard-sort-button.active {
  background: transparent;
  box-shadow: none;
  color: #73b5ff;
}

body.dark-mode .dashboard-sort-indicator {
  color: #6b7280;
}

body.dark-mode .dashboard-mini-trend.up {
  --trend-color: #22c55e;
}

body.dark-mode .dashboard-mini-trend.down {
  --trend-color: #fb7185;
}

body.dark-mode .dashboard-trend-dot.up {
  --trend-dot-color: #22c55e;
}

body.dark-mode .dashboard-trend-dot.down {
  --trend-dot-color: #fb7185;
}

body.dark-mode .dashboard-row-action:hover {
  border-color: #3b82f6;
  background: rgba(59, 130, 246, 0.16);
}

body.dark-mode .dashboard-link-metric-grid,
body.dark-mode .dashboard-link-source-card {
  border-color: #20283a;
  background: #10141d;
}

body.dark-mode .dashboard-link-metric-grid .dashboard-stat-item + .dashboard-stat-item {
  border-left-color: #20283a;
}

body.dark-mode .dashboard-link-source-head strong,
body.dark-mode .dashboard-link-source-main strong,
body.dark-mode .dashboard-link-source-stats strong,
body.dark-mode .dashboard-source-share-head,
body.dark-mode .dashboard-link-source-tag {
  color: #f9fafb;
}

body.dark-mode .dashboard-link-source-main span,
body.dark-mode .dashboard-link-source-stats span {
  color: #9ca3af;
}

body.dark-mode .dashboard-link-trend-area {
  opacity: 0.16;
}

body.dark-mode .dashboard-stat-item + .dashboard-stat-item {
  border-left-color: #1f2937;
}

body.dark-mode .dashboard-stat-item strong,
body.dark-mode .dashboard-stat-item span {
  color: #f9fafb;
}

body.dark-mode .dashboard-cny-value {
  color: #f9fafb;
}

body.dark-mode .dashboard-trend,
body.dark-mode .dashboard-trend-history {
  color: #9ca3af;
}

body.dark-mode .dashboard-trend.trend-up .dashboard-trend-line {
  color: #4ade80;
}

body.dark-mode .dashboard-trend.trend-up .dashboard-trend-arrow {
  background: transparent;
}

body.dark-mode .dashboard-trend.trend-up .dashboard-trend-arrow circle {
  fill: #22c55e;
}

body.dark-mode .dashboard-trend.trend-down .dashboard-trend-line {
  color: #f87171;
}

body.dark-mode .dashboard-trend.trend-down .dashboard-trend-arrow {
  background: transparent;
}

body.dark-mode .dashboard-trend.trend-down .dashboard-trend-arrow circle {
  fill: #fb7185;
}

body.dark-mode .dashboard-chart-card,
body.dark-mode .dashboard-chart-plot-bg {
  border-color: #20283a;
  background: #10141d;
  box-shadow: 0 14px 34px rgba(0, 0, 0, 0.28);
}

body.dark-mode .dashboard-chart-plot-bg {
  fill: #0b0f18;
}

body.dark-mode .dashboard-chart-head h3,
body.dark-mode .dashboard-chart-legend,
body.dark-mode .dashboard-chart-option {
  color: #f9fafb;
}

body.dark-mode .dashboard-chart-head span,
body.dark-mode .dashboard-chart-axis-label,
body.dark-mode .dashboard-chart-x-label,
body.dark-mode .dashboard-chart-empty {
  color: #a8b3c7;
  fill: #a8b3c7;
}

body.dark-mode .dashboard-chart-grid-line {
  stroke: #273247;
  opacity: 0.85;
}

body.dark-mode .dashboard-chart-line {
  filter: drop-shadow(0 0 5px color-mix(in srgb, var(--series-color) 42%, transparent));
}

body.dark-mode .dashboard-chart-area {
  opacity: 0.16;
}

body.dark-mode .dashboard-chart-hover-line {
  stroke: #64748b;
}

body.dark-mode .dashboard-chart-hover-dot {
  fill: #0b0f18;
}

body.dark-mode .dashboard-chart-tooltip-bg {
  fill: #111827;
  stroke: #334155;
  filter: drop-shadow(0 12px 22px rgba(0, 0, 0, 0.38));
}

body.dark-mode .dashboard-chart-tooltip-title {
  fill: #f8fafc;
}

body.dark-mode .dashboard-chart-tooltip-row {
  fill: #dbeafe;
}

body.dark-mode .dashboard-chart-tooltip-value {
  fill: #ffffff;
}

body.dark-mode .dashboard-chart-option {
  border-color: #273247;
  background: #0d111a;
  color: #dce6f7;
}

body.dark-mode .dashboard-chart-option:hover:not(.disabled) {
  border-color: #375178;
  background: #121a28;
}

body.dark-mode .dashboard-chart-option.selected {
  border-color: #3b82f6;
  background: rgba(59, 130, 246, 0.18);
  color: #d8e8ff;
  box-shadow: inset 0 0 0 1px rgba(96, 165, 250, 0.16);
}

body.dark-mode .dashboard-chart-option.disabled {
  opacity: 0.34;
}

body.dark-mode .data-grid-toolbar,
body.dark-mode .data-grid-footer,
body.dark-mode .data-grid-table th,
body.dark-mode .data-grid-table td {
  border-color: #1f2937;
}

body.dark-mode .data-grid-table,
body.dark-mode .data-grid-table th,
body.dark-mode .data-grid-table td {
  background: #09090b;
  color: #e5e7eb;
}

body.dark-mode .data-grid-table th {
  background: #111318;
  color: #f9fafb;
}

body.dark-mode .data-grid-search,
body.dark-mode .data-grid-tool,
body.dark-mode .data-grid-size select,
body.dark-mode .data-grid-check,
body.dark-mode .claim-open-button,
body.dark-mode .data-grid-table .video-actions button,
body.dark-mode .data-grid-table .user-actions button,
body.dark-mode .data-grid-table .shop-actions button,
body.dark-mode .data-grid-table .data-grid-actions button {
  border-color: #252b36;
  background: #111318;
  color: #f9fafb;
}

body.dark-mode .data-grid-search input {
  color: #f9fafb;
}

body.dark-mode .data-grid-search input::placeholder {
  color: #78829d;
}

body.dark-mode .data-grid-tool:hover:not(:disabled),
body.dark-mode .data-grid-page:hover:not(:disabled),
body.dark-mode .claim-open-button:hover:not(:disabled),
body.dark-mode .data-grid-table .video-actions button:hover:not(:disabled),
body.dark-mode .data-grid-table .user-actions button:hover:not(:disabled),
body.dark-mode .data-grid-table .shop-actions button:hover:not(:disabled),
body.dark-mode .data-grid-table .data-grid-actions button:hover:not(:disabled) {
  border-color: #1b84ff;
  background: rgba(27, 132, 255, 0.14);
  color: #73b5ff;
}

body.dark-mode .data-grid-table .shop-actions button.shop-auth-button {
  border-color: #1b4f9c;
  background: rgba(27, 132, 255, 0.14);
  color: #93c5fd;
}

body.dark-mode .data-grid-tool.primary {
  border-color: #1b84ff;
  background: #1b84ff;
  color: #ffffff;
}

body.dark-mode .data-grid-icon.sliders::after {
  background: #111318;
  box-shadow: 7px 7px 0 -1.5px #111318, 7px 7px 0 0 currentColor;
}

body.dark-mode .data-grid-table .order-cell,
body.dark-mode .data-grid-size,
body.dark-mode .data-grid-info,
body.dark-mode .data-grid-empty {
  color: #d1d5db;
}

body.dark-mode .claims-agent-status,
body.dark-mode .claim-muted {
  color: #a8b3c7;
}

body.dark-mode .claims-title-actions button:disabled {
  background: #334155;
  color: #94a3b8;
  opacity: 1;
}

body.dark-mode .data-grid-page {
  color: #9ca3af;
}

body.dark-mode .data-grid-page.active {
  background: rgba(27, 132, 255, 0.18);
  color: #73b5ff;
}

body.dark-mode .data-grid-table .video-actions button.danger,
body.dark-mode .data-grid-table .user-actions button.danger,
body.dark-mode .data-grid-table .shop-actions button.danger {
  border-color: rgba(248, 40, 90, 0.36);
  background: rgba(248, 40, 90, 0.12);
  color: #ff6b8d;
}

body.dark-mode .data-grid-table .video-actions button.danger:hover:not(:disabled),
body.dark-mode .data-grid-table .user-actions button.danger:hover:not(:disabled),
body.dark-mode .data-grid-table .shop-actions button.danger:hover:not(:disabled) {
  border-color: #ff6b8d;
  background: rgba(248, 40, 90, 0.18);
  color: #ff8aa6;
}

body.dark-mode .date-range-control,
body.dark-mode .date-range-panel {
  border-color: #252b36;
  background: #111318;
  color: #f9fafb;
}

body.dark-mode .date-range-control:hover:not(:disabled) {
  border-color: #1b84ff;
  background: rgba(27, 132, 255, 0.14);
  color: #73b5ff;
}

body.dark-mode .date-range-icon,
body.dark-mode .date-range-panel label {
  color: #d1d5db;
}

body.dark-mode .range-calendar-month-head strong,
body.dark-mode .range-calendar-day,
body.dark-mode .range-calendar-reset,
body.dark-mode .range-calendar-shortcut {
  color: #f9fafb;
}

body.dark-mode .range-calendar-shortcuts {
  border-color: #1f2937;
  background: #0b0f16;
}

body.dark-mode .range-calendar-shortcut {
  border-color: #252b36;
  background: #111318;
}

body.dark-mode .range-calendar-shortcut:hover:not(:disabled) {
  border-color: #1b84ff;
  background: rgba(27, 132, 255, 0.14);
  color: #73b5ff;
}

body.dark-mode .range-calendar-shortcut.active {
  border-color: #13b5b1;
  background: rgba(19, 181, 177, 0.16);
  color: #5eead4;
}

body.dark-mode .range-calendar-weekdays span,
body.dark-mode .range-calendar-day.muted {
  color: #78829d;
}

body.dark-mode .range-calendar-nav {
  color: #78829d;
}

body.dark-mode .range-calendar-nav:hover:not(:disabled),
body.dark-mode .range-calendar-day:hover:not(:disabled) {
  background: rgba(27, 132, 255, 0.14);
  color: #73b5ff;
}

body.dark-mode .range-calendar-day.in-range {
  background: rgba(27, 132, 255, 0.16);
  color: #73b5ff;
}

body.dark-mode .range-calendar-day.selected {
  background: #1b84ff;
  color: #ffffff;
}

body.dark-mode .range-calendar-footer {
  border-color: #1f2937;
}

body.dark-mode .range-calendar-reset {
  border-color: #252b36;
  background: #111318;
}

body.dark-mode .range-calendar-reset:hover:not(:disabled) {
  border-color: #1b84ff;
  background: rgba(27, 132, 255, 0.14);
  color: #73b5ff;
}

@media (max-width: 1180px) {
  .dashboard-control-main {
    align-items: flex-start;
    flex-direction: column;
  }

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

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

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

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

  .dashboard-stat-item + .dashboard-stat-item {
    border-left: 0;
  }

  .dashboard-stat-item {
    border-top: 1px solid #e5e7eb;
  }

  .dashboard-stat-item:first-child {
    border-top: 0;
  }

  .dashboard-stat-item:nth-child(-n + 3) {
    border-top: 0;
  }

  .dashboard-stat-item:not(:nth-child(3n + 1)) {
    border-left: 1px solid #e5e7eb;
  }

  .dashboard-link-metric-grid .dashboard-stat-item + .dashboard-stat-item {
    border-left: 0;
  }

  .dashboard-link-metric-grid .dashboard-stat-item {
    border-top: 1px solid #e5e7eb;
  }

  .dashboard-link-metric-grid .dashboard-stat-item:nth-child(-n + 3) {
    border-top: 0;
  }

  .dashboard-link-metric-grid .dashboard-stat-item:not(:nth-child(3n + 1)) {
    border-left: 1px solid #e5e7eb;
  }

  body.dark-mode .dashboard-stat-item {
    border-top-color: #1f2937;
  }

  body.dark-mode .dashboard-stat-item:not(:nth-child(3n + 1)) {
    border-left-color: #1f2937;
  }

  body.dark-mode .dashboard-link-metric-grid .dashboard-stat-item {
    border-top-color: #20283a;
  }

  body.dark-mode .dashboard-link-metric-grid .dashboard-stat-item:not(:nth-child(3n + 1)) {
    border-left-color: #20283a;
  }
}

@media (max-width: 760px) {
  .dashboard-filter-field {
    width: calc(50% - 5px);
  }

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

  .dashboard-link-metric-grid,
  .dashboard-link-source-grid,
  .dashboard-link-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .dashboard-stat-item:nth-child(-n + 3) {
    border-top: 1px solid #e5e7eb;
  }

  .dashboard-stat-item:nth-child(-n + 2) {
    border-top: 0;
  }

  .dashboard-stat-item:not(:nth-child(3n + 1)) {
    border-left: 0;
  }

  .dashboard-stat-item:nth-child(even) {
    border-left: 1px solid #e5e7eb;
  }

  .dashboard-link-metric-grid .dashboard-stat-item:nth-child(-n + 3) {
    border-top: 1px solid #e5e7eb;
  }

  .dashboard-link-metric-grid .dashboard-stat-item:nth-child(-n + 2) {
    border-top: 0;
  }

  .dashboard-link-metric-grid .dashboard-stat-item:not(:nth-child(3n + 1)) {
    border-left: 0;
  }

  .dashboard-link-metric-grid .dashboard-stat-item:nth-child(even) {
    border-left: 1px solid #e5e7eb;
  }

  body.dark-mode .dashboard-stat-item:nth-child(-n + 3) {
    border-top-color: #1f2937;
  }

  body.dark-mode .dashboard-stat-item:nth-child(even) {
    border-left-color: #1f2937;
  }

  body.dark-mode .dashboard-link-metric-grid .dashboard-stat-item:nth-child(-n + 3) {
    border-top-color: #20283a;
  }

  body.dark-mode .dashboard-link-metric-grid .dashboard-stat-item:nth-child(even) {
    border-left-color: #20283a;
  }

  .data-grid-toolbar,
  .data-grid-footer {
    align-items: stretch;
    flex-direction: column;
  }

  .data-grid-toolbar-group,
  .data-grid-toolbar-group.right,
  .data-grid-size,
  .data-grid-pager {
    width: 100%;
    justify-content: flex-start;
  }

  .data-grid-search {
    width: 100%;
  }

  .data-grid-pager {
    align-items: flex-start;
    flex-direction: column;
  }

  .section-title {
    align-items: flex-start;
    flex-direction: column;
  }

  .section-title-actions,
  .date-range-control {
    width: 100%;
  }

  .date-range-control {
    justify-content: center;
  }

  .dashboard-funnel-row {
    grid-template-columns: 1fr;
    gap: 7px;
  }

  .dashboard-funnel-value {
    text-align: left;
  }

  .date-range-panel {
    left: 0;
    right: auto;
    width: min(590px, calc(100vw - 48px));
  }

  .range-calendar-content {
    grid-template-columns: 1fr;
  }

  .range-calendar-shortcuts {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    border-right: 0;
    border-bottom: 1px solid #e5e7eb;
  }

  .range-calendar-months {
    grid-template-columns: 1fr;
  }

  body.dark-mode .range-calendar-shortcuts {
    border-bottom-color: #1f2937;
  }
}

@media (max-width: 460px) {
  .dashboard-view-switch,
  .dashboard-filter-field {
    width: 100%;
  }

  .dashboard-view-button {
    flex: 1;
  }

  .dashboard-stat-strip {
    grid-template-columns: 1fr;
  }

  .dashboard-link-metric-grid,
  .dashboard-link-source-grid,
  .dashboard-link-grid {
    grid-template-columns: 1fr;
  }

  .dashboard-stat-item:first-child {
    grid-column: auto;
  }

  .dashboard-stat-item:nth-child(odd):not(:first-child),
  .dashboard-stat-item:nth-child(even) {
    border-left: 0;
  }

  .dashboard-stat-item:nth-child(3) {
    border-top: 1px solid #e5e7eb;
  }

  .dashboard-stat-item:nth-child(2) {
    border-top: 1px solid #e5e7eb;
  }

  .dashboard-link-metric-grid .dashboard-stat-item:nth-child(-n + 2),
  .dashboard-link-metric-grid .dashboard-stat-item:nth-child(3),
  .dashboard-link-metric-grid .dashboard-stat-item:nth-child(4),
  .dashboard-link-metric-grid .dashboard-stat-item:nth-child(5) {
    border-top: 1px solid #e5e7eb;
  }

  .dashboard-link-metric-grid .dashboard-stat-item:first-child {
    border-top: 0;
  }

  .dashboard-link-metric-grid .dashboard-stat-item:nth-child(odd):not(:first-child),
  .dashboard-link-metric-grid .dashboard-stat-item:nth-child(even) {
    border-left: 0;
  }

  body.dark-mode .dashboard-stat-item:nth-child(3) {
    border-top-color: #1f2937;
  }

  body.dark-mode .dashboard-stat-item:nth-child(2) {
    border-top-color: #1f2937;
  }

  body.dark-mode .dashboard-link-metric-grid .dashboard-stat-item:nth-child(-n + 2),
  body.dark-mode .dashboard-link-metric-grid .dashboard-stat-item:nth-child(3),
  body.dark-mode .dashboard-link-metric-grid .dashboard-stat-item:nth-child(4),
  body.dark-mode .dashboard-link-metric-grid .dashboard-stat-item:nth-child(5) {
    border-top-color: #20283a;
  }
}

.preview-dialog {
  width: min(960px, calc(100vw - 32px));
  border: 0;
  border-radius: 8px;
  padding: 0;
  background: transparent;
}

.preview-dialog::backdrop {
  background: rgba(0, 0, 0, 0.48);
}

.preview-box {
  background: #fff;
  border-radius: 8px;
  overflow: hidden;
  box-shadow: 0 28px 80px rgba(0, 0, 0, 0.26);
}

.preview-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 12px 14px;
  border-bottom: 1px solid #e5e5ea;
}

.preview-head strong {
  overflow-wrap: anywhere;
}

#previewVideo {
  display: block;
  width: 100%;
  max-height: min(72vh, 720px);
  background: #111;
}

@media (max-width: 880px) {
  .app-layout {
    --sidebar-width: 100%;
    grid-template-columns: 1fr;
  }

  .app-sidebar {
    z-index: 20;
    width: 100%;
    height: auto;
    padding: 0 14px;
    flex-direction: row;
    align-items: center;
    gap: 10px;
    overflow-x: auto;
  }

  .app-layout.sidebar-collapsed .app-sidebar:hover {
    width: 100%;
    box-shadow: none;
  }

  .topbar {
    display: grid;
    gap: 10px;
  }

  .topbar-search {
    width: 100%;
  }

  .account-actions {
    justify-content: flex-start;
    flex-wrap: wrap;
  }

  .sidebar-logo {
    flex: 0 0 auto;
  }

  .sidebar-logo-copy {
    display: none;
  }

  .sidebar-header {
    height: 54px;
    padding: 0 4px 0 0;
    flex: 0 0 auto;
  }

  .sidebar-toggle {
    display: none;
  }

  .sidebar-scroll {
    min-width: max-content;
    padding: 0;
    overflow: visible;
  }

  .sidebar-nav {
    display: flex;
    gap: 6px;
  }

  .sidebar-footer {
    margin-top: 0;
    margin-left: auto;
    padding: 0;
    flex: 0 0 auto;
  }

  .nav-item {
    width: auto;
    height: 34px;
    white-space: nowrap;
  }

  .app-layout.sidebar-collapsed .app-sidebar:not(:hover) .nav-item [data-slot='accordion-menu-title'],
  .app-layout.sidebar-collapsed .app-sidebar:not(:hover) .sidebar-footer {
    display: initial;
  }

  .shell {
    width: 100%;
    padding: 14px 12px 36px;
  }

  .hero,
  .workspace,
  .ads-metric-row,
  .camera-tools,
  .user-form {
    grid-template-columns: 1fr;
  }

  .ads-metric-card {
    min-height: 148px;
  }

  .hero {
    display: block;
  }

  .status-pill {
    display: inline-block;
    margin-top: 18px;
  }
}
