/* ==========================================================================
   速云盘 — 极光渐变工作台 (v4)
   顶部导航布局 + 靛蓝/紫/青极光渐变 + 玻璃拟态
   ========================================================================== */

:root {
  color-scheme: light;

  --brand-700: #4338ca;
  --brand-600: #4f46e5;
  --brand-500: #6366f1;
  --brand-400: #818cf8;
  --brand-300: #a5b4fc;
  --brand-200: #c7d2fe;
  --brand-100: #e0e7ff;
  --brand-50: #eef2ff;

  --blue-500: #3b82f6;
  --cyan-500: #06b6d4;
  --violet-500: #8b5cf6;
  --violet-100: #ede9fe;

  --ink-900: #171a26;
  --text: #1c1f2b;
  --text-2: #5a6072;
  --text-3: #8b90a0;
  --text-4: #b6bac6;

  --bg: #f5f6fb;
  --surface: #ffffff;
  --surface-2: #fafbfe;
  --surface-3: #f2f3f9;

  --line: #e7e9f2;
  --line-2: #eff1f7;
  --line-3: #dcdfea;

  --success: #10b981;
  --success-soft: #e7f9f1;
  --warning: #f59e0b;
  --warning-soft: #fef4e2;
  --danger: #ef4444;
  --danger-soft: #feecec;
  --purple: #8b5cf6;
  --purple-soft: #f1ecfe;

  --grad: linear-gradient(135deg, #6366f1 0%, #4f46e5 22%, #3b82f6 58%, #06b6d4 100%);
  --grad-soft: linear-gradient(135deg, #eef2ff, #e0f7ff);

  --r-sm: 8px;
  --r: 12px;
  --r-lg: 16px;
  --r-xl: 22px;

  --sh-1: 0 1px 2px rgba(23, 26, 38, .05);
  --sh-2: 0 4px 16px rgba(23, 26, 38, .07);
  --sh-3: 0 12px 40px rgba(23, 26, 38, .14);
  --sh-brand: 0 6px 18px -4px rgba(79, 70, 229, .45);

  --ease: cubic-bezier(.4, 0, .2, 1);

  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC",
    "Hiragino Sans GB", "Microsoft YaHei", "Source Han Sans SC", sans-serif;
  font-synthesis: none;
  color: var(--text);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
}

*, *::before, *::after { box-sizing: border-box; }
html, body { height: 100%; }
body { margin: 0; background: var(--bg); color: var(--text); font-size: 14px; line-height: 1.6; }
h1, h2, h3, h4, p, dl, dd, dt { margin: 0; }
ul, ol { margin: 0; padding: 0; list-style: none; }
a { color: inherit; text-decoration: none; }
button, input, select, textarea { font: inherit; color: inherit; letter-spacing: inherit; }
button { cursor: pointer; background: none; border: 0; padding: 0; }
button:disabled { cursor: not-allowed; }
table { border-collapse: collapse; width: 100%; }
svg { flex: none; }
svg.lucide { display: block; }
:focus-visible { outline: 2px solid var(--brand-400); outline-offset: 1px; border-radius: 3px; }
::selection { background: var(--brand-100); color: var(--brand-700); }

* { scrollbar-width: thin; scrollbar-color: #d3d6e3 transparent; }
*::-webkit-scrollbar { width: 9px; height: 9px; }
*::-webkit-scrollbar-track { background: transparent; }
*::-webkit-scrollbar-thumb { background: #d3d6e3; border: 2px solid transparent; background-clip: content-box; border-radius: 99px; }
*::-webkit-scrollbar-thumb:hover { background: #b6bbc9; background-clip: content-box; }

/* --------------------------------------------------------------------------
   通用
   -------------------------------------------------------------------------- */
.mono { font-variant-numeric: tabular-nums; font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; }
.eyebrow { display: inline-block; font-size: 12px; font-weight: 600; color: var(--brand-500); letter-spacing: .02em; }
.subtext { color: var(--text-3); font-size: 13px; line-height: 1.7; }
.status-dot { display: inline-block; width: 7px; height: 7px; border-radius: 50%; background: var(--success); flex: none; box-shadow: 0 0 0 3px var(--success-soft); }

.icon-btn {
  display: inline-flex; align-items: center; justify-content: center;
  width: 36px; height: 36px; border-radius: var(--r-sm);
  color: var(--text-2);
  transition: background .16s var(--ease), color .16s var(--ease);
}
.icon-btn svg { width: 18px; height: 18px; }
.icon-btn:hover { background: var(--brand-100); color: var(--brand-600); }
.icon-btn:disabled { opacity: .35; pointer-events: none; }

.btn {
  display: inline-flex; align-items: center; justify-content: center;
  gap: 7px; height: 38px; padding: 0 16px;
  border-radius: var(--r-sm);
  border: 1px solid var(--line-3);
  background: var(--surface);
  color: var(--text);
  font-size: 14px; font-weight: 500;
  white-space: nowrap;
  box-shadow: var(--sh-1);
  transition: transform .12s var(--ease), box-shadow .18s var(--ease),
              background .16s var(--ease), border-color .16s var(--ease), color .16s var(--ease);
}
.btn svg { width: 16px; height: 16px; }
.btn:hover { border-color: var(--brand-300); color: var(--brand-600); background: var(--brand-50); }
.btn:active { transform: translateY(1px); }
.btn:disabled { opacity: .45; box-shadow: none; pointer-events: none; }

.btn.primary { border-color: transparent; background: var(--grad); color: #fff; box-shadow: var(--sh-brand); background-size: 160% 160%; }
.btn.primary:hover { color: #fff; filter: brightness(1.06); box-shadow: 0 8px 22px -6px rgba(79, 70, 229, .55); }

.btn.danger { border-color: transparent; background: var(--danger); color: #fff; box-shadow: 0 4px 14px -4px rgba(239, 68, 68, .5); }
.btn.danger:hover { background: #dc2626; color: #fff; border-color: transparent; }

.btn.ghost { background: transparent; box-shadow: none; border-color: var(--line-3); color: var(--text-2); }
.btn.ghost:hover { background: var(--surface-3); color: var(--text); border-color: var(--line-3); }
.btn.full { width: 100%; }

.pill {
  display: inline-flex; align-items: center; gap: 6px;
  height: 24px; padding: 0 10px;
  border-radius: 99px; font-size: 12px; font-weight: 500;
  background: var(--success-soft); color: var(--success);
}
.pill::before { content: ""; width: 6px; height: 6px; border-radius: 50%; background: currentColor; }
.pill.off { background: var(--surface-3); color: var(--text-3); }

.brand { display: inline-flex; align-items: center; gap: 10px; min-width: 0; }
.brand-mark {
  display: inline-flex; align-items: center; justify-content: center;
  width: 36px; height: 36px; border-radius: 11px;
  background: var(--grad);
  color: #fff;
  box-shadow: var(--sh-brand), inset 0 1px 0 rgba(255, 255, 255, .3);
  flex: none;
}
.brand-mark svg { width: 20px; height: 20px; }
.brand-copy { display: flex; flex-direction: column; line-height: 1.15; min-width: 0; }
.brand-copy strong { font-size: 17px; font-weight: 700; color: var(--text); letter-spacing: .01em; }
.brand-copy small { font-size: 9.5px; font-weight: 700; letter-spacing: .16em; text-transform: uppercase; color: var(--text-3); }

.info-strip {
  display: flex; align-items: center; gap: 9px;
  padding: 12px 16px; border-radius: var(--r);
  background: var(--brand-50); border: 1px solid var(--brand-100);
  color: var(--brand-700); font-size: 13px; line-height: 1.6;
  /* 公告条与下面的文件列表/卡片必须留出间距，否则会与文件名贴在一起 */
  margin-bottom: 16px;
}
.info-strip:last-child { margin-bottom: 0; }
.info-strip svg { width: 16px; height: 16px; flex: none; }
.info-strip > span { min-width: 0; }
.danger-strip { background: var(--danger-soft); border-color: #fbdcdc; color: #c21b1b; }
.link-strip { background: #e4f9fd; border-color: #c8f0f7; color: #087c92; }

.loading-screen {
  display: flex; align-items: center; justify-content: center; gap: 11px;
  min-height: 100vh; color: var(--text-3); font-size: 14px;
  background: var(--bg);
}
.loading-screen::before {
  content: ""; width: 20px; height: 20px; border-radius: 50%;
  border: 2.5px solid var(--brand-200); border-top-color: var(--brand-500);
  animation: spin .7s linear infinite;
}
@keyframes spin { to { transform: rotate(360deg); } }

/* --------------------------------------------------------------------------
   登录 / 注册：极光渐变 + 居中玻璃卡
   -------------------------------------------------------------------------- */
.login-page {
  position: relative;
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  min-height: 100vh; padding: 48px 20px;
  background:
    radial-gradient(55% 48% at 14% 12%, rgba(139, 92, 246, .30), transparent 62%),
    radial-gradient(48% 46% at 88% 18%, rgba(6, 182, 212, .26), transparent 60%),
    radial-gradient(65% 55% at 50% 100%, rgba(59, 130, 246, .24), transparent 66%),
    linear-gradient(165deg, #eef2ff, #f6f7fb 55%);
}
/* 细网格纹理 */
.login-page::before {
  content: ""; position: absolute; inset: 0; pointer-events: none;
  background-image: linear-gradient(rgba(79, 70, 229, .045) 1px, transparent 1px),
                    linear-gradient(90deg, rgba(79, 70, 229, .045) 1px, transparent 1px);
  background-size: 46px 46px;
  mask-image: radial-gradient(90% 70% at 50% 0%, #000 30%, transparent 90%);
  -webkit-mask-image: radial-gradient(90% 70% at 50% 0%, #000 30%, transparent 90%);
}
.login-page > * { position: relative; z-index: 1; }

.login-brand-panel {
  display: flex; flex-direction: column; align-items: center; gap: 12px;
  width: 100%; max-width: 420px; padding: 0; margin-bottom: 22px;
  background: none; text-align: center;
}
.login-brand-panel::before, .login-brand-panel::after { display: none; }
.login-brand-top { flex-direction: column; align-items: center; gap: 14px; width: 100%; }
.login-brand-panel .brand { justify-content: center; }
.login-brand-panel .brand-mark { width: 54px; height: 54px; border-radius: 16px; }
.login-brand-panel .brand-mark svg { width: 28px; height: 28px; }
.login-brand-panel .brand-copy strong { font-size: 24px; }
.login-brand-panel .brand-copy small { font-size: 10px; }

.login-private, .login-statement, .login-file-stack, .register-steps, .login-brand-foot { display: none; }

.login-access { display: block; width: 100%; max-width: 420px; padding: 0; }
.login-box {
  width: 100%; padding: 32px 32px 28px;
  border-radius: var(--r-xl);
  background: rgba(255, 255, 255, .82);
  backdrop-filter: blur(18px);
  border: 1px solid rgba(255, 255, 255, .9);
  box-shadow: 0 20px 60px -20px rgba(79, 70, 229, .35), inset 0 1px 0 rgba(255, 255, 255, .9);
}
.login-number { display: none; }
.login-heading h1 { font-size: 21px; font-weight: 700; }
.login-heading p { margin-top: 6px; color: var(--text-3); font-size: 13.5px; }
.login-heading .eyebrow { display: none; }

label { display: block; }
label > span:first-child { display: block; margin-bottom: 6px; font-size: 13px; font-weight: 500; color: var(--text-2); }
input[type="text"], input[type="password"], input[type="number"],
input[type="email"], input[type="search"], input:not([type]), select, textarea {
  width: 100%; min-height: 42px; padding: 10px 13px;
  border-radius: var(--r-sm);
  border: 1px solid var(--line-3);
  background: rgba(255, 255, 255, .8);
  color: var(--text); font-size: 14px;
  transition: border-color .16s var(--ease), box-shadow .16s var(--ease), background .16s var(--ease);
}
textarea { min-height: 92px; resize: vertical; line-height: 1.65; }
select { appearance: none; cursor: pointer; padding-right: 34px;
  background-image: linear-gradient(45deg, transparent 50%, var(--text-3) 50%), linear-gradient(135deg, var(--text-3) 50%, transparent 50%);
  background-position: calc(100% - 17px) 52%, calc(100% - 12px) 52%;
  background-size: 5px 5px, 5px 5px; background-repeat: no-repeat;
}
input::placeholder, textarea::placeholder { color: var(--text-4); }
input:hover, select:hover, textarea:hover { border-color: var(--brand-300); }
input:focus, select:focus, textarea:focus {
  outline: none; border-color: var(--brand-400); background: #fff;
  box-shadow: 0 0 0 4px rgba(99, 102, 241, .14);
}
input:disabled, select:disabled, textarea:disabled { background: var(--surface-3); color: var(--text-3); }
label + label { margin-top: 16px; }

.password-field { position: relative; display: flex; align-items: center; }
.password-field input { padding-right: 42px; }
.password-field .icon-btn { position: absolute; right: 4px; width: 30px; height: 30px; }

.check { display: flex; align-items: flex-start; gap: 9px; margin-top: 15px; cursor: pointer; }
.check input, .register-rule input { width: 16px; height: 16px; margin: 3px 0 0; accent-color: var(--brand-500); flex: none; }
.check > span, .register-rule > span { margin: 0; font-size: 13px; color: var(--text-2); line-height: 1.6; }

.error-text { min-height: 18px; margin-top: 10px; color: var(--danger); font-size: 13px; }
.error-text:empty { margin-top: 0; min-height: 0; }
.login-submit { margin-top: 22px; height: 44px; font-size: 15px; }
.login-form-wrap { display: block; }

.login-entry-links {
  display: flex; justify-content: space-between; gap: 12px;
  margin-top: 20px; padding-top: 18px; border-top: 1px solid var(--line-2); font-size: 13px;
}
.login-entry-links a { color: var(--brand-600); font-weight: 500; }
.login-entry-links a:hover { color: var(--brand-700); }
.login-note {
  display: flex; align-items: center; gap: 8px; margin-top: 18px;
  padding: 10px 13px; border-radius: var(--r-sm);
  background: var(--surface-3); font-size: 12.5px; color: var(--text-3);
}
.login-note .status-dot { background: var(--brand-400); box-shadow: 0 0 0 3px var(--brand-100); }

.register-rule { display: flex; align-items: flex-start; gap: 9px; margin-top: 16px; cursor: pointer; }

.registration-state {
  display: flex; align-items: center; justify-content: center; min-height: 100vh; padding: 40px 20px;
  background:
    radial-gradient(55% 48% at 14% 12%, rgba(139, 92, 246, .28), transparent 62%),
    linear-gradient(165deg, #eef2ff, #f6f7fb 55%);
}
.registration-state section {
  width: 100%; max-width: 440px; padding: 42px 34px; text-align: center;
  border-radius: var(--r-xl);
  background: rgba(255, 255, 255, .86); backdrop-filter: blur(16px);
  border: 1px solid rgba(255, 255, 255, .9);
  box-shadow: 0 20px 60px -20px rgba(79, 70, 229, .3);
}
.registration-state-icon {
  display: inline-flex; align-items: center; justify-content: center;
  width: 60px; height: 60px; margin-bottom: 18px; border-radius: 18px;
  background: var(--grad); color: #fff; box-shadow: var(--sh-brand);
}
.registration-state-icon svg { width: 28px; height: 28px; }
.registration-state-icon.success { background: var(--success); box-shadow: 0 6px 16px -4px rgba(16, 185, 129, .5); }
.registration-state h1 { font-size: 20px; font-weight: 700; }
.registration-state p { margin-top: 10px; color: var(--text-3); font-size: 13.5px; line-height: 1.7; }
.registration-state .btn { margin-top: 24px; }
.registration-state .eyebrow { display: none; }

/* --------------------------------------------------------------------------
   顶部导航框架
   -------------------------------------------------------------------------- */
.shell { display: flex; flex-direction: column; min-height: 100vh; background: var(--bg); }

.topbar {
  position: sticky; top: 0; z-index: 30;
  background: rgba(255, 255, 255, .85);
  backdrop-filter: saturate(1.5) blur(14px);
  border-bottom: 1px solid var(--line);
  box-shadow: 0 2px 12px rgba(23, 26, 38, .04);
}
.topbar-inner {
  display: flex; align-items: center; gap: 22px;
  max-width: 1240px; margin: 0 auto;
  height: 64px; padding: 0 24px;
}

.topbar-brand { flex: none; }

.topnav { display: flex; align-items: center; gap: 3px; flex: 1; min-width: 0; }
.topnav-link {
  display: inline-flex; align-items: center; gap: 7px;
  height: 38px; padding: 0 14px; border-radius: 99px;
  color: var(--text-2); font-size: 14px; font-weight: 500;
  white-space: nowrap;
  transition: background .16s var(--ease), color .16s var(--ease);
}
.topnav-link:hover { background: var(--surface-3); color: var(--text); }
.topnav-link.active { background: var(--brand-100); color: var(--brand-600); font-weight: 600; }
.nav-icon { display: inline-flex; align-items: center; justify-content: center; width: 17px; height: 17px; flex: none; }
.nav-icon svg { width: 17px; height: 17px; }

.topbar-actions { display: flex; align-items: center; gap: 8px; flex: none; }

.storage-chip {
  display: flex; align-items: center; gap: 10px;
  height: 44px; padding: 0 12px 0 8px; border-radius: var(--r);
  background: var(--surface-3); border: 1px solid var(--line);
  cursor: pointer;
  transition: border-color .16s var(--ease), box-shadow .16s var(--ease);
}
.storage-chip:hover { border-color: var(--brand-300); box-shadow: var(--sh-2); }
.storage-ring {
  --p: 0;
  position: relative;
  display: inline-flex; align-items: center; justify-content: center;
  width: 34px; height: 34px; border-radius: 50%; flex: none;
  background: conic-gradient(var(--brand-500) calc(var(--p) * 1%), #e5e7f1 0);
}
.storage-ring::before { content: ""; position: absolute; inset: 4px; border-radius: 50%; background: var(--surface); }
.storage-ring span { position: relative; font-size: 9px; font-weight: 700; color: var(--text); }
.storage-chip-copy { display: flex; flex-direction: column; line-height: 1.25; }
.storage-chip-copy strong { font-size: 12.5px; font-weight: 600; color: var(--text); }
.storage-chip-copy small { font-size: 11px; color: var(--text-3); font-variant-numeric: tabular-nums; }

.account { display: flex; align-items: center; gap: 9px; padding: 4px 6px; border-radius: var(--r); }
.account:hover { background: var(--surface-3); }
.avatar {
  display: inline-flex; align-items: center; justify-content: center;
  width: 34px; height: 34px; border-radius: 50%;
  background: var(--grad); color: #fff; font-size: 14px; font-weight: 600; flex: none;
  box-shadow: var(--sh-brand);
}
.account-copy { display: flex; flex-direction: column; line-height: 1.2; min-width: 0; }
.account-name { font-size: 13px; font-weight: 600; color: var(--text); max-width: 120px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.account-role { font-size: 11px; color: var(--text-3); }

.workspace { display: flex; flex-direction: column; flex: 1; min-width: 0; }
.content { width: 100%; max-width: 1240px; margin: 0 auto; padding: 26px 24px 60px; flex: 1; }

.environment-state {
  display: inline-flex; align-items: center; gap: 7px;
  height: 28px; padding: 0 12px; border-radius: 99px;
  background: var(--surface-3); border: 1px solid var(--line);
  font-size: 12px; font-weight: 500; color: var(--text-2);
}
.environment-state .status-dot { background: var(--brand-400); box-shadow: 0 0 0 3px var(--brand-100); }

.mobile-menu { display: none; }
.mobile-shade { display: none; position: fixed; inset: 0; z-index: 40; background: rgba(23, 26, 38, .4); backdrop-filter: blur(2px); }

/* --------------------------------------------------------------------------
   内容组件
   -------------------------------------------------------------------------- */
.heading-row {
  display: flex; align-items: flex-end; justify-content: space-between;
  gap: 18px; flex-wrap: wrap; margin-bottom: 20px;
}
.heading-copy .eyebrow { margin-bottom: 8px; }
.heading-copy h1 { font-size: 24px; font-weight: 700; letter-spacing: -.01em; }
.heading-copy .subtext { margin-top: 5px; }
.heading-actions { display: flex; align-items: center; gap: 9px; flex-wrap: wrap; }

.toolbar { display: flex; align-items: center; justify-content: space-between; gap: 14px; flex-wrap: wrap; }
.browser-toolbar { padding: 0; margin-bottom: 14px; border-radius: 0; background: none; border: 0; box-shadow: none; }

.crumbs { display: flex; align-items: center; gap: 3px; flex-wrap: wrap; min-width: 0; }
.crumbs svg { width: 14px; height: 14px; color: var(--text-4); flex: none; }
.crumbs button { padding: 5px 9px; border-radius: var(--r-sm); font-size: 13px; font-weight: 500; color: var(--text-2); transition: background .15s var(--ease), color .15s var(--ease); }
.crumbs button:hover { background: var(--brand-50); color: var(--brand-600); }
.crumbs button:last-of-type { color: var(--text); }

.search-box {
  display: flex; align-items: center; gap: 8px;
  min-width: 260px; height: 38px; padding: 0 5px 0 13px;
  border-radius: 99px;
  background: var(--surface); border: 1px solid var(--line-3);
  transition: border-color .16s var(--ease), box-shadow .16s var(--ease);
}
.search-box:focus-within { border-color: var(--brand-400); box-shadow: 0 0 0 4px rgba(99, 102, 241, .12); }
.search-box svg { width: 16px; height: 16px; color: var(--text-3); flex: none; }
.search-box input { border: 0; background: none; min-height: 0; height: 36px; padding: 0; box-shadow: none !important; font-size: 13.5px; }
.search-box input:hover { border: 0; }
.search-box input:focus { outline: none; border: 0; box-shadow: none; }
.search-box .icon-btn { width: 28px; height: 28px; }

.empty { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 8px; padding: 58px 24px; text-align: center; }
.empty > svg { width: 40px; height: 40px; margin-bottom: 6px; color: var(--brand-200); }
.empty h3 { font-size: 15px; font-weight: 600; color: var(--text); }
.empty p { font-size: 13px; color: var(--text-3); max-width: 46ch; }

.folder-announcement {
  display: flex; flex-direction: column; align-items: flex-start; gap: 8px;
  padding: 15px 17px; margin-bottom: 14px; border-radius: var(--r);
  background: var(--grad-soft); border: 1px solid var(--brand-100);
}
.notice-label {
  display: inline-flex; align-items: center; gap: 7px;
  width: 100%; padding-bottom: 9px; border-bottom: 1px solid var(--brand-100);
  font-size: 12.5px; font-weight: 700; color: var(--brand-600);
}
.notice-label svg { width: 16px; height: 16px; }
.notice-text { width: 100%; font-size: 13.5px; line-height: 1.75; color: var(--text-2); white-space: pre-wrap; }

.notice-preview { margin-top: 13px; padding: 13px 15px; border-radius: var(--r-sm); background: var(--surface-3); font-size: 13px; line-height: 1.7; color: var(--text-2); white-space: pre-wrap; }

.upload-progress { padding: 13px 16px; margin-bottom: 14px; border-radius: var(--r); background: var(--surface); border: 1px solid var(--brand-100); box-shadow: var(--sh-2); }
.upload-progress > div { display: flex; justify-content: space-between; align-items: baseline; gap: 12px; margin-bottom: 9px; font-size: 13px; }
.upload-progress strong { font-weight: 500; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.upload-progress span { color: var(--text-3); font-size: 12px; font-variant-numeric: tabular-nums; flex: none; }
.upload-progress progress { appearance: none; -webkit-appearance: none; width: 100%; height: 6px; border: 0; border-radius: 99px; background: var(--surface-3); overflow: hidden; }
.upload-progress progress::-webkit-progress-bar { background: var(--surface-3); border-radius: 99px; }
.upload-progress progress::-webkit-progress-value { background: var(--grad); border-radius: 99px; }
.upload-progress progress::-moz-progress-bar { background: var(--grad); border-radius: 99px; }
/* 上行发完后进入「服务器处理中」阶段：去掉 value 走不确定模式。
   appearance:none 会把浏览器自带的循环动画一并去掉，所以这里自己扫一条。 */
.upload-progress progress:indeterminate {
  background-color: var(--surface-3);
  background-image: linear-gradient(90deg,
    transparent 0%,
    color-mix(in srgb, var(--brand, #2563eb) 55%, transparent) 40%,
    var(--brand, #2563eb) 50%,
    color-mix(in srgb, var(--brand, #2563eb) 55%, transparent) 60%,
    transparent 100%);
  background-size: 45% 100%;
  background-repeat: no-repeat;
  background-position: -45% 0;
  animation: upload-sweep 1.15s linear infinite;
}
@keyframes upload-sweep {
  from { background-position: -45% 0; }
  to { background-position: 145% 0; }
}
/* 进度条下方的字节数 / 阶段说明 */
.upload-progress > .upload-meta { margin: 9px 0 0; }
.upload-progress > .upload-meta span { color: var(--text-3); }
.upload-progress > .upload-meta #upload-phase { text-align: right; }
@media (prefers-reduced-motion: reduce) {
  .upload-progress progress:indeterminate { animation-duration: 2.4s; }
}

.list-footer { display: flex; justify-content: space-between; gap: 12px; flex-wrap: wrap; margin-top: 14px; font-size: 12.5px; color: var(--text-3); }

/* --------------------------------------------------------------------------
   文件列表
   -------------------------------------------------------------------------- */
.file-browser { border-radius: var(--r-lg); background: var(--surface); border: 1px solid var(--line); box-shadow: var(--sh-1); overflow: hidden; }
.empty-browser { background: var(--surface); }

.file-table { width: 100%; }
.file-table thead th {
  padding: 11px 18px; text-align: left;
  font-size: 12px; font-weight: 600; letter-spacing: .03em;
  color: var(--text-3); background: var(--surface-2); border-bottom: 1px solid var(--line); white-space: nowrap;
}
.file-table tbody tr { border-bottom: 1px solid var(--line-2); transition: background .13s var(--ease); }
.file-table tbody tr:last-child { border-bottom: 0; }
.file-table tbody tr:hover { background: var(--brand-50); }
.file-table td { padding: 12px 18px; font-size: 13.5px; vertical-align: middle; color: var(--text-2); }
.file-table td.mono { font-size: 12.5px; }
.name-cell { width: 100%; }
.date-cell { white-space: nowrap; color: var(--text-3); font-size: 12.5px; }
.file-table tbody tr[data-node]:not([data-public]) { cursor: pointer; }

.file-name { display: flex; align-items: center; gap: 12px; min-width: 0; }
.file-copy { display: flex; flex-direction: column; min-width: 0; }
.file-title { font-size: 14px; font-weight: 500; color: var(--text); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.file-table tbody tr:hover .file-title { color: var(--brand-600); }
.file-desc { font-size: 12px; color: var(--text-3); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

.file-icon {
  display: inline-flex; align-items: center; justify-content: center;
  width: 38px; height: 38px; border-radius: 11px; flex: none;
  background: var(--brand-100); color: var(--brand-600);
}
.file-icon svg { width: 19px; height: 19px; }
.file-icon.folder { background: linear-gradient(135deg, #c7d2fe, #a5b4fc); color: #4338ca; }
.file-icon.archive { background: var(--warning-soft); color: var(--warning); }
.file-icon.image { background: var(--purple-soft); color: var(--purple); }
.file-icon.pdf { background: var(--danger-soft); color: var(--danger); }

.row-actions { display: flex; align-items: center; justify-content: flex-end; gap: 3px; }
.action-cell { text-align: right; width: 100px; }
.quick-share { color: var(--text-3); }
.quick-share:hover { background: var(--brand-100); color: var(--brand-600); }

/* --------------------------------------------------------------------------
   数据表格
   -------------------------------------------------------------------------- */
.table-wrap { border-radius: var(--r-lg); border: 1px solid var(--line); background: var(--surface); box-shadow: var(--sh-1); overflow-x: auto; }
.table-surface { overflow: hidden; }
.data-table { width: 100%; min-width: 720px; }
.data-table thead th {
  padding: 11px 18px; text-align: left; font-size: 12px; font-weight: 600; letter-spacing: .03em;
  color: var(--text-3); background: var(--surface-2); border-bottom: 1px solid var(--line); white-space: nowrap;
}
.data-table tbody tr { border-bottom: 1px solid var(--line-2); transition: background .13s var(--ease); }
.data-table tbody tr:last-child { border-bottom: 0; }
.data-table tbody tr:hover { background: var(--brand-50); }
.data-table td { padding: 13px 18px; font-size: 13.5px; vertical-align: middle; color: var(--text-2); }
.primary-text { font-size: 13.5px; font-weight: 500; color: var(--text); }
.row-sub { margin-top: 2px; font-size: 12px; color: var(--text-3); }
.table-link {
  display: inline-block; max-width: 320px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
  vertical-align: bottom; color: var(--brand-600); font-size: 12.5px;
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
}
.table-link:hover { color: var(--brand-700); text-decoration: underline; }
.billing-source { margin-top: 2px; font-size: 12px; color: var(--text-3); }

.share-overview { display: grid; grid-template-columns: repeat(auto-fit, minmax(170px, 1fr)); gap: 14px; margin-bottom: 16px; }
.share-overview > div {
  padding: 18px 20px; border-radius: var(--r-lg); background: var(--surface); border: 1px solid var(--line); box-shadow: var(--sh-1);
}
.share-overview span { display: block; font-size: 12.5px; color: var(--text-3); margin-bottom: 5px; }
.share-overview strong { font-size: 26px; font-weight: 700; color: var(--text); font-variant-numeric: tabular-nums; }
.share-overview strong.overview-text { font-size: 18px; font-weight: 600; color: var(--brand-600); }

/* --------------------------------------------------------------------------
   统计 / 标签页 / 方案 / 设置
   -------------------------------------------------------------------------- */
.stats { display: grid; grid-template-columns: repeat(auto-fit, minmax(210px, 1fr)); gap: 14px; margin-bottom: 16px; }
.stat { position: relative; padding: 20px 22px; border-radius: var(--r-lg); background: var(--surface); border: 1px solid var(--line); box-shadow: var(--sh-1); overflow: hidden; }
.stat::before { content: ""; position: absolute; inset: 0 auto 0 0; width: 4px; background: var(--grad); }
.stat-label { font-size: 12.5px; color: var(--text-3); }
.stat-value { margin-top: 8px; font-size: 28px; font-weight: 700; color: var(--text); letter-spacing: -.02em; line-height: 1.15; }
.stat-value small { margin-left: 4px; font-size: 13px; font-weight: 500; color: var(--text-3); }
.stat-note { margin-top: 6px; font-size: 12px; color: var(--text-3); }

.type-tabs { display: inline-flex; gap: 3px; padding: 4px; margin-bottom: 16px; border-radius: 99px; background: var(--surface-3); }
.type-tabs button { padding: 8px 18px; border-radius: 99px; font-size: 13.5px; font-weight: 500; color: var(--text-2); transition: background .16s var(--ease), color .16s var(--ease), box-shadow .16s var(--ease); }
.type-tabs button:hover { color: var(--text); }
.type-tabs button.active { background: var(--surface); color: var(--brand-600); box-shadow: var(--sh-2); }

.plan-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(250px, 1fr)); gap: 16px; margin: 18px 0 24px; }
.plan {
  position: relative; display: flex; flex-direction: column; padding: 26px 24px;
  border-radius: var(--r-lg); background: var(--surface); border: 1px solid var(--line); box-shadow: var(--sh-1);
  transition: transform .18s var(--ease), box-shadow .18s var(--ease), border-color .18s var(--ease);
}
.plan:hover { transform: translateY(-3px); box-shadow: var(--sh-2); border-color: var(--brand-200); }
.plan.current { border-color: var(--brand-400); box-shadow: 0 0 0 1px var(--brand-400), var(--sh-2); background: linear-gradient(175deg, var(--brand-50), #fff 38%); }
.plan h3 { font-size: 16px; font-weight: 700; }
.plan .pill { position: absolute; top: 22px; right: 22px; }
.capacity { margin-top: 14px; font-size: 38px; font-weight: 700; letter-spacing: -.03em; line-height: 1; color: var(--brand-600); }
.capacity small { margin-left: 5px; font-size: 14px; font-weight: 500; color: var(--text-3); letter-spacing: 0; }
.plan-price { margin-top: 8px; font-size: 12.5px; color: var(--text-3); }
.plan ul { display: flex; flex-direction: column; gap: 10px; margin: 20px 0 24px; padding-top: 18px; border-top: 1px solid var(--line-2); }
.plan li { display: flex; align-items: center; gap: 9px; font-size: 13px; color: var(--text-2); }
.plan li svg { width: 15px; height: 15px; color: var(--success); flex: none; }
.plan .btn { margin-top: auto; }

.settings-section { padding: 22px 24px; margin-bottom: 16px; border-radius: var(--r-lg); background: var(--surface); border: 1px solid var(--line); box-shadow: var(--sh-1); }
.settings-section h2 { font-size: 15px; font-weight: 700; margin-bottom: 18px; padding-bottom: 14px; border-bottom: 1px solid var(--line-2); }
.settings-section .subtext { margin-top: 13px; }
.form-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 18px; }
/* 同上：压掉 `.modal-content label + label { margin-top:16px }`（同为 (0,1,2) 但更靠后） */
.form-grid > label + label,
.modal-content .form-grid > label + label,
.modal-content .form-grid label + label { margin-top: 0; }

.status-row { display: flex; justify-content: space-between; align-items: center; gap: 14px; padding: 11px 0; border-bottom: 1px solid var(--line-2); font-size: 13.5px; }
.status-row:last-child { border-bottom: 0; }
.status-row > span:first-child { color: var(--text-3); }
.status-row > span:last-child { font-weight: 500; color: var(--text); }

.share-result { margin-top: 16px; padding: 15px 17px; border-radius: var(--r); background: var(--brand-50); border: 1px solid var(--brand-100); }
.share-result-label { display: block; margin-bottom: 7px; font-size: 11.5px; font-weight: 600; letter-spacing: .02em; color: var(--brand-500); }
.share-result a { display: block; word-break: break-all; font-size: 13px; font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; color: var(--brand-700); }
.share-result a:hover { text-decoration: underline; }

/* --------------------------------------------------------------------------
   弹窗 / 菜单 / 提示
   -------------------------------------------------------------------------- */
.modal-backdrop {
  position: fixed; inset: 0; z-index: 100;
  display: flex; align-items: center; justify-content: center;
  padding: 22px; background: rgba(23, 26, 38, .5); backdrop-filter: blur(6px);
  animation: fade-in .16s var(--ease);
}
@keyframes fade-in { from { opacity: 0; } }
.modal {
  display: flex; flex-direction: column;
  width: 100%; max-width: 500px; max-height: calc(100vh - 44px);
  border-radius: var(--r-xl);
  background: var(--surface); box-shadow: var(--sh-3);
  overflow: hidden; animation: modal-in .2s var(--ease);
}
@keyframes modal-in { from { opacity: 0; transform: translateY(10px) scale(.99); } }
.modal.wide { max-width: 680px; }
.modal-header { display: flex; align-items: center; justify-content: space-between; gap: 14px; padding: 18px 22px; border-bottom: 1px solid var(--line-2); }
.modal-header h2 { font-size: 16px; font-weight: 700; }
.modal-content { padding: 22px; overflow-y: auto; }
.modal-content label + label { margin-top: 16px; }
.modal-content .file-name { margin-bottom: 6px; }
.modal-content progress { width: 100%; }
.modal-footer { display: flex; align-items: center; justify-content: flex-end; gap: 9px; flex-wrap: wrap; padding: 14px 22px; border-top: 1px solid var(--line-2); background: var(--surface-2); }

.menu { position: fixed; z-index: 120; min-width: 190px; padding: 5px; border-radius: var(--r); background: var(--surface); border: 1px solid var(--line); box-shadow: var(--sh-3); animation: modal-in .14s var(--ease); }
.menu button { display: flex; align-items: center; gap: 10px; width: 100%; padding: 9px 11px; border-radius: var(--r-sm); font-size: 13.5px; color: var(--text); text-align: left; transition: background .12s var(--ease), color .12s var(--ease); }
.menu button svg { width: 16px; height: 16px; color: var(--text-3); flex: none; }
.menu button:hover { background: var(--brand-100); color: var(--brand-600); }
.menu button:hover svg { color: var(--brand-500); }
.menu button.danger { color: var(--danger); }
.menu button.danger svg { color: var(--danger); }
.menu button.danger:hover { background: var(--danger-soft); color: var(--danger); }
.menu hr { margin: 5px 7px; border: 0; border-top: 1px solid var(--line-2); }

#toast-root, #admin-toast-root { position: fixed; left: 50%; bottom: 32px; z-index: 200; transform: translateX(-50%); pointer-events: none; }
.toast { display: flex; align-items: center; gap: 9px; padding: 12px 18px; border-radius: 99px; background: var(--ink-900); color: #fff; font-size: 13.5px; box-shadow: var(--sh-3); animation: toast-in .22s var(--ease); max-width: min(88vw, 540px); }
.toast svg { width: 17px; height: 17px; flex: none; }
.toast.error, .toast.danger { background: var(--danger); }
.toast.success { background: var(--success); }
@keyframes toast-in { from { opacity: 0; transform: translateY(12px); } }

body.drop-zone-active::after {
  content: "松开鼠标，上传到当前文件夹";
  position: fixed; inset: 14px; z-index: 300;
  display: flex; align-items: center; justify-content: center;
  border-radius: var(--r-xl); border: 2px dashed var(--brand-400);
  background: rgba(238, 242, 255, .95); backdrop-filter: blur(6px);
  color: var(--brand-600); font-size: 18px; font-weight: 600; pointer-events: none;
}

/* --------------------------------------------------------------------------
   公开分享页
   -------------------------------------------------------------------------- */
.public-page { display: flex; flex-direction: column; min-height: 100vh; background: var(--bg); }
.public-header {
  position: sticky; top: 0; z-index: 30;
  background: rgba(255, 255, 255, .85); backdrop-filter: saturate(1.5) blur(14px);
  border-bottom: 1px solid var(--line);
  box-shadow: 0 2px 12px rgba(23, 26, 38, .04);
}
.public-header-inner, .public-header { padding: 0; }
.public-header { display: flex; align-items: center; justify-content: space-between; gap: 16px; flex-wrap: wrap; height: 64px; padding: 0 24px; }
.public-identity { display: flex; align-items: center; gap: 16px; flex-wrap: wrap; min-width: 0; }
.public-brand { display: inline-flex; align-items: center; }
.public-owner { display: inline-flex; align-items: center; gap: 7px; padding: 5px 13px; border-radius: 99px; background: var(--surface-3); border: 1px solid var(--line); font-size: 12.5px; font-weight: 500; color: var(--text-2); }
.public-owner .status-dot { background: var(--brand-400); box-shadow: 0 0 0 3px var(--brand-100); }
.public-owner-name { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-width: 40vw; }
.public-actions { display: flex; align-items: center; gap: 9px; }

.public-main { flex: 1; width: 100%; max-width: 1080px; margin: 0 auto; padding: 26px 24px 60px; }
.public-error { display: flex; align-items: center; justify-content: center; }
.public-footer {
  display: flex; align-items: center; justify-content: space-between; gap: 14px; flex-wrap: wrap;
  padding: 20px 24px; border-top: 1px solid var(--line); background: var(--surface); font-size: 12.5px; color: var(--text-3);
}

.public-folder-hero {
  position: relative; overflow: hidden;
  padding: 26px 28px; margin-bottom: 18px; border-radius: var(--r-xl);
  background: var(--grad); color: #fff; box-shadow: var(--sh-brand);
}
.public-folder-hero::after { content: ""; position: absolute; width: 260px; height: 260px; right: -60px; top: -90px; border-radius: 50%; background: rgba(255, 255, 255, .14); }
.public-title { position: relative; z-index: 1; display: flex; align-items: center; justify-content: space-between; gap: 18px; }
.public-title .eyebrow { color: rgba(255, 255, 255, .8); }
.public-title h1 { font-size: 24px; font-weight: 700; line-height: 1.35; word-break: break-word; }
.public-title .subtext { color: rgba(255, 255, 255, .85); }
.public-title-icon { display: inline-flex; align-items: center; justify-content: center; width: 56px; height: 56px; border-radius: 16px; background: rgba(255, 255, 255, .18); border: 1px solid rgba(255, 255, 255, .3); color: #fff; flex: none; }
.public-title-icon svg { width: 27px; height: 27px; }
.public-folder-facts { position: relative; z-index: 1; display: flex; flex-wrap: wrap; gap: 32px; margin-top: 20px; padding-top: 16px; border-top: 1px solid rgba(255, 255, 255, .22); }
.public-folder-facts > span { display: flex; flex-direction: column; gap: 2px; }
.public-folder-facts small { font-size: 12px; color: rgba(255, 255, 255, .75); }
.public-folder-facts strong { font-size: 15px; font-weight: 600; color: #fff; }

.delivery-list { border-radius: var(--r-lg); background: var(--surface); border: 1px solid var(--line); box-shadow: var(--sh-1); overflow: hidden; }
.delivery-empty { background: var(--surface); }
.delivery-list-head { display: grid; grid-template-columns: 1fr 190px 44px; gap: 14px; padding: 10px 20px; font-size: 12px; font-weight: 600; color: var(--text-3); background: var(--surface-2); border-bottom: 1px solid var(--line); }
.delivery-list-body { display: flex; flex-direction: column; }
.delivery-row { display: grid; grid-template-columns: 1fr 190px 44px; gap: 14px; align-items: center; width: 100%; padding: 11px 20px; border-bottom: 1px solid var(--line-2); text-align: left; transition: background .13s var(--ease); }
.delivery-row:last-child { border-bottom: 0; }
.delivery-row:hover { background: var(--brand-50); }
.delivery-name { display: flex; align-items: center; gap: 11px; min-width: 0; }
.delivery-copy { display: flex; flex-direction: column; min-width: 0; }
.delivery-copy strong { font-size: 14px; font-weight: 500; color: var(--text); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.delivery-row:hover .delivery-copy strong { color: var(--brand-600); }
.delivery-copy small { font-size: 12px; color: var(--text-3); }
.delivery-meta { display: flex; flex-direction: column; }
.delivery-meta strong { font-size: 12.5px; font-weight: 500; color: var(--text-2); font-variant-numeric: tabular-nums; }
.delivery-meta small { font-size: 12px; color: var(--text-3); }
.delivery-open { display: flex; align-items: center; justify-content: flex-end; color: var(--text-4); }
.delivery-open svg { width: 17px; height: 17px; }
.delivery-row:hover .delivery-open { color: var(--brand-500); }

/* 单文件下载卡：居中单卡，公告内联在文件信息下方 */
.download-card {
  width: 100%; max-width: 680px; margin: 0 auto;
  padding: 34px 36px;
  border-radius: var(--r-xl);
  background: var(--surface);
  border: 1px solid var(--line);
  box-shadow: var(--sh-2);
}
.download-head { display: flex; align-items: center; gap: 18px; }
.download-icon { flex: none; }
.download-icon .file-icon { width: 68px; height: 68px; border-radius: 18px; }
.download-icon .file-icon svg { width: 34px; height: 34px; }
.download-title { min-width: 0; }
.download-title h1 { font-size: 22px; font-weight: 700; line-height: 1.35; word-break: break-word; }
.download-title p { margin-top: 6px; font-size: 13px; color: var(--text-3); }

.download-card .folder-announcement { margin-top: 22px; margin-bottom: 0; }

/* 三项信息条：与下载按钮等宽，三栏均分，竖线点缀 */
.download-actions {
  margin-top: 22px;
  display: flex; flex-direction: column; gap: 12px;
}
.download-meta {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  width: 100%; margin: 0;
  padding: 13px 6px;
  background: var(--surface-3);
  border: 1px solid var(--line-2);
  border-radius: var(--r);
}
.meta-cell {
  display: flex; flex-direction: column; align-items: center; gap: 3px;
  text-align: center;
}
.meta-cell + .meta-cell { border-left: 1px solid var(--line-3); }
.download-meta dt { font-size: 12px; color: var(--text-3); }
.download-meta dd { font-size: 14px; font-weight: 600; color: var(--text); font-variant-numeric: tabular-nums; }

.download-btn { width: 100%; height: 52px; font-size: 16px; border-radius: var(--r); }

.download-note {
  display: flex; flex-direction: column; align-items: center; gap: 4px;
  margin-top: 18px; padding-top: 16px;
  border-top: 1px dashed var(--line-3);
  text-align: center;
}
.download-note p { margin: 0; font-size: 12px; line-height: 1.75; color: var(--text-3); }
.download-panel-label { display: none; }

@media (max-width: 480px) {
  .download-card { padding: 26px 18px; }
  .download-title h1 { font-size: 19px; }
  .download-meta { padding: 11px 2px; }
  .download-meta dd { font-size: 13px; }
}

.public-back { display: inline-flex; align-items: center; gap: 7px; margin-bottom: 14px; padding: 7px 14px; border-radius: 99px; border: 1px solid var(--line-3); background: var(--surface); font-size: 13px; font-weight: 500; color: var(--text-2); box-shadow: var(--sh-1); transition: border-color .15s var(--ease), color .15s var(--ease); }
.public-back svg { width: 15px; height: 15px; }
.public-back:hover { border-color: var(--brand-300); color: var(--brand-600); }

.public-unlock-layout { display: grid; grid-template-columns: minmax(0, 1fr) 360px; gap: 18px; align-items: center; min-height: 60vh; }
.public-unlock-summary { padding: 30px 30px; border-radius: var(--r-xl); background: var(--surface); border: 1px solid var(--line); box-shadow: var(--sh-1); }
.unlock-mark { display: flex; align-items: center; justify-content: center; width: 58px; height: 58px; margin: 16px 0 20px; border-radius: 18px; background: var(--grad); color: #fff; box-shadow: var(--sh-brand); }
.unlock-mark svg { width: 27px; height: 27px; }
.public-unlock-summary .eyebrow { display: none; }
.public-unlock-summary h1 { font-size: 22px; font-weight: 700; line-height: 1.4; }
.public-unlock-summary p { margin-top: 12px; font-size: 13.5px; line-height: 1.75; color: var(--text-2); max-width: 52ch; }
.unlock-trust { display: flex; flex-direction: column; gap: 9px; margin-top: 22px; padding-top: 18px; border-top: 1px solid var(--line-2); }
.unlock-trust span { display: flex; align-items: center; gap: 9px; font-size: 13px; color: var(--text-3); }
.unlock-trust svg { width: 16px; height: 16px; color: var(--success); flex: none; }
.public-unlock-panel { display: flex; flex-direction: column; gap: 15px; padding: 26px 24px; border-radius: var(--r-xl); background: var(--surface); border: 1px solid var(--line); box-shadow: var(--sh-2); }
.public-unlock-panel h2 { font-size: 17px; font-weight: 700; }
.public-unlock-panel p { margin-top: 5px; font-size: 13px; color: var(--text-3); }

/* --------------------------------------------------------------------------
   VIP 会员视觉
   -------------------------------------------------------------------------- */
.vip-badge {
  display: inline-block;
  margin-left: 6px;
  padding: 1px 6px;
  border-radius: 4px;
  background: linear-gradient(135deg, #f59e0b, #ef4444);
  color: #fff;
  font-size: 10px;
  font-weight: 700;
  letter-spacing: .04em;
  vertical-align: 1px;
}

/* 分享页广告位：非会员分享可见，会员免广告 */
.share-ad {
  display: flex; align-items: center; gap: 10px;
  padding: 12px 16px; margin-bottom: 14px;
  border-radius: var(--r);
  background: linear-gradient(135deg, #fff7ed, #fef2f2);
  border: 1px solid #fed7aa;
  color: #9a3412;
  font-size: 13px; line-height: 1.6;
}
.share-ad svg { width: 17px; height: 17px; flex: none; color: #ea580c; }

/* 分享页内搜索（会员特权） */
.share-search {
  display: flex; align-items: center; gap: 8px;
  height: 40px; padding: 0 5px 0 13px; margin-bottom: 14px;
  border-radius: 99px;
  background: var(--surface); border: 1px solid var(--line-3);
  transition: border-color .16s var(--ease), box-shadow .16s var(--ease);
}
.share-search:focus-within { border-color: var(--brand-400); box-shadow: 0 0 0 4px rgba(99, 102, 241, .12); }
.share-search svg { width: 16px; height: 16px; color: var(--text-3); flex: none; }
.share-search input { border: 0; background: none; height: 36px; min-height: 0; padding: 0; font-size: 13.5px; box-shadow: none !important; }
.share-search input:hover { border: 0; }
.share-search input:focus { outline: none; border: 0; box-shadow: none; }
.share-search .icon-btn { width: 28px; height: 28px; }

/* 分享页模板变体（会员可选） */
.public-main.tpl-compact .public-folder-hero { padding: 18px 20px; }
.public-main.tpl-compact .folder-announcement { margin-bottom: 10px; padding: 12px 14px; }
.public-main.tpl-compact .delivery-row { padding: 8px 16px; }
.public-main.tpl-glass .public-folder-hero {
  background: linear-gradient(135deg, rgba(99, 102, 241, .94), rgba(6, 182, 212, .86));
  backdrop-filter: blur(10px);
}
.public-main.tpl-glass .delivery-list,
.public-main.tpl-glass .download-card {
  background: rgba(255, 255, 255, .8);
  backdrop-filter: blur(14px);
  border-color: rgba(255, 255, 255, .9);
}

/* 会员权益卡片 */
.vip-card {
  position: relative; overflow: hidden;
  padding: 26px 28px; margin-bottom: 18px;
  border-radius: var(--r-xl);
  background: var(--grad); color: #fff;
  box-shadow: var(--sh-brand);
}
.vip-card::after { content: ""; position: absolute; width: 240px; height: 240px; right: -60px; top: -100px; border-radius: 50%; background: rgba(255, 255, 255, .14); }
.vip-card > * { position: relative; z-index: 1; }
.vip-card h2 { font-size: 22px; font-weight: 700; }
.vip-card p { margin-top: 7px; font-size: 13.5px; color: rgba(255, 255, 255, .88); }
.vip-state { display: inline-flex; align-items: center; gap: 7px; margin-top: 14px; padding: 6px 13px; border-radius: 99px; background: rgba(255, 255, 255, .2); border: 1px solid rgba(255, 255, 255, .32); font-size: 13px; font-weight: 500; }

/* VIP 特权清单 */
.vip-perks { display: grid; grid-template-columns: repeat(auto-fit, minmax(210px, 1fr)); gap: 12px; margin-bottom: 18px; }
.vip-perk {
  display: flex; align-items: flex-start; gap: 11px;
  padding: 15px 17px; border-radius: var(--r-lg);
  background: var(--surface); border: 1px solid var(--line); box-shadow: var(--sh-1);
}
.vip-perk.on { border-color: var(--brand-200); background: linear-gradient(175deg, var(--brand-50), #fff 60%); }
.vip-perk-icon {
  display: inline-flex; align-items: center; justify-content: center;
  width: 36px; height: 36px; border-radius: 11px; flex: none;
  background: var(--surface-3); color: var(--text-3);
}
.vip-perk.on .vip-perk-icon { background: var(--brand-100); color: var(--brand-600); }
.vip-perk-icon svg { width: 18px; height: 18px; }
.vip-perk div { min-width: 0; }
.vip-perk strong { display: block; font-size: 13.5px; font-weight: 600; color: var(--text); }
.vip-perk small { display: block; margin-top: 2px; font-size: 12px; color: var(--text-3); line-height: 1.55; }

/* 分享弹窗内的会员选项 */
.vip-share-options {
  margin-top: 18px; padding: 15px 16px;
  border-radius: var(--r);
  background: linear-gradient(175deg, var(--brand-50), #fff 70%);
  border: 1px solid var(--brand-100);
}
.vip-share-head {
  display: flex; align-items: center; gap: 7px;
  margin-bottom: 13px; padding-bottom: 10px;
  border-bottom: 1px solid var(--brand-100);
  font-size: 13px; font-weight: 600; color: var(--brand-600);
}
.vip-share-head svg { width: 16px; height: 16px; }
.vip-share-options label + label { margin-top: 13px; }

.vip-hint {
  display: flex; align-items: flex-start; gap: 9px;
  margin-top: 16px; padding: 11px 14px;
  border-radius: var(--r-sm);
  background: var(--surface-3);
  font-size: 12.5px; color: var(--text-3); line-height: 1.6;
}
.vip-hint svg { width: 16px; height: 16px; flex: none; margin-top: 1px; color: var(--warning); }

/* 勾选项（分享弹窗等复用） */
.check { display: flex; align-items: flex-start; gap: 9px; cursor: pointer; }
.check input { width: 16px; height: 16px; margin: 2px 0 0; accent-color: var(--brand-500); flex: none; }
.check > span { margin: 0; font-size: 13px; font-weight: 400; color: var(--text-2); line-height: 1.55; }
.vip-share-options .check > span { font-weight: 500; }

/* --------------------------------------------------------------------------
   修饰类
   -------------------------------------------------------------------------- */
.register-page { background: radial-gradient(55% 48% at 14% 12%, rgba(139, 92, 246, .28), transparent 62%), linear-gradient(165deg, #eef2ff, #f6f7fb 55%); }
.public-locked { display: flex; flex-direction: column; justify-content: center; }
.public-file { display: block; }
.public-browser { box-shadow: var(--sh-1); }
.public-browser .file-table tbody tr { cursor: default; }
.file-table .size-col { width: 115px; }
.file-table .date-col { width: 170px; }
.file-table .action-col { width: 100px; }
.share-table-wrap { overflow: hidden; }
.share-table td:first-child { min-width: 200px; }

/* --------------------------------------------------------------------------
   响应式
   -------------------------------------------------------------------------- */
@media (min-width: 1440px) {
  .content { padding: 30px 28px 64px; }
  .public-main { padding: 30px 28px 64px; }
}

@media (max-width: 1100px) {
  .public-unlock-layout, .public-file-layout { grid-template-columns: minmax(0, 1fr); }
  .public-download-panel { position: static; }
}

@media (max-width: 980px) {
  .topbar-inner { gap: 12px; padding: 0 16px; }
  .topnav {
    position: fixed; top: 64px; left: 0; right: 0; z-index: 50;
    flex-direction: column; align-items: stretch; gap: 2px;
    padding: 12px;
    background: var(--surface);
    border-bottom: 1px solid var(--line);
    box-shadow: var(--sh-3);
    transform: translateY(-130%);
    transition: transform .24s var(--ease);
  }
  .shell.nav-open .topnav { transform: none; }
  .shell.nav-open .mobile-shade { display: block; }
  .topnav-link { height: 44px; border-radius: var(--r-sm); padding: 0 14px; }
  .mobile-menu { display: inline-flex; }
  .storage-chip { display: none; }
  .account-copy { display: none; }
  .content { padding: 20px 16px 48px; }
  .public-header { padding: 0 16px; }
  .public-main { padding: 20px 16px 48px; }
  .public-footer { padding: 16px; }
}

@media (max-width: 760px) {
  .modal-backdrop { padding: 12px; align-items: flex-end; }
  .modal { max-width: none; max-height: calc(100vh - 24px); }
  .public-folder-facts, .public-file-specs { gap: 20px; }
  .delivery-list-head { display: none; }
  .delivery-row { grid-template-columns: 1fr 32px; gap: 8px; padding: 11px 14px; }
  .delivery-meta { display: none; }
  .public-title { flex-direction: row-reverse; align-items: flex-start; }

  .file-table thead, .data-table thead { display: none; }
  .file-table colgroup { display: none; }
  .file-table, .data-table { min-width: 0; }
  .file-table tbody tr, .data-table tbody tr {
    display: flex; flex-direction: column; gap: 6px;
    padding: 14px 16px; margin-bottom: 10px;
    background: var(--surface); border: 1px solid var(--line) !important; border-radius: var(--r);
    box-shadow: var(--sh-1);
  }
  .file-table tbody tr:last-child, .data-table tbody tr:last-child { margin-bottom: 0; }
  .file-table tbody tr:hover, .data-table tbody tr:hover { background: var(--surface); }
  .file-table td, .data-table td { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 0; }
  .file-table td::before, .data-table td::before { content: attr(data-label); font-size: 12px; color: var(--text-3); flex: none; }
  .file-table td.name-cell, .data-table td.name-cell { width: 100%; }
  .file-table td.name-cell::before, .file-table td:first-child::before { content: none; }
  .file-table td.action-cell, .data-table td.action-cell { justify-content: flex-end; padding-top: 2px; width: auto; }
  .file-table td.action-cell::before, .data-table td.action-cell::before { content: none; }
  .table-wrap, .file-browser { border: 0; background: none; box-shadow: none; overflow: visible; }
}

@media (max-width: 480px) {
  .login-page { padding: 28px 14px; }
  .login-box { padding: 26px 20px 24px; }
  .login-brand-panel { margin-bottom: 16px; }
  .login-brand-panel .brand-copy strong { font-size: 21px; }
  .registration-state section { padding: 32px 22px; }
  .heading-copy h1 { font-size: 20px; }
  .heading-row { align-items: flex-start; }
  .heading-actions { width: 100%; }
  .heading-actions .btn { flex: 1; }
  .search-box { min-width: 0; width: 100%; }
  .browser-toolbar { flex-direction: column; align-items: stretch; gap: 10px; }
  .type-tabs { display: flex; width: 100%; }
  .type-tabs button { flex: 1; padding: 8px 8px; }
  .public-owner-name { max-width: 44vw; }
  .public-file-summary, .public-unlock-summary, .public-unlock-panel { padding: 20px 16px; }
  .public-folder-facts, .public-file-specs { flex-direction: column; gap: 12px; }
  .brand-copy small { display: none; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .001ms !important; animation-iteration-count: 1 !important; transition-duration: .001ms !important; }
}

/* ==========================================================================
   左侧导航（可收缩，默认展开）
   ========================================================================== */
.shell { display: grid; grid-template-columns: 232px minmax(0, 1fr); min-height: 100vh; background: var(--bg); }

.sidenav {
  display: flex; flex-direction: column; gap: 14px;
  padding: 16px 12px;
  background: var(--surface);
  border-right: 1px solid var(--line);
  position: sticky; top: 0; height: 100vh; overflow-y: auto;
}
.sidenav-head { display: flex; align-items: center; gap: 8px; padding: 2px 2px 12px; }
.sidenav-brand { flex: 1; min-width: 0; overflow: hidden; }
.sidenav-toggle { flex: none; }
.sidenav-nav { display: flex; flex-direction: column; gap: 3px; flex: 1; }
.sidenav-link {
  display: flex; align-items: center; gap: 11px;
  height: 40px; padding: 0 11px; border-radius: var(--r-sm);
  color: var(--text-2); font-size: 14px; font-weight: 500;
  white-space: nowrap; overflow: hidden;
  transition: background .16s var(--ease), color .16s var(--ease);
}
.sidenav-link:hover { background: var(--surface-3); color: var(--text); }
.sidenav-link.active { background: var(--brand-100); color: var(--brand-600); }
.sidenav-foot { margin-top: auto; padding-top: 10px; border-top: 1px solid var(--line-2); }

/* 收缩态：仅保留图标（桌面端生效；移动端是抽屉，不参与收缩） */
@media (min-width: 901px) {
  .shell.nav-collapsed { grid-template-columns: 74px minmax(0, 1fr); }
  .shell.nav-collapsed .sidenav { padding: 16px 10px; }
  .shell.nav-collapsed .sidenav-label,
  .shell.nav-collapsed .brand-copy,
  .shell.nav-collapsed .account-copy { display: none; }
  .shell.nav-collapsed .sidenav-head { flex-direction: column; gap: 8px; }
  .shell.nav-collapsed .sidenav-link { justify-content: center; padding: 0; }
  .shell.nav-collapsed .account { flex-direction: column; gap: 6px; padding: 6px 0; }
  .shell.nav-collapsed .sidenav-toggle svg { transform: rotate(180deg); }
}

/* 顶栏 */
.topbar {
  display: flex; align-items: center; justify-content: space-between; gap: 16px;
  height: 60px; padding: 0 22px;
  background: var(--surface); border-bottom: 1px solid var(--line);
  position: sticky; top: 0; z-index: 20;
}
.topbar-left, .topbar-right { display: flex; align-items: center; gap: 9px; }

.membership-chip {
  display: inline-flex; align-items: center; gap: 10px;
  height: 44px; padding: 0 14px 0 8px; border-radius: var(--r);
  background: var(--surface-3); border: 1px solid var(--line);
  transition: border-color .16s var(--ease), box-shadow .16s var(--ease);
}
.membership-chip:hover { border-color: var(--brand-300); box-shadow: var(--sh-2); }
.membership-chip-copy { display: flex; flex-direction: column; line-height: 1.25; text-align: left; }
.membership-chip-copy strong { font-size: 12.5px; font-weight: 600; color: var(--text); }
.membership-chip-copy small { font-size: 11px; color: var(--text-3); font-variant-numeric: tabular-nums; }

.workspace { display: flex; flex-direction: column; flex: 1; min-width: 0; }
.content { width: 100%; max-width: 1240px; margin: 0 auto; padding: 24px 24px 56px; flex: 1; }

/* 下载页内置图片广告位：高度 60，宽度与下载按钮一致 */
.download-ad {
  width: 100%; height: 60px;
  border-radius: var(--r);
  background: var(--surface-3);
  border: 1px solid var(--line-2);
  overflow: hidden;
}
.download-ad img { display: block; width: 100%; height: 60px; object-fit: cover; }

/* 会员信息卡（会员页顶部单独卡片） */
.member-card {
  display: grid; grid-template-columns: repeat(4, minmax(0, 1fr));
  margin-bottom: 18px;
  border-radius: var(--r-lg);
  background: var(--surface); border: 1px solid var(--line); box-shadow: var(--sh-1);
  overflow: hidden;
}
.member-card > div { padding: 18px 22px; border-left: 1px solid var(--line-2); }
.member-card > div:first-child { border-left: 0; }
.member-card dt { font-size: 12.5px; color: var(--text-3); }
.member-card dd { margin-top: 6px; font-size: 17px; font-weight: 600; color: var(--text); }
.member-card dd.accent { color: var(--brand-600); }

/* VIP 功能开关（账户设置）——行轨高度、盒子高度、内部行高全部钉死 */
.vip-switches {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  grid-auto-rows: 92px;     /* 行轨钉死，所有格子起点绝对一致 */
  align-items: stretch;     /* 禁止基线对齐造成的垂直偏移 */
  align-content: start;
  gap: 12px; margin-top: 4px;
}
@media (max-width: 1180px) { .vip-switches { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 720px) { .vip-switches { grid-template-columns: minmax(0, 1fr); } }
.vip-switch {
  display: flex; align-items: flex-start; gap: 10px;
  height: 92px; min-height: 0; max-height: 92px;
  align-self: stretch; margin: 0;
  box-sizing: border-box;
  padding: 14px 16px;
  overflow: hidden;
  border-radius: var(--r);
  background: var(--surface-2); border: 1px solid var(--line);
  cursor: pointer;
  transition: border-color .16s var(--ease), background .16s var(--ease);
}
.vip-switches .vip-switch { height: 92px; min-height: 0; max-height: 92px; }
.vip-switch:hover { border-color: var(--brand-300); }
.vip-switch:has(input:checked) { border-color: var(--brand-300); background: linear-gradient(175deg, var(--brand-50), #fff 70%); }
.vip-switch input { width: 16px; height: 16px; margin: 2px 0 0; accent-color: var(--brand-500); flex: none; }
.vip-switch > span { display: flex; flex-direction: column; gap: 3px; min-width: 0; flex: 1; }
.vip-switch strong {
  height: 20px; line-height: 20px;
  font-size: 13.5px; font-weight: 600; color: var(--text);
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.vip-switch small {
  height: 36px; line-height: 18px;
  font-size: 12px; color: var(--text-3);
  display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden;
}

@media (max-width: 900px) {
  .shell, .shell.nav-collapsed { grid-template-columns: minmax(0, 1fr); }
  .sidenav {
    position: fixed; top: 0; left: 0; bottom: 0; width: 232px; height: 100vh; z-index: 50;
    transform: translateX(-100%); transition: transform .22s var(--ease);
    box-shadow: var(--sh-3);
  }
  .shell.nav-open .sidenav { transform: none; }
  .shell.nav-open .mobile-shade { display: block; }
  .mobile-menu { display: inline-flex; }
  .content { padding: 18px 14px 44px; }
}

/* ==========================================================================
   会员视觉：顶栏状态 / 特效名字 / 登录欢迎
   ========================================================================== */
.vip-status {
  display: inline-flex; align-items: center; gap: 9px;
  height: 44px; padding: 0 15px 0 12px; border-radius: 99px;
  background: var(--surface-3); border: 1px solid var(--line);
  transition: border-color .16s var(--ease), box-shadow .16s var(--ease);
}
.vip-status:hover { border-color: var(--brand-300); box-shadow: var(--sh-2); }
.vip-crown {
  display: inline-flex; align-items: center; justify-content: center;
  width: 26px; height: 26px; border-radius: 50%;
  background: var(--surface); color: var(--text-3); flex: none;
}
.vip-crown svg { width: 15px; height: 15px; }
.vip-status-copy { display: flex; flex-direction: column; line-height: 1.25; text-align: left; }
.vip-status-copy strong { font-size: 12.5px; font-weight: 600; color: var(--text); }
.vip-status-copy small { font-size: 11px; color: var(--text-3); font-variant-numeric: tabular-nums; }
.vip-status.is-vip {
  border-color: transparent;
  background: linear-gradient(135deg, #f59e0b, #ef4444);
  box-shadow: 0 4px 14px -4px rgba(239, 68, 68, .5);
}
.vip-status.is-vip .vip-crown { background: rgba(255, 255, 255, .22); color: #fff; }
.vip-status.is-vip .vip-status-copy strong { color: #fff; }
.vip-status.is-vip .vip-status-copy small { color: rgba(255, 255, 255, .85); }

/* 会员分享者名字：渐变特效文字 */
.vip-owner {
  font-weight: 700;
  background: linear-gradient(92deg, #f59e0b, #ef4444 45%, #8b5cf6);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  text-shadow: 0 0 18px rgba(245, 158, 11, .25);
}

/* 会员登录后的屏幕中央欢迎特效 */
.vip-welcome {
  position: fixed; inset: 0; z-index: 300;
  display: flex; align-items: center; justify-content: center;
  background: rgba(15, 18, 30, .55);
  backdrop-filter: blur(6px);
  animation: fade-in .22s var(--ease);
}
.vip-welcome-card {
  position: relative; overflow: hidden;
  min-width: 330px; max-width: 88vw;
  padding: 34px 40px 30px; text-align: center;
  border-radius: var(--r-xl);
  background: linear-gradient(160deg, #1b1f33, #0f1322);
  border: 1px solid rgba(245, 158, 11, .35);
  box-shadow: 0 24px 70px -20px rgba(245, 158, 11, .45), 0 0 60px -20px rgba(139, 92, 246, .5);
  animation: vip-pop .45s cubic-bezier(.2, 1.2, .3, 1);
}
.vip-welcome-card::before {
  content: ""; position: absolute; left: -20%; right: -20%; top: -40%; height: 180px;
  background: radial-gradient(60% 100% at 50% 0%, rgba(245, 158, 11, .35), transparent 70%);
  pointer-events: none;
}
@keyframes vip-pop { from { opacity: 0; transform: scale(.86) translateY(16px); } }
.vip-welcome-crown {
  display: inline-flex; align-items: center; justify-content: center;
  width: 62px; height: 62px; margin-bottom: 16px; border-radius: 50%;
  background: linear-gradient(135deg, #f59e0b, #ef4444);
  color: #fff; box-shadow: 0 8px 26px -6px rgba(245, 158, 11, .8);
  animation: vip-float 2.2s ease-in-out infinite;
}
.vip-welcome-crown svg { width: 31px; height: 31px; }
@keyframes vip-float { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-6px); } }
.vip-welcome-card h2 { font-size: 21px; font-weight: 700; color: #fff; }
.vip-welcome-card h2 em,
.vip-welcome-name {
  font-style: normal;
  background: linear-gradient(92deg, #fbbf24, #f87171 50%, #a78bfa);
  -webkit-background-clip: text; background-clip: text; color: transparent;
}
.vip-welcome-name { margin-top: 12px; font-size: 27px; font-weight: 800; letter-spacing: .01em; }
.vip-welcome-note { margin-top: 8px; font-size: 14px; color: rgba(255, 255, 255, .78); }
.vip-welcome-expire {
  display: inline-block; margin-top: 18px; padding: 6px 14px; border-radius: 99px;
  background: rgba(245, 158, 11, .16); border: 1px solid rgba(245, 158, 11, .35);
  font-size: 12.5px; color: #fbbf24; font-variant-numeric: tabular-nums;
}

/* --------------------------------------------------------------------------
   分享页模板选择器（方框卡片）
   扩展新模板：后端 SHARE_TEMPLATES 加一行 + 这里补 .tpl-preview-<id> 和
   .public-main.tpl-<id> 两句样式即可，其余全自动
   -------------------------------------------------------------------------- */
/* 分享页模板选择器（方框卡片） */
.tpl-picker {
  display: grid; grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px; margin-top: 4px;
}
@media (max-width: 900px) { .tpl-picker { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 560px) { .tpl-picker { grid-template-columns: minmax(0, 1fr); } }
.tpl-option {
  display: flex; flex-direction: column; align-items: flex-start; gap: 8px;
  padding: 14px; border-radius: var(--r);
  background: var(--surface); border: 1.5px solid var(--line);
  text-align: left; cursor: pointer;
  transition: border-color .16s var(--ease), box-shadow .16s var(--ease), transform .16s var(--ease);
}
.tpl-option:hover { border-color: var(--brand-300); transform: translateY(-2px); box-shadow: var(--sh-2); }
.tpl-option.selected { border-color: var(--brand-500); box-shadow: 0 0 0 3px rgba(99, 102, 241, .14); }
.tpl-option.selected strong { color: var(--brand-600); }
.tpl-option strong { font-size: 13.5px; font-weight: 600; color: var(--text); }
.tpl-option small { font-size: 12px; color: var(--text-3); line-height: 1.5; }

/* 模板缩略示意（纯 CSS 画的小样） */
.tpl-preview {
  position: relative; display: block; overflow: hidden;
  width: 100%; height: 56px; border-radius: var(--r-sm);
  background: var(--surface-3); border: 1px solid var(--line-2);
}
.tpl-preview::before {
  content: ""; position: absolute; left: 10px; right: 10px; top: 8px;
  height: 12px; border-radius: 4px; background: var(--line-3);
}
.tpl-preview::after {
  content: ""; position: absolute; left: 10px; right: 40px; top: 26px;
  height: 8px; border-radius: 4px; background: var(--line-2);
}
.tpl-preview-default { background: #fff; }
.tpl-preview-compact::before { height: 8px; top: 6px; }
.tpl-preview-compact::after { top: 19px; left: 10px; right: 20px; }
.tpl-preview-glass { background: linear-gradient(135deg, #6366f1, #06b6d4); }
.tpl-preview-glass::before { background: rgba(255, 255, 255, .62); }
.tpl-preview-glass::after { background: rgba(255, 255, 255, .34); }

/* --------------------------------------------------------------------------
   账户区 / 头像 布局修正
   -------------------------------------------------------------------------- */
/* 侧栏底部账户：整块可点击进账户设置 */
.account { display: flex; align-items: center; gap: 4px; padding: 4px 6px; border-radius: var(--r); transition: background .16s var(--ease); }
.account:hover { background: var(--surface-3); }
.account-link {
  display: flex; align-items: center; gap: 10px;
  flex: 1; min-width: 0;
  padding: 2px; border: 0; background: none;
  border-radius: var(--r-sm);
  text-align: left; cursor: pointer;
}
.account-link .account-copy { min-width: 0; }
.account-link .account-name,
.account-link .account-role { display: block; }

/* 头像图（首字母圆标之外的上传头像） */
.avatar-img { object-fit: cover; display: block; }
.avatar.avatar-lg { width: 72px; height: 72px; border-radius: 50%; font-size: 28px; }

/* 账户设置 · 基本信息里的头像编辑区 */
.avatar-editor {
  display: flex; align-items: center; gap: 20px;
  padding-bottom: 22px; margin-bottom: 20px;
  border-bottom: 1px solid var(--line-2);
}
.avatar-editor .avatar { flex: none; }
.avatar-editor-actions { display: flex; flex-direction: column; gap: 9px; min-width: 0; }
.avatar-buttons { display: flex; align-items: center; gap: 9px; flex-wrap: wrap; }
.avatar-upload { cursor: pointer; }
.avatar-editor-actions .subtext { margin: 0; max-width: 56ch; }

/* 分享页左上角头像 logo */
.public-avatar {
  width: 40px; height: 40px; border-radius: 12px;
  object-fit: cover; display: block;
  box-shadow: var(--sh-1);
}
.public-brand:has(.public-avatar) { line-height: 0; }

@media (max-width: 480px) {
  .avatar-editor { flex-direction: column; align-items: flex-start; gap: 14px; }
  .avatar.avatar-lg { width: 60px; height: 60px; border-radius: 50%; font-size: 23px; }
  .public-avatar { width: 34px; height: 34px; border-radius: 10px; }
}

/* 会员信息卡：固定 4 列 → 平板 2×2 → 手机单列，分隔线跟着换边 */
@media (max-width: 900px) {
  .member-card { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .member-card > div:nth-child(odd) { border-left: 0; }
  .member-card > div:nth-child(n + 3) { border-top: 1px solid var(--line-2); }
}
@media (max-width: 520px) {
  .member-card { grid-template-columns: minmax(0, 1fr); }
  .member-card > div { border-left: 0; border-top: 1px solid var(--line-2); }
  .member-card > div:first-child { border-top: 0; }
}

/* ===== 在线支付（易支付）===== */
.pay-channels { display: flex; flex-wrap: wrap; gap: 10px; margin: 4px 0 14px; }
.pay-channel {
  display: inline-flex; align-items: center; gap: 6px; padding: 9px 18px;
  border: 1px solid var(--line-2); border-radius: 10px; background: var(--surface, #fff);
  color: var(--text-2, #475569); font: inherit; font-size: 14px; cursor: pointer;
  transition: border-color .15s, background .15s, color .15s, box-shadow .15s;
}
.pay-channel:hover { border-color: var(--brand, #2563eb); color: var(--brand, #2563eb); }
.pay-channel.selected {
  border-color: var(--brand, #2563eb);
  background: color-mix(in srgb, var(--brand, #2563eb) 10%, transparent);
  color: var(--brand, #2563eb); font-weight: 600;
  box-shadow: 0 0 0 3px color-mix(in srgb, var(--brand, #2563eb) 14%, transparent);
}
.btn.small { padding: 5px 12px; font-size: 13px; border-radius: 8px; }
.data-table td .btn.small { white-space: nowrap; }
@media (max-width: 520px) {
  .pay-channel { flex: 1 1 calc(50% - 5px); justify-content: center; padding: 10px 12px; }
}

/* ===== 邮箱验证码 ===== */
.code-row { display: flex; align-items: stretch; gap: 8px; }
.code-row > input { flex: 1 1 auto; min-width: 0; letter-spacing: .28em; font-variant-numeric: tabular-nums; }
.code-row > .code-btn, .code-btn {
  flex: 0 0 auto; white-space: nowrap; padding: 0 14px; min-height: 0;
  font-size: 13px; border-radius: 10px; align-self: stretch;
}
.code-btn:disabled { opacity: .6; cursor: default; }
.email-state { display: inline-flex; align-items: center; gap: 6px; font-size: 13px; }
.email-state .pill { font-size: 12px; }
@media (max-width: 520px) {
  .code-row { flex-wrap: wrap; }
  .code-row > .code-btn { width: 100%; padding: 9px 12px; }
}

/* ===== 流量中心：流量包购买卡片 ===== */
.package-card {
  margin: 16px 0 18px; border: 1px solid var(--line-2); border-radius: 16px;
  background: var(--surface, #fff); overflow: hidden;
}
.package-card > header {
  display: flex; align-items: center; justify-content: space-between; gap: 12px;
  padding: 16px 18px; border-bottom: 1px solid var(--line-2);
}
.package-card > header h2 { margin: 0 0 3px; font-size: 16px; }
.package-card > header p { margin: 0; font-size: 13px; color: var(--text-3, #64748b); }
.package-grid {
  display: grid; gap: 14px; padding: 18px;
  grid-template-columns: repeat(auto-fit, minmax(190px, 1fr));
}
.package-item {
  display: flex; flex-direction: column; gap: 10px; padding: 16px;
  border: 1px solid var(--line-2); border-radius: 13px;
  transition: border-color .18s, box-shadow .18s, transform .18s;
}
.package-item:hover { border-color: var(--brand, #2563eb); box-shadow: 0 6px 20px -12px rgba(37, 99, 235, .5); transform: translateY(-2px); }
.package-head { display: flex; align-items: baseline; justify-content: space-between; gap: 8px; }
.package-head strong { font-size: 14px; }
.package-size { font-size: 12px; color: var(--text-3, #64748b); font-variant-numeric: tabular-nums; }
.package-price { display: flex; align-items: baseline; gap: 3px; flex-wrap: wrap; }
.package-price b { font-size: 26px; line-height: 1.1; color: var(--brand, #2563eb); font-variant-numeric: tabular-nums; }
.package-price small { font-size: 13px; color: var(--text-3, #64748b); }
.package-unit {
  margin-left: auto; font-size: 12px; color: var(--text-3, #64748b);
  background: rgba(127, 127, 127, .1); padding: 2px 7px; border-radius: 999px;
}
.share-stats { margin-bottom: 16px; }
@media (max-width: 520px) {
  .package-grid { grid-template-columns: minmax(0, 1fr); padding: 14px; }
  .package-card > header { flex-direction: column; align-items: flex-start; }
}

/* 回收站：文件行里的剩余天数标签 */
.file-table .trash-left { margin-left: 8px; }

/* ===== 会员中心：方案状态条 ===== */
.plan-status {
  display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 18px;
  padding: 18px 20px; margin-bottom: 18px;
  border: 1px solid var(--line-2); border-radius: 16px; background: var(--surface, #fff);
}
.plan-status-main { display: flex; align-items: center; gap: 14px; min-width: 0; }
.plan-status-icon {
  display: grid; place-items: center; flex: none;
  width: 46px; height: 46px; border-radius: 14px;
  background: var(--surface-3, rgba(127, 127, 127, .12)); color: var(--text-3, #64748b);
}
.plan-status-icon.vip {
  background: linear-gradient(135deg, #f7b733, #fc4a1a); color: #fff;
  box-shadow: 0 8px 20px -10px rgba(252, 74, 26, .75);
}
.plan-status-main strong { display: block; font-size: 17px; }
.plan-status-main small { display: block; margin-top: 3px; font-size: 12.5px; color: var(--text-3, #64748b); line-height: 1.6; }
.plan-status-meta { display: flex; flex-wrap: wrap; gap: 22px; }
.plan-status-meta > span { display: flex; flex-direction: column; gap: 2px; }
.plan-status-meta small { font-size: 12px; color: var(--text-3, #64748b); }
.plan-status-meta strong { font-size: 15px; font-variant-numeric: tabular-nums; }

/* ===== 会员中心：权益对比表（核心，突出 SVIP 那一列）===== */
.plan-compare {
  margin-bottom: 18px; overflow: hidden;
  border: 1px solid var(--line-2); border-radius: 16px; background: var(--surface, #fff);
}
.plan-compare table { width: 100%; border-collapse: collapse; }
.plan-compare th, .plan-compare td {
  padding: 13px 18px; text-align: left; font-size: 13.5px;
  border-bottom: 1px solid var(--line-2); vertical-align: middle;
}
.plan-compare thead th { background: var(--surface-2, #f7f8fa); font-weight: 600; }
.plan-compare thead th span { display: block; }
.plan-compare thead th small { display: block; margin-top: 3px; font-size: 12px; font-weight: 400; color: var(--text-3, #64748b); }
.plan-compare tbody tr:last-child td { border-bottom: 0; }
.plan-compare tbody tr:hover td { background: color-mix(in srgb, var(--brand, #2563eb) 4%, transparent); }
.cmp-feature { width: 44%; color: var(--text-2, #475569); }
.cmp-feature svg { width: 16px; height: 16px; margin-right: 9px; vertical-align: -3px; color: var(--text-3, #64748b); }
.cmp-free { color: var(--text-3, #64748b); }
.cmp-vip { color: var(--brand-700, #1d4ed8); font-weight: 600; background: color-mix(in srgb, var(--brand, #2563eb) 5%, transparent); }
.plan-compare thead .cmp-vip {
  color: var(--brand-700, #1d4ed8);
  background: color-mix(in srgb, var(--brand, #2563eb) 11%, transparent);
  box-shadow: inset 0 3px 0 var(--brand, #2563eb);
}
.cmp-check { display: inline-flex; margin-right: 8px; vertical-align: -3px; color: #16a34a; }
.cmp-check svg { width: 15px; height: 15px; }
/* 后台把某项特权关掉时，这一行整体弱化，避免误导 */
.cmp-row-off .cmp-vip { color: var(--text-3, #64748b); font-weight: 400; }
.cmp-row-off .cmp-check { color: var(--text-4, #94a3b8); }
.plan-now {
  display: inline-block; margin-top: 7px; padding: 2px 10px; border-radius: 999px;
  font-size: 11px; font-style: normal; font-weight: 600;
  background: var(--brand, #2563eb); color: #fff;
}
.cmp-free .plan-now { background: var(--text-3, #94a3b8); }

/* ===== 会员中心：购买卡片 ===== */
.plan-buy { padding: 20px; border: 1px solid var(--line-2); border-radius: 16px; background: var(--surface, #fff); }
.plan-buy > header {
  display: flex; align-items: flex-start; justify-content: space-between; gap: 16px; flex-wrap: wrap;
  margin-bottom: 16px; padding-bottom: 16px; border-bottom: 1px solid var(--line-2);
}
.plan-buy h2 { margin-bottom: 4px; font-size: 16px; }
.plan-buy > header p { font-size: 13px; color: var(--text-3, #64748b); }
.plan-buy-price { text-align: right; }
.plan-buy-price b { font-size: 30px; line-height: 1.1; color: var(--brand, #2563eb); font-variant-numeric: tabular-nums; }
.plan-buy-price small { display: block; margin-top: 2px; font-size: 12px; color: var(--text-3, #64748b); }
.plan-buy-facts { display: grid; grid-template-columns: repeat(auto-fit, minmax(160px, 1fr)); gap: 12px; margin-bottom: 18px; }
.plan-buy-facts > span {
  display: flex; flex-direction: column; gap: 3px;
  padding: 12px 14px; border-radius: 11px; background: var(--surface-2, #f7f8fa);
}
.plan-buy-facts small { font-size: 12px; color: var(--text-3, #64748b); }
.plan-buy-facts strong { font-size: 14px; }
@media (max-width: 640px) {
  .plan-compare th, .plan-compare td { padding: 11px 12px; font-size: 13px; }
  .cmp-feature { width: 40%; }
  .cmp-feature svg { display: none; }
  .plan-status-meta { gap: 16px; }
  .plan-buy-price { text-align: left; }
}
