/* ==========================================================================
   上海芝士昱森科技有限公司 · 官方下载中心
   在官网 site.css 的变量与组件之上扩展，保持奶油底 + 暖金的统一视觉。
   ========================================================================== */

.skip-link {
  position: fixed;
  left: 16px;
  top: -60px;
  z-index: 200;
  padding: 10px 16px;
  border-radius: 10px;
  background: var(--brand-deep);
  color: #fff;
  font-size: 13.5px;
  font-weight: 700;
  transition: top .2s ease;
}
.skip-link:focus { top: 14px; }

:focus-visible {
  outline: 2px solid var(--brand-strong);
  outline-offset: 3px;
  border-radius: 6px;
}

/* ---------- Hero ---------- */
.dl-hero {
  position: relative;
  padding: 62px 0 30px;
  overflow: hidden;
}
.dl-hero::after {
  content: "";
  position: absolute;
  right: -180px;
  top: -160px;
  width: 560px;
  height: 560px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(233, 197, 120, .34), transparent 66%);
  pointer-events: none;
  z-index: -1;
}
.dl-hero-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.12fr) minmax(0, .88fr);
  gap: 56px;
  align-items: center;
}
.dl-hero h1 {
  margin-top: 22px;
  font-size: clamp(36px, 4.5vw, 57px);
  line-height: 1.13;
  font-weight: 900;
  letter-spacing: -.03em;
}
.dl-hero .lead {
  margin-top: 20px;
  max-width: 590px;
  font-size: 16px;
  color: var(--on-surface-muted);
}
.dl-hero .hero-cta { margin-top: 28px; }
.dl-hero .hero-meta { margin-top: 28px; }

.dl-domains {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 7px;
  margin-top: 24px;
  font-size: 11.5px;
  color: var(--on-surface-muted);
}
.dl-domains > span {
  margin-right: 2px;
  font-weight: 700;
  letter-spacing: .08em;
}
.dl-domains code {
  padding: 4px 9px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: rgba(255, 253, 247, .72);
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-size: 11px;
  color: var(--brand-deep);
}

.error-card {
  max-width: 760px;
  margin: 26px 0 40px;
  padding: 46px;
  border-radius: var(--radius-lg);
  background: var(--surface-raised);
  border: 1px solid var(--line);
  box-shadow: var(--shadow-md);
}
.error-card h1 {
  margin-top: 18px;
  font-size: clamp(28px, 4vw, 42px);
  font-weight: 900;
  letter-spacing: -.025em;
  line-height: 1.2;
}
.error-card .lead { margin-top: 14px; max-width: 560px; font-size: 15px; color: var(--on-surface-muted); }
.error-card .hero-cta { margin-top: 26px; }

