/* =========================================================
   雨后初晴 - Pages Layer
   Hero / 软件栅格 / 注册 / 结果 / 支付 / 成功 / 详情 / 404
   ========================================================= */

/* ============ Hero 卡片 ============ */
.hero {
  /* main#main-content 已全局避让导航高度，这里只补呼吸间距 */
  margin-top: 24px;
  position: relative;
}
.hero-card {
  position: relative;
  height: 340px;
  border-radius: var(--radius-card);
  background: var(--color-primary-gradient);
  overflow: hidden;
  box-shadow: 0 12px 48px rgba(79,124,255,0.25);
  animation: hero-breath 8s ease-in-out infinite;
  display: flex;
  align-items: center;
  padding: 0 64px;
}
@keyframes hero-breath {
  0%, 100% { opacity: 0.9; box-shadow: 0 12px 48px rgba(79,124,255,0.25); }
  50% { opacity: 1; box-shadow: 0 16px 56px rgba(79,124,255,0.35); }
}

.hero-bg-deco {
  position: absolute;
  inset: 0;
  pointer-events: none;
  overflow: hidden;
}
.hero-bg-deco::before {
  content: '';
  position: absolute;
  top: -40%;
  right: -10%;
  width: 600px;
  height: 600px;
  background: radial-gradient(circle, rgba(255,255,255,0.15) 0%, transparent 70%);
  border-radius: 50%;
}
.hero-bg-deco::after {
  content: '';
  position: absolute;
  bottom: -50%;
  left: -20%;
  width: 400px;
  height: 400px;
  background: radial-gradient(circle, rgba(255,255,255,0.1) 0%, transparent 70%);
  border-radius: 50%;
}

