/* =============================================================
 * local.css —— 本地模型库页面（library.html）
 * 沿用 style.css 的变量与按钮，只管本页新增的块
 * ============================================================= */

/* ---------- HERO ---------- */
.lib-hero {
  position: relative;
  padding: 52px 0 10px;
}
.lib-hero::after {
  content: "";
  position: absolute;
  left: 50%;
  top: 0;
  width: min(1100px, 92vw);
  height: 1px;
  transform: translateX(-50%);
  background: linear-gradient(90deg, transparent, rgba(122,92,255,.65), rgba(255,79,216,.55), rgba(34,211,238,.55), transparent);
  opacity: .8;
}
.lib-hero-top {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 28px;
  flex-wrap: wrap;
}
.lib-hero-copy h1 {
  font-size: clamp(30px, 4.2vw, 48px);
  font-weight: 800;
  letter-spacing: -.03em;
  margin-top: 14px;
  background: linear-gradient(100deg, #fff 10%, #c9b8ff 45%, #8be9ff 80%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}
.lib-hero-copy .lead {
  color: var(--txt-2);
  font-size: 14.5px;
  margin-top: 14px;
  max-width: 720px;
}
.lib-hero-actions {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
}
.lib-hero-actions .btn { white-space: nowrap; }

/* ---------- 统计条 ---------- */
.lib-stats {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 12px;
  margin-top: 30px;
}
.lib-stat {
  padding: 16px 18px;
  border-radius: var(--r-md);
  background: var(--panel);
  border: 1px solid var(--line);
  backdrop-filter: var(--glass);
  -webkit-backdrop-filter: var(--glass);
  display: flex;
  flex-direction: column;
  gap: 4px;
  min-width: 0;
}
.lib-stat b {
  font-size: clamp(19px, 2.1vw, 25px);
  font-weight: 800;
  letter-spacing: -.02em;
  background: linear-gradient(120deg, #fff, #b9a8ff 70%, #8be9ff);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.lib-stat span {
  font-size: 11.5px;
  color: var(--dim);
  letter-spacing: .05em;
}
.lib-roots {
  margin-top: 12px;
  font-family: var(--mono);
  font-size: 11.5px;
  color: var(--dim);
  word-break: break-all;
  line-height: 1.7;
}

/* ---------- 工具条 ---------- */
.lib-section { padding-top: 34px; }
.lib-toolbar {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
  padding: 12px;
  border-radius: var(--r-md);
  background: var(--panel);
  border: 1px solid var(--line);
  backdrop-filter: var(--glass);
  -webkit-backdrop-filter: var(--glass);
  margin-bottom: 24px;
  position: sticky;
  top: calc(var(--nav-h) + 8px);
  z-index: 40;
}
.lib-search {
  position: relative;
  display: flex;
  align-items: center;
  gap: 9px;
  flex: 1 1 260px;
  min-width: 200px;
  padding: 0 12px;
  height: 42px;
  border-radius: var(--r-sm);
  background: rgba(0,0,0,.28);
  border: 1px solid var(--line);
  color: var(--dim);
  transition: border-color .2s, box-shadow .2s;
}
.lib-search:focus-within {
  border-color: rgba(122,92,255,.6);
  box-shadow: 0 0 0 3px rgba(122,92,255,.16);
}
.lib-search svg { width: 17px; height: 17px; flex-shrink: 0; }
.lib-search input {
  flex: 1;
  background: none;
  border: 0;
  outline: none;
  color: var(--txt);
  font-size: 13.5px;
  min-width: 0;
}
.lib-search input::-webkit-search-cancel-button { display: none; }
.lib-clear {
  background: none;
  border: 0;
  color: var(--dim);
  cursor: pointer;
  font-size: 13px;
  padding: 2px 4px;
}
.lib-clear:hover { color: var(--txt); }

.lib-seg {
  display: flex;
  gap: 4px;
  padding: 4px;
  border-radius: var(--r-sm);
  background: rgba(0,0,0,.28);
  border: 1px solid var(--line);
  overflow-x: auto;
}
.lib-seg .seg-btn {
  border: 0;
  background: transparent;
  color: var(--dim);
  font-size: 12.5px;
  padding: 7px 12px;
  border-radius: 9px;
  cursor: pointer;
  white-space: nowrap;
  transition: .2s;
}
.lib-seg .seg-btn:hover { color: var(--txt); background: var(--panel); }
.lib-seg .seg-btn.is-on {
  background: linear-gradient(120deg, rgba(122,92,255,.85), rgba(255,79,216,.7));
  color: #fff;
  box-shadow: 0 5px 16px rgba(122,92,255,.32);
}

.lib-sort {
  height: 42px;
  padding: 0 12px;
  border-radius: var(--r-sm);
  background: rgba(0,0,0,.28);
  border: 1px solid var(--line);
  color: var(--txt);
  font-size: 13px;
  cursor: pointer;
  outline: none;
}
.lib-sort option { background: #0b0b18; color: var(--txt); }
.lib-count {
  font-family: var(--mono);
  font-size: 12px;
  color: var(--dim);
  margin-left: auto;
  white-space: nowrap;
}

/* ---------- 网格 ---------- */
.lib-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(216px, 1fr));
  gap: 18px;
}
.lib-card {
  position: relative;
  border-radius: var(--r-md);
  background: var(--panel);
  border: 1px solid var(--line);
  overflow: hidden;
  cursor: pointer;
  transition: transform .32s cubic-bezier(.2,.8,.2,1), box-shadow .32s, border-color .32s;
  display: flex;
  flex-direction: column;
}
.lib-card:hover {
  transform: translateY(-6px);
  box-shadow: var(--sh-2);
  border-color: rgba(122,92,255,.42);
}
.lib-media {
  position: relative;
  aspect-ratio: 3 / 3.5;
  background:
    radial-gradient(circle at 30% 20%, color-mix(in srgb, var(--a, #7a5cff) 42%, transparent), transparent 62%),
    linear-gradient(160deg, #121228, #08080f 78%);
  overflow: hidden;
}
.lib-media img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  z-index: 1;
  transition: transform .7s cubic-bezier(.2,.8,.2,1);
}
.lib-card:hover .lib-media img { transform: scale(1.06); }
.lib-media.is-empty img { display: none; }
.lib-ph {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 54px;
  font-weight: 800;
  color: rgba(255,255,255,.14);
  letter-spacing: -.04em;
  z-index: 0;
  user-select: none;
}
.lib-badge {
  position: absolute;
  right: 9px;
  bottom: 9px;
  z-index: 2;
  font-size: 10.5px;
  padding: 3px 8px;
  border-radius: 999px;
  letter-spacing: .04em;
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
}
.b-exact  { background: rgba(74,222,128,.22); color: #a7f3c4; border: 1px solid rgba(74,222,128,.45); }
.b-strong { background: rgba(34,211,238,.20); color: #a5ecff; border: 1px solid rgba(34,211,238,.45); }
.b-fuzzy  { background: rgba(255,202,58,.18); color: #ffe09a; border: 1px solid rgba(255,202,58,.42); }
.b-cover  { background: rgba(167,139,250,.18); color: #ddd0ff; border: 1px solid rgba(167,139,250,.45); }
.b-none   { background: rgba(255,255,255,.08); color: var(--dim); border: 1px solid var(--line); }

.lib-body {
  padding: 13px 14px 15px;
  display: flex;
  flex-direction: column;
  gap: 6px;
  flex: 1;
}
.lib-name {
  font-size: 14.5px;
  font-weight: 700;
  line-height: 1.35;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.lib-sub {
  font-size: 11.5px;
  color: var(--dim);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.lib-meta {
  display: flex;
  justify-content: space-between;
  gap: 8px;
  font-family: var(--mono);
  font-size: 10.5px;
  color: rgba(255,255,255,.42);
}
.lib-flag {
  display: inline-block;
  font-size: 10px;
  padding: 1.5px 7px;
  border-radius: 7px;
  background: rgba(122,92,255,.18);
  border: 1px solid rgba(122,92,255,.34);
  color: #c8bbff;
  margin-right: 4px;
}
.lib-flags { margin: 2px 0 10px; }
.lib-imgn {
  margin-top: auto;
  padding-top: 9px;
  border-top: 1px dashed rgba(255,255,255,.09);
  font-family: var(--mono);
  font-size: 10.5px;
  color: rgba(255,255,255,.44);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.lib-imgn.is-off { color: rgba(255,255,255,.22); }

/* ---------- 空态 / 加载更多 / 离线提示 ---------- */
.lib-empty {
  text-align: center;
  padding: 60px 0;
  color: var(--dim);
}
.lib-empty h3 { font-size: 19px; color: var(--txt); margin-bottom: 8px; }
.lib-empty .empty-orb { margin: 0 auto 18px; }
.lib-more { text-align: center; margin-top: 30px; }
.lib-offline {
  grid-column: 1 / -1;
  text-align: center;
  padding: 46px 24px;
  border-radius: var(--r-md);
  border: 1px dashed rgba(255,202,58,.4);
  background: rgba(255,202,58,.06);
}
.lib-offline h3 { font-size: 18px; color: #ffdd8a; margin-bottom: 10px; }
.lib-offline p { color: var(--txt-2); font-size: 13.5px; max-width: 620px; margin: 0 auto 14px; }
.lib-offline code {
  display: inline-block;
  font-family: var(--mono);
  font-size: 12.5px;
  padding: 8px 14px;
  border-radius: 10px;
  background: rgba(0,0,0,.4);
  border: 1px solid var(--line);
  color: #a5ecff;
}

/* ---------- 详情弹层 ---------- */
.lib-modal {
  position: fixed;
  inset: 0;
  z-index: 120;
  display: none;
  align-items: center;
  justify-content: center;
  padding: 22px;
  opacity: 0;
  transition: opacity .22s ease;
}
.lib-modal.open { display: flex; opacity: 1; }
.lib-modal-mask {
  position: absolute;
  inset: 0;
  background: rgba(3,3,10,.78);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
}
.lib-modal-card {
  position: relative;
  display: grid;
  grid-template-columns: minmax(0, 1fr) 380px;
  gap: 0;
  width: min(1080px, 96vw);
  max-height: 88vh;
  border-radius: var(--r-lg);
  overflow: hidden;
  background: #090913;
  border: 1px solid var(--line-2);
  box-shadow: var(--sh-3);
  transform: translateY(14px) scale(.985);
  transition: transform .28s cubic-bezier(.2,.8,.2,1);
}
.lib-modal.open .lib-modal-card { transform: none; }
.lib-modal-x {
  position: absolute;
  right: 12px;
  top: 12px;
  z-index: 3;
  width: 34px;
  height: 34px;
  border-radius: 50%;
  border: 1px solid var(--line-2);
  background: rgba(0,0,0,.5);
  color: var(--txt);
  cursor: pointer;
}
.lib-modal-x:hover { background: rgba(255,255,255,.14); }
.lib-modal-media {
  position: relative;
  background: #05050c;
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 320px;
  max-height: 88vh;
  overflow: hidden;
}
.lib-modal-media img {
  width: 100%;
  height: 100%;
  max-height: 88vh;
  object-fit: contain;
}
.lib-modal-ph {
  width: 100%;
  height: 100%;
  min-height: 320px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 120px;
  font-weight: 800;
  color: rgba(255,255,255,.12);
  background:
    radial-gradient(circle at 35% 25%, color-mix(in srgb, var(--a, #7a5cff) 40%, transparent), transparent 65%),
    linear-gradient(160deg, #121228, #08080f);
}
.lib-modal-info {
  padding: 26px 24px;
  overflow-y: auto;
  border-left: 1px solid var(--line);
}
.lib-modal-info h2 {
  font-size: 21px;
  font-weight: 800;
  line-height: 1.3;
  margin-bottom: 12px;
  word-break: break-word;
}
.lib-rows { display: flex; flex-direction: column; gap: 10px; margin-bottom: 20px; }
.lib-row {
  display: grid;
  grid-template-columns: 74px minmax(0, 1fr);
  gap: 10px;
  font-size: 12.5px;
  align-items: start;
}
.lib-row i {
  font-style: normal;
  color: var(--dim);
  font-size: 11.5px;
}
.lib-row b {
  font-weight: 500;
  color: var(--txt-2);
  word-break: break-all;
  font-family: var(--mono);
  font-size: 11.5px;
  line-height: 1.6;
}
.lib-modal-btns { display: flex; gap: 9px; flex-wrap: wrap; }
.lib-modal-btns .btn { padding: 11px 16px; font-size: 13px; }

/* ---------- 响应式 ---------- */
@media (max-width: 900px) {
  .lib-stats { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .lib-modal-card { grid-template-columns: 1fr; max-height: 90vh; }
  .lib-modal-media { max-height: 46vh; }
  .lib-modal-info { border-left: 0; border-top: 1px solid var(--line); max-height: 44vh; }
}
@media (max-width: 720px) {
  .lib-hero { padding-top: 34px; }
  .lib-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
  .lib-stats { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .lib-toolbar { position: static; }
  .lib-count { margin-left: 0; width: 100%; }
  .lib-sort { flex: 1; }
}

/* ---------- 加入 ARC（卡片左上角 + 弹层按钮） ---------- */
.lib-arc {
  position: absolute;
  left: 9px;
  top: 9px;
  z-index: 3;
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 5px 10px 5px 8px;
  font: inherit;
  font-size: 10.5px;
  font-weight: 600;
  letter-spacing: .06em;
  color: #d9ffa6;
  background: rgba(6, 8, 16, .78);
  border: 1px solid rgba(182, 255, 92, .5);
  border-radius: 999px;
  cursor: pointer;
  opacity: .85;
  transform: none;
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  transition: opacity .18s ease, filter .18s ease, border-color .18s ease;
  box-shadow: 0 4px 14px rgba(0, 0, 0, .45);
}
.lib-arc::before {
  content: "";
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: #b6ff5c;
  box-shadow: 0 0 8px rgba(182, 255, 92, .9);
}
.lib-card:hover .lib-arc,
.lib-arc:focus-visible { opacity: 1; border-color: rgba(182, 255, 92, .95); }
.lib-arc:hover { filter: brightness(1.15); }
.lib-arc:disabled { cursor: progress; filter: saturate(.4) brightness(.85); }
.lib-arc span { pointer-events: none; }
.btn.is-busy { opacity: .62; cursor: progress; }
@media (hover: none) {
  .lib-arc { opacity: 1; }
}

/* ---------- 3D 预览（卡片角标 + 弹层大图） ---------- */
.lib-view {
  position: absolute;
  right: 9px;
  top: 9px;
  z-index: 3;
  display: inline-flex;
  align-items: center;
  padding: 5px 10px;
  font: inherit;
  font-size: 10.5px;
  font-weight: 700;
  letter-spacing: .07em;
  color: #06121a;
  background: linear-gradient(135deg, #7dd3fc, #a78bfa);
  border: 0;
  border-radius: 999px;
  cursor: pointer;
  opacity: .62;
  transition: opacity .18s ease, filter .18s ease;
  box-shadow: 0 6px 18px rgba(125, 211, 252, .24);
}
.lib-card:hover .lib-view,
.lib-view:focus-visible { opacity: 1; }
.lib-view:hover { filter: brightness(1.08); }
.lib-view:disabled { cursor: progress; opacity: 1; filter: saturate(.5) brightness(.9); }
.lib-view span { pointer-events: none; }
@media (hover: none) { .lib-view { opacity: 1; } }

.lib-3d {
  position: absolute;
  right: 9px;
  bottom: 9px;
  z-index: 2;
  padding: 2px 7px;
  font-size: 10px;
  font-weight: 700;
  letter-spacing: .08em;
  color: #041019;
  background: #7dd3fc;
  border-radius: 5px;
  box-shadow: 0 3px 12px rgba(0, 0, 0, .45);
}

/* ---------- VRChat SDK 上传（官方那颗云朵箭头；模型卡 / 世界卡 / 弹层共用） ---------- */
.sdk-ico { width: 1.15em; height: 1.15em; display: block; flex: none; }
/* 卡片上那颗图标要压得住亮封面：单独放大到 14px，别跟着字号缩 */
.lib-up .sdk-ico, .world-up .sdk-ico { width: 16px; height: 16px; }

.lib-up {
  position: absolute;
  left: 9px;
  bottom: 9px;
  z-index: 3;
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 5px 10px 5px 7px;
  font: inherit;
  font-size: 10.5px;
  font-weight: 800;
  letter-spacing: .05em;
  color: #04121f;
  background: linear-gradient(135deg, #7ae4ff 0%, #38b6ff 46%, #2f6bff 100%);
  border: 1px solid rgba(6, 16, 30, .45);
  border-radius: 999px;
  cursor: pointer;
  opacity: .92;
  transition: opacity .18s ease, filter .18s ease, transform .18s ease;
  box-shadow: 0 6px 18px rgba(47, 107, 255, .42), inset 0 1px 0 rgba(255, 255, 255, .55);
}
.lib-up:hover { opacity: 1; filter: brightness(1.08); transform: translateY(-1px); }
.lib-up:active { transform: translateY(0); }
.lib-up:disabled { cursor: progress; filter: saturate(.55) brightness(.9); }
.lib-up.is-busy { animation: upPulse 1.1s ease-in-out infinite; }
.lib-up span { pointer-events: none; }
.lib-card:hover .lib-up { opacity: 1; }
@keyframes upPulse { 0%,100% { filter: brightness(1); } 50% { filter: brightness(1.35); } }
@media (hover: none) { .lib-up { opacity: 1; } }

/* 世界卡：盖在封面右上角，压在「进世界」那层之上，点它不会误进世界 */
.world-up {
  position: absolute;
  right: 10px;
  top: 10px;
  z-index: 5;
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 5px 10px 5px 7px;
  font: inherit;
  font-size: 10.5px;
  font-weight: 800;
  letter-spacing: .05em;
  color: #04121f;
  background: linear-gradient(135deg, #7ae4ff 0%, #38b6ff 46%, #2f6bff 100%);
  border: 1px solid rgba(6, 16, 30, .45);
  border-radius: 999px;
  cursor: pointer;
  opacity: .95;
  transition: opacity .18s ease, filter .18s ease, transform .18s ease;
  box-shadow: 0 6px 18px rgba(47, 107, 255, .46), inset 0 1px 0 rgba(255, 255, 255, .55);
}
.world-up:hover { opacity: 1; filter: brightness(1.1); transform: translateY(-1px); }
.world-up:disabled { cursor: progress; filter: saturate(.55) brightness(.9); }
.world-up.is-busy { animation: upPulse 1.1s ease-in-out infinite; }
.world-up span { pointer-events: none; }

/* 弹层里那颗：跟 Pro 并排，蓝色实体，一眼看出是「传上去」 */
.btn-sdk {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  color: #04121f;
  font-weight: 800;
  letter-spacing: .05em;
  background-image: linear-gradient(100deg, #8ceaff 0%, #46bdff 34%, #2f6bff 72%, #46bdff 100%);
  background-size: 200% 100%;
  border: 1px solid rgba(140, 234, 255, .9);
  box-shadow: 0 8px 22px rgba(47, 107, 255, .34),
              inset 0 1px 0 rgba(255, 255, 255, .5);
}
.btn-sdk:hover { background-position: 100% 0; filter: brightness(1.06); }
.btn-sdk .sdk-ico { width: 16px; height: 16px; }
.btn-sdk:disabled { cursor: progress; filter: saturate(.6) brightness(.92); }

.lib-mstack { position: absolute; inset: 0; }
/* 背景那层：放大虚化铺满，把两边空出来的地方补上，不留黑边 */
.lib-modal-media img.lib-m3bg {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  filter: blur(26px) brightness(.45) saturate(1.15);
  transform: scale(1.12);
  z-index: 1;
}
/* 前景那层：完整显示模型，不裁不拉伸 */
.lib-modal-media img.lib-m3d {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: contain;
  z-index: 2;
  background: transparent;
}
.lib-mtag {
  position: absolute;
  left: 12px;
  bottom: 12px;
  z-index: 3;
  padding: 3px 9px;
  font-size: 10.5px;
  font-weight: 700;
  letter-spacing: .06em;
  color: #041019;
  background: #7dd3fc;
  border-radius: 6px;
}

/* 详情页多了一个「3D 预览」，按钮挤成 3+1+2 很难看，压一压最小宽度变成 3+3 */
.buy-row .btn { min-width: 126px; }

/* 封面 / 3D 预览 切换：点画面切（只有两者都有时才会挂这个 class） */
.lib-mstack.has-cover { cursor: pointer; }
.lib-mstack.has-cover .lib-mcover { display: none; }
.lib-mstack.has-cover.show-cover .lib-mcover { display: block; position: absolute; inset: 0; width: 100%; height: 100%; object-fit: contain; z-index: 3; }
.lib-mstack.show-cover .lib-m3bg,
.lib-mstack.show-cover .lib-m3d { opacity: 0; }
.lib-mstack.show-cover .lib-mtag { display: none; }

/* ---------- 世界预览 ---------- */
.wd-list::-webkit-scrollbar { width: 8px; }
.wd-list::-webkit-scrollbar-thumb { background: rgba(255,255,255,.14); border-radius: 4px; }
.wd-card { grid-template-columns: minmax(260px, 26%) 1fr; }
.wd-find { display: flex; gap: 6px; padding: 10px 12px; }
.wd-find input {
  flex: 1; min-width: 0; height: 30px; padding: 0 9px;
  border-radius: 8px; border: 1px solid var(--line);
  background: rgba(0,0,0,.35); color: var(--txt); font-size: 11.5px; outline: none;
}
.wd-find input:focus { border-color: var(--acc-1); }
.wd-list { flex: 1; min-height: 0; overflow: auto; padding: 4px 8px 14px; }
.wd-item {
  padding: 9px 10px; border-radius: 9px; cursor: pointer;
  border: 1px solid transparent; margin-bottom: 4px;
}
.wd-item:hover { background: var(--panel-2); }
.wd-item.is-on { border-color: var(--acc-3); background: rgba(34,211,238,.1); }
.wd-item b { display: block; font-size: 12px; font-weight: 500; color: var(--txt); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.wd-item i { display: block; font-size: 10.5px; color: var(--dim); font-style: normal; margin-top: 3px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

.wd-stage {
  flex: 1; min-height: 0; overflow: auto;
  margin: 12px 16px 14px; padding: 0;
  border-radius: var(--r-sm); border: 1px solid var(--line);
  background: radial-gradient(circle at 50% 40%, #12121f, #06060c 70%);
  display: flex; flex-direction: column; gap: 10px;
  align-items: center; justify-content: center;
  padding: 14px;
}
.wd-shot { width: 100%; border-radius: 10px; overflow: hidden; border: 1px solid var(--line); }
.wd-shot img { width: 100%; display: block; }
.wd-shot figcaption {
  font-size: 10.5px; color: var(--dim); padding: 6px 9px;
  background: rgba(0,0,0,.45);
}

@media (max-width: 1080px) {
  .ed { padding: 0; }
  .ed-card { height: 100vh; border-radius: 0; grid-template-columns: 1fr; grid-template-rows: 44% 1fr; }
  .ed-side { border-right: 0; border-bottom: 1px solid var(--line); }
}

/* 节点上的「删掉这个预制件」按钮 */
.ed-del {
  flex: 0 0 auto; width: 17px; height: 17px; line-height: 1;
  border-radius: 5px; border: 1px solid transparent;
  background: transparent; color: rgba(255,120,145,.0);
  font-size: 10px; cursor: pointer; padding: 0;
  transition: color .12s, border-color .12s;
}
.ed-node:hover .ed-del { color: rgba(255,120,145,.75); border-color: rgba(255,120,145,.25); }
.ed-del:hover { color: #fff; background: #ff3d63; border-color: #ff3d63; }
.ed-node.is-gone > .ed-node-h { text-decoration: line-through; }

/* =============================================================
 * VRCW 世界房间墙
 * ============================================================= */
.world-section { padding: 24px 0 26px; }

.world-head {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 20px;
  flex-wrap: wrap;
  margin-bottom: 22px;
  padding-bottom: 16px;
  border-bottom: 1px solid var(--line);
}
.world-title {
  display: flex;
  align-items: center;
  gap: 11px;
  font-size: clamp(20px, 2.4vw, 27px);
  font-weight: 800;
  letter-spacing: -.02em;
  margin: 0;
}
.world-dot {
  width: 9px; height: 9px; border-radius: 50%;
  background: linear-gradient(135deg, var(--acc-1, #7a5cff), var(--acc-3, #ff4fd8));
  box-shadow: 0 0 12px rgba(122,92,255,.75);
  flex: 0 0 auto;
}
.world-sub {
  margin: 9px 0 0;
  font-size: 13px;
  color: var(--txt-2);
  line-height: 1.6;
}
.world-tools { display: flex; gap: 9px; align-items: center; flex-wrap: wrap; }
.world-scanstat {
  display: flex;
  align-items: center;
  gap: 9px;
  height: 34px;
  padding: 0 13px;
  border-radius: var(--r-sm);
  border: 1px solid rgba(34, 211, 238, .42);
  background: rgba(34, 211, 238, .08);
  color: #9fe8ff;
  font-size: 12px;
  font-family: var(--mono);
  max-width: 52vw;
  white-space: nowrap;
  overflow: hidden;
  box-shadow: 0 0 14px rgba(34, 211, 238, .14);
}
.world-scanstat[hidden] { display: none; }
.world-scanbar {
  position: relative;
  flex: 0 0 auto;
  width: 56px;
  height: 4px;
  border-radius: 2px;
  background: rgba(34, 211, 238, .18);
  overflow: hidden;
}
.world-scanbar i {
  position: absolute;
  top: 0;
  bottom: 0;
  width: 42%;
  border-radius: 2px;
  background: linear-gradient(90deg, rgba(34, 211, 238, 0), #22d3ee 40%, #a78bfa 75%, rgba(167, 139, 250, 0));
  animation: world-scan-run 1.15s linear infinite;
}
@keyframes world-scan-run {
  0% { transform: translateX(-115%); }
  100% { transform: translateX(330%); }
}

.world-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(252px, 1fr));
  gap: 18px;
}

.world-card {
  border-radius: var(--r-md);
  background: var(--panel);
  border: 1px solid var(--line);
  overflow: hidden;
  display: flex;
  flex-direction: column;
  cursor: pointer;
  transition: transform .32s cubic-bezier(.2,.8,.2,1), box-shadow .32s, border-color .32s;
}
.world-card:hover {
  transform: translateY(-5px);
  box-shadow: var(--sh-2);
  border-color: rgba(255,79,216,.4);
}

.world-cover {
  position: relative;
  aspect-ratio: 16 / 10;
  overflow: hidden;
  cursor: pointer;
  background:
    radial-gradient(circle at 32% 24%, rgba(122,92,255,.34), transparent 62%),
    linear-gradient(160deg, #14142a, #07070d 80%);
}
.world-cover img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform .6s cubic-bezier(.2,.8,.2,1), filter .4s;
}
.world-card:hover .world-cover img { transform: scale(1.055); }
.world-cover.has-shot::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(to top, rgba(6,6,12,.55), transparent 46%);
  pointer-events: none;
}
.world-tag {
  position: absolute;
  top: 10px;
  left: 10px;
  z-index: 2;
  padding: 3px 8px;
  border-radius: 6px;
  font-size: 10px;
  font-weight: 700;
  letter-spacing: .09em;
  color: #fff;
  background: rgba(10,10,20,.62);
  border: 1px solid rgba(255,255,255,.16);
  backdrop-filter: blur(8px);
}
.world-play {
  position: absolute;
  inset: 0;
  z-index: 2;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  font-size: 13.5px;
  font-weight: 700;
  letter-spacing: .02em;
  color: #fff;
  background: linear-gradient(180deg, rgba(8,8,16,.18), rgba(8,8,16,.72));
  opacity: 0;
  transition: opacity .28s;
}
.world-play svg { width: 26px; height: 26px; }
.world-cover:hover .world-play { opacity: 1; }
.world-nocover {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 12px;
  letter-spacing: .16em;
  color: rgba(255,255,255,.26);
}

.world-meta { padding: 13px 14px 15px; display: flex; flex-direction: column; gap: 5px; }
.world-meta b {
  font-size: 14.5px;
  font-weight: 700;
  color: var(--txt);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.world-meta i {
  font-style: normal;
  font-size: 11.5px;
  color: var(--dim, var(--txt-2));
  font-family: var(--mono);
}
.world-acts { display: flex; gap: 7px; margin-top: 8px; }
.world-acts button {
  flex: 1;
  height: 30px;
  border-radius: 8px;
  border: 1px solid rgba(122,92,255,.34);
  background: rgba(122,92,255,.14);
  color: #cfc2ff;
  font-size: 12px;
  font-weight: 600;
  cursor: pointer;
  transition: background .18s, border-color .18s, color .18s;
}
.world-acts button:hover { background: rgba(122,92,255,.3); border-color: rgba(122,92,255,.6); color: #fff; }
/* 赛博配色的「VRCW 预览」：青→紫霓虹描边 + 呼吸辉光 + hover 扫光 */
.world-acts .world-play-btn {
  flex: 1.32;
  position: relative;
  overflow: hidden;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  border: 1px solid rgba(34, 211, 238, .55);
  background: linear-gradient(160deg, rgba(34, 211, 238, .17), rgba(167, 139, 250, .15) 62%, rgba(255, 79, 216, .13));
  color: #9fe8ff;
  letter-spacing: .03em;
  text-shadow: 0 0 9px rgba(34, 211, 238, .6);
  box-shadow: inset 0 0 0 1px rgba(167, 139, 250, .13), 0 0 12px rgba(34, 211, 238, .17);
  transition: background .18s, border-color .18s, color .18s, box-shadow .28s;
}
.world-acts .world-play-btn::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(115deg, transparent 22%, rgba(255, 255, 255, .5) 48%, transparent 64%);
  transform: translateX(-135%);
  transition: transform .62s ease;
  pointer-events: none;
}
.world-acts .world-play-btn:hover::after { transform: translateX(135%); }
.world-acts .world-play-btn:hover {
  color: #fff;
  border-color: rgba(34, 211, 238, .95);
  background: linear-gradient(160deg, rgba(34, 211, 238, .34), rgba(167, 139, 250, .3) 62%, rgba(255, 79, 216, .26));
  box-shadow: inset 0 0 0 1px rgba(167, 139, 250, .28), 0 0 18px rgba(34, 211, 238, .45), 0 0 28px rgba(167, 139, 250, .3);
  text-shadow: 0 0 12px rgba(255, 255, 255, .85);
}
.world-acts .world-play-btn:active { transform: translateY(1px); }
.world-acts .world-play-btn > span,
.world-acts .world-play-btn > svg { position: relative; z-index: 1; }
.wp-ico {
  width: 16px;
  height: 16px;
  flex: 0 0 auto;
  filter: drop-shadow(0 0 5px rgba(34, 211, 238, .95));
  transition: filter .24s, transform .24s;
}
.world-acts .world-play-btn:hover .wp-ico {
  transform: scale(1.08);
  filter: drop-shadow(0 0 7px rgba(34, 211, 238, 1)) drop-shadow(0 0 13px rgba(167, 139, 250, .9));
}

.world-acts .world-open {
  flex: 1;
  border-color: var(--line);
  background: transparent;
  color: var(--txt-2);
  font-weight: 500;
}
.world-acts .world-open:hover { background: rgba(255,255,255,.06); border-color: var(--line-2); color: var(--txt); }

.world-wait {
  grid-column: 1 / -1;
  padding: 34px 0;
  text-align: center;
  font-size: 13px;
  color: var(--txt-2);
}
.world-empty {
  padding: 40px 0;
  text-align: center;
  font-size: 13px;
  color: var(--txt-2);
}

@media (max-width: 720px) {
  .world-scanstat { max-width: none; flex: 1 1 auto; }
  .world-tools { width: 100%; }
  .world-grid { grid-template-columns: repeat(auto-fill, minmax(158px, 1fr)); gap: 12px; }
  .world-meta { padding: 10px 11px 12px; }
  .world-acts .world-open { display: none; }
}

.wd-item.is-on { background: rgba(122,92,255,.2); border-color: rgba(122,92,255,.5); }

/* =============================================================
 * 应用图标条（VRCA 头像模型 / VRCW 世界房间 两个应用）
 *   页面顶部常驻，点图标切「视图」——两个页面各自独立，
 *   模型墙不会再把世界区块压到底下去。
 * ============================================================= */
.app-dock {
  position: sticky;
  top: var(--nav-h, 74px);
  z-index: 55;
  margin: 0 0 6px;
  padding: 12px 0;
  background: linear-gradient(180deg, rgba(6,6,14,.94), rgba(6,6,14,.72));
  backdrop-filter: blur(18px) saturate(140%);
  -webkit-backdrop-filter: blur(18px) saturate(140%);
  border-bottom: 1px solid rgba(255,255,255,.07);
}
.app-dock-in { display: flex; align-items: center; gap: 10px; }
.app-dock-sp { flex: 1 1 auto; }

.app-btn {
  display: flex;
  align-items: center;
  gap: 11px;
  padding: 7px 15px 7px 7px;
  border-radius: 17px;
  border: 1px solid rgba(255,255,255,.09);
  background: rgba(255,255,255,.035);
  color: var(--txt, #fff);
  cursor: pointer;
  text-align: left;
  transition: background .2s, border-color .2s, transform .2s, box-shadow .2s;
  -webkit-tap-highlight-color: transparent;
}
.app-btn:hover {
  background: rgba(255,255,255,.08);
  border-color: rgba(255,255,255,.2);
  transform: translateY(-1px);
}
.app-btn:active { transform: translateY(0) scale(.985); }
.app-btn.is-on {
  background: rgba(255,255,255,.1);
  border-color: rgba(255,255,255,.3);
  box-shadow: 0 10px 30px rgba(0,0,0,.45), inset 0 1px 0 rgba(255,255,255,.14);
}

.app-ico {
  position: relative;
  width: 44px; height: 44px;
  flex: 0 0 auto;
  border-radius: 13px;
  display: grid;
  place-items: center;
  overflow: hidden;
  transition: transform .22s, box-shadow .22s, filter .22s;
  box-shadow: 0 6px 16px rgba(0,0,0,.42), inset 0 1px 0 rgba(255,255,255,.34);
}
.app-ico svg {
  position: relative;
  z-index: 1;
  width: 26px; height: 26px;
  fill: none;
  stroke: #fff;
  stroke-width: 2.6;
  stroke-linecap: round;
  stroke-linejoin: round;
  filter: drop-shadow(0 1px 2px rgba(0,0,0,.28));
}
.app-ico::after {
  content: "";
  position: absolute; inset: 0;
  background: linear-gradient(180deg, rgba(255,255,255,.36), rgba(255,255,255,0) 58%);
  pointer-events: none;
}
.ico-models { background: linear-gradient(155deg, #a78bfa, #d946ef 52%, #fb7185); }
.ico-worlds { background: linear-gradient(155deg, #22d3ee, #3b82f6 58%, #6366f1); }

.app-btn:not(.is-on) .app-ico { filter: saturate(.72) brightness(.9); }
.app-btn:hover .app-ico { filter: saturate(.9) brightness(.95); }
.app-btn.is-on .app-ico {
  filter: none;
  transform: translateY(-1px) scale(1.03);
  box-shadow: 0 10px 24px rgba(0,0,0,.5), 0 0 0 1px rgba(255,255,255,.22),
              inset 0 1px 0 rgba(255,255,255,.42);
}

.app-txt { display: flex; flex-direction: column; gap: 2px; line-height: 1.2; min-width: 0; }
.app-txt b { font-size: 13.5px; font-weight: 650; letter-spacing: .2px; white-space: nowrap; }
.app-txt i {
  font-style: normal;
  font-size: 11px;
  color: var(--txt-2, #b9bee0);
  opacity: .72;
  white-space: nowrap;
}
.app-btn.is-on .app-txt i { opacity: .95; }

.app-back {
  font-size: 12.5px;
  color: var(--txt-2, #b9bee0);
  text-decoration: none;
  padding: 8px 13px;
  border-radius: 11px;
  border: 1px solid rgba(255,255,255,.1);
  white-space: nowrap;
  transition: .2s;
}
.app-back:hover { color: #fff; border-color: rgba(255,255,255,.24); background: rgba(255,255,255,.05); }

/* 视图容器：hidden 必须真的不占位 */
.app-view[hidden] { display: none !important; }

/* 世界页也当正经首页用，标题放大、留白对齐模型页 */
#view-worlds .world-section { padding: 34px 0 40px; }
#view-worlds .world-head { align-items: flex-end; }
#view-worlds .world-title {
  font-size: clamp(24px, 3.2vw, 36px);
  margin-top: 12px;
}
#view-worlds .world-sub { font-size: 13.5px; max-width: 720px; }
#view-models .lib-hero { padding-top: 34px; }

@media (max-width: 720px) {
  .app-dock { padding: 9px 0; }
  .app-dock-in { gap: 8px; }
  .app-btn { flex: 1 1 0; padding: 6px 10px 6px 6px; border-radius: 15px; gap: 8px; }
  .app-ico { width: 38px; height: 38px; border-radius: 11px; }
  .app-ico svg { width: 22px; height: 22px; }
  .app-txt b { font-size: 12px; }
  .app-txt i { display: none; }
  .app-back { display: none; }
  #view-models .lib-hero { padding-top: 24px; }
}

/* ---------- VRCA 预览 Pro：至尊金按钮（每张模型卡片都有一枚） ---------- */
.lib-pro {
  margin-top: auto;
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  width: 100%;
  height: 34px;
  padding: 0 10px;
  font: inherit;
  font-size: 12.5px;
  font-weight: 800;
  letter-spacing: .06em;
  color: #3a2400;
  background-image: linear-gradient(100deg, #fff6cf 0%, #ffd964 18%, #f2b021 38%, #e08a12 58%, #ffd964 80%, #fff6cf 100%);
  background-size: 240% 100%;
  background-position: 0 0;
  border: 1px solid rgba(255, 226, 140, .88);
  border-radius: 10px;
  cursor: pointer;
  overflow: hidden;
  text-shadow: 0 1px 0 rgba(255, 255, 255, .48);
  box-shadow: 0 5px 16px rgba(224, 140, 18, .22),
              inset 0 1px 0 rgba(255, 255, 255, .62),
              inset 0 -1px 0 rgba(120, 70, 0, .16);
  transition: background-position .6s ease, transform .18s ease, box-shadow .3s ease, filter .2s ease;
}
/* 悬停时一道高光扫过去，别太晃眼，一次就够 */
.lib-pro::after {
  content: "";
  position: absolute;
  top: -60%;
  left: -45%;
  width: 32%;
  height: 220%;
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, .58), transparent);
  transform: rotate(18deg);
  opacity: 0;
  pointer-events: none;
}
.lib-pro:hover {
  background-position: 100% 0;
  transform: translateY(-1px);
  box-shadow: 0 8px 22px rgba(255, 190, 60, .34),
              inset 0 1px 0 rgba(255, 255, 255, .72);
}
.lib-pro:hover::after { animation: proShine .75s ease; }
@keyframes proShine {
  0%   { opacity: 0; left: -45%; }
  22%  { opacity: 1; }
  100% { opacity: 0; left: 122%; }
}
.lib-pro .pro-ico { width: 15px; height: 15px; display: block; flex: none; }
.lib-pro:disabled { cursor: progress; filter: saturate(.6) brightness(.96); }
.lib-pro.is-off { filter: saturate(.16) brightness(.8); box-shadow: none; }
@media (hover: none) { .lib-pro:hover { transform: none; } }

/* 详情弹层里那枚大号金按钮 */
.btn-pro {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  color: #3a2400;
  font-weight: 800;
  letter-spacing: .05em;
  background-image: linear-gradient(100deg, #fff6cf 0%, #ffd964 26%, #f0ab1c 62%, #ffd964 100%);
  background-size: 200% 100%;
  border: 1px solid rgba(255, 226, 140, .88);
  text-shadow: 0 1px 0 rgba(255, 255, 255, .46);
  box-shadow: 0 8px 22px rgba(224, 140, 18, .28),
              inset 0 1px 0 rgba(255, 255, 255, .62);
}
.btn-pro:hover { background-position: 100% 0; filter: brightness(1.05); }
.btn-pro .pro-ico { width: 16px; height: 16px; display: block; }
.btn-pro.is-off { filter: saturate(.16) brightness(.8); }

/* =============================================================
 * 设置面板 —— 批量勾硬盘符 + 后台自动识别
 * ============================================================= */
.btn-set { gap: 7px; display: inline-flex; align-items: center; }
.btn-set svg { width: 16px; height: 16px; display: block; opacity: .9; }

/* 统计下面那行：扫描范围 · 自动识别 · 立即识别 */
.lib-roots { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.lib-roots-txt { min-width: 0; }
.lib-watch {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 3px 10px;
  border-radius: 999px;
  font-size: 11.5px;
  color: var(--dim);
  border: 1px solid var(--line);
  background: rgba(255,255,255,.03);
  white-space: nowrap;
}
.lib-watch::before {
  content: "";
  width: 6px; height: 6px;
  border-radius: 50%;
  background: #4b5170;
}
.lib-watch.is-on { color: #9cf5d2; border-color: rgba(47,240,192,.35); background: rgba(47,240,192,.08); }
.lib-watch.is-on::before { background: #2ff0c0; box-shadow: 0 0 8px rgba(47, 240, 192, .38); }
.lib-roots-btn {
  font: inherit;
  font-size: 11.5px;
  padding: 3px 11px;
  border-radius: 999px;
  border: 1px solid var(--line-2);
  background: transparent;
  color: var(--txt-2);
  cursor: pointer;
  transition: background .18s ease, color .18s ease;
}
.lib-roots-btn:hover { background: var(--panel-2); color: var(--txt); }
.lib-roots-btn:disabled { opacity: .5; cursor: progress; }

/* 「日志」：常驻的小尾巴，别抢注意力，右边贴齐 */
.lib-roots-log {
  margin-left: auto;
  border-color: var(--line);
  color: var(--dim);
  letter-spacing: .02em;
}
.lib-roots-log:hover {
  border-color: var(--line-2);
  color: var(--txt-2);
}

/* ---------- 弹层外壳 ---------- */
.set-modal {
  position: fixed;
  inset: 0;
  z-index: 130;
  display: none;
  align-items: center;
  justify-content: center;
  padding: 22px;
  opacity: 0;
  transition: opacity .2s ease;
}
.set-modal.open { display: flex; opacity: 1; }
.set-mask {
  position: absolute;
  inset: 0;
  background: rgba(3,3,10,.8);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
}
.set-card {
  position: relative;
  width: min(680px, 96vw);
  max-height: 90vh;
  overflow-y: auto;
  padding: 26px 26px 0;
  border-radius: var(--r-lg);
  background: #090913;
  border: 1px solid var(--line-2);
  box-shadow: var(--sh-3);
  min-width: 0;
  transform: translateY(12px) scale(.99);
  transition: transform .26s cubic-bezier(.2,.8,.2,1);
}
.set-modal.open .set-card { transform: none; }
.set-head h2 { font-size: 21px; margin-bottom: 8px; }
.set-head p { color: var(--txt-2); font-size: 13px; line-height: 1.65; max-width: 56ch; }

.set-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
  margin: 20px 0 10px;
}
.set-bar-t { font-size: 12px; letter-spacing: .06em; text-transform: uppercase; color: var(--dim); }
.set-bar-btns { display: flex; gap: 6px; flex-wrap: wrap; }
.set-mini {
  font: inherit;
  font-size: 12px;
  padding: 6px 11px;
  border-radius: 10px;
  border: 1px solid var(--line-2);
  background: var(--panel);
  color: var(--txt-2);
  cursor: pointer;
  transition: background .16s ease, color .16s ease, border-color .16s ease;
}
.set-mini:hover { background: var(--panel-2); color: var(--txt); border-color: rgba(255,255,255,.28); }

/* ---------- 盘符列表 ---------- */
.set-drives {
  display: flex;
  flex-direction: column;
  gap: 8px;
  /* 7 个盘一行一个，46vh 在 1200 高的屏上正好全露出来；再多就滚动 */
  max-height: 46vh;
  overflow-y: auto;
  overscroll-behavior: contain;
  padding-right: 4px;
}
.set-drives::-webkit-scrollbar, .set-card::-webkit-scrollbar { width: 8px; }
.set-drives::-webkit-scrollbar-thumb, .set-card::-webkit-scrollbar-thumb {
  background: rgba(255,255,255,.16);
  border-radius: 8px;
}
.set-drives::-webkit-scrollbar-thumb:hover, .set-card::-webkit-scrollbar-thumb:hover { background: rgba(255,255,255,.28); }
.set-drive {
  position: relative;
  display: grid;
  grid-template-columns: 18px 34px minmax(0, 1fr) auto auto;
  align-items: center;
  gap: 10px;
  padding: 11px 13px;
  border-radius: 14px;
  border: 1px solid var(--line);
  background: rgba(255,255,255,.028);
  cursor: pointer;
  transition: border-color .16s ease, background .16s ease, transform .16s ease;
}
.set-drive:hover { border-color: var(--line-2); background: rgba(255,255,255,.05); }
.set-drive input { position: absolute; opacity: 0; pointer-events: none; }
.sd-box {
  width: 16px; height: 16px;
  border-radius: 5px;
  border: 1.6px solid rgba(255,255,255,.28);
  background: rgba(0,0,0,.35);
  display: inline-block;
  position: relative;
}
.set-drive.is-on { border-color: rgba(122,92,255,.55); background: rgba(122,92,255,.10); }
.set-drive.is-on .sd-box {
  border-color: transparent;
  background: linear-gradient(135deg, var(--acc-1), var(--acc-2));
}
.set-drive.is-on .sd-box::after {
  content: "";
  position: absolute;
  left: 4.5px; top: 1.2px;
  width: 5px; height: 9px;
  border: solid #fff;
  border-width: 0 2px 2px 0;
  transform: rotate(42deg);
}
.set-drive.is-off { opacity: .45; cursor: not-allowed; }
.sd-letter {
  font-family: var(--mono);
  font-size: 15px;
  font-weight: 700;
  color: var(--txt);
}
.sd-main { min-width: 0; display: flex; flex-direction: column; gap: 2px; }
.sd-main b {
  font-size: 13.5px;
  font-weight: 600;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.sd-main i {
  font-style: normal;
  font-size: 11.5px;
  color: var(--dim);
  font-family: var(--mono);
}
.sd-note {
  font-size: 10.5px;
  color: #ffd98a;
  border: 1px solid rgba(255,202,58,.35);
  background: rgba(255,202,58,.10);
  border-radius: 999px;
  padding: 2px 8px;
  white-space: nowrap;
}
.sd-tag {
  font-size: 10.5px;
  padding: 2px 9px;
  border-radius: 999px;
  border: 1px solid var(--line);
  color: var(--dim);
  white-space: nowrap;
}
.sd-tag.t-fixed { color: #a9c4ff; border-color: rgba(122,140,255,.4); background: rgba(122,140,255,.10); }
.sd-tag.t-removable { color: #9cf5d2; border-color: rgba(47,240,192,.35); background: rgba(47,240,192,.09); }
.sd-tag.t-network { color: #ffd98a; border-color: rgba(255,202,58,.32); background: rgba(255,202,58,.08); }
.set-empty {
  padding: 22px;
  text-align: center;
  color: var(--dim);
  font-size: 13px;
  border: 1px dashed var(--line-2);
  border-radius: 14px;
}

/* ---------- 开关 ---------- */
.set-opts { display: flex; flex-direction: column; gap: 4px; margin-top: 16px; }
.set-chk {
  display: flex;
  align-items: flex-start;
  gap: 11px;
  padding: 10px 12px;
  border-radius: 12px;
  cursor: pointer;
  transition: background .16s ease;
}
.set-chk:hover { background: rgba(255,255,255,.04); }
.set-chk input {
  appearance: none;
  -webkit-appearance: none;
  flex: 0 0 auto;
  width: 36px;
  height: 21px;
  margin-top: 2px;
  border-radius: 999px;
  background: rgba(255,255,255,.14);
  border: 1px solid var(--line-2);
  position: relative;
  cursor: pointer;
  transition: background .18s ease, border-color .18s ease;
}
.set-chk input::after {
  content: "";
  position: absolute;
  left: 2px; top: 2px;
  width: 15px; height: 15px;
  border-radius: 50%;
  background: #c9cde6;
  transition: transform .18s cubic-bezier(.2,.8,.2,1), background .18s ease;
}
.set-chk input:checked {
  background: linear-gradient(120deg, var(--acc-1), var(--acc-2));
  border-color: transparent;
}
.set-chk input:checked::after { transform: translateX(15px); background: #fff; }
.set-chk-t { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.set-chk-t b { font-size: 13.5px; font-weight: 600; }
.set-chk-t i {
  font-style: normal;
  font-size: 11.5px;
  color: var(--dim);
  line-height: 1.55;
}
.set-chk-sel { align-items: center; justify-content: space-between; cursor: default; }
.set-chk-sel select {
  font: inherit;
  font-size: 12.5px;
  padding: 8px 10px;
  border-radius: 10px;
  border: 1px solid var(--line-2);
  background: #0d0d1a;
  color: var(--txt);
  cursor: pointer;
}

/* ---------- 额外目录 ---------- */
.set-extra { margin-top: 14px; display: flex; flex-direction: column; gap: 7px; }
.set-extra label { font-size: 12px; color: var(--dim); }
.set-extra textarea {
  width: 100%;
  resize: vertical;
  padding: 10px 12px;
  border-radius: 12px;
  border: 1px solid var(--line-2);
  background: rgba(0,0,0,.35);
  color: var(--txt);
  font-family: var(--mono);
  font-size: 12px;
  line-height: 1.6;
}
.set-extra textarea:focus { outline: none; border-color: rgba(122,92,255,.6); }

/* ---------- 底部（钉在卡片底部，盘符多也不怕按钮被挤下去） ---------- */
.set-foot {
  position: sticky;
  bottom: 0;
  display: flex;
  align-items: center;
  gap: 10px;
  margin: 20px -26px 0;
  padding: 14px 26px 16px;
  border-top: 1px solid var(--line);
  background: linear-gradient(180deg, rgba(9,9,19,.92), #090913 42%);
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
  flex-wrap: wrap;
}
.set-hint {
  flex: 1 1 160px;
  min-width: 0;
  font-size: 12px;
  color: #ffb4b4;
  opacity: 0;
  transition: opacity .2s ease;
}
.set-hint.is-on { opacity: 1; }
.set-foot .btn { padding: 11px 18px; font-size: 13px; }

@media (max-width: 560px) {
  .set-modal { padding: 8px; }
  .set-card { width: 100%; max-height: 94vh; padding: 18px 14px 0; border-radius: 20px; }
  .set-head h2 { font-size: 19px; }
  .set-bar { margin: 16px 0 8px; }
  .set-bar-btns { width: 100%; }
  .set-mini { flex: 1 1 auto; text-align: center; }
  .set-drive { grid-template-columns: 18px 28px minmax(0, 1fr); gap: 8px; padding: 10px 11px; }
  .sd-note, .sd-tag { display: none; }
  .set-drives { max-height: 34vh; }
  .set-foot { margin: 16px -14px 0; padding: 12px 14px 14px; }
  .set-hint { flex: 1 1 100%; }
}

/* =============================================================
 * VRCW 房间页：范围条
 * ============================================================= */
.world-roots { margin: 0 0 14px; }
.world-roots-chip {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
  padding: 6px 13px;
  border-radius: 999px;
  font-size: 12px;
  color: var(--dim);
  border: 1px solid var(--line);
  background: rgba(255,255,255,.03);
  max-width: 100%;
}
.world-roots-chip i {
  font-style: normal;
  font-size: 10.5px;
  padding: 1px 8px;
  border-radius: 999px;
  color: #a9c4ff;
  border: 1px solid rgba(122,140,255,.4);
  background: rgba(122,140,255,.1);
}
.world-roots-chip.is-custom { color: var(--txt-2); border-color: rgba(47,240,192,.3); background: rgba(47,240,192,.06); }

/* =============================================================
 * VRChat 启动（房间卡片上的主按钮 + 粘世界 ID 的弹框）
 * ============================================================= */
.world-acts { flex-wrap: wrap; }

/* 主按钮单独占一整行：紫→青的传送门配色，压过下面三个次要按钮 */
/* 主按钮那一行：独占整行，里面主按钮拉伸 + 线上小按钮定宽 */
.world-acts .wvrc-line {
  flex: 0 0 100%;
  display: flex;
  align-items: stretch;
  gap: 6px;
  min-width: 0;
}
.world-acts .world-vrc-btn {
  flex: 1 1 auto;
  min-width: 0;
  position: relative;
  overflow: hidden;
  height: 33px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  border: 1px solid rgba(167, 139, 250, .62);
  border-radius: 9px;
  background: linear-gradient(120deg, rgba(122, 92, 255, .3), rgba(34, 211, 238, .2) 70%, rgba(255, 79, 216, .18));
  color: #e8ddff;
  font-size: 12.5px;
  font-weight: 700;
  letter-spacing: .02em;
  text-shadow: 0 0 10px rgba(167, 139, 250, .55);
  box-shadow: inset 0 0 0 1px rgba(34, 211, 238, .12), 0 0 14px rgba(122, 92, 255, .2);
  transition: background .18s, border-color .18s, color .18s, box-shadow .3s, transform .1s;
}
.world-acts .world-vrc-btn::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(112deg, transparent 20%, rgba(255, 255, 255, .42) 48%, transparent 66%);
  transform: translateX(-140%);
  transition: transform .66s ease;
  pointer-events: none;
}
.world-acts .world-vrc-btn:hover::after { transform: translateX(140%); }
.world-acts .world-vrc-btn:hover {
  color: #fff;
  border-color: rgba(34, 211, 238, .9);
  background: linear-gradient(120deg, rgba(122, 92, 255, .5), rgba(34, 211, 238, .34) 70%, rgba(255, 79, 216, .3));
  box-shadow: inset 0 0 0 1px rgba(167, 139, 250, .3), 0 0 20px rgba(122, 92, 255, .45), 0 0 30px rgba(34, 211, 238, .28);
}
.world-acts .world-vrc-btn:active { transform: translateY(1px); }
.world-acts .world-vrc-btn.is-bound {
  border-color: rgba(47, 240, 192, .55);
  background: linear-gradient(120deg, rgba(34, 211, 238, .26), rgba(47, 240, 192, .18) 70%);
  color: #d3fff4;
  text-shadow: 0 0 10px rgba(47, 240, 192, .5);
  box-shadow: inset 0 0 0 1px rgba(47, 240, 192, .14), 0 0 14px rgba(47, 240, 192, .18);
}
.wv-ico { width: 15px; height: 15px; flex: 0 0 auto; filter: drop-shadow(0 0 5px rgba(167, 139, 250, .9)); }
.world-acts .world-vrc-btn.is-bound .wv-ico { filter: drop-shadow(0 0 5px rgba(47, 240, 192, .95)); }
.wv-badge {
  font-style: normal;
  font-size: 9.5px;
  font-weight: 600;
  letter-spacing: .02em;
  padding: 1px 5px;
  border-radius: 999px;
  color: #9df3dd;
  border: 1px solid rgba(47, 240, 192, .45);
  background: rgba(47, 240, 192, .12);
  text-shadow: none;
}

/* 弹框：粘世界链接 / ID */
.wvrc-modal {
  position: fixed;
  inset: 0;
  z-index: 140;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
}
.wvrc-mask {
  position: absolute;
  inset: 0;
  background: rgba(3, 3, 10, .82);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
}
.wvrc-card {
  position: relative;
  width: min(540px, 96vw);
  padding: 24px 24px 18px;
  border-radius: var(--r-lg);
  background: #090913;
  border: 1px solid var(--line-2);
  box-shadow: var(--sh-3);
  animation: wvrcIn .24s cubic-bezier(.2, .8, .2, 1);
}
@keyframes wvrcIn { from { opacity: 0; transform: translateY(12px) scale(.99); } to { opacity: 1; transform: none; } }
.wvrc-card h3 { font-size: 18px; font-weight: 800; letter-spacing: -.01em; }
.wvrc-name {
  margin-top: 6px;
  font-family: var(--mono);
  font-size: 12.5px;
  color: #9fe8ff;
  word-break: break-all;
}
.wvrc-hint { margin-top: 12px; font-size: 12.5px; line-height: 1.72; color: var(--txt-2); }
.wvrc-in {
  width: 100%;
  height: 40px;
  margin-top: 14px;
  padding: 0 12px;
  border-radius: 10px;
  border: 1px solid var(--line-2);
  background: rgba(255, 255, 255, .045);
  color: var(--txt);
  font-family: var(--mono);
  font-size: 12.5px;
  outline: none;
  transition: border-color .16s, box-shadow .16s;
}
.wvrc-in:focus { border-color: rgba(122, 92, 255, .7); box-shadow: 0 0 0 3px rgba(122, 92, 255, .16); }
.wvrc-in::placeholder { color: var(--dim); }
.wvrc-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  flex-wrap: wrap;
  margin-top: 12px;
}
.wvrc-sel { display: inline-flex; align-items: center; gap: 8px; font-size: 11.5px; color: var(--dim); }
.wvrc-sel select {
  height: 28px;
  padding: 0 8px;
  border-radius: 8px;
  border: 1px solid var(--line-2);
  background: #0f0f1c;
  color: var(--txt);
  font-size: 11.5px;
  outline: none;
}
.wvrc-search {
  height: 28px;
  padding: 0 10px;
  border-radius: 8px;
  border: 1px dashed rgba(122, 92, 255, .45);
  background: transparent;
  color: #c7bbff;
  font-size: 11.5px;
  cursor: pointer;
  transition: background .16s, border-color .16s, color .16s;
}
.wvrc-search:hover { background: rgba(122, 92, 255, .16); border-color: rgba(122, 92, 255, .8); color: #fff; }
.wvrc-err { min-height: 17px; margin-top: 8px; font-size: 11.5px; color: #ff8aa8; }
.wvrc-foot { display: flex; justify-content: flex-end; gap: 10px; margin-top: 6px; }
.wvrc-foot button {
  height: 34px;
  padding: 0 16px;
  border-radius: 9px;
  font-size: 12.5px;
  font-weight: 600;
  cursor: pointer;
  transition: background .16s, border-color .16s, color .16s, box-shadow .2s;
}
.wvrc-cancel { border: 1px solid var(--line); background: transparent; color: var(--txt-2); }
.wvrc-cancel:hover { background: rgba(255, 255, 255, .06); color: var(--txt); }
.wvrc-go {
  border: 1px solid rgba(34, 211, 238, .7);
  background: linear-gradient(120deg, rgba(122, 92, 255, .45), rgba(34, 211, 238, .3));
  color: #eafcff;
  box-shadow: 0 0 16px rgba(122, 92, 255, .3);
}
.wvrc-go:hover { border-color: rgba(34, 211, 238, 1); box-shadow: 0 0 22px rgba(34, 211, 238, .45); }

/* 设置面板：VRChat 客户端那一段 */
.set-vrc {
  margin-top: 16px;
  padding: 14px 14px 12px;
  border-radius: 14px;
  border: 1px solid rgba(122, 92, 255, .26);
  background: linear-gradient(150deg, rgba(122, 92, 255, .1), rgba(34, 211, 238, .05));
  display: flex;
  flex-direction: column;
  gap: 9px;
}
.set-vrc-head { display: flex; flex-direction: column; gap: 4px; }
.set-vrc-head b { font-size: 12.5px; color: #cfc2ff; letter-spacing: .02em; }
.set-vrc-head i { font-style: normal; font-size: 11.5px; line-height: 1.6; color: var(--dim); }
.set-vrc-f { display: flex; align-items: center; gap: 10px; }
.set-vrc-f > span { flex: 0 0 132px; font-size: 11.5px; color: var(--txt-2); }
.set-vrc-f input {
  flex: 1 1 auto;
  min-width: 0;
  height: 32px;
  padding: 0 10px;
  border-radius: 9px;
  border: 1px solid var(--line-2);
  background: rgba(0, 0, 0, .35);
  color: var(--txt);
  font-family: var(--mono);
  font-size: 11.5px;
  outline: none;
  transition: border-color .16s, box-shadow .16s;
}
.set-vrc-f input:focus { border-color: rgba(122, 92, 255, .65); box-shadow: 0 0 0 3px rgba(122, 92, 255, .14); }
.set-vrc-hint { min-height: 15px; margin: 2px 0 0; font-size: 11px; line-height: 1.55; color: #7fe6c8; word-break: break-all; }
.set-vrc-hint.is-off { color: #ffb4b4; }
@media (max-width: 640px) {
  .set-vrc-f { flex-wrap: wrap; }
  .set-vrc-f > span { flex: 0 0 100%; }
}

/* 「线上进」小按钮：跟主按钮同一行，只有绑过世界 ID 的房间才出现 */
.world-acts .world-vrc-online {
  flex: 0 0 33px;
  width: 33px;
  height: 33px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0;
  border: 1px solid rgba(167, 139, 250, .34);
  border-radius: 9px;
  background: rgba(122, 92, 255, .12);
  color: #bdb0ff;
  cursor: pointer;
  transition: background .16s, border-color .16s, color .16s, box-shadow .2s;
}
.world-acts .world-vrc-online:hover {
  border-color: rgba(167, 139, 250, .85);
  background: rgba(122, 92, 255, .28);
  color: #fff;
  box-shadow: 0 0 14px rgba(122, 92, 255, .4);
}
.wo-ico { width: 14px; height: 14px; }

/* 启动中的按钮：压暗一点，右下角跑一条光带，别让人以为没反应 */
.world-acts .world-vrc-btn.is-working {
  cursor: progress;
  padding-right: 34px;
}
.world-acts .world-vrc-btn.is-working::before {
  content: "";
  position: absolute;
  right: 12px;
  top: 50%;
  width: 11px;
  height: 11px;
  margin-top: -5.5px;
  border-radius: 50%;
  border: 2px solid rgba(214, 247, 255, .28);
  border-top-color: #7fe6ff;
  animation: wvSpin .8s linear infinite;
}
@keyframes wvSpin { to { transform: rotate(360deg); } }
.world-acts .world-vrc-btn.is-done {
  border-color: rgba(47, 240, 192, .8);
  background: linear-gradient(120deg, rgba(47, 240, 192, .3), rgba(34, 211, 238, .24));
  color: #eafff9;
}

@media (prefers-reduced-motion: reduce) {
  .world-acts .world-vrc-btn.is-working::before { animation: none; }
  .world-acts .world-vrc-btn::after { transition: none; }
}