/* ---------- 最新版本卡 ---------- */
.release-card {
  position: relative;
  overflow: hidden;
  padding: 26px;
  border-radius: var(--radius-lg);
  background: linear-gradient(160deg, #FFFDF7 0%, #FFF9EA 100%);
  border: 1px solid rgba(192, 132, 42, .28);
  box-shadow: var(--shadow-lg), inset 0 1px 0 #fff;
}
.release-card::before {
  content: "";
  position: absolute;
  right: -70px;
  top: -90px;
  width: 230px;
  height: 230px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(217, 160, 63, .22), transparent 68%);
  pointer-events: none;
}
.release-top {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}
.release-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  height: 27px;
  padding: 0 11px;
  border-radius: 999px;
  background: var(--brand-deep);
  color: #FFF8E7;
  font-size: 11.5px;
  font-weight: 700;
  letter-spacing: .04em;
}
.release-badge .icon { font-size: 13px; }
.release-date { font-size: 12px; color: var(--on-surface-muted); }
.release-product {
  position: relative;
  display: flex;
  align-items: center;
  gap: 13px;
  margin-top: 20px;
}
.release-icon {
  width: 56px;
  height: 56px;
  border-radius: 16px;
  display: grid;
  place-items: center;
  background: #FFFCF2;
  border: 1px solid rgba(192, 132, 42, .22);
  box-shadow: inset 0 1px 0 #fff, 0 8px 18px -12px rgba(120, 95, 30, .45);
  flex: none;
}
.release-icon img { width: 40px; height: 40px; object-fit: contain; }
.release-title strong { display: block; font-size: 20px; font-weight: 900; letter-spacing: -.02em; }
.release-title span { display: block; margin-top: 2px; font-size: 11.5px; font-weight: 600; letter-spacing: .04em; color: var(--brand-strong); }
.release-version {
  position: relative;
  display: flex;
  align-items: baseline;
  gap: 12px;
  margin-top: 18px;
}
.release-v { font-size: 38px; font-weight: 900; letter-spacing: -.035em; line-height: 1; color: var(--on-surface); }
.release-build {
  padding: 3px 9px;
  border-radius: 999px;
  background: var(--surface-sunken);
  font-size: 11.5px;
  font-weight: 700;
  color: #6B5B37;
}
.release-card .btn-block { margin-top: 18px; height: 48px; }
.release-foot {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 7px;
  margin-top: 12px;
  font-size: 12px;
  color: var(--on-surface-muted);
}
.release-foot a { color: var(--brand-deep); font-weight: 700; }
.release-dot { width: 3px; height: 3px; border-radius: 50%; background: #C9BCA2; }
.release-qr {
  position: relative;
  display: flex;
  align-items: center;
  gap: 14px;
  margin-top: 20px;
  padding-top: 18px;
  border-top: 1px dashed rgba(31, 26, 17, .14);
}
.release-qr img {
  width: 108px;
  height: 108px;
  padding: 8px;
  border-radius: 14px;
  background: #fff;
  border: 1px solid var(--line);
  flex: none;
}
.release-qr strong { display: block; font-size: 13px; font-weight: 800; }
.release-qr span { display: block; margin-top: 3px; font-size: 11.5px; color: var(--on-surface-muted); }

/* ---------- 保障条 ---------- */
.dl-trust { padding: 10px 0 0; }
.trust-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 0;
  padding: 20px 8px;
  border-radius: var(--radius);
  background: rgba(255, 253, 247, .78);
  border: 1px solid var(--line);
  box-shadow: var(--shadow-sm);
  backdrop-filter: blur(8px);
}
.trust-grid li {
  display: flex;
  align-items: flex-start;
  gap: 11px;
  padding: 4px 18px;
}
.trust-grid li + li { border-left: 1px solid var(--line); }
.trust-icon {
  flex: none;
  width: 34px;
  height: 34px;
  border-radius: 10px;
  display: grid;
  place-items: center;
  background: rgba(217, 160, 63, .14);
  color: var(--brand-deep);
}
.trust-icon .icon { font-size: 17px; }
.trust-grid strong { display: block; font-size: 13.5px; font-weight: 800; }
.trust-grid span { display: block; margin-top: 2px; font-size: 11.5px; color: var(--on-surface-muted); line-height: 1.45; }

/* ---------- 下载目录 ---------- */
.dl-section { padding-top: 78px; }
.dl-head {
  max-width: none;
  display: flex;
  flex-wrap: wrap;
  align-items: flex-end;
  justify-content: space-between;
  gap: 22px 32px;
  margin-bottom: 0;
}
.dl-head .section-head { margin-bottom: 0; }
.dl-head .section-desc { max-width: 620px; }
.filter-bar { display: flex; flex-wrap: wrap; gap: 7px; }
.filter-chip {
  height: 34px;
  padding: 0 14px;
  border-radius: 999px;
  border: 1px solid var(--line-strong);
  background: rgba(255, 253, 247, .6);
  color: var(--on-surface-muted);
  font-size: 12.5px;
  font-weight: 700;
  transition: all .2s ease;
}
.filter-chip:hover { border-color: rgba(192, 132, 42, .45); color: var(--on-surface); }
.filter-chip.is-active {
  background: var(--brand-deep);
  border-color: var(--brand-deep);
  color: #FFF8E7;
  box-shadow: 0 6px 14px -10px rgba(80, 55, 10, .7);
}

