/* 2026-10-06: mobile administration, scoped to the existing admin shell. */
@media(max-width:767px){
 html[data-hs-admin] [data-slot="sidebar-inset"]>header{height:auto!important;min-height:68px;flex-wrap:nowrap!important;gap:8px!important;padding:10px 12px!important;position:relative;z-index:20;box-sizing:border-box}
 html[data-hs-admin] [data-slot="sidebar-inset"]>header>[data-slot="sidebar-trigger"]{width:44px;min-width:44px;height:44px;margin:0}
 html[data-hs-admin] [data-slot="sidebar-inset"]>header>div.flex-1{min-width:0}
 html[data-hs-admin] [data-slot="sidebar-inset"]>header>div:has(>[role="combobox"]){gap:8px;min-width:0}
 html[data-hs-admin] [data-slot="sidebar-inset"]>header [role="combobox"]{width:100px!important;height:44px!important;min-height:44px;font-size:14px}
 html[data-hs-admin] [data-slot="sidebar-inset"]>header [data-slot="popover-trigger"]{width:44px;min-width:44px;height:44px;padding:12px}
 .hs-mobile-more{position:relative;flex:0 0 44px;margin:0}
 .hs-mobile-more>summary{display:flex;align-items:center;justify-content:center;width:44px;height:44px;list-style:none;cursor:pointer;color:var(--hs-admin-text);border-radius:14px;background:var(--hs-admin-surface)}
 .hs-mobile-more>summary::-webkit-details-marker{display:none}
 .hs-mobile-more>summary:focus-visible{outline:2px solid var(--hs-admin-focus);outline-offset:2px}
 .hs-mobile-more[open]>summary{background:var(--hs-admin-selected)}
 .hs-mobile-more-content{position:absolute;right:0;top:calc(100% + 10px);width:min(260px,calc(100vw - 24px));padding:12px;border-radius:20px;background:var(--hs-admin-surface);box-shadow:0 10px 30px rgb(23 36 51 / 18%);display:grid;gap:8px;z-index:30}
 .hs-mobile-more-content:before{content:'后台工具';font-size:13px;font-weight:600;color:var(--hs-admin-muted);padding:4px 8px}
 html[data-hs-admin] .hs-mobile-more-content :is(#hs-upgrade-link,#hs-account-link){margin:0!important;min-height:44px;display:flex;align-items:center;justify-content:flex-start;box-sizing:border-box;font-size:14px!important;padding:10px 12px!important}
 html[data-hs-admin] .hs-mobile-more-content .hs-workspace-tools{display:grid;gap:4px;width:100%;padding:0;margin:0}
 html[data-hs-admin] .hs-mobile-more-content .hs-workspace-tools button{display:flex;justify-content:flex-start;width:100%;min-height:44px;border-radius:12px;box-shadow:none;gap:10px;padding:10px 12px}
 .hs-mobile-more-content .hs-tool-label{display:inline!important;font-size:14px}
 html[data-hs-admin] [data-slot="sidebar-inset"]>div{min-width:0;max-width:100%;padding-top:24px}
 html[data-hs-admin] h1{font-size:26px;line-height:1.25;overflow-wrap:anywhere}
 html[data-hs-admin] h1+p{font-size:14px;line-height:1.65}
 html[data-hs-admin] .hs-mobile-profile-list{overflow:visible!important;background:transparent!important;box-shadow:none!important;border:0!important;border-radius:0!important}
 html[data-hs-admin] .hs-mobile-profile-list table{display:block;width:100%;min-width:0!important}
 html[data-hs-admin] .hs-mobile-profile-list thead{position:absolute;width:1px;height:1px;padding:0;margin:-1px;overflow:hidden;clip:rect(0,0,0,0);white-space:nowrap}
 html[data-hs-admin] .hs-mobile-profile-list tbody{display:grid;gap:12px;width:100%}
 html[data-hs-admin] .hs-mobile-profile-list tbody tr{display:grid;grid-template-columns:28px minmax(0,1fr) minmax(0,1fr);gap:10px 8px;padding:16px 12px;width:100%;box-sizing:border-box;background:var(--hs-admin-reading);border:1px solid var(--hs-admin-line);border-radius:16px}
 html[data-hs-admin] .hs-mobile-profile-list td{display:block;padding:0!important;min-width:0;max-width:100%;white-space:normal!important;font-size:13px;line-height:1.5;overflow-wrap:anywhere}
 html[data-hs-admin] .hs-mobile-profile-list td:before{content:attr(data-mobile-label);display:block;color:var(--hs-admin-muted);font-size:11px;margin-bottom:3px}
 html[data-hs-admin] .hs-mobile-profile-list td:nth-child(1){grid-column:1;grid-row:1;align-self:start}
 html[data-hs-admin] .hs-mobile-profile-list td:nth-child(1):before,html[data-hs-admin] .hs-mobile-profile-list td:nth-child(2):before{display:none}
 html[data-hs-admin] .hs-mobile-profile-list td:nth-child(2){grid-column:2/-1;grid-row:1}
 html[data-hs-admin] .hs-mobile-profile-list td:nth-child(2)>div{align-items:flex-start;gap:10px}
 html[data-hs-admin] .hs-mobile-profile-list td:nth-child(2) a{font-size:15px;white-space:normal;overflow-wrap:anywhere}
 html[data-hs-admin] .hs-mobile-profile-list td:nth-child(2) .font-mono{font-size:10px;white-space:normal;overflow-wrap:anywhere;max-width:100%}
 html[data-hs-admin] .hs-mobile-profile-list td:nth-child(3){grid-column:2/-1}
 html[data-hs-admin] .hs-mobile-profile-list td:nth-child(4){grid-column:2}
 html[data-hs-admin] .hs-mobile-profile-list td:nth-child(5){grid-column:3}
 html[data-hs-admin] .hs-mobile-profile-list td:nth-child(6){grid-column:2/-1}
 html[data-hs-admin] .hs-mobile-profile-list td:nth-child(7){grid-column:2/-1;border-top:1px solid var(--hs-admin-line);padding-top:8px!important}
 html[data-hs-admin] .hs-mobile-profile-list td:nth-child(7)>div{justify-content:flex-start;gap:8px}
 html[data-hs-admin] .hs-mobile-profile-list td:nth-child(7) button{width:44px;min-width:44px;min-height:44px}
 html[data-hs-admin] .hs-mobile-profile-list [role="checkbox"]{width:24px;height:24px;border-radius:8px}
 html[data-hs-admin] .hs-mobile-profile-list td:nth-child(2) .group>div{position:static!important;opacity:1!important;display:flex;flex-wrap:wrap;gap:4px;margin-top:8px}
 html[data-hs-admin] .hs-mobile-profile-list td:nth-child(2) .group>div button{width:36px;min-width:36px;min-height:44px;height:44px;box-shadow:none}
 html[data-hs-admin] [data-slot="dialog-content"],html[data-hs-admin] [data-slot="alert-dialog-content"]{max-width:calc(100vw - 24px)!important;max-height:calc(100dvh - 32px);overflow-y:auto}
 html[data-hs-admin] .hs-page-jump{flex-wrap:wrap}
}

@media(max-width:767px){
 html[data-hs-admin] .hs-mobile-filter-bar{display:block!important;width:100%;min-width:0}
 html[data-hs-admin] .hs-mobile-filter-bar>div:empty{display:none}
 html[data-hs-admin] .hs-mobile-filter-bar>div:has(>.hs-mobile-filters){width:100%;min-width:0;display:block}
 html[data-hs-admin] .hs-mobile-filters{display:grid!important;grid-template-columns:minmax(0,1fr) minmax(0,1fr);gap:10px!important;width:100%;min-width:0}
 html[data-hs-admin] .hs-mobile-filters form{grid-column:1/-1;display:flex;width:100%;min-width:0;gap:8px}
 html[data-hs-admin] .hs-mobile-filters form input{flex:1;width:0;min-width:0;height:44px}
 html[data-hs-admin] .hs-mobile-filters>[role="combobox"]{width:100%;min-width:0;height:44px}
 html[data-hs-admin] .hs-mobile-filters>button:not([role="combobox"]){grid-column:1/-1;justify-self:start;min-height:44px}
 html[data-hs-admin] div:has(>.hs-mobile-profile-list){border:0!important}
}

/* 2026-10-06: give brand marks enough room on mobile without enlarging member avatars. */
@media(max-width:767px){
 html[data-hs-admin] .hs-mobile-profile-list .hs-profile-brand td:nth-child(2) .group{width:92px}
 html[data-hs-admin] .hs-mobile-profile-list .hs-profile-brand [data-slot="avatar"]{width:72px!important;height:72px!important;border-radius:14px!important;background:#fff;margin-inline:auto;padding:4px;box-sizing:border-box}
 html[data-hs-admin] .hs-mobile-profile-list .hs-profile-brand [data-slot="avatar-image"]{width:100%;height:100%;object-fit:contain;border-radius:10px}
 html[data-hs-admin] .hs-mobile-profile-list .hs-profile-brand td:nth-child(2) .group>div{justify-content:center}
 html[data-hs-admin] .hs-mobile-profile-list .hs-profile-brand td:nth-child(2) .group>div button{width:44px;min-width:44px}
}

/* Compact scan-first mobile profiles; original action handlers remain intact. */
.hs-row-more{display:none}
@media(max-width:767px){
html[data-hs-admin] .hs-mobile-profile-list tbody{gap:8px}
html[data-hs-admin] .hs-mobile-profile-list tbody tr{position:relative;display:block;padding:12px;min-height:130px;border-radius:16px}
html[data-hs-admin] .hs-mobile-profile-list td:before{display:none}
html[data-hs-admin] .hs-mobile-profile-list td:nth-child(1),html[data-hs-admin] .hs-mobile-profile-list td:nth-child(4),html[data-hs-admin] .hs-mobile-profile-list td:nth-child(5),html[data-hs-admin] .hs-mobile-profile-list td:nth-child(7){display:none}
html[data-hs-admin] .hs-mobile-profile-list td:nth-child(2)>div{align-items:center;gap:12px;padding-right:34px}
html[data-hs-admin] .hs-mobile-profile-list td:nth-child(2) .group{width:72px!important}
html[data-hs-admin] .hs-mobile-profile-list td:nth-child(2) .group>div{display:none!important}
html[data-hs-admin] .hs-mobile-profile-list td:nth-child(2) .font-mono{display:none}
html[data-hs-admin] .hs-mobile-profile-list td:nth-child(2) a{font-size:14px;line-height:1.35}
html[data-hs-admin] .hs-mobile-profile-list td:nth-child(2) span.truncate{font-size:11px;white-space:normal;overflow-wrap:anywhere}
html[data-hs-admin] .hs-mobile-profile-list td:nth-child(3){margin-left:84px;margin-top:4px;font-size:12px;line-height:1.6;color:var(--hs-admin-text)}
html[data-hs-admin] .hs-mobile-profile-list td:nth-child(6){margin-left:84px;margin-top:3px;font-size:11px;line-height:1.5;color:var(--hs-admin-muted)}
html[data-hs-admin] .hs-mobile-profile-list td:nth-child(6):before{content:'更新 ';display:inline;font-size:11px;color:inherit}
html[data-hs-admin] .hs-row-more{display:block;position:absolute;right:4px;top:6px}
.hs-row-more summary{display:flex;align-items:center;justify-content:center;width:44px;height:44px;list-style:none;cursor:pointer;border-radius:12px;color:var(--hs-admin-muted)}
.hs-row-more summary::-webkit-details-marker{display:none}
.hs-row-more[open] summary{background:var(--hs-admin-selected)}
html[data-hs-admin] .hs-mobile-profile-list tr:has(.hs-row-more[open]) td:nth-child(2) .group>div{display:flex!important}
html[data-hs-admin] .hs-mobile-profile-list tr:has(.hs-row-more[open]) td:nth-child(3){margin-top:8px}
html[data-hs-admin] .hs-mobile-profile-list tr:has(.hs-row-more[open]) td:nth-child(7){display:block;margin-top:10px;padding-top:8px!important}
html[data-hs-admin] .hs-mobile-profile-list tr:has(.hs-row-more[open]) td:nth-child(7)>div{justify-content:flex-end}
html[data-hs-admin] .hs-profile-categories a{min-height:44px;font-size:15px}
html[data-hs-admin] h1+p{display:none}
html[data-hs-admin] .hs-mobile-filters{grid-template-columns:minmax(0,1fr) auto;gap:8px!important}
html[data-hs-admin] .hs-profile-filters>[role="combobox"]:not(.hs-profile-type-hidden){grid-column:1!important}
html[data-hs-admin] .hs-mobile-filters>button:not([role="combobox"]){grid-column:2!important;grid-row:2;font-size:12px;padding-inline:10px}
}