.hero-content {
  position: relative;
  z-index: 2;
  color: white;
  max-width: 560px;
}
.hero-content .hero-icon {
  font-size: 32px;
  margin-bottom: 8px;
  display: block;
}
.hero-content h1 {
  font-size: 42px;
  margin-bottom: 12px;
  letter-spacing: -0.5px;
}
.hero-content .hero-sub {
  font-size: 18px;
  opacity: 0.85;
  margin-bottom: 24px;
  font-weight: 400;
}
.hero-content .hero-desc {
  font-size: 14px;
  opacity: 0.7;
  margin-bottom: 32px;
}
.hero-buttons { display: flex; gap: 12px; flex-wrap: wrap; }
.hero-buttons .btn-primary { background: white; color: var(--color-primary); }
.hero-buttons .btn-primary:hover { background: #f0f0ff; }
.hero-buttons .btn-secondary { border-color: rgba(255,255,255,0.6); color: white; background: transparent; }
.hero-buttons .btn-secondary:hover { background: rgba(255,255,255,0.1); }

.hero-visual {
  position: absolute;
  right: 64px;
  top: 50%;
  transform: translateY(-50%);
  width: 400px;
  height: 270px;
  border-radius: 14px;
  border: 1px solid rgba(255,255,255,0.2);
  z-index: 2;
  overflow: hidden;
  /* 提升层级以便接收焦点 */
  outline: none;
}
.hero-visual:focus-visible { box-shadow: 0 0 0 3px rgba(255,255,255,0.5); }

/* Carousel track：横向排列三张 slide */
.carousel-track {
  display: flex;
  width: 300%;           /* 3 张各占 100% */
  height: 100%;
  transition: transform 0.55s cubic-bezier(.22,.9,.32,1);
}
.carousel-slide {
  flex: 0 0 33.3333%;
  height: 100%;
  background: rgba(255,255,255,0.98);
  border-radius: inherit;
  overflow: hidden;
  color: #2c3e5c;
  display: flex;
  flex-direction: column;
}
.carousel-slide .window-bar {
  flex-shrink: 0;
  height: 30px;
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 0 10px;
  background: linear-gradient(180deg, #f4f6fa, #e8ecf3);
  border-bottom: 1px solid #dfe4ec;
}
.carousel-slide .window-bar .dot {
  width: 10px; height: 10px; border-radius: 50%;
}
.carousel-slide .window-bar .dot.close    { background: #FF5F56; }
.carousel-slide .window-bar .dot.minimize { background: #FFBD2E; }
.carousel-slide .window-bar .dot.maximize { background: #27C93F; }
.carousel-slide .window-bar .win-title {
  flex: 1;
  text-align: center;
  font-size: 11px;
  color: #8a94a6;
  font-weight: 500;
}
.carousel-slide .canvas-area {
  flex: 1;
  position: relative;
  padding: 12px;
  background:
    linear-gradient(180deg, #fbfcfe 0%, #f4f6fb 100%);
  overflow: hidden;
}

/* ----- Slide 内部 mock ----- */
/* 通用 drawing canvas */
.drawing-canvas { width: 100%; height: 100%; position: relative; }

/* Slide 0：工程图 + 工具栏 */
.d-toolbar {
  display: flex; gap: 4px;
  padding: 4px 6px;
  background: #fff;
  border: 1px solid #e2e7ef;
  border-radius: 6px;
  box-shadow: 0 1px 2px rgba(0,0,0,0.04);
  margin-bottom: 8px;
}
.d-toolbar .d-tool {
  width: 24px; height: 24px;
  display: flex; align-items: center; justify-content: center;
  border-radius: 4px;
  font-size: 14px;
  color: #6b7a8f;
  cursor: default;
  transition: background .15s, color .15s;
}
.d-toolbar .d-tool.active { background: #E8EFFF; color: #4F7CFF; }
.d-svg {
  width: 100%;
  height: calc(100% - 40px);
  color: #4F7CFF;
}

/* Slide 1：多光标协作 */
.d-collab { position: absolute; inset: 0; pointer-events: none; }
.d-cursor {
  position: absolute;
  transform: translate(-4px, -10px);
  font-size: 11px;
  font-weight: 600;
  color: var(--cur, #4F7CFF);
  background: var(--cur, #4F7CFF);
  color: white;
  padding: 1px 5px;
  border-radius: 3px;
  opacity: 0.9;
  animation: cursor-blink 2.2s ease-in-out infinite;
}
@keyframes cursor-blink {
  0%, 100% { opacity: 0.9; }
  50%      { opacity: 0.4; }
}
.d-cursor::before {
  content: '';
  position: absolute;
  top: -8px; left: 0;
  width: 0; height: 0;
  border-left: 4px solid var(--cur, #4F7CFF);
  border-top: 8px solid var(--cur, #4F7CFF);
  border-right: 4px solid transparent;
  border-bottom: 0 solid transparent;
  transform: rotate(225deg);
  transform-origin: top left;
}

/* Slide 2：导出列表 */
.d-export-list {
  display: flex; flex-direction: column; gap: 6px;
  padding: 6px 0;
}
.d-export-item {
  display: flex; align-items: center; gap: 10px;
  padding: 8px 10px;
  background: #fff;
  border: 1px solid #e2e7ef;
  border-radius: 6px;
  font-size: 12px;
  color: #2c3e5c;
}
.d-export-item span:nth-child(2) { flex: 1; font-family: var(--font-mono); }
.d-export-ico {
  width: 24px; height: 24px;
  display: flex; align-items: center; justify-content: center;
  border-radius: 4px;
  font-size: 13px;
}
.d-export-ico.pdf { background: #FFECEC; }
.d-export-ico.img { background: #E6F4FF; }
.d-export-ico.dxf { background: #E8FFF0; }
.d-export-status { font-size: 11px; color: #52C41A; font-weight: 500; }
.d-export-status.load { color: #4F7CFF; }

/* Slide 底部 caption */
.d-slide-caption {
  position: absolute;
  left: 0; right: 0; bottom: 0;
  display: flex; align-items: baseline; gap: 8px;
  padding: 8px 12px;
  background: linear-gradient(180deg, transparent, rgba(0,0,0,0.03));
  font-size: 12px;
  color: #6b7a8f;
}
.d-slide-caption strong {
  color: var(--color-primary);
  font-size: 13px;
  font-weight: 600;
}

/* ----- Carousel 箭头 ----- */
.carousel-arrow {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: rgba(255,255,255,0.9);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  border: 1px solid rgba(255,255,255,0.6);
  color: var(--text-primary);
  font-size: 18px;
  line-height: 1;
  cursor: pointer;
  z-index: 3;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 2px 8px rgba(0,0,0,0.15);
  transition: background .2s, transform .15s, opacity .2s;
  opacity: 0;
  pointer-events: none;
}
.hero-visual:hover .carousel-arrow,
.hero-visual:focus-within .carousel-arrow {
  opacity: 1;
  pointer-events: auto;
}
.carousel-arrow:hover { background: white; transform: translateY(-50%) scale(1.08); }
.carousel-arrow:active { transform: translateY(-50%) scale(0.94); }
.carousel-prev { left: -4px; }
.carousel-next { right: -4px; }

/* ----- Carousel 指示点 ----- */
.carousel-dots {
  position: absolute;
  bottom: 8px;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  gap: 6px;
  z-index: 3;
}
.carousel-dot {
  width: 7px; height: 7px;
  border-radius: 50%;
  border: none;
  background: rgba(255,255,255,0.6);
  cursor: pointer;
  padding: 0;
  transition: width .3s, background .3s;
  box-shadow: 0 1px 3px rgba(0,0,0,0.1);
}
.carousel-dot.active {
  width: 18px;
  border-radius: 4px;
  background: white;
  box-shadow: 0 1px 4px rgba(0,0,0,0.18);
}

/* ============ 软件作品集 ============ */
.portfolio {
  margin-top: 48px;
}
.portfolio-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 24px;
}
.portfolio-header h2 {
  font-size: 24px;
  display: flex;
  align-items: center;
  gap: 8px;
}
.portfolio-count {
  font-size: 15px;
  color: var(--text-secondary);
  font-weight: 400;
}

/* 软件卡片网格 */
.software-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 20px;
}

.software-card {
  background: var(--bg-card);
  border-radius: var(--radius-card);
  padding: 24px;
  box-shadow: var(--shadow-card);
  border: 1px solid var(--border-light);
  transition: box-shadow .25s, border-color .25s, transform .2s;
  cursor: pointer;
  position: relative;
  overflow: hidden;
  opacity: 0;
  transform: translateY(12px);
  animation: card-in 0.4s var(--ease-out) forwards;
}
@keyframes card-in {
  to { opacity: 1; transform: translateY(0); }
}

/* hover 增强层（基础样式，3D 倾斜由 JS 动态控制） */
.software-card.is-hovered {
  border-color: rgba(79, 124, 255, 0.2);
  box-shadow: 0 20px 48px rgba(79, 124, 255, 0.18);
}

/* cursor-follow 光晕层 */
.software-card .card-glow {
  position: absolute;
  inset: 0;
  border-radius: inherit;
  pointer-events: none;           /* 不挡点击 */
  opacity: 0;
  transition: opacity .4s var(--ease-out);
  background: radial-gradient(
    circle 180px at var(--glow-x, 50%) var(--glow-y, 50%),
    rgba(79, 124, 255, 0.12) 0%,
    rgba(79, 124, 255, 0.05) 40%,
    transparent 70%
  );
  z-index: 0;
}
.software-card.is-hovered .card-glow { opacity: 1; }

/* 卡片内所有元素层级提升到光晕之上 */
.software-card > * { position: relative; z-index: 1; }

/* 卡片底部分割线 + 渐变描边（hover 时出现） */
.software-card::before {
  content: '';
  position: absolute;
  inset: 0;
  border-radius: inherit;
  padding: 1px;
  background: linear-gradient(135deg, rgba(79,124,255,0.5), rgba(123,159,255,0));
  -webkit-mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
  -webkit-mask-composite: xor;
          mask-composite: exclude;
  opacity: 0;
  transition: opacity .3s var(--ease-out);
  pointer-events: none;
  z-index: 2;
}
.software-card.is-hovered::before { opacity: 1; }

.software-card .card-icon {
  width: 64px;
  height: 64px;
  border-radius: 14px;
  position: relative;
  /* 渐变底：深 → 浅，比 --icon-l 深 5% 作为底，浅 8% 作为顶 */
  background:
    linear-gradient(145deg,
      hsl(var(--icon-h,210) var(--icon-s,75) calc(var(--icon-l,58) - 10%)) 0%,
      hsl(var(--icon-h,210) var(--icon-s,75) calc(var(--icon-l,58) - 2%)) 55%,
      hsl(var(--icon-h,210) var(--icon-s,65) calc(var(--icon-l,58) + 12%)) 100%);
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 16px;
  transition: transform .3s var(--ease-out), box-shadow .3s var(--ease-out);
  /* 分层外投影：近处实 + 远处柔 */
  box-shadow:
    0 2px 4px  rgba(0,0,0,0.18),
    0 8px 18px hsl(var(--icon-h,210) var(--icon-s,75) calc(var(--icon-l,58) - 15%) / 0.35);
  overflow: hidden;
}

/* emoji/文字包一层，确保在高光/阴影伪元素之上 */
.software-card .card-icon .icon-emoji {
  position: relative;
  z-index: 1;
  font-size: 28px;
  color: white;
  /* icon 本身投影（emoji 看起来更实） */
  text-shadow: 0 1px 2px rgba(0,0,0,0.25), 0 0 0.5px rgba(255,255,255,0.15);
  line-height: 1;
}

/* 内高光覆盖层：左上角亮、右下暗的整体渐变，配合底纹制造"光照立体感" */
.software-card .card-icon::before {
  content: '';
  position: absolute;
  inset: 0;
  border-radius: inherit;
  background: linear-gradient(135deg,
    rgba(255,255,255,0.50) 0%,
    rgba(255,255,255,0.18) 30%,
    rgba(255,255,255,0) 65%);
  pointer-events: none;
}

/* 底部内阴影：模拟底边凹陷感 */
.software-card .card-icon::after {
  content: '';
  position: absolute;
  inset: 0;
  border-radius: inherit;
  box-shadow: inset 0 -3px 6px rgba(0,0,0,0.18),
              inset 0 2px 0 rgba(255,255,255,0.08);
  pointer-events: none;
}

.software-card.is-hovered .card-icon {
  transform: rotate(3deg) scale(1.08) translateZ(20px);
  box-shadow:
    0 4px 8px  rgba(0,0,0,0.22),
    0 14px 32px hsl(var(--icon-h,210) var(--icon-s,75) calc(var(--icon-l,58) - 15%) / 0.55);
}
.software-card.is-hovered .card-icon .icon-emoji {
  text-shadow: 0 2px 4px rgba(0,0,0,0.3), 0 0 1px rgba(255,255,255,0.2);
}

.software-card .card-title {
  font-size: 18px;
  font-weight: 600;
  margin-bottom: 6px;
  color: var(--text-primary);
  transition: color .2s var(--ease-out);
}
.software-card.is-hovered .card-title { color: var(--color-primary); }

.software-card .card-tags {
  display: flex;
  gap: 4px;
  flex-wrap: wrap;
  margin-bottom: 10px;
}
.software-card .card-desc {
  font-size: 14px;
  color: var(--text-secondary);
  line-height: 1.5;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  margin-bottom: 16px;
  min-height: 42px;
}
.software-card .card-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  transition: transform .3s var(--ease-out);
}
.software-card.is-hovered .card-footer { transform: translateZ(10px); }

.card-price {
  font-size: 14px;
  font-weight: 600;
  padding: 4px 10px;
  border-radius: 8px;
  transition: transform .2s var(--ease-out);
}
.software-card.is-hovered .card-price { transform: scale(1.05); }
.card-price.free { background: var(--color-success-soft); color: var(--color-success); }
.card-price.paid { background: var(--color-danger-soft); color: var(--color-danger); }
.card-arrow {
  font-size: 13px;
  color: var(--color-primary);
  font-weight: 500;
  transition: transform .25s var(--ease-out), letter-spacing .25s;
}
.software-card.is-hovered .card-arrow {
  transform: translateX(6px);
  letter-spacing: 1px;
}

/* ============ 注册流程通用样式 ============ */
.register-hero {
  text-align: center;
  padding: 40px 0 32px;
}
.register-hero .big-icon {
  font-size: 64px;
  margin-bottom: 16px;
  display: inline-block;
}
.register-hero h1 { font-size: 36px; margin-bottom: 8px; }
.register-hero p { font-size: 16px; color: var(--text-secondary); }

/* ============ 错误状态卡片 ============ */
.error-card {
  background: white;
  border-radius: var(--radius-card);
  padding: 32px;
  box-shadow: var(--shadow-card);
  text-align: center;
  margin-top: 24px;
}
.error-card .error-icon {
  font-size: 48px;
  margin-bottom: 16px;
}
.error-card h2 {
  font-size: 22px;
  margin-bottom: 16px;
  color: var(--color-danger);
}
.error-card ol, .error-card ul {
  text-align: left;
  max-width: 440px;
  margin: 0 auto 20px;
  font-size: 14px;
  color: var(--text-secondary);
}
.error-card ol li { margin-bottom: 6px; padding-left: 4px; }
.error-card .error-actions {
  display: flex;
  justify-content: center;
  gap: 12px;
  flex-wrap: wrap;
}
.error-card .error-hint {
  margin-top: 24px;
  padding-top: 16px;
  border-top: 1px solid var(--border-light);
  font-size: 13px;
  color: var(--text-tertiary);
}

/* ============ 成功页 / 授权码结果页 ============ */
.success-icon {
  font-size: 64px;
  animation: success-bounce 0.5s var(--ease-bounce);
  display: inline-block;
  margin-bottom: 12px;
}
@keyframes success-bounce {
  0% { transform: scale(0); }
  50% { transform: scale(1.3); }
  100% { transform: scale(1); }
}

.license-info {
  background: var(--color-primary-soft);
  border-radius: var(--radius-card);
  padding: 20px 24px;
  margin: 20px 0;
}
.license-info .info-row {
  display: flex;
  gap: 10px;
  font-size: 14px;
  padding: 4px 0;
}
.license-info .info-row .info-label {
  color: var(--text-secondary);
  min-width: 80px;
}
.license-info .info-row .info-value {
  color: var(--text-primary);
  font-weight: 500;
  word-break: break-all;
}

/* ============ 授权码卡片 ============ */
.regcode-card {
  background: white;
  border-radius: var(--radius-card);
  padding: 28px;
  box-shadow: var(--shadow-card);
  margin-top: 20px;
  position: relative;
  overflow: hidden;
}
.regcode-card .confidential-watermark {
  position: absolute;
  inset: 0;
  pointer-events: none;
  opacity: 0.12;
  z-index: 0;
  overflow: hidden;
}
.regcode-card .confidential-watermark::before {
  content: 'Confidential  Confidential  Confidential  Confidential  Confidential  Confidential  ';
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%) rotate(-30deg);
  font-size: 28px;
  font-weight: 700;
  color: var(--text-primary);
  white-space: nowrap;
  width: 200%;
  letter-spacing: 20px;
}

.regcode-header {
  position: relative;
  z-index: 1;
  font-size: 16px;
  font-weight: 600;
  margin-bottom: 16px;
  display: flex;
  align-items: center;
  gap: 8px;
}

.regcode-display {
  position: relative;
  z-index: 1;
  background: var(--border-light);
  border-radius: 12px;
  padding: 20px;
  overflow-x: auto;
  margin-bottom: 16px;
  scroll-behavior: smooth;
}
.regcode-display::-webkit-scrollbar {
  height: 6px;
}
.regcode-display::-webkit-scrollbar-thumb {
  background: var(--border);
  border-radius: 3px;
}
.regcode-text {
  font-family: var(--font-mono);
  font-size: 16px;
  letter-spacing: 1px;
  color: var(--text-primary);
  white-space: pre;
  line-height: 1.8;
  min-width: max-content;
}
.regcode-text .seg {
  display: inline-block;
  opacity: 0;
  transform: translateY(6px);
  animation: seg-in 0.3s var(--ease-out) forwards;
}
.regcode-text .seg.revealed {
  opacity: 1;
  transform: translateY(0);
}
@keyframes seg-in {
  to { opacity: 1; transform: translateY(0); }
}

.regcode-actions {
  position: relative;
  z-index: 1;
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
}
.regcode-hint {
  position: relative;
  z-index: 1;
  margin-top: 16px;
  padding-top: 16px;
  border-top: 1px solid var(--border-light);
  font-size: 13px;
  color: var(--text-tertiary);
  line-height: 1.6;
}

/* ============ 付款确认 ============ */
.order-confirm {
  background: white;
  border-radius: var(--radius-card);
  padding: 24px 28px;
  box-shadow: var(--shadow-card);
  margin-top: 16px;
}
.order-confirm h3 {
  font-size: 18px;
  margin-bottom: 16px;
}
.order-row {
  display: flex;
  justify-content: space-between;
  padding: 8px 0;
  font-size: 15px;
}
.order-row .order-label { color: var(--text-secondary); }
.order-divider {
  border-top: 1px dashed var(--border);
  margin: 12px 0;
}
.order-total {
  display: flex;
  justify-content: space-between;
  padding-top: 12px;
  font-size: 18px;
  font-weight: 700;
}

/* 支付方式选择 */
.pay-methods {
  display: flex;
  gap: 16px;
  margin-top: 16px;
}
.pay-method-card {
  flex: 1;
  border: 2px solid var(--border);
  border-radius: var(--radius-card);
  padding: 20px;
  text-align: center;
  cursor: pointer;
  position: relative;
  transition: border-color .2s, box-shadow .2s;
  background: white;
}
.pay-method-card:hover { border-color: var(--color-primary); }
.pay-method-card.selected {
  border-color: var(--color-primary);
  box-shadow: var(--shadow-focus);
}
.pay-method-card .pay-icon {
  font-size: 32px;
  margin-bottom: 8px;
  display: block;
}
.pay-method-card .pay-name {
  font-size: 15px;
  font-weight: 600;
}
.pay-method-card .pay-check {
  position: absolute;
  top: 10px;
  left: 10px;
  width: 22px;
  height: 22px;
  background: var(--color-primary);
  color: white;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 14px;
  font-weight: 700;
}
.pay-method-card .pay-check.hidden { display: none; }

/* 二维码占位 */
.pay-qrcode-area {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
  padding: 16px 0;
}
.qr-box {
  width: 200px;
  height: 200px;
  border: 1px solid var(--border);
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: white;
  font-size: 12px;
  color: var(--text-tertiary);
  font-family: var(--font-mono);
  padding: 8px;
  text-align: center;
  line-height: 1.4;
}

/* ============ 详情页 ============ */
.detail-page .back-link {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  color: var(--text-secondary);
  font-size: 14px;
  font-weight: 500;
  text-decoration: none;
  margin-bottom: 20px;
  transition: color .2s;
}
.detail-page .back-link:hover { color: var(--color-primary); }
.detail-page .back-arrow {
  font-size: 16px;
  transition: transform .2s;
  display: inline-block;
}
.detail-page .back-link:hover .back-arrow { transform: translateX(-3px); }

/* 头部：icon 精细分层 + hero 渐变条底 */
.detail-header {
  display: flex;
  gap: 28px;
  align-items: center;
  padding: 28px 32px;
  border-radius: var(--radius-card);
  /* 渐变底：用软件的 iconColor */
  background:
    linear-gradient(135deg,
      hsl(var(--icon-h,210) var(--icon-s,75) calc(var(--icon-l,58) + 30%) / 0.12) 0%,
      hsl(var(--icon-h,210) var(--icon-s,75) calc(var(--icon-l,58) + 40%) / 0.04) 100%),
    white;
  border: 1px solid hsl(var(--icon-h,210) var(--icon-s,40) 70% / 0.2);
  box-shadow: 0 2px 12px rgba(0,0,0,0.04);
  margin-bottom: 36px;
  position: relative;
  overflow: hidden;
}
/* 头部右上角装饰光斑 */
.detail-header::before {
  content: '';
  position: absolute;
  top: -40px;
  right: -40px;
  width: 200px;
  height: 200px;
  border-radius: 50%;
  background: hsl(var(--icon-h,210) var(--icon-s,75) calc(var(--icon-l,58) * 1%) / 0.08);
  pointer-events: none;
}

/* 头部 icon：复用 home 的精细分层 */
.detail-icon {
  width: 96px;
  height: 96px;
  border-radius: 22px;
  flex-shrink: 0;
  position: relative;
  overflow: hidden;
  box-shadow:
    0 3px 6px rgba(0,0,0,0.18),
    0 10px 24px hsl(var(--icon-h,210) var(--icon-s,75) calc(var(--icon-l,58) - 15%) / 0.4);
}
.detail-icon-inner {
  width: 100%; height: 100%;
  background: linear-gradient(145deg,
    hsl(var(--icon-h,210) var(--icon-s,75) calc(var(--icon-l,58) - 10%)) 0%,
    hsl(var(--icon-h,210) var(--icon-s,75) calc(var(--icon-l,58) - 2%)) 55%,
    hsl(var(--icon-h,210) var(--icon-s,65) calc(var(--icon-l,58) + 12%)) 100%);
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
  border-radius: inherit;
}
/* 内高光 */
.detail-icon-inner::before {
  content: '';
  position: absolute;
  inset: 0;
  border-radius: inherit;
  background: linear-gradient(135deg,
    rgba(255,255,255,0.50) 0%,
    rgba(255,255,255,0.18) 30%,
    rgba(255,255,255,0) 65%);
  pointer-events: none;
}
/* 底部内阴影 */
.detail-icon-inner::after {
  content: '';
  position: absolute;
  inset: 0;
  border-radius: inherit;
  box-shadow: inset 0 -3px 6px rgba(0,0,0,0.18),
              inset 0 2px 0 rgba(255,255,255,0.08);
  pointer-events: none;
}
.detail-icon-emoji {
  position: relative;
  z-index: 1;
  font-size: 44px;
  line-height: 1;
  text-shadow: 0 1px 2px rgba(0,0,0,0.25), 0 0 0.5px rgba(255,255,255,0.15);
}

/* 头部右侧信息 */
.detail-info { flex: 1; min-width: 0; position: relative; z-index: 1; }
.detail-info-top {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 8px;
  flex-wrap: wrap;
}
.detail-info h1 {
  font-size: 28px;
  margin: 0;
  letter-spacing: -0.3px;
}
.detail-badge {
  font-size: 12px;
  font-weight: 600;
  padding: 3px 10px;
  border-radius: 20px;
  line-height: 1.4;
}
.detail-badge.badge-free {
  background: rgba(82,196,26,0.12);
  color: #389E0D;
  border: 1px solid rgba(82,196,26,0.25);
}
.detail-badge.badge-pro {
  background: hsl(var(--icon-h,210) var(--icon-s,75) calc(var(--icon-l,58) * 1%) / 0.12);
  color: hsl(var(--icon-h,210) 70% 42%);
  border: 1px solid hsl(var(--icon-h,210) var(--icon-s,60) 60% / 0.3);
}
.detail-desc {
  color: var(--text-secondary);
  font-size: 15px;
  margin-bottom: 14px;
  line-height: 1.5;
}
.detail-meta {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 12px;
  max-width: 560px;
}
.detail-meta-row {
  font-size: 13px;
  display: flex;
  flex-direction: column;
  gap: 2px;
}
.detail-meta-row .meta-label {
  color: var(--text-tertiary);
  font-size: 12px;
  font-weight: 500;
}
.detail-meta-row .meta-value {
  color: var(--text-primary);
  font-weight: 500;
}
.detail-meta-row .meta-value.meta-price {
  color: var(--color-primary);
  font-weight: 700;
}

/* section 通用 header */
.section-header {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  margin-bottom: 18px;
}
.section-header h2 {
  font-size: 22px;
  margin: 0;
  padding-bottom: 12px;
  border-bottom: 1px solid var(--border);
}
.download-count {
  font-size: 13px;
  color: var(--text-tertiary);
  font-weight: 500;
}

/* ========== 下载卡片（每 OS 一张独立卡片） ========== */
.download-section { margin-top: 36px; }
.download-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 14px;
}

.dl-card {
  background: white;
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 20px 18px;
  display: flex;
  flex-direction: column;
  gap: 6px;
  transition: border-color .2s, box-shadow .2s, transform .15s;
}
.dl-card:hover {
  border-color: var(--color-primary);
  box-shadow: 0 4px 14px rgba(79,124,255,0.10);
  transform: translateY(-1px);
}
.dl-card.disabled { opacity: 0.4; cursor: default; }
.dl-card.dl-card-web { border-color: var(--color-primary); }

.dl-card-name {
  font-size: 15px;
  font-weight: 600;
  color: var(--text-primary);
  border-bottom: 1px solid var(--border-light);
  padding-bottom: 8px;
  margin-bottom: 4px;
}
.dl-card-ver { font-size: 12px; color: var(--text-secondary); font-family: var(--font-mono); }
.dl-card-size { font-size: 12px; color: var(--text-tertiary); }

.dl-card-btn {
  margin-top: 10px;
  height: 34px;
  border: 1px solid var(--border);
  border-radius: 7px;
  background: white;
  font-size: 13px;
  font-weight: 600;
  color: var(--text-primary);
  cursor: pointer;
  transition: background .2s, border-color .2s, color .2s;
}
.dl-card-btn:hover:not(:disabled) {
  background: var(--color-primary);
  border-color: var(--color-primary);
  color: white;
}
.dl-card-btn:disabled { cursor: not-allowed; opacity: 0.5; }
.dl-card-btn-primary {
  background: var(--color-primary);
  border-color: var(--color-primary);
  color: white;
}
.dl-card-btn-primary:hover:not(:disabled) {
  background: var(--color-primary-dark);
  border-color: var(--color-primary-dark);
}
.dl-card-btn.is-loading { pointer-events: none; opacity: 0.85; }

/* ========== 提示条（callout） ========== */
.detail-callout {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-top: 20px;
  padding: 14px 18px;
  border-radius: 12px;
  font-size: 14px;
  line-height: 1.6;
}
.detail-callout .callout-icon { font-size: 16px; flex-shrink: 0; }
.detail-callout.callout-info {
  background: linear-gradient(135deg, rgba(82,196,26,0.08), rgba(82,196,26,0.02));
  border: 1px solid rgba(82,196,26,0.2);
  color: #389E0D;
}
.detail-callout.callout-paid {
  background: linear-gradient(135deg, rgba(250,140,22,0.08), rgba(250,140,22,0.02));
  border: 1px solid rgba(250,140,22,0.25);
  color: #D46B08;
}
.detail-callout .callout-link {
  margin-left: auto;
  font-size: 13px;
  font-weight: 600;
  color: var(--color-primary);
  text-decoration: none;
  white-space: nowrap;
  transition: transform .15s;
}
.detail-callout .callout-link:hover { transform: translateX(2px); }

.detail-section { margin-top: 48px; }

/* ============ 超时页 ============ */
.timeout-card {
  text-align: center;
  padding: 40px;
}
.timeout-card .big-icon {
  font-size: 64px;
  margin-bottom: 16px;
}
.timeout-card h2 { font-size: 24px; margin-bottom: 12px; }
.timeout-card .order-meta {
  margin: 20px 0;
  padding: 16px 24px;
  background: var(--border-light);
  border-radius: 12px;
  font-family: var(--font-mono);
  font-size: 14px;
  text-align: left;
}
.timeout-card .order-meta div { padding: 4px 0; }

/* ============ 通用内容页 ============ */
.prose {
  font-size: 15px;
  line-height: 1.8;
}
.prose h2 { font-size: 22px; margin: 32px 0 12px; }
.prose h3 { font-size: 18px; margin: 24px 0 8px; }
.prose p { margin: 12px 0; color: var(--text-primary); }
.prose ul { padding-left: 20px; margin: 12px 0; }
.prose ul li { padding: 4px 0; list-style: disc; }
.prose ol { padding-left: 20px; margin: 12px 0; }
.prose ol li { padding: 6px 0; }
.prose a { color: var(--color-primary); }
.prose .divider { border: none; border-top: 1px solid var(--border); margin: 32px 0; }

/* ============ 404 页 ============ */
.not-found {
  text-align: center;
  padding: 80px 24px;
}
.not-found .nf-code {
  font-size: 120px;
  font-weight: 800;
  color: var(--color-primary);
  letter-spacing: -4px;
  line-height: 1;
}
.not-found h2 { font-size: 28px; margin: 12px 0 8px; }
.not-found p { color: var(--text-secondary); margin-bottom: 24px; }
.not-found .nf-actions { display: flex; justify-content: center; gap: 12px; flex-wrap: wrap; }

/* ============ 教程页步骤 ============ */
.tutorial-step {
  background: white;
  border-radius: var(--radius-card);
  padding: 24px;
  box-shadow: var(--shadow-card);
  margin-bottom: 16px;
  display: flex;
  gap: 20px;
  align-items: flex-start;
}
.tutorial-step .step-num {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: var(--color-primary-gradient);
  color: white;
  font-size: 20px;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}
.tutorial-step .step-content h3 { font-size: 17px; margin-bottom: 4px; }
.tutorial-step .step-content p { color: var(--text-secondary); font-size: 14px; }

.help-section {
  margin-top: 32px;
  padding: 24px;
  background: var(--color-primary-soft);
  border-radius: var(--radius-card);
}
.help-section h3 { font-size: 16px; margin-bottom: 12px; color: var(--color-primary-dark); }
.help-section .help-links { display: flex; gap: 16px; flex-wrap: wrap; }

/* ============ 已付款跳转按钮区 ============ */
.action-row {
  display: flex;
  justify-content: center;
  gap: 12px;
  margin-top: 24px;
  flex-wrap: wrap;
}