.dl-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 20px;
  margin-top: 34px;
}
.dl-card {
  position: relative;
  display: flex;
  flex-direction: column;
  padding: 24px;
  border-radius: var(--radius);
  background: var(--surface-raised);
  border: 1px solid var(--line);
  box-shadow: var(--shadow-sm);
  transition: transform .35s var(--ease), box-shadow .35s var(--ease), border-color .35s ease;
}
.dl-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-md);
  border-color: rgba(192, 132, 42, .32);
}
.dl-card.is-internal { background: linear-gradient(170deg, #FFFDF7 0%, #FBF6E9 100%); }
.dl-card[hidden] { display: none; }
.dl-card-top { display: flex; align-items: flex-start; gap: 11px; }
.dl-icon {
  flex: none;
  width: 44px;
  height: 44px;
  border-radius: 13px;
  display: grid;
  place-items: center;
  background: linear-gradient(150deg, #FBEED3, #F1DCA9);
  border: 1px solid rgba(192, 132, 42, .2);
  color: var(--brand-deep);
}
.dl-icon .icon { font-size: 21px; }
.dl-card.is-internal .dl-icon {
  background: linear-gradient(150deg, #F3EDDF, #EADFC7);
  color: #6E5A31;
}
.dl-name { min-width: 0; padding-top: 1px; }
.dl-name h3 { font-size: 17.5px; font-weight: 800; letter-spacing: -.01em; line-height: 1.25; }
.dl-name span {
  display: block;
  margin-top: 1px;
  font-size: 10px;
  font-weight: 700;
  letter-spacing: .12em;
  text-transform: uppercase;
  color: var(--brand-strong);
}
.dl-badge {
  flex: none;
  margin-left: auto;
  padding: 3px 8px;
  border-radius: 999px;
  font-size: 10.5px;
  font-weight: 700;
  white-space: nowrap;
}
.dl-badge.is-hot { background: rgba(192, 132, 42, .16); color: var(--brand-deep); }
.dl-badge.is-stable { background: rgba(64, 145, 88, .12); color: #2F6B42; }
.dl-badge.is-dev { background: rgba(74, 104, 168, .12); color: #3F5C94; }
.dl-badge.is-web { background: rgba(46, 122, 118, .12); color: #246B67; }
.dl-badge.is-internal { background: rgba(31, 26, 17, .07); color: #6E6455; }
.dl-desc {
  margin-top: 14px;
  font-size: 13.5px;
  line-height: 1.65;
  color: var(--on-surface-muted);
}
.dl-tags { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 14px; }
.dl-tags li {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 3px 9px;
  border-radius: 999px;
  background: var(--surface-sunken);
  font-size: 11px;
  font-weight: 600;
  color: #6B5B37;
}
.dl-tags .icon { font-size: 12px; color: var(--brand-strong); }
.dl-meta {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 4px 10px;
  margin-top: 14px;
  padding-top: 12px;
  border-top: 1px solid var(--line);
  font-size: 11px;
  color: var(--on-surface-muted);
}
.dl-hash {
  max-width: 190px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-size: 10px;
}
.dl-card-foot {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 9px;
  margin-top: auto;
  padding-top: 16px;
}
.dl-card-foot .link-arrow { margin-left: auto; font-size: 12.5px; }
.dl-card-foot .btn { height: 36px; padding: 0 14px; font-size: 12.5px; }
.dl-card-foot .btn .icon { font-size: 14px; }

.dl-grid-note {
  display: flex;
  align-items: flex-start;
  gap: 8px;
  margin-top: 20px;
  font-size: 12px;
  color: var(--on-surface-muted);
}
.dl-grid-note .icon { flex: none; margin-top: 2px; color: var(--brand-strong); font-size: 14px; }

/* ---------- 版本动态 ---------- */
.dl-updates { padding-top: 0; }
.update-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 20px; }
.update-card {
  display: flex;
  flex-direction: column;
  padding: 26px;
  border-radius: var(--radius);
  background: var(--surface-raised);
  border: 1px solid var(--line);
  box-shadow: var(--shadow-sm);
  transition: transform .35s var(--ease), box-shadow .35s var(--ease), border-color .35s ease;
}
.update-card:hover { transform: translateY(-3px); box-shadow: var(--shadow-md); border-color: rgba(192, 132, 42, .28); }
.update-head { display: flex; align-items: flex-start; gap: 12px; }
.update-icon {
  flex: none;
  width: 40px;
  height: 40px;
  border-radius: 12px;
  display: grid;
  place-items: center;
  background: rgba(217, 160, 63, .15);
  color: var(--brand-deep);
}
.update-icon .icon { font-size: 19px; }
.update-head h3 { font-size: 16.5px; font-weight: 800; letter-spacing: -.01em; }
.update-ver {
  margin-left: 6px;
  font-size: 12px;
  font-weight: 700;
  color: var(--brand-strong);
}
.update-date { display: block; margin-top: 3px; font-size: 11.5px; color: var(--on-surface-muted); }
.update-notes {
  margin-top: 16px;
  padding: 14px 15px;
  border-radius: 12px;
  background: var(--surface);
  border: 1px solid var(--line);
  font-size: 13px;
  line-height: 1.7;
  color: var(--on-surface-muted);
  overflow-wrap: anywhere;
}
.update-foot {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  margin-top: 16px;
  font-size: 11.5px;
  color: var(--on-surface-muted);
}
.update-foot .link-arrow { margin-left: auto; font-size: 12.5px; }

/* ---------- 安装帮助 ---------- */
.dl-guide { padding-top: 0; }
.guide-shell {
  overflow: hidden;
  border-radius: var(--radius-lg);
  background: var(--surface-raised);
  border: 1px solid var(--line);
  box-shadow: var(--shadow-sm);
}
.guide-tabs {
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
  padding: 10px;
  border-bottom: 1px solid var(--line);
  background: rgba(242, 232, 211, .42);
}
.guide-tab {
  height: 38px;
  padding: 0 18px;
  border-radius: 10px;
  font-size: 13px;
  font-weight: 700;
  color: var(--on-surface-muted);
  transition: background .2s ease, color .2s ease, box-shadow .2s ease;
}
.guide-tab:hover { color: var(--on-surface); background: rgba(255, 253, 247, .8); }
.guide-tab.is-active {
  background: var(--surface-raised);
  color: var(--brand-deep);
  box-shadow: var(--shadow-sm);
}
.guide-panel { padding: 30px 32px 32px; }
.guide-panel[hidden] { display: none; }
.steps { display: grid; gap: 22px; }
.steps > li { display: grid; grid-template-columns: 34px minmax(0, 1fr); gap: 14px; align-items: start; }
.step-num {
  width: 34px;
  height: 34px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  background: linear-gradient(150deg, #FBEED3, #F1DCA9);
  border: 1px solid rgba(192, 132, 42, .24);
  font-size: 13px;
  font-weight: 800;
  color: var(--brand-deep);
}
.steps h3 { font-size: 15px; font-weight: 800; }
.steps p { margin-top: 4px; font-size: 13.5px; color: var(--on-surface-muted); }
.guide-note {
  display: flex;
  align-items: flex-start;
  gap: 9px;
  margin-top: 24px;
  padding: 13px 15px;
  border-radius: 12px;
  background: #FFF8E9;
  border: 1px solid #F0E1C2;
  font-size: 12px;
  line-height: 1.6;
  color: #6B5A2E;
}
.guide-note .icon { flex: none; margin-top: 2px; font-size: 15px; color: var(--brand-strong); }
.guide-note code { font-family: ui-monospace, Menlo, Consolas, monospace; }

.inline-code {
  padding: 1px 6px;
  border-radius: 6px;
  background: var(--surface-sunken);
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-size: .92em;
  color: var(--brand-deep);
  word-break: break-all;
}

.code-block {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-top: 10px;
  padding: 11px 12px 11px 15px;
  border-radius: 12px;
  background: #201B13;
  border: 1px solid #33291A;
  color: #F6E7C4;
  overflow: hidden;
}
.code-block code {
  flex: 1;
  min-width: 0;
  overflow-x: auto;
  white-space: nowrap;
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-size: 12px;
  line-height: 1.7;
  scrollbar-width: thin;
}
.copy-btn {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  flex: none;
  height: 30px;
  padding: 0 10px;
  border-radius: 8px;
  border: 1px solid rgba(246, 231, 196, .26);
  color: #F6E7C4;
  font-size: 11.5px;
  font-weight: 700;
  transition: background .2s ease, border-color .2s ease;
}
.copy-btn:hover { background: rgba(246, 231, 196, .1); border-color: rgba(246, 231, 196, .45); }
.copy-btn.is-done { background: rgba(120, 160, 90, .24); border-color: rgba(150, 195, 110, .5); }
.copy-btn .icon { font-size: 13px; }

.verify-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 28px; }
.verify-grid h3 { font-size: 15px; font-weight: 800; }
.verify-grid p { margin-top: 6px; font-size: 13px; color: var(--on-surface-muted); }
.verify-hash { margin-top: 14px; word-break: break-all; }
.verify-hash code { font-size: 11px; line-height: 1.7; }
.verify-hash .link-arrow { font-size: 12.5px; }

/* ---------- FAQ ---------- */
.dl-faq { padding-top: 0; }
.faq-list { display: grid; gap: 10px; max-width: 940px; }
.faq-item {
  border-radius: 16px;
  background: var(--surface-raised);
  border: 1px solid var(--line);
  box-shadow: var(--shadow-sm);
  transition: border-color .25s ease, box-shadow .25s ease;
}
.faq-item:hover { border-color: rgba(192, 132, 42, .3); box-shadow: 0 10px 24px -18px rgba(88, 68, 26, .5); }
.faq-item summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 18px 22px;
  cursor: pointer;
  list-style: none;
  font-size: 14.5px;
  font-weight: 700;
}
.faq-item summary::-webkit-details-marker { display: none; }
.faq-item summary .icon { flex: none; font-size: 17px; color: var(--brand-strong); transition: transform .25s var(--ease); }
.faq-item[open] summary .icon { transform: rotate(180deg); }
.faq-item p {
  padding: 0 22px 20px;
  font-size: 13.5px;
  line-height: 1.75;
  color: var(--on-surface-muted);
}
.faq-item p a { color: var(--brand-deep); font-weight: 700; text-decoration: underline; text-underline-offset: 3px; }

/* ---------- 响应式 ---------- */
@media (max-width: 1080px) {
  .dl-hero-grid { grid-template-columns: 1fr; gap: 34px; }
  .dl-hero .lead { max-width: 680px; }
  .release-card { max-width: 560px; }
  .trust-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px 0; padding: 18px 8px; }
  .trust-grid li:nth-child(3) { border-left: 0; }
  .dl-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

@media (max-width: 860px) {
  .dl-hero { padding-top: 42px; }
  .dl-hero h1 { font-size: clamp(32px, 8vw, 44px); }
  .dl-hero .lead { max-width: none; }
  .dl-grid { grid-template-columns: 1fr; }
  .update-grid { grid-template-columns: 1fr; }
  .verify-grid { grid-template-columns: 1fr; gap: 22px; }
  .dl-head { align-items: flex-start; }
  .filter-bar { width: 100%; }
  .trust-grid { grid-template-columns: 1fr; }
  .trust-grid li + li { border-left: 0; border-top: 1px solid var(--line); padding-top: 12px; margin-top: 2px; }
  .guide-panel { padding: 24px; }
}

@media (max-width: 620px) {
  .nav-actions .btn-outline,
  .nav-actions .btn-primary { display: none; }
  .dl-hero { padding: 32px 0 20px; }
  .dl-hero .lead { font-size: 14.5px; }
  .dl-hero .hero-cta .btn { flex: 1 1 46%; padding: 0 14px; }
  .dl-domains code { font-size: 10px; }
  .release-card { padding: 20px; border-radius: 22px; }
  .release-v { font-size: 32px; }
  .release-qr img { width: 96px; height: 96px; }
  .dl-card, .update-card { padding: 20px; }
  .dl-card-foot .link-arrow { margin-left: 0; }
  .dl-hash { max-width: 100%; }
  .filter-bar { gap: 6px; }
  .filter-chip { height: 32px; padding: 0 12px; font-size: 12px; }
  .guide-tabs { flex-wrap: nowrap; overflow-x: auto; }
  .guide-tab { flex: none; padding: 0 14px; }
  .guide-panel { padding: 20px 18px 24px; }
  .steps > li { grid-template-columns: 30px minmax(0, 1fr); gap: 11px; }
  .step-num { width: 30px; height: 30px; font-size: 12px; }
  .code-block { padding: 10px; }
  .copy-btn span { display: none; }
  .copy-btn { padding: 0 8px; }
  .faq-item summary { padding: 16px 18px; font-size: 13.5px; }
  .faq-item p { padding: 0 18px 18px; }
}
