/* Apps download -- flat editorial Chinese product UI (no gradients) */
:root {
  --apps-bg: #111827;
  --apps-fg: #f4f4f5;
  --apps-muted: rgba(255,255,255,.55);
  --apps-card: #1f2937;
  --apps-card-border: rgba(255,255,255,.1);
  --apps-card-hover: #273549;
  --apps-pill: rgba(255,255,255,.06);
  --apps-pill-on: #fff;
  --apps-pill-on-fg: #111;
  --apps-accent: #ff8a3d;
  --apps-accent-strong: #ff6a00;
  --apps-accent-rgb: 255, 138, 61;
  --apps-modal: #1f2937;
  --apps-input: #111827;
  --apps-glow: rgba(var(--apps-accent-rgb), .2);
  --apps-featured-bg: rgba(var(--apps-accent-rgb), .08);
  --apps-avatar-a: var(--apps-accent);
  --apps-avatar-b: #ff3d81;
  --apps-cta-shadow: transparent;
  --apps-header-surface: #1f2937;
  --apps-stripe: var(--apps-accent);
  --apps-radius: 8px;
  --apps-radius-panel: 12px;
}
html[data-theme="light"] {
  --apps-bg: #ffffff;
  --apps-fg: #111827;
  --apps-muted: #6b7280;
  --apps-card: #fff;
  --apps-card-border: #e5e7eb;
  --apps-card-hover: #fff;
  --apps-pill: #eef2f7;
  --apps-pill-on: #111827;
  --apps-pill-on-fg: #fff;
  --apps-accent: #f97316;
  --apps-accent-strong: #ea580c;
  --apps-accent-rgb: 249, 115, 22;
  --apps-modal: #fff;
  --apps-input: #fff;
  --apps-glow: rgba(var(--apps-accent-rgb), .16);
  --apps-featured-bg: #fff;
  --apps-avatar-a: var(--apps-accent);
  --apps-avatar-b: #db2777;
  --apps-cta-shadow: transparent;
  --apps-header-surface: #fff;
  --apps-stripe: var(--apps-accent);
}
* { box-sizing: border-box; }
html, body { margin: 0; min-height: 100%; }
html { background: var(--apps-bg); }
body.apps-page {
  font-family: "PingFang SC", "Microsoft YaHei", "Noto Sans SC", sans-serif;
  background: var(--apps-bg);
  color: var(--apps-fg);
}

