@font-face {
  font-family: "FogAct Studio";
  font-style: normal;
  font-weight: 400 800;
  font-display: swap;
  src: url("/assets/noto-sans-sc-studio.woff2?v=20261001-customer-links") format("woff2");
}

:root {
  --admin-bg: hsl(210, 40%, 98%);
  --admin-surface: #ffffff;
  --admin-surface-soft: hsl(210, 40%, 96%);
  --admin-surface-strong: hsl(214, 32%, 91%);
  --admin-ink: hsl(222, 47%, 11%);
  --admin-muted: hsl(215, 16%, 47%);
  --admin-soft: #64748b;
  --admin-line: hsl(214, 32%, 91%);
  --admin-line-strong: hsl(214, 32%, 85%);
  --admin-primary: hsl(221, 83%, 53%);
  --admin-primary-hover: hsl(221, 83%, 47%);
  --admin-primary-soft: hsl(221, 83%, 96%);
  --admin-sidebar-width: 256px;
  --admin-radius: 8px;
}

html.dark {
  --admin-bg: hsl(240, 10%, 3.9%);
  --admin-surface: hsl(240, 6%, 7%);
  --admin-surface-soft: hsl(240, 3.7%, 15.9%);
  --admin-surface-strong: hsl(240, 3.7%, 22%);
  --admin-ink: hsl(0, 0%, 98%);
  --admin-muted: hsl(240, 5%, 64.9%);
  --admin-soft: hsl(240, 5%, 64.9%);
  --admin-line: hsl(240, 3.7%, 15.9%);
  --admin-line-strong: hsl(240, 3.7%, 25%);
  --admin-primary: hsl(217, 91%, 60%);
  --admin-primary-hover: hsl(217, 91%, 65%);
  --admin-primary-soft: #14233b;
}

body.market-admin {
  font-family: ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Microsoft YaHei", "FogAct Studio", sans-serif;
}

.market-admin .admin-login-overlay {
  display: flex;
  flex-direction: row;
  align-items: stretch;
  justify-content: flex-start;
  overflow-y: auto;
  padding: 0 !important;
  background: var(--admin-bg) !important;
}

.query-login-brand {
  position: relative;
  display: flex;
  flex: 0 0 55%;
  align-items: center;
  min-height: 100%;
  padding: max(64px, env(safe-area-inset-top)) 64px max(64px, env(safe-area-inset-bottom));
  overflow: hidden;
  color: #fff;
  background: radial-gradient(ellipse at 5% 10%, #1d3b6355, transparent 55%), radial-gradient(ellipse at 95% 95%, #37308a33, transparent 50%), linear-gradient(135deg, #0f172a, #1e293b, #0f172a);
}

.query-login-brand::before { content: ""; position: absolute; inset: 0; background-image: radial-gradient(circle, #ffffff26 1px, transparent 1px); background-size: 24px 24px; opacity: .12; pointer-events: none; }
html.dark .query-login-brand { background: linear-gradient(135deg, #030712, #0f172a, #030712); }
.query-brand-content { position: relative; width: 100%; max-width: 600px; }
.query-wordmark { display: flex; align-items: center; gap: 12px; margin-bottom: 32px; font-size: 20px; font-weight: 600; letter-spacing: .5px; }
.query-cloud { display: inline-flex; align-items: center; justify-content: center; width: 40px; height: 40px; border: 1px solid #ffffff26; border-radius: 12px; background: #ffffff10; }
.query-cloud svg { width: 20px; height: 20px; flex-shrink: 0; }
.query-brand-content h2 { font-size: 48px; font-weight: 700; line-height: 1.2; margin: 0 0 16px; }
.query-brand-content > p { max-width: 450px; font-size: 18px; line-height: 1.7; color: #ffffff99; }
.query-brand-tags { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 32px; }
.query-brand-tags span { padding: 6px 12px; border: 1px solid #ffffff19; border-radius: 999px; background: #ffffff0f; color: #ffffff99; font-size: 12px; }
.studio-login-layout { position: relative; display: flex; align-items: center; justify-content: center; flex: 1; min-width: 0; padding: max(64px, env(safe-area-inset-top)) max(48px, env(safe-area-inset-right)) max(48px, env(safe-area-inset-bottom)); }
.studio-access { width: 100%; max-width: 384px; padding: 0; }
.studio-access header { margin-bottom: 32px; }
.studio-access h1 { color: var(--admin-ink); font-size: 24px; font-weight: 700; line-height: 1.35; }
.studio-access header p { margin-top: 8px; color: var(--admin-muted); font-size: 14px; line-height: 1.6; }
.query-theme-toggle { position: absolute; top: max(16px, env(safe-area-inset-top)); right: max(16px, env(safe-area-inset-right)); display: grid; place-items: center; width: 36px; height: 36px; border: 0; border-radius: 6px; background: transparent; color: var(--admin-muted); cursor: pointer; }
.query-theme-toggle:hover { background: var(--admin-surface-soft); color: var(--admin-ink); }
.query-theme-toggle .material-symbols-outlined { font-size: 19px; }
.studio-password-wrap { position: relative; }
.market-admin .studio-password-wrap input { min-height: 40px; padding-right: 44px !important; border-radius: 6px !important; border-color: var(--admin-line) !important; background: var(--admin-bg) !important; font-size: 14px !important; }
.market-admin .studio-password-wrap input:focus { border-color: var(--admin-primary) !important; }
.market-admin .admin-login-field label { font-size: 14px; font-weight: 500; }
#login-password-toggle { position: absolute; top: 0; right: 0; display: grid; place-items: center; width: 40px; height: 40px; border: 0; border-radius: 6px; color: var(--admin-muted); background: transparent; cursor: pointer; }
#login-password-toggle:hover { color: var(--admin-ink); }
#login-password-toggle .material-symbols-outlined { display: block; font-size: 0; width: 16px; height: 16px; background: currentColor; mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='1.5'%3E%3Cpath d='M2 12s4-7 10-7 10 7 10 7-4 7-10 7S2 12 2 12Z'/%3E%3Ccircle cx='12' cy='12' r='3'/%3E%3C/svg%3E") center / contain no-repeat; }
#login-password-toggle[aria-pressed="true"]::after { content: ""; position: absolute; width: 20px; height: 1.5px; background: currentColor; transform: rotate(-45deg); }
.studio-caps-lock { color: var(--admin-warning); font-size: 12px; }
.market-admin #login-submit { justify-content: center; min-height: 44px; margin-top: 24px; border-radius: 6px !important; font-weight: 500; }
.market-admin #login-submit:disabled { opacity: .5; cursor: wait; }

.market-admin #admin-sidebar { background: var(--admin-surface) !important; padding-top: var(--admin-safe-top) !important; }
.market-admin .admin-sidebar-brand { min-height: 56px; margin: 0 0 20px; padding: 0 10px; gap: 10px; }
.market-admin .admin-sidebar-brand .market-logo { width: 32px; height: 32px; border: 0; border-radius: 8px; color: #fff; background: linear-gradient(135deg, var(--admin-primary), color-mix(in srgb, var(--admin-primary) 60%, #fff)); }
.admin-sidebar-brand-title { font-size: 17px; font-weight: 600; }
.admin-sidebar-brand-subtitle { font-size: 10px; }
.admin-nav-label { font-size: 11px; font-weight: 500; }
.market-admin #admin-sidebar .nav-item { min-height: 40px; margin: 2px 0; border-radius: 8px !important; font-size: 13px; }
.market-admin #admin-sidebar .nav-item .material-symbols-outlined { font-size: 18px; }
.market-admin #admin-sidebar .nav-item.active, .market-admin #admin-sidebar .nav-item.bg-surface-container-lowest { color: var(--admin-primary) !important; background: var(--admin-primary-soft) !important; }
.market-admin .admin-sidebar-account-avatar { border-radius: 8px; color: var(--admin-primary); background: var(--admin-primary-soft); }
.studio-sidebar-link { display: flex; align-items: center; gap: 8px; padding: 14px 8px; color: var(--admin-muted) !important; font-size: 12px; text-decoration: none; }
.studio-sidebar-link:hover { color: var(--admin-primary) !important; }
.studio-sidebar-link .material-symbols-outlined, .studio-overview-heading > a .material-symbols-outlined { width: 17px; font-size: 0; }
.studio-sidebar-link .material-symbols-outlined::after, .studio-overview-heading > a .material-symbols-outlined::after { content: "↗"; font-family: sans-serif; font-size: 17px; }
.market-admin .admin-header { background: var(--admin-surface) !important; backdrop-filter: none; }
.studio-overview-heading { display: flex; justify-content: space-between; align-items: center; gap: 24px; margin: 0 0 24px; }
.studio-overview-heading h2 { margin: 0 0 6px; font-size: 24px; font-weight: 700; }
.studio-overview-heading p { font-size: 14px; color: var(--admin-muted); }
.studio-overview-heading > a { display: inline-flex; align-items: center; gap: 10px; padding: 8px 12px; border: 1px solid var(--admin-line); border-radius: 6px; background: var(--admin-surface); font-size: 12px; white-space: nowrap; text-decoration: none; }
.studio-overview-heading > a:hover { background: var(--admin-surface-soft); }
.market-admin .admin-stat-grid { gap: 16px !important; background: transparent; border: 0; border-radius: 0; }
.market-admin .admin-metric, .market-admin .admin-metric:first-child { padding: 24px; border: 1px solid var(--admin-line); border-radius: 12px; background: var(--admin-surface); color: var(--admin-ink); }
.market-admin .admin-metric h2, .market-admin .admin-metric:first-child h2 { color: var(--admin-ink); font-size: 26px; font-weight: 700; }
.market-admin .admin-metric-head p, .market-admin .admin-metric:first-child .admin-metric-head p, .market-admin .admin-metric:first-child .admin-metric-sub { color: var(--admin-muted); }
.market-admin .admin-metric-icon { border-radius: 10px; }
.market-admin .admin-metric:first-child .admin-metric-icon { color: var(--admin-primary); background: var(--admin-primary-soft); }
.market-admin .admin-workspace, .market-admin .admin-activity-panel, .market-admin .admin-quick-actions { border-radius: 12px !important; box-shadow: none !important; }
.market-admin .admin-command-icon { border-radius: 8px; }
.market-admin thead { background: var(--admin-surface-soft) !important; }
.market-admin #app-container .bg-primary { color: #fff !important; }

@media (min-width: 901px) {
  .market-admin .admin-header { height: 56px !important; min-height: 56px !important; padding: 0 24px !important; }
  .market-admin .admin-main { padding: 24px !important; }
  .market-admin .admin-stat-grid { grid-template-columns: repeat(4, minmax(0, 1fr)) !important; }
  .market-admin .admin-dashboard-grid { grid-template-columns: minmax(0, 1.25fr) minmax(0, 1fr) !important; }
}

@media (min-width: 768px) and (max-width: 1100px) {
  .query-login-brand { flex-basis: 50%; padding: 48px 40px; }
  .query-brand-content h2 { font-size: 36px; }
  .query-brand-content > p { font-size: 16px; }
  .studio-login-layout { padding-left: 32px; padding-right: 32px; }
}

@media (max-width: 767px) {
  .market-admin .admin-login-overlay { flex-direction: column; }
  .query-login-brand { flex: 0 0 auto; min-height: 0; padding: max(24px, env(safe-area-inset-top)) 24px 24px; }
  .query-wordmark { margin-bottom: 0; }
  .query-brand-content h2, .query-brand-content > p, .query-brand-tags { display: none; }
  .studio-login-layout { flex: 1 0 auto; padding: 64px max(24px, env(safe-area-inset-right)) max(48px, env(safe-area-inset-bottom)) max(24px, env(safe-area-inset-left)); }
  .studio-access { max-width: 384px; }
  .studio-overview-heading { align-items: flex-start; gap: 16px; margin-bottom: 24px; flex-direction: column; }
  .studio-overview-heading h2 { font-size: 22px; }
  .market-admin .admin-stat-grid { gap: 12px !important; }
  .market-admin .admin-metric, .market-admin .admin-metric:first-child { padding: 18px; }
}

.user-access-summary { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; margin-bottom: 24px; }
.user-access-summary > div { padding: 18px 20px; border: 1px solid var(--admin-line); border-radius: 10px; background: var(--admin-surface); }
.user-access-summary span, .user-access-summary small { display: block; color: var(--admin-muted); font-size: 12px; }
.user-access-summary strong { display: block; margin: 9px 0; font-size: 26px; font-weight: 700; font-variant-numeric: tabular-nums; }
.user-access-summary small { font-size: 10px; line-height: 1.6; }
#users-panel .admin-filter-bar { flex-wrap: wrap; }
#users-panel .admin-filter-bar select { padding: 9px 12px; border: 1px solid var(--admin-line); border-radius: 6px; background: var(--admin-surface); color: var(--admin-ink); font-size: 12px; }
.user-access-note { margin: 0 0 20px; color: var(--admin-muted); font-size: 12px; line-height: 1.8; }
#user-access-error { margin-bottom: 16px; padding: 12px; border-radius: 8px; background: var(--admin-danger-soft); color: var(--admin-danger); font-size: 13px; }
#users-table-container { overflow: visible !important; }
.user-access-avatar { display: grid; place-items: center; width: 36px; height: 36px; border-radius: 8px; background: var(--admin-surface-soft); color: var(--admin-primary); font-size: 15px; font-weight: 600; }
.user-access-detail-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 16px; }
.user-access-detail-head > div:first-child { min-width: 0; overflow-wrap: anywhere; }
.user-access-detail-head p { margin-top: 5px; font-size: 12px; color: var(--admin-muted); }
.user-access-actions { display: flex; gap: 8px; flex-shrink: 0; }
.user-access-actions button, #user-access-clear-location { padding: 6px 10px; border: 1px solid var(--admin-line); border-radius: 6px; color: var(--admin-primary); background: var(--admin-surface); font-size: 12px; cursor: pointer; }
.user-access-actions [data-user-delete] { color: var(--admin-danger); }
.user-access-facts { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 18px; padding: 22px 0; }
.user-access-facts dt { color: var(--admin-muted); font-size: 11px; }
.user-access-facts dd { margin-top: 6px; font-size: 18px; font-weight: 600; overflow-wrap: anywhere; }
.user-access-last { font-size: 11px; color: var(--admin-muted); padding-bottom: 20px; }
.user-access-tabs { display: flex; gap: 4px; padding: 4px; border-radius: 8px; background: var(--admin-surface-soft); margin-bottom: 22px; }
.user-access-tabs button { flex: 1; min-height: 36px; border: 0; border-radius: 6px; background: transparent; color: var(--admin-muted); font-size: 12px; cursor: pointer; }
.user-access-tabs button[aria-pressed="true"] { color: var(--admin-primary); background: var(--admin-surface); box-shadow: 0 1px 3px #0000000d; }
.user-access-chart-heading { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; gap: 10px; margin-bottom: 16px; font-size: 12px; }
.user-access-chart-heading > span { color: var(--admin-muted); font-size: 11px; }
.user-access-chart { display: flex; gap: 5px; height: 150px; border-bottom: 1px solid var(--admin-line); background: repeating-linear-gradient(to top, transparent, transparent 49px, var(--admin-line) 49px, var(--admin-line) 50px); }
.user-access-chart button { display: flex; flex: 1; align-items: flex-end; height: 100%; min-width: 0; max-width: 52px; padding: 0; border: 0; background: transparent; cursor: pointer; }
.user-access-chart button > span { display: block; width: 100%; background: var(--admin-primary); border-radius: 4px 4px 0 0; opacity: .7; }
.user-access-chart button:hover > span, .user-access-chart button[aria-pressed="true"] > span { opacity: 1; }
.user-access-chart-range { display: flex; justify-content: space-between; margin-top: 10px; color: var(--admin-muted); font-size: 10px; }
.user-access-explanation { color: var(--admin-muted); font-size: 11px; line-height: 1.8; margin-bottom: 14px; }
.user-access-locations { display: flex; flex-direction: column; }
.user-access-locations button { display: flex; justify-content: space-between; align-items: center; gap: 12px; text-align: left; padding: 14px 0; border: 0; border-bottom: 1px solid var(--admin-line); background: transparent; color: var(--admin-ink); font-size: 12px; cursor: pointer; }
.user-access-locations button > span { min-width: 0; overflow-wrap: anywhere; }
.user-access-locations button > strong { flex-shrink: 0; }
.user-access-locations button:hover { color: var(--admin-primary); }
.user-access-locations small { display: block; margin-top: 5px; font-size: 10px; color: var(--admin-muted); }
.user-access-recent article { padding: 14px 0; border-bottom: 1px solid var(--admin-line); }
.user-access-recent article > div { display: flex; justify-content: space-between; gap: 12px; font-size: 12px; overflow-wrap: anywhere; }
.user-access-recent p, .user-access-recent small { display: block; margin-top: 6px; font-size: 11px; color: var(--admin-muted); overflow-wrap: anywhere; }
.access-success { color: var(--admin-success); }
.access-failed { color: var(--admin-danger); }
.user-access-empty { padding: 32px 12px; text-align: center; color: var(--admin-muted); font-size: 13px; line-height: 1.8; }
@media (max-width: 620px) {
  .user-access-detail-head { flex-direction: column; }
  .user-access-summary { gap: 10px; }
  .user-access-summary > div { padding: 14px; }
  .user-access-summary strong { font-size: 22px; }
  .user-access-chart { gap: 3px; }
}

.customer-toolbar {
  display: grid;
  grid-template-columns: minmax(220px, 1.6fr) repeat(3, minmax(130px, .7fr)) auto;
  gap: 10px;
  align-items: end;
  padding: 14px;
  margin: 0 0 18px;
  border: 1px solid var(--admin-line);
  border-radius: 10px;
  background: var(--admin-surface-soft);
}
.customer-toolbar > div { min-width: 0; }
.customer-toolbar #user-search { display: block !important; }
.customer-toolbar label { display: block; margin: 0 0 6px 2px; color: var(--admin-muted); font-size: 11px; font-weight: 600; }
.customer-toolbar input, .customer-toolbar select { width: 100%; min-height: 38px; padding: 0 11px; border: 1px solid var(--admin-line); border-radius: 6px; color: var(--admin-ink); background: var(--admin-surface); outline: none; font: inherit; font-size: 12px; }
.customer-toolbar input:focus, .customer-toolbar select:focus { border-color: var(--admin-primary); box-shadow: 0 0 0 3px color-mix(in srgb, var(--admin-primary) 15%, transparent); }
.customer-toolbar button { min-height: 38px; padding: 0 11px; border: 0; color: var(--admin-primary); background: transparent; font-size: 12px; white-space: nowrap; cursor: pointer; }
.customer-toolbar button:disabled { color: var(--admin-soft); cursor: not-allowed; }
.customer-list-meta { display: flex; justify-content: space-between; gap: 12px; margin: 0 0 10px; color: var(--admin-muted); font-size: 11px; }
.customer-list-meta span:first-child { color: var(--admin-ink); font-weight: 600; }
.customer-notice { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin: 0 0 14px; padding: 10px 12px; border: 1px solid color-mix(in srgb, var(--admin-warning) 28%, var(--admin-line)); border-radius: 8px; color: var(--admin-warning); background: var(--admin-warning-soft); font-size: 12px; }
.customer-notice button, #user-access-error button { flex-shrink: 0; border: 0; color: inherit; background: transparent; text-decoration: underline; cursor: pointer; }
#user-access-error { display: flex; justify-content: space-between; gap: 12px; margin: 0 0 14px; padding: 11px 12px; border: 1px solid var(--admin-danger); border-radius: 8px; color: var(--admin-danger); background: var(--admin-danger-soft); font-size: 12px; }
#customer-loading { padding: 10px 0; color: var(--admin-muted); font-size: 12px; }
#users-table-container { overflow-x: auto !important; border: 1px solid var(--admin-line); border-radius: 10px; background: var(--admin-surface); }
.customer-table { min-width: 850px; }
.customer-table th { padding: 11px 14px; border-bottom: 1px solid var(--admin-line); color: var(--admin-muted); background: var(--admin-surface-soft); font-size: 10px; font-weight: 650; text-align: left; white-space: nowrap; }
.customer-table td { padding: 14px; border-bottom: 1px solid var(--admin-line); color: var(--admin-ink); font-size: 12px; vertical-align: middle; }
.customer-table tbody tr:last-child td { border-bottom: 0; }
.customer-table tbody tr:hover, .customer-table tbody tr.is-selected { background: var(--admin-primary-soft); }
.customer-identity { display: flex; align-items: center; gap: 10px; min-width: 190px; }
.customer-identity > div { min-width: 0; }
.customer-identity small, .customer-table td > span + small, .customer-table td > small { display: block; margin-top: 4px; color: var(--admin-muted); font-size: 10px; overflow-wrap: anywhere; }
.customer-name { display: block; max-width: 220px; padding: 0; overflow: hidden; border: 0; color: var(--admin-ink); background: transparent; font-size: 13px; font-weight: 650; text-align: left; text-overflow: ellipsis; white-space: nowrap; cursor: pointer; }
.customer-name:hover { color: var(--admin-primary); text-decoration: underline; text-underline-offset: 3px; }
.customer-status { display: inline-flex; padding: 4px 8px; border-radius: 999px; font-size: 10px; white-space: nowrap; }
.customer-request-count { font-size: 16px; font-variant-numeric: tabular-nums; }
.customer-view-button { padding: 6px 9px; border: 1px solid var(--admin-line); border-radius: 6px; color: var(--admin-primary); background: var(--admin-surface); font-size: 11px; cursor: pointer; }
.customer-view-button:hover { border-color: var(--admin-primary); background: var(--admin-primary-soft); }
.market-admin .customer-table .customer-name { display: block; width: auto; height: auto; padding: 0 !important; text-align: left; }
.market-admin .customer-table .customer-view-button { width: auto; height: auto; min-height: 32px; padding: 6px 9px !important; border: 1px solid var(--admin-line); background: var(--admin-surface) !important; white-space: nowrap; }
.market-admin .customer-table th:last-child, .market-admin .customer-table td:last-child { min-width: 100px; }
.market-admin .customer-table tbody tr.is-selected { background: var(--admin-primary-soft) !important; }
.customer-empty { padding: 64px 20px; text-align: center; }
.customer-empty h4 { font-size: 15px; font-weight: 650; }
.customer-empty p { margin: 8px 0 18px; color: var(--admin-muted); font-size: 12px; }
.customer-empty button { min-height: 36px; padding: 0 14px; border: 0; border-radius: 6px; color: #fff; background: var(--admin-primary); font-size: 12px; cursor: pointer; }
.customer-help { margin-top: 16px; color: var(--admin-muted); font-size: 11px; }
.customer-help summary { display: inline-block; cursor: pointer; color: var(--admin-primary); }
.customer-help .user-access-note { margin: 10px 0 0; line-height: 1.8; }
.customer-drawer { width: min(620px, calc(100vw - 20px)); max-width: none; height: min(100dvh, 820px); max-height: calc(100dvh - 20px); margin: 10px 10px 10px auto; padding: 0; overflow: hidden; border: 1px solid var(--admin-line); border-radius: 14px; color: var(--admin-ink); background: var(--admin-surface); box-shadow: -14px 0 50px #0000001c; }
.customer-drawer::backdrop { background: #11182766; backdrop-filter: blur(3px); }
.customer-drawer:not([open]) { display: none; }
.customer-drawer[open] { display: flex; flex-direction: column; animation: customer-drawer-in 180ms ease-out both; }
@keyframes customer-drawer-in { from { opacity: 0; transform: translateX(30px); } to { opacity: 1; transform: translateX(0); } }
.customer-drawer-header { display: flex; align-items: flex-start; justify-content: space-between; gap: 20px; padding: 22px 24px 18px; border-bottom: 1px solid var(--admin-line); }
.customer-drawer-header h2 { font-size: 18px; font-weight: 700; }
.customer-drawer-header p { margin-top: 5px; color: var(--admin-muted); font-size: 11px; }
.customer-drawer-header button { width: 30px; height: 30px; border: 0; border-radius: 6px; color: var(--admin-muted); background: transparent; font-size: 25px; line-height: 1; cursor: pointer; }
.customer-drawer-header button:hover { color: var(--admin-ink); background: var(--admin-surface-soft); }
.customer-drawer-body { flex: 1; min-height: 0; padding: 22px 24px; overflow-y: auto; overscroll-behavior: contain; }
.customer-drawer-body .user-access-detail { padding: 0; border: 0; }
.customer-drawer-footer { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 12px 24px; border-top: 1px solid var(--admin-line); background: var(--admin-surface-soft); }
.customer-drawer-footer button { min-width: 62px; min-height: 30px; border: 1px solid var(--admin-line); border-radius: 6px; color: var(--admin-primary); background: var(--admin-surface); font-size: 11px; cursor: pointer; }
.customer-drawer-footer button:disabled { color: var(--admin-soft); cursor: not-allowed; }
.customer-drawer-footer span { color: var(--admin-muted); font-size: 11px; }
.customer-drawer .user-access-detail-head { padding-bottom: 18px; }
.customer-drawer .user-access-facts { padding: 18px 0; }
.customer-drawer .user-access-tabs { margin-top: 2px; }
.customer-drawer-header, .customer-drawer-footer { flex-shrink: 0; }
.customer-drawer-header h2 { overflow-wrap: anywhere; }
.customer-drawer .user-access-facts { grid-template-columns: repeat(3, minmax(0, 1fr)); border-top: 1px solid var(--admin-line); }
.user-access-tabs button[aria-selected="true"] { color: var(--admin-primary); background: var(--admin-surface); box-shadow: 0 1px 3px #0000000d; }
.customer-notice[hidden], #user-access-error[hidden], #customer-loading[hidden] { display: none !important; }
.customer-danger { padding-top: 18px; margin-top: 24px; border-top: 1px solid var(--admin-line); color: var(--admin-muted); font-size: 12px; }
.customer-danger summary { cursor: pointer; }
.customer-danger p { margin: 12px 0; line-height: 1.7; }
.customer-danger button { padding: 8px 12px; border: 1px solid var(--admin-danger); border-radius: 6px; color: var(--admin-danger); background: var(--admin-surface); cursor: pointer; }
#customer-detail-error { margin-top: 16px; padding: 12px; color: var(--admin-danger); background: var(--admin-danger-soft); border-radius: 8px; font-size: 12px; }
body.market-admin:has(#customer-detail-dialog[open]) { overflow: hidden; }
#users-panel[aria-busy="true"] #users-table-container { opacity: .55; pointer-events: none; }
@media (max-width: 1100px) {
  .customer-toolbar { grid-template-columns: minmax(220px, 1fr) repeat(2, minmax(130px, .7fr)); }
  .customer-toolbar > div:nth-of-type(4), .customer-toolbar > button { grid-column: span 1; }
}
@media (max-width: 700px) {
  .customer-toolbar { grid-template-columns: 1fr 1fr; }
  .customer-toolbar .customer-search-field { grid-column: 1 / -1; }
  .customer-toolbar button { justify-self: start; }
  .customer-list-meta { align-items: flex-start; flex-direction: column; gap: 4px; }
  #users-table-container { border: 0; background: transparent; overflow: visible !important; }
  .customer-table, .customer-table tbody, .customer-table tr, .customer-table td { display: block; min-width: 0; }
  .customer-table { border: 0; }
  .customer-table thead { display: none; }
  .customer-table tr { margin-bottom: 10px; padding: 12px; border: 1px solid var(--admin-line); border-radius: 10px; background: var(--admin-surface); }
  .customer-table td { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 8px 0; border: 0; }
  .market-admin .customer-table td { height: auto; min-height: 36px; padding: 8px 0 !important; }
  .customer-table td:first-child { display: block; padding-top: 0; }
  .customer-table td::before { content: attr(data-label); flex: 0 0 auto; color: var(--admin-muted); font-size: 10px; }
  .customer-table td:first-child::before { display: none; }
  .customer-table td:last-child { justify-content: flex-end; border-top: 1px solid var(--admin-line); margin-top: 5px; padding-top: 12px; }
  .customer-drawer { width: calc(100vw - 12px); height: calc(100dvh - 12px); max-height: none; margin: 6px 6px 6px auto; border-radius: 12px; }
  .customer-drawer-header, .customer-drawer-body { padding-left: 18px; padding-right: 18px; }
  .customer-drawer-footer { padding-left: 18px; padding-right: 18px; }
  .customer-notice { flex-direction: column; align-items: flex-start; }
  .user-access-summary > div { padding: 12px; }
  .user-access-summary small { display: none; }
  .user-access-summary span { font-size: 10px; }
  .user-access-summary strong { font-size: 22px; }
  .customer-table td[data-label="最近来源"] { flex-wrap: wrap; }
  .customer-table td[data-label="最近来源"] small { width: 100%; text-align: right; }
}
@media (prefers-reduced-motion: reduce) {
  .customer-drawer[open] { animation: none; }
}