/* Capsule-matched thin accent scrollbar (from 完整版 style.css + --ocap-scrollbar-*) */
html {
  --ocap-scrollbar-thumb: rgba(var(--apps-accent-rgb), 0.46);
  --ocap-scrollbar-thumb-hover: rgba(var(--apps-accent-rgb), 0.64);
}
html[data-theme="dark"] {
  --ocap-scrollbar-thumb: rgba(var(--apps-accent-rgb), 0.56);
  --ocap-scrollbar-thumb-hover: rgba(var(--apps-accent-rgb), 0.76);
}
html::-webkit-scrollbar,
body::-webkit-scrollbar,
.apps-modal-panel::-webkit-scrollbar {
  width: 3px;
  height: 3px;
}
html::-webkit-scrollbar-button,
body::-webkit-scrollbar-button,
.apps-modal-panel::-webkit-scrollbar-button {
  display: none;
  width: 0;
  height: 0;
}
html::-webkit-scrollbar-track,
body::-webkit-scrollbar-track,
.apps-modal-panel::-webkit-scrollbar-track {
  background: transparent;
}
html::-webkit-scrollbar-thumb,
body::-webkit-scrollbar-thumb,
.apps-modal-panel::-webkit-scrollbar-thumb {
  background-color: var(--ocap-scrollbar-thumb, rgba(255, 127, 0, 0.46));
  border-radius: 999px;
}
html::-webkit-scrollbar-thumb:hover,
body::-webkit-scrollbar-thumb:hover,
.apps-modal-panel::-webkit-scrollbar-thumb:hover {
  background-color: var(--ocap-scrollbar-thumb-hover, rgba(255, 127, 0, 0.64));
}
html, body, .apps-modal-panel {
  scrollbar-width: thin;
  scrollbar-color: var(--ocap-scrollbar-thumb, rgba(255, 127, 0, 0.46)) transparent;
}
.apps-wrap { max-width: 1100px; margin: 0 auto; padding: 18px 18px 48px; }
.apps-top {
  display: flex; align-items: center; justify-content: space-between;
  gap: 12px; margin-bottom: 10px; min-height: 0;
}
.apps-top-right {
  display: flex; align-items: center; flex-wrap: wrap; justify-content: flex-end;
  gap: 8px 10px; flex-shrink: 0; margin-left: auto;
}
.apps-top.is-campaign,
body.has-campaign .apps-top {
  position: relative;
  padding: 8px 12px 8px 14px;
  border-radius: var(--apps-radius-panel);
  background: var(--apps-header-surface);
  border: 1px solid var(--apps-card-border);
  border-left: 3px solid var(--apps-accent);
  margin-bottom: 8px;
  align-items: center;
}
.apps-brand { min-width: 0; }
.apps-brand h1 {
  margin: 0; font-size: 18px; font-weight: 700; letter-spacing: .04em;
  display: inline-flex; align-items: center; gap: 8px; line-height: 1.25;
}
.apps-brand h1::before {
  content: ""; width: 10px; height: 10px; flex-shrink: 0;
  background: var(--apps-accent); border-radius: 2px;
}
.apps-top.is-campaign .apps-brand h1::before,
body.has-campaign .apps-top .apps-brand h1::before { display: none; }
.apps-brand p.apps-sub {
  margin: 2px 0 0; color: var(--apps-muted); font-size: 12px;
  line-height: 1.35; max-width: 42em;
  display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden;
}
.apps-campaign-badge {
  display: inline-flex; align-items: center; margin: 0;
  padding: 3px 8px; font-size: 11px; font-weight: 700; letter-spacing: .04em;
  color: var(--apps-accent); background: transparent;
  border: 1px solid var(--apps-accent); border-radius: 6px; line-height: 1.2;
  white-space: nowrap;
}
.apps-home {
  flex-shrink: 0; align-self: center; padding: 6px 12px;
  border-radius: var(--apps-radius); border: 1px solid var(--apps-card-border);
  background: var(--apps-card); color: var(--apps-fg); font-size: 12px;
  text-decoration: none; transition: border-color .15s ease, color .15s ease;
}
.apps-home:hover { border-color: var(--apps-accent); color: var(--apps-accent); }
.apps-cats {
  display: flex; flex-wrap: wrap; gap: 2px; margin: 6px 0 12px;
  padding: 4px; border-radius: var(--apps-radius);
  background: var(--apps-pill);
  border: 1px solid var(--apps-card-border);
  border-bottom: 1px solid var(--apps-card-border);
}
.apps-cats button {
  border: 0; cursor: pointer; border-radius: 6px; padding: 8px 12px;
  background: transparent; color: var(--apps-muted); font-size: 13px;
  font-weight: 500; position: relative; transition: color .15s ease, background .15s ease;
}
.apps-cats button:hover { color: var(--apps-fg); background: rgba(127,127,127,.08); }
.apps-cats button.is-on {
  color: var(--apps-fg); font-weight: 700;
  background: var(--apps-card);
  box-shadow: inset 0 -2px 0 var(--apps-accent);
}
.apps-cats button.is-on::after { display: none; }
.apps-seek { margin-bottom: 18px; }
.apps-seek input {
  width: 100%; max-width: 360px; height: 40px; border-radius: var(--apps-radius);
  border: 1px solid var(--apps-card-border); background: var(--apps-input);
  color: var(--apps-fg); padding: 0 14px; outline: none;
  transition: border-color .15s ease, box-shadow .15s ease;
}
.apps-seek input:focus {
  border-color: var(--apps-accent);
  box-shadow: 0 0 0 3px rgba(var(--apps-accent-rgb), .22);
}
.apps-chips { display: flex; flex-wrap: wrap; gap: 8px; margin: 0 0 12px; }
.apps-chip {
  border: 1px solid var(--apps-card-border); background: transparent; color: var(--apps-fg);
  border-radius: 6px; padding: 6px 11px; font-size: 12px; cursor: pointer;
  transition: border-color .15s ease, color .15s ease, background .15s ease;
}
.apps-chip:hover { border-color: var(--apps-accent); color: var(--apps-accent); }
.apps-chip.is-on {
  background: rgba(var(--apps-accent-rgb), .12); border-color: var(--apps-accent);
  color: var(--apps-accent); font-weight: 650;
}
.apps-chip.is-last {
  border-style: solid; color: var(--apps-muted);
  display: inline-flex; align-items: center; gap: 6px;
}
.apps-chip.is-last::before {
  content: ""; width: 6px; height: 6px; background: var(--apps-accent);
  border-radius: 1px; flex-shrink: 0;
}
.apps-chip.is-last:not([hidden]) { display: inline-flex; }
.apps-section { margin-bottom: 28px; }
.apps-section h2 {
  margin: 0 0 12px; font-size: 15px; font-weight: 650;
  color: var(--apps-muted); letter-spacing: .02em;
}
.apps-grid {
  display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 14px;
}
.apps-grid-featured {
  grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px;
}
.app-card {
  display: flex;
  flex-direction: row;
  flex-wrap: wrap;
  align-items: center;
  gap: 12px;
  text-align: left;
  padding: 14px;
  width: 100%;
  min-width: 0;
  border-radius: var(--apps-radius-panel);
  border: 1px solid var(--apps-card-border);
  background: var(--apps-card);
  color: inherit;
  cursor: pointer;
  transition: transform .12s ease, border-color .15s ease, background .15s ease;
  position: relative;
  overflow: hidden;
  writing-mode: horizontal-tb;
  box-sizing: border-box;
}
.app-card:hover {
  transform: translateY(-1px); background: var(--apps-card-hover);
  border-color: rgba(var(--apps-accent-rgb), .35);
}
.app-card.is-featured {
  padding: 16px;
  border-color: rgba(var(--apps-accent-rgb), .42);
  border-left: 4px solid var(--apps-accent);
  background: var(--apps-featured-bg);
  box-shadow: 0 0 0 1px rgba(var(--apps-accent-rgb), .08);
}
.app-card.is-featured:hover {
  transform: translateY(-1px);
  border-color: rgba(var(--apps-accent-rgb), .55);
  border-left-color: var(--apps-accent);
  box-shadow: 0 0 0 1px rgba(var(--apps-accent-rgb), .14);
}
.app-card.is-featured .app-icon {
  width: 56px; height: 56px; border-radius: 12px; box-shadow: none; flex-shrink: 0;
}
.app-card.is-main-push {
  border-color: var(--apps-accent) !important;
  border-left: 4px solid var(--apps-accent) !important;
  box-shadow: none !important;
}
.app-card.is-chip-hit {
  outline: 2px solid var(--apps-accent); outline-offset: 1px; box-shadow: none;
}
.app-ribbon {
  position: absolute; top: 10px; right: 10px; z-index: 2;
  font-size: 10px; font-weight: 750; line-height: 1; padding: 5px 8px;
  border-radius: 6px; background: var(--apps-accent); color: #fff;
  box-shadow: none; letter-spacing: .02em;
}
.app-card.is-featured .app-ribbon { top: 12px; right: 12px; }
.app-card-body {
  display: flex;
  flex-direction: column;
  flex: 1 1 auto;
  min-width: 0;
  gap: 8px;
}
.app-badge-strip { display: flex; flex-wrap: wrap; gap: 6px; margin: 0; }
.app-badge {
  font-style: normal; font-size: 11px; line-height: 1.2; padding: 4px 8px;
  border-radius: 4px; background: rgba(127,127,127,.12); color: var(--apps-muted); font-weight: 650;
  flex: 0 0 auto; white-space: nowrap;
}
.app-badge.is-official {
  background: rgba(var(--apps-accent-rgb), .14); color: var(--apps-accent);
}
html[data-theme="light"] .app-badge.is-official {
  background: rgba(var(--apps-accent-rgb), .12); color: var(--apps-accent-strong);
}
.app-trust,
.app-meta-row {
  display: flex; flex-wrap: wrap; align-items: center; gap: 4px 6px;
  margin: 0; min-width: 0; max-width: 100%;
  font-size: 11px; color: var(--apps-muted);
  overflow: visible; white-space: normal;
}
.app-meta-row {
  flex: 1 1 100%;
  width: 100%;
  order: 5;
}
.app-card.is-featured .app-meta-row {
  flex-wrap: nowrap;
  gap: 4px 6px;
  overflow: hidden;
}
.app-card.is-featured .app-meta-row .app-meta-item,
.app-card.is-featured .app-meta-row .app-badge,
.app-card.is-featured .app-meta-row > em:not(.app-badge) {
  font-size: 10px;
  padding: 2px 6px;
  line-height: 1.15;
}
.app-meta-row .app-meta-item,
.app-trust > span {
  flex: 0 0 auto;
  white-space: nowrap;
}
.app-meta-row .app-badge,
.app-trust .app-badge { flex: 0 0 auto; }
.app-trust strong,
.app-meta-row strong { color: var(--apps-fg); font-weight: 650; }
.app-icon {
  width: 48px; height: 48px; border-radius: 10px; overflow: hidden; flex-shrink: 0;
  background: rgba(127,127,127,.12); display: flex; align-items: center; justify-content: center;
  position: relative; border: 1px solid var(--apps-card-border);
}
.app-icon.lg { width: 52px; height: 52px; border-radius: 12px; }
.app-icon img { width: 100%; height: 100%; object-fit: cover; display: block; }
.app-icon-fallback {
  width: 100%; height: 100%; display: flex; align-items: center; justify-content: center;
  font-weight: 800; font-size: 18px; color: #fff; background: var(--apps-accent); letter-spacing: .02em;
}
.app-icon.lg .app-icon-fallback { font-size: 20px; }
.app-meta {
  flex: 1 1 auto;
  min-width: 0;
  max-width: 100%;
  overflow: visible;
  writing-mode: horizontal-tb;
  display: flex;
  flex-direction: column;
  align-items: stretch;
  justify-content: center;
  gap: 5px;
  padding-right: 0;
}
.app-meta > * { max-width: 100%; margin: 0; }
.app-name {
  display: block;
  font-size: 15px;
  font-weight: 700;
  line-height: 1.3;
  white-space: normal;
  overflow: visible;
  word-break: break-word;
  writing-mode: horizontal-tb;
}
.app-slogan {
  display: -webkit-box;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
  line-clamp: 2;
  margin: 0;
  font-size: 13px;
  line-height: 1.45;
  color: var(--apps-muted);
  white-space: normal;
  overflow: hidden;
  word-break: break-word;
  overflow-wrap: break-word;
  writing-mode: horizontal-tb;
}
.app-card.is-featured .app-slogan {
  white-space: normal;
  display: -webkit-box;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
  line-clamp: 2;
  line-height: 1.45;
}
.app-tags {
  display: none; /* merged into .app-meta-row; keep selector for safety */
  margin: 0;
}
.app-tags em,
.app-meta-row > em:not(.app-badge) {
  font-style: normal;
  font-size: 11px;
  line-height: 1.2;
  padding: 3px 7px;
  border-radius: 4px;
  background: rgba(127,127,127,.1);
  color: var(--apps-muted);
  flex: 0 0 auto;
  white-space: nowrap;
  display: inline-block;
}
.app-story {
  display: -webkit-box;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
  line-clamp: 2;
  margin: 0;
  font-size: 12px;
  line-height: 1.4;
  color: var(--apps-muted);
  white-space: normal;
  overflow: hidden;
  word-break: break-word;
  writing-mode: horizontal-tb;
}
.app-companion-hint {
  display: block; margin: 0; font-size: 12px; line-height: 1.35;
  color: var(--apps-accent); font-weight: 600;
  white-space: normal; overflow: visible; word-break: break-word;
}
.app-cta {
  flex: 0 0 auto;
  flex-shrink: 0;
  align-self: center;
  width: auto;
  max-width: none;
  box-sizing: border-box;
  font-size: 12px;
  font-weight: 700;
  color: #fff;
  padding: 10px 14px;
  border-radius: var(--apps-radius);
  background: var(--apps-accent);
  box-shadow: none;
  white-space: nowrap;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 4px;
  transition: background .15s ease, transform .1s ease;
  writing-mode: horizontal-tb;
}
.app-cta::after { content: "\2192"; font-weight: 700; letter-spacing: 0; }
.app-card:hover .app-cta { background: var(--apps-accent-strong); }
.app-card:active .app-cta { transform: scale(0.98); }
.app-card.is-featured .app-cta { align-self: center; width: auto; padding: 10px 16px; font-size: 13px; }
.app-card.is-featured .app-meta { gap: 5px; }
.app-card:has(.app-ribbon) .app-name { padding-right: 52px; }
.apps-empty { color: var(--apps-muted); font-size: 13px; text-align: center; padding: 24px 0; }.apps-empty { color: var(--apps-muted); font-size: 13px; text-align: center; padding: 24px 0; }.apps-empty { color: var(--apps-muted); font-size: 13px; text-align: center; padding: 24px 0; }
.apps-modal[hidden] { display: none !important; }
.apps-modal {
  position: fixed; inset: 0; z-index: 9999; display: flex;
  align-items: center; justify-content: center; padding: 10px;
}
.apps-modal-backdrop { position: absolute; inset: 0; background: rgba(0,0,0,.55); }
.apps-modal-panel {
  position: relative; width: min(92vw, 500px); max-height: 90vh;
  overflow-x: hidden; overflow-y: auto; -webkit-overflow-scrolling: touch;
  border-radius: var(--apps-radius-panel); background: var(--apps-modal);
  border: 1px solid var(--apps-card-border); padding: 12px 14px 12px;
  box-shadow: 0 12px 40px rgba(0,0,0,.28); z-index: 1;
}
body.apps-modal-open { overflow: hidden !important; }
.apps-modal-x {
  position: absolute; top: 10px; right: 12px; border: 0; background: transparent;
  color: var(--apps-muted); font-size: 24px; cursor: pointer; line-height: 1;
}
.apps-modal-head {
  display: flex; gap: 10px; align-items: center; margin-bottom: 8px;
  padding: 0 28px 8px 0; border-bottom: 1px solid var(--apps-card-border);
}
.apps-modal-head h3 { margin: 0; font-size: 16px; line-height: 1.25; font-weight: 700; }
.apps-modal-head p { margin: 3px 0 0; color: var(--apps-muted); font-size: 12px; line-height: 1.35;
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-width: 100%; }
.apps-modal-story { margin: 3px 0 0; font-size: 12px; color: var(--apps-muted); line-height: 1.4;
  display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.apps-modal-meta {
  display: flex; flex-wrap: wrap; gap: 6px; align-items: center;
  margin: 0 0 10px; font-size: 12px; color: var(--apps-muted);
}
.apps-modal-trust {
  display: contents;
}
.apps-modal-trust[hidden] { display: none !important; }
.apps-trust-strip {
  display: flex; flex-wrap: wrap; gap: 6px 8px; align-items: center;
  margin: 0; font-size: 12px; color: var(--apps-muted);
}
.apps-modal-trust .app-badge,
.apps-modal-meta .app-badge { font-size: 11px; padding: 4px 7px; }
.apps-modal-trust strong,
.apps-modal-meta strong { color: var(--apps-fg); }
/* Redundant gray safe banner — hidden when QR/modal compact; tip lives in trust chip */
.apps-modal-safe {
  display: none !important;
  margin: 0; font-size: 12px; color: var(--apps-muted);
  padding: 0; border: 0; background: transparent;
}
.apps-modal.has-qr .apps-modal-safe,
.apps-modal-panel.has-qr .apps-modal-safe { display: none !important; }
.apps-trust-item {
  display: inline-flex; align-items: center; gap: 5px; font-size: 11px;
  color: var(--apps-muted); background: transparent; border: 1px solid var(--apps-card-border);
  border-radius: 6px; padding: 4px 8px; line-height: 1.2; max-width: 100%;
}
.apps-trust-item.is-safe {
  max-width: min(100%, 28em);
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.apps-lock { color: var(--apps-accent); flex-shrink: 0; }
.apps-platform {
  display: flex; gap: 0; margin-bottom: 8px;
  border: 1px solid var(--apps-card-border); border-radius: var(--apps-radius); overflow: hidden;
}
.apps-platform button {
  flex: 1; height: 36px; border: 0; border-radius: 0; cursor: pointer;
  background: transparent; color: var(--apps-muted); font-size: 13px;
}
.apps-platform button + button { border-left: 1px solid var(--apps-card-border); }
.apps-platform button.is-on { background: var(--apps-accent); color: #fff; font-weight: 700; }
.apps-platform button:disabled { opacity: .35; cursor: not-allowed; }
.apps-qr-box { text-align: center; padding: 2px 0; }
.apps-qr-box > img {
  width: 180px; height: 180px; border-radius: var(--apps-radius-panel);
  background: #fff; padding: 8px; box-sizing: border-box;
}
.apps-qr-box > p { margin: 8px 0 0; color: var(--apps-muted); font-size: 12px; }
.apps-qr-box p { margin: 10px 0 0; color: var(--apps-muted); font-size: 13px; }
.apps-modal-actions { display: flex; gap: 8px; margin-top: 8px; }
.apps-modal-actions a,
.apps-modal-actions button {
  flex: 1; height: 38px; border-radius: var(--apps-radius);
  display: inline-flex; align-items: center; justify-content: center; gap: 4px;
  text-decoration: none; border: 0; cursor: pointer; font-size: 14px; font-weight: 700;
  transition: background .15s ease, transform .1s ease;
}
.apps-modal-actions a { background: var(--apps-accent); color: #fff; box-shadow: none; }
.apps-modal-actions a::after { content: "\2192"; }
.apps-modal-actions a:hover { background: var(--apps-accent-strong); }
.apps-modal-actions a:active { transform: scale(0.98); }
.apps-modal-actions button {
  background: transparent; color: var(--apps-fg); font-weight: 650;
  border: 1px solid var(--apps-card-border);
}
.apps-companion {
  margin: 0 0 8px; padding: 8px 10px; border-radius: var(--apps-radius);
  border: 1px solid rgba(var(--apps-accent-rgb), .35);
  background: rgba(var(--apps-accent-rgb), .08);
}
.apps-companion-split { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.apps-companion-label { display: block; font-size: 11px; color: var(--apps-muted); margin-bottom: 2px; }
.apps-companion-split strong { font-size: 13px; }
.apps-companion-tip { margin: 8px 0 0; font-size: 11px; color: var(--apps-muted); line-height: 1.4; }
.apps-qr-card {
  display: inline-flex; flex-direction: column; align-items: center; gap: 6px;
  padding: 0; background: transparent; border: 0; box-shadow: none;
}
.apps-qr-card img {
  width: 168px; height: 168px; border-radius: var(--apps-radius-panel);
  background: #fff; padding: 8px; box-sizing: border-box; display: block;
  border: 1px solid var(--apps-card-border);
}
.apps-qr-card.is-single img { width: 180px; height: 180px; }
.apps-qr-label {
  margin: 0; font-size: 12px; font-weight: 650; color: var(--apps-muted); letter-spacing: .02em;
}
.apps-qr-dual {
  display: flex; justify-content: center; align-items: flex-start;
  gap: 20px; flex-wrap: nowrap; padding: 4px 0 2px;
}
.apps-qr-dual[hidden], .apps-qr-box[hidden], .apps-companion[hidden] { display: none !important; }

/* Simplified download modal — QR mode hides toggle + tip chip */
.apps-platform[hidden],
.apps-modal-actions[hidden],
.apps-link-actions[hidden],
.apps-send-phone[hidden],
.apps-trust-item[hidden] { display: none !important; }
.apps-link-actions { display: flex; gap: 8px; margin-top: 8px; flex-wrap: wrap; }
.apps-link-actions a[hidden] { display: none !important; }
.apps-link-actions a {
  flex: 1; min-width: 140px; height: 38px; border-radius: var(--apps-radius);
  display: inline-flex; align-items: center; justify-content: center; gap: 4px;
  text-decoration: none; border: 0; cursor: pointer; font-size: 14px; font-weight: 700;
  background: var(--apps-accent); color: #fff;
  transition: background .15s ease, transform .1s ease;
}
.apps-link-actions a:hover { background: var(--apps-accent-strong); }
.apps-link-actions a:active { transform: scale(0.98); }
.apps-qr-box.is-centered, .apps-qr-box { text-align: center; }
.apps-modal-panel.has-qr .apps-trust-item.is-safe { display: none !important; }

.apps-send-phone {
  width: 100%; margin-top: 8px; height: 38px;
  border: 1px solid var(--apps-card-border); border-radius: var(--apps-radius);
  cursor: pointer; font-size: 14px; font-weight: 700; color: var(--apps-fg); background: transparent;
}
.apps-send-phone.is-done { color: #22c55e; border-color: #22c55e; }
.apps-social {
  margin: 0; font-size: 12px; color: var(--apps-muted);
  display: inline-flex; align-items: baseline; gap: 4px; white-space: nowrap;
}
.apps-social strong {
  color: var(--apps-accent); font-size: 14px; font-weight: 750; letter-spacing: .02em;
}
.apps-social-label { opacity: .9; }
.apps-top-right .apps-social { margin: 0; }
@keyframes apps-featured-in {
  from { opacity: 0; transform: translateY(8px); }
  to { opacity: 1; transform: translateY(0); }
}
@keyframes apps-social-tick {
  from { opacity: .4; transform: translateY(2px); }
  to { opacity: 1; transform: translateY(0); }
}
.apps-social { animation: apps-social-tick .45s ease both; }
.apps-grid-featured .app-card.is-featured {
  opacity: 0; animation: apps-featured-in .28s ease forwards;
}
.apps-grid-featured .app-card.is-featured:nth-child(1) { animation-delay: .02s; }
.apps-grid-featured .app-card.is-featured:nth-child(2) { animation-delay: .05s; }
.apps-grid-featured .app-card.is-featured:nth-child(3) { animation-delay: .08s; }
.apps-grid-featured .app-card.is-featured:nth-child(4) { animation-delay: .11s; }
.apps-grid-featured .app-card.is-featured:nth-child(5) { animation-delay: .14s; }
@media (min-width: 900px) {
  .apps-wrap { padding: 24px 24px 56px; }
  .apps-brand h1 { font-size: 20px; }
  .apps-grid { grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: 14px; }
  .apps-grid-featured { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}
@media (max-width: 640px) {
  .apps-wrap { padding: 12px 12px 36px; }
  .apps-brand h1 { font-size: 20px; }
  .apps-brand p.apps-sub { font-size: 12px; }
  .apps-grid, .apps-grid-featured { grid-template-columns: 1fr; gap: 10px; }
  .app-card { padding: 12px; gap: 10px; align-items: center; }
  .app-card.is-featured { padding: 14px; }
  .app-card.is-featured .app-icon { width: 52px; height: 52px; }
  .app-meta { padding-right: 0; gap: 5px; }
  .app-card:has(.app-ribbon) .app-meta { padding-right: 8px; }
  .app-cta { padding: 9px 12px; font-size: 12px; width: auto; flex-shrink: 0; }
  .apps-qr-box img { width: 160px; height: 160px; }
  .apps-modal-panel { width: min(96vw, 500px); padding: 12px; border-radius: var(--apps-radius-panel); max-height: 92vh; }
  .apps-qr-card.is-single img { width: 168px; height: 168px; }
  .apps-qr-card img { width: 148px; height: 148px; }
  .apps-qr-dual { flex-wrap: nowrap; justify-content: center; gap: 14px; }
  .apps-chips { gap: 6px; }
  .apps-chip { padding: 5px 10px; font-size: 11px; }
  .apps-companion-split { grid-template-columns: 1fr; }
  .apps-modal { padding: 8px; }
  .apps-cats button { padding: 9px 12px 8px; font-size: 12px; }
}
/* Capsule iframe: page bg transparent (wallpaper shows); frosted white = Software Center cards
   Source: App.vue workspaceCardGlassStyle + BeautyCenter beautyCardStyle (wallpaperActive)
   Cards: light rgba(255,255,255,0.80) / dark rgba(15,23,42,0.45) + backdrop-filter blur(10px)
   Panels/chips: Beauty beautyGlassStyle light rgba(255,255,255,0.74) / dark rgba(15,23,42,0.62) + blur(18px) */
html:has(body.from-capsule),
body.from-capsule.apps-page {
  background: transparent !important;
}
/* Dark theme: Software Center dark frosted cards */
body.from-capsule.theme-dark {
  --apps-card: rgba(15, 23, 42, 0.45);
  --apps-card-hover: rgba(31, 41, 55, 0.65);
  --apps-header-surface: rgba(15, 23, 42, 0.62);
  --apps-input: rgba(15, 23, 42, 0.45);
  --apps-pill: rgba(15, 23, 42, 0.62);
  --apps-modal: rgba(15, 23, 42, 0.45);
  --apps-card-border: rgba(255, 255, 255, 0.14);
  --apps-featured-bg: rgba(15, 23, 42, 0.45);
  --apps-muted: rgba(255, 255, 255, 0.72);
}
/* Light theme: Software Center frosted white (白透明) — NOT #ffffff */
body.from-capsule.theme-light {
  --apps-card: rgba(255, 255, 255, 0.80);
  --apps-card-hover: rgba(255, 255, 255, 0.90);
  --apps-header-surface: rgba(255, 255, 255, 0.74);
  --apps-input: rgba(255, 255, 255, 0.80);
  --apps-pill: rgba(255, 255, 255, 0.74);
  --apps-modal: rgba(255, 255, 255, 0.80);
  --apps-card-border: rgba(15, 23, 42, 0.12);
  --apps-featured-bg: rgba(255, 255, 255, 0.80);
  --apps-muted: #4b5563;
}
/* Featured + dense + modal: acrylic blur like Beauty beautyCardStyle */
body.from-capsule .app-card,
body.from-capsule .app-card.is-featured,
body.from-capsule .apps-list-dense .app-card,
body.from-capsule .apps-grid-featured .app-card.is-featured,
body.from-capsule .apps-modal-panel {
  background: var(--apps-card) !important;
  background-color: var(--apps-card) !important;
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
}
body.from-capsule .app-card.is-featured:hover,
body.from-capsule .app-card:hover {
  background: var(--apps-card-hover) !important;
  background-color: var(--apps-card-hover) !important;
}
/* Filter bar / chips / search: Beauty panel glass (blur 18px) */
body.from-capsule .apps-cats,
body.from-capsule .apps-top.is-campaign,
body.from-capsule.has-campaign .apps-top {
  background: var(--apps-header-surface) !important;
  border-color: var(--apps-card-border) !important;
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.06);
  backdrop-filter: blur(18px);
  -webkit-backdrop-filter: blur(18px);
}
body.from-capsule .apps-cats button {
  color: var(--apps-muted);
}
body.from-capsule .apps-cats button.is-on {
  color: var(--apps-fg);
  background: rgba(var(--apps-accent-rgb), 0.12);
}
body.from-capsule .apps-chip {
  background: var(--apps-card) !important;
  border-color: var(--apps-card-border);
  color: var(--apps-fg);
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.04);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
}
body.from-capsule .apps-chip.is-on {
  background: rgba(var(--apps-accent-rgb), 0.14) !important;
  border-color: var(--apps-accent);
  color: var(--apps-accent);
}
body.from-capsule .apps-seek input,
body.from-capsule .apps-seek.apps-seek-inline.is-open input {
  background: var(--apps-input) !important;
  color: var(--apps-fg);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
}
/* Section titles readable on wallpaper */
body.from-capsule .apps-section h2 {
  color: var(--apps-fg);
  font-weight: 700;
  text-shadow: 0 1px 0 rgba(255, 255, 255, 0.35);
}
body.from-capsule.theme-dark .apps-section h2 {
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.45);
}
body.from-capsule .apps-wrap { max-width: none; padding: 8px 10px 14px; }
body.from-capsule .apps-top { margin-bottom: 6px; }
body.from-capsule .apps-brand h1 { font-size: 16px; }
body.from-capsule .apps-brand h1::before { width: 8px; height: 8px; }
body.from-capsule .apps-brand p.apps-sub {
  font-size: 11px; margin-top: 2px; max-width: none;
  display: -webkit-box; -webkit-line-clamp: 1; -webkit-box-orient: vertical; overflow: hidden;
}
body.from-capsule .apps-brand p {
  font-size: 12px; display: -webkit-box; -webkit-line-clamp: 2;
  -webkit-box-orient: vertical; overflow: hidden;
}
body.from-capsule .apps-section { margin-bottom: 10px; }
body.from-capsule .apps-section[data-section="featured"] { margin-bottom: 8px; }
body.from-capsule .apps-section h2 { margin-bottom: 6px; font-size: 12px; }
body.from-capsule .apps-grid {
  gap: 10px; grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
}
body.from-capsule .apps-grid-featured {
  gap: 8px; grid-template-columns: repeat(3, minmax(0, 1fr));
}
body.from-capsule .app-card { padding: 12px; border-radius: 10px; gap: 8px; }
body.from-capsule .app-card.is-featured { padding: 14px; }
body.from-capsule .app-icon { width: 42px; height: 42px; border-radius: 8px; }
body.from-capsule .app-card.is-featured .app-icon { width: 48px; height: 48px; border-radius: 10px; }
body.from-capsule .app-slogan { font-size: 12px; -webkit-line-clamp: 2; line-clamp: 2; }
body.from-capsule .app-card { align-items: center; }
body.from-capsule .app-meta { gap: 6px; padding-right: 0; }
body.from-capsule .app-card:has(.app-ribbon) .app-name { padding-right: 48px; }
body.from-capsule .app-name { font-size: 14px; font-weight: 700; white-space: normal; }
body.from-capsule .app-meta-row { gap: 6px 8px; font-size: 11px; flex-wrap: wrap; white-space: normal; }
body.from-capsule .app-meta-row > em:not(.app-badge) { font-size: 10px; padding: 2px 6px; }
body.from-capsule .app-cta { width: auto; flex-shrink: 0; align-self: center; padding: 8px 12px; font-size: 12px; border-radius: 6px; justify-content: center; }



body.from-capsule .apps-qr-box img { width: 168px; height: 168px; padding: 8px; }
body.from-capsule .apps-seek { margin-bottom: 8px; }
body.from-capsule .apps-cats { margin: 4px 0 8px; padding: 3px; }
body.from-capsule .apps-cats button { padding: 6px 10px; font-size: 12px; }
body.from-capsule .apps-chips { margin-bottom: 8px; }
body.from-capsule .apps-social { font-size: 11px; }
body.from-capsule .apps-social strong { font-size: 13px; }
body.from-capsule .apps-top.is-campaign,
body.from-capsule.has-campaign .apps-top {
  padding: 6px 10px 6px 12px; border-radius: 10px; margin-bottom: 2px;
  background: var(--apps-header-surface);
  border: 1px solid var(--apps-card-border);
  border-left: 3px solid var(--apps-accent);
}
body.from-capsule .app-story { font-size: 10px; }
body.from-capsule .apps-campaign-badge { margin: 0; font-size: 10px; padding: 2px 7px; }
body.from-capsule .apps-qr-card img { width: 160px; height: 160px; }
body.from-capsule .apps-qr-card.is-single img { width: 176px; height: 176px; }
body.from-capsule .apps-qr-dual { gap: 18px; flex-wrap: nowrap; }
body.from-capsule .apps-modal-panel { width: min(92vw, 500px); padding: 10px 12px 12px; max-height: 88vh; }
body.from-capsule .apps-top-right { gap: 6px 8px; }

/* ===== Dense multi-column grid (全部 / category lists) ===== */
.apps-list-dense {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(152px, 1fr));
  gap: 8px;
  align-items: stretch;
}
.apps-list-dense .app-card {
  display: flex;
  flex-direction: row;
  flex-wrap: wrap;
  align-items: center;
  padding: 8px 8px 8px 8px;
  gap: 6px 8px;
  border-radius: 8px;
  min-height: 0;
  width: 100%;
}
.apps-list-dense .app-card:hover {
  transform: none;
}
.apps-list-dense .app-icon {
  width: 34px;
  height: 34px;
  border-radius: 8px;
}
.apps-list-dense .app-meta {
  flex: 1 1 0;
  min-width: 0;
  flex-direction: column;
  flex-wrap: nowrap;
  align-items: stretch;
  justify-content: center;
  gap: 2px;
  overflow: hidden;
  padding-right: 0;
}
.apps-list-dense .app-name {
  flex: 0 0 auto;
  font-size: 12px;
  font-weight: 700;
  line-height: 1.25;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  max-width: 100%;
  padding-right: 0 !important;
}
.apps-list-dense .app-slogan {
  flex: 0 0 auto;
  min-width: 0;
  margin: 0;
  font-size: 11px;
  line-height: 1.25;
  display: block;
  -webkit-line-clamp: unset;
  line-clamp: unset;
  -webkit-box-orient: unset;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.apps-list-dense .app-slogan::before {
  content: none;
}
.apps-list-dense .app-story,
.apps-list-dense .app-companion-hint,
.apps-list-dense .app-ribbon,
.apps-list-dense .app-meta-row {
  display: none !important;
}
.apps-list-dense .app-cta {
  flex: 0 0 auto;
  margin-left: auto;
  padding: 5px 8px;
  font-size: 11px;
  border-radius: 6px;
  align-self: center;
}
.apps-list-dense .app-cta::after {
  content: none;
}
.apps-list-dense .app-card:has(.app-ribbon) .app-name {
  padding-right: 0;
}
@media (min-width: 900px) {
  .apps-list-dense {
    grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
    gap: 10px;
  }
}
@media (max-width: 640px) {
  .apps-list-dense {
    grid-template-columns: repeat(auto-fill, minmax(140px, 1fr));
    gap: 6px;
  }
  .apps-list-dense .app-card { padding: 7px; gap: 6px; }
  .apps-list-dense .app-icon { width: 32px; height: 32px; }
  .apps-list-dense .app-name { font-size: 12px; }
  .apps-list-dense .app-slogan { font-size: 10px; }
  .apps-list-dense .app-cta { padding: 4px 7px; font-size: 10px; }
}
body.from-capsule .apps-list-dense {
  grid-template-columns: repeat(auto-fill, minmax(128px, 1fr));
  gap: 6px;
}
body.from-capsule .apps-list-dense .app-card {
  padding: 6px 7px;
  gap: 5px 6px;
  border-radius: 8px;
}
body.from-capsule .apps-list-dense .app-icon {
  width: 30px;
  height: 30px;
  border-radius: 7px;
}
body.from-capsule .apps-list-dense .app-name {
  font-size: 11px;
  max-width: 100%;
}
body.from-capsule .apps-list-dense .app-slogan {
  font-size: 10px;
  -webkit-line-clamp: unset;
  line-clamp: unset;
}
body.from-capsule .apps-list-dense .app-meta {
  gap: 1px;
}
body.from-capsule .apps-list-dense .app-cta {
  padding: 4px 7px;
  font-size: 10px;
  border-radius: 5px;
}

/* Featured: keep chips on one visual row under content (full-width sibling) */
body.from-capsule .app-card.is-featured .app-meta-row {
  flex-wrap: nowrap;
  gap: 3px 5px;
  font-size: 10px;
  overflow: hidden;
}
body.from-capsule .app-card.is-featured .app-meta-row .app-meta-item,
body.from-capsule .app-card.is-featured .app-meta-row .app-badge,
body.from-capsule .app-card.is-featured .app-meta-row > em:not(.app-badge) {
  font-size: 9px;
  padding: 1px 5px;
}
/* ===== Featured card redesign 2026-10-13 (afc-*) ===== */
.apps-grid-featured { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; align-items: stretch; }
.apps-grid-featured .app-card.is-featured,
body.from-capsule .apps-grid-featured .app-card.is-featured {
  display: flex !important; flex-direction: column !important; align-items: stretch !important;
  gap: 12px !important; padding: 16px !important; height: 100%; min-width: 0; text-align: left; position: relative;
}
.app-card.is-featured .afc-head { display: flex; align-items: center; gap: 12px; min-width: 0; }
.app-card.is-featured .afc-head .app-icon,
body.from-capsule .app-card.is-featured .afc-head .app-icon { width: 48px !important; height: 48px !important; flex: 0 0 48px; border-radius: 12px; margin: 0 !important; }
.app-card.is-featured .afc-titles { display: flex; flex-direction: column; gap: 4px; min-width: 0; flex: 1 1 auto; }
.app-card.is-featured .afc-titles .app-name {
  font-size: 16px; font-weight: 700; line-height: 1.3; margin: 0 !important; padding: 0 !important;
  white-space: nowrap !important; overflow: hidden; text-overflow: ellipsis; word-break: keep-all; max-width: 100%;
}
.app-card.is-featured .afc-titles .app-slogan {
  font-size: 13px; line-height: 1.4; opacity: .75; margin: 0 !important;
  white-space: nowrap !important; overflow: hidden; text-overflow: ellipsis; display: block !important; -webkit-line-clamp: unset !important;
}
.app-card.is-featured .afc-badge {
  flex: 0 0 auto; align-self: flex-start; white-space: nowrap; font-size: 12px; font-weight: 700; line-height: 1;
  padding: 5px 9px; border-radius: 999px; color: #fff; background: var(--apps-accent, #16b47a);
}
.app-card.is-featured .afc-desc {
  display: -webkit-box; -webkit-box-orient: vertical; -webkit-line-clamp: 2; overflow: hidden;
  font-size: 13px; line-height: 1.5; min-height: 3em; opacity: .85; margin: 0;
}
.app-card.is-featured .afc-foot { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-top: auto; min-width: 0; }
.app-card.is-featured .afc-chips { display: flex; align-items: center; gap: 6px; flex: 1 1 auto; min-width: 0; flex-wrap: nowrap; overflow: hidden; white-space: nowrap; }
.app-card.is-featured .afc-chip {
  flex: 0 0 auto; font-style: normal; font-size: 12px; line-height: 1; padding: 5px 8px; border-radius: 6px;
  background: rgba(127,127,127,.12); white-space: nowrap;
}
.app-card.is-featured .afc-chip strong { font-weight: 700; margin-left: 2px; }
.app-card.is-featured .afc-chip.is-official { color: var(--apps-accent, #16b47a); background: rgba(var(--apps-accent-rgb, 22,180,122), .12); font-weight: 700; }
.app-card.is-featured .afc-cta,
body.from-capsule .app-card.is-featured .afc-cta {
  flex: 0 0 auto; align-self: center !important; width: auto !important; margin: 0 !important; position: static !important;
  padding: 8px 14px !important; font-size: 13px !important; line-height: 1 !important; white-space: nowrap; border-radius: 999px;
}
@media (max-width: 900px) { .apps-grid-featured { grid-template-columns: 1fr; } }
/* ===== Overflow polish 2026-10-13 (apps_overflow) ===== */
/* Featured cards: everything stays inside padding */
.apps-grid-featured > .app-card.is-featured { min-width: 0 !important; max-width: 100%; overflow: hidden; box-sizing: border-box; }
.app-card.is-featured > .afc-head,
.app-card.is-featured > .afc-desc,
.app-card.is-featured > .afc-foot { width: 100%; max-width: 100%; min-width: 0; box-sizing: border-box; }
.app-card.is-featured .afc-head { overflow: visible; }
.app-card.is-featured .afc-titles { flex: 1 1 0 !important; min-width: 0 !important; overflow: hidden; }
.app-card.is-featured .afc-badge,
body.from-capsule .app-card.is-featured .afc-badge {
  position: static !important; top: auto !important; right: auto !important; transform: none !important;
  flex: 0 0 auto; max-width: 40%; overflow: hidden; text-overflow: ellipsis; margin: 0 !important;
}
.app-card.is-featured .afc-desc,
body.from-capsule .app-card.is-featured .afc-desc {
  display: -webkit-box !important; -webkit-box-orient: vertical; -webkit-line-clamp: 2; line-clamp: 2;
  white-space: normal !important; overflow: hidden !important; text-overflow: ellipsis; word-break: break-all; overflow-wrap: anywhere;
}
.app-card.is-featured .afc-foot { flex-wrap: nowrap !important; gap: 8px !important; overflow: hidden; }
.app-card.is-featured .afc-chips { flex: 1 1 0 !important; min-width: 0 !important; overflow: hidden !important; }
.app-card.is-featured .afc-chip { flex: 0 1 auto !important; min-width: 0; max-width: 100%; overflow: hidden; text-overflow: ellipsis; }
.app-card.is-featured .afc-cta,
body.from-capsule .app-card.is-featured .afc-cta {
  flex: 0 0 auto !important; flex-shrink: 0 !important; max-width: none; padding: 8px 16px !important;
}
.app-card.is-featured .afc-cta::after { content: none !important; }

/* Dense 全部 tiles: icon + name/slogan + small 下载, single row */
.apps-list-dense { grid-template-columns: repeat(auto-fill, minmax(168px, 1fr)); }
body.from-capsule .apps-list-dense { grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); }
.apps-list-dense .app-card,
body.from-capsule .apps-list-dense .app-card { flex-wrap: nowrap !important; min-width: 0; overflow: hidden; }
.apps-list-dense .app-icon { flex: 0 0 auto; }
.apps-list-dense .app-meta { flex: 1 1 0 !important; min-width: 0 !important; overflow: hidden; }
.apps-list-dense .app-name,
.apps-list-dense .app-slogan,
body.from-capsule .apps-list-dense .app-name,
body.from-capsule .apps-list-dense .app-slogan {
  display: block !important; white-space: nowrap !important; overflow: hidden !important; text-overflow: ellipsis !important;
  word-break: normal !important; max-width: 100%; min-width: 0;
}
.apps-list-dense .app-cta,
body.from-capsule .apps-list-dense .app-cta { flex: 0 0 auto !important; flex-shrink: 0 !important; width: auto !important; white-space: nowrap; margin-left: auto; }
@media (max-width: 640px) {
  .apps-list-dense, body.from-capsule .apps-list-dense { grid-template-columns: repeat(auto-fill, minmax(140px, 1fr)); }
}
/* ===== Balance featured vs dense 2026-10-13 (apps_balance) ===== */
/* Shared tokens: radius, border, icon, button */
.apps-grid-featured > .app-card.is-featured,
.apps-list-dense > .app-card { border-radius: 12px !important; border-width: 1px !important; }
.apps-section[data-section="featured"],
body.from-capsule .apps-section[data-section="featured"] { margin-bottom: 18px !important; }
.apps-grid-featured .afc-head .app-icon,
body.from-capsule .app-card.is-featured .afc-head .app-icon,
.apps-list-dense .app-icon,
body.from-capsule .apps-list-dense .app-icon { width: 40px !important; height: 40px !important; flex: 0 0 40px !important; border-radius: 10px !important; margin: 0 !important; }
.app-card.is-featured .afc-cta,
body.from-capsule .app-card.is-featured .afc-cta,
.apps-list-dense .app-cta,
body.from-capsule .apps-list-dense .app-cta { border-radius: 999px !important; line-height: 1 !important; font-weight: 700; }

/* Featured: ~130px, 12px padding, meta line under title, 1-line desc + CTA */
.apps-grid-featured .app-card.is-featured,
body.from-capsule .apps-grid-featured .app-card.is-featured { padding: 12px !important; gap: 10px !important; min-height: 0; justify-content: space-between; }
.app-card.is-featured .afc-head { gap: 10px; align-items: center; }
.app-card.is-featured .afc-titles { gap: 3px; }
.app-card.is-featured .afc-titles .app-name { font-size: 15px !important; line-height: 1.25; }
.app-card.is-featured .afc-metaline {
  display: block; min-width: 0; max-width: 100%; font-size: 12px; line-height: 1.3; opacity: .7;
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.app-card.is-featured .afc-badge { padding: 4px 8px; font-size: 11px; }
.app-card.is-featured .afc-chips { display: none !important; }
.app-card.is-featured .afc-foot { display: flex; align-items: center; gap: 10px !important; margin-top: auto; min-width: 0; overflow: hidden; }
.app-card.is-featured .afc-desc,
body.from-capsule .app-card.is-featured .afc-desc {
  display: block !important; flex: 1 1 0; min-width: 0; min-height: 0 !important; -webkit-line-clamp: unset !important; line-clamp: unset !important;
  white-space: nowrap !important; overflow: hidden !important; text-overflow: ellipsis !important; word-break: normal !important;
  font-size: 13px; line-height: 1.4; margin: 0;
}
.app-card.is-featured .afc-cta,
body.from-capsule .app-card.is-featured .afc-cta { padding: 8px 16px !important; font-size: 13px !important; margin-left: auto !important; }

/* Dense: 4 per row, ~64px tiles, bigger text/CTA */
.apps-list-dense,
body.from-capsule .apps-list-dense { grid-template-columns: repeat(4, minmax(0, 1fr)) !important; gap: 10px !important; }
.apps-list-dense > .app-card,
body.from-capsule .apps-list-dense > .app-card { min-height: 64px; padding: 10px 12px !important; gap: 10px !important; align-items: center !important; min-width: 0; overflow: hidden; box-sizing: border-box; }
.apps-list-dense .app-meta,
body.from-capsule .apps-list-dense .app-meta { gap: 3px !important; }
.apps-list-dense .app-name,
body.from-capsule .apps-list-dense .app-name { font-size: 14px !important; line-height: 1.25; }
.apps-list-dense .app-slogan,
body.from-capsule .apps-list-dense .app-slogan { font-size: 12px !important; line-height: 1.3; }
.apps-list-dense .app-cta,
body.from-capsule .apps-list-dense .app-cta { padding: 7px 13px !important; font-size: 12px !important; }
@media (max-width: 760px) {
  .apps-list-dense, body.from-capsule .apps-list-dense { grid-template-columns: repeat(3, minmax(0, 1fr)) !important; }
}
@media (max-width: 560px) {
  .apps-list-dense, body.from-capsule .apps-list-dense { grid-template-columns: repeat(2, minmax(0, 1fr)) !important; gap: 8px !important; }
}
@media (max-width: 360px) {
  .apps-list-dense, body.from-capsule .apps-list-dense { grid-template-columns: 1fr !important; }
}
/* ---- Platform filter (安卓 / iOS) in category bar — 2026-10-13 ---- */
.apps-cats { align-items: center; }
.apps-plat { display: inline-flex; align-items: center; gap: 2px; margin-left: auto; }
.apps-plat-sep { width: 1px; height: 16px; margin: 0 6px; background: var(--apps-card-border); opacity: .9; }
.apps-cats .apps-plat button { font-size: 12px; padding-left: 10px; padding-right: 10px; }
.apps-cats .apps-plat button.is-on {
  color: var(--apps-accent-strong, var(--apps-accent)); font-weight: 700;
  background: var(--apps-card);
  box-shadow: inset 0 0 0 1px rgba(var(--apps-accent-rgb, 34,197,94), .45);
}
.app-card[hidden], .apps-section[hidden], .apps-section h2[hidden], .apps-empty[hidden] { display: none !important; }
body.from-capsule .apps-plat-sep { margin: 0 4px; height: 14px; }
body.from-capsule .apps-cats .apps-plat button { padding: 6px 9px; }

/* ---- Capsule only: header hidden (PHP), stat in category bar right end — 2026-10-13 ---- */
body.from-capsule .apps-cats { align-items: center; row-gap: 2px; }
body.from-capsule .apps-cats .apps-plat { margin-left: auto; flex: 0 0 auto; }
body.from-capsule .apps-cats-stat {
  display: inline-flex; align-items: center; gap: 5px; flex: 0 1 auto; min-width: 0;
  margin-left: 6px; padding-left: 8px; border-left: 1px solid var(--apps-card-border);
  white-space: nowrap; overflow: hidden;
}
body.from-capsule .apps-cats-stat .apps-campaign-badge { margin: 0; flex: 0 1 auto; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: 10px; padding: 2px 6px; }
body.from-capsule .apps-cats-stat .apps-social { margin: 0; flex: 0 1 auto; min-width: 0; overflow: hidden; text-overflow: ellipsis; font-size: 11px; }
body.from-capsule .apps-cats-stat .apps-social-label { overflow: hidden; text-overflow: ellipsis; min-width: 0; }
@media (max-width: 760px) { body.from-capsule .apps-cats-stat .apps-campaign-badge { display: none; } }
@media (max-width: 520px) { body.from-capsule .apps-cats-stat .apps-social-label { display: none; } }
/* ---- 2026-10-13 bar+search: accent-tinted filter bar, inline search, square icons ---- */
.apps-cats {
  background: rgba(var(--apps-accent-rgb), .07) !important;
  border-color: rgba(var(--apps-accent-rgb), .20) !important;
}
html[data-theme="dark"] .apps-cats {
  background: rgba(var(--apps-accent-rgb), .10) !important;
  border-color: rgba(var(--apps-accent-rgb), .24) !important;
}
.apps-cats button:hover { background: rgba(var(--apps-accent-rgb), .10); }
.apps-cats .apps-plat { margin-left: 0 !important; }
.apps-seek.apps-seek-inline {
  margin: 0 0 0 auto !important; display: inline-flex; align-items: center; gap: 4px;
  flex: 0 1 auto; min-width: 0;
}
.apps-cats .apps-seek-btn {
  display: inline-flex; align-items: center; justify-content: center;
  width: 30px; height: 30px; padding: 0 !important; border-radius: 6px;
  color: var(--apps-muted); background: transparent;
}
.apps-cats .apps-seek-btn:hover, .apps-seek.is-open .apps-seek-btn { color: var(--apps-accent); background: rgba(var(--apps-accent-rgb), .12); }
.apps-seek.apps-seek-inline input {
  width: 0; max-width: 220px; height: 28px; padding: 0; border-width: 0; opacity: 0;
  border-radius: 6px; font-size: 12px; pointer-events: none;
  transition: width .18s ease, opacity .15s ease, padding .18s ease;
}
.apps-seek.apps-seek-inline.is-open input {
  width: 180px; padding: 0 10px; border-width: 1px; opacity: 1; pointer-events: auto;
}
@media (max-width: 640px) { .apps-seek.apps-seek-inline.is-open input { width: 120px; } }
body.from-capsule .apps-seek.apps-seek-inline { margin-bottom: 0 !important; }
body.from-capsule .apps-cats .apps-seek-btn { width: 28px; height: 28px; }
body.from-capsule .apps-seek.apps-seek-inline.is-open input { width: 150px; }
/* Square, non-squished icons everywhere */
.app-icon, .app-icon.lg,
.app-card .app-icon, .apps-list-dense .app-icon, .app-card.is-featured .app-icon,
.apps-grid-featured .afc-head .app-icon {
  aspect-ratio: 1 / 1; flex-shrink: 0 !important; flex-grow: 0 !important; box-sizing: border-box;
}
.apps-grid-featured .app-icon,
.apps-grid-featured .afc-head .app-icon,
body.from-capsule .apps-grid-featured .afc-head .app-icon {
  width: 40px !important; height: 40px !important; min-width: 40px !important; max-width: 40px !important;
  flex: 0 0 40px !important;
}
.apps-list-dense .app-icon,
body.from-capsule .apps-list-dense .app-icon { min-width: 40px !important; max-width: 40px !important; }
.app-icon img {
  width: 100% !important; height: 100% !important; max-width: none; object-fit: contain !important; flex-shrink: 0;
}
