/**
 * PHP 首页补丁：重置、插画动画、移动抽屉、教程封面（对齐 Nuxt landing）
 */
*,
*::before,
*::after {
  box-sizing: border-box;
}

html,
body {
  margin: 0;
}

body {
  font-family: "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", "Noto Sans SC", system-ui,
    -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  -webkit-font-smoothing: antialiased;
  background: #f4f7fc;
  color: #1d2129;
}

.landing-ico {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  line-height: 0;
}

.landing-ico svg {
  display: block;
  width: 100%;
  height: 100%;
}

.landing-hero-illustration,
.landing-features-illustration,
.landing-position-illustration {
  display: block;
  width: 100%;
  height: auto;
}

.landing-hero-illustration {
  max-width: 520px;
}

.landing-features-illustration {
  max-width: 360px;
}

.landing-workflow-illustration {
  display: block;
  width: 100%;
  max-width: 960px;
  height: auto;
  margin: 0 auto 28px;
  opacity: 0.9;
}

.landing-position-illustration {
  max-width: 400px;
}

.landing-vision-illustration {
  display: block;
  width: 100%;
  max-width: 480px;
  height: auto;
  margin: 0 auto 20px;
}

.landing-cta-decoration {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
}

@media (prefers-reduced-motion: no-preference) {
  .landing-illus-float--1 {
    animation: landing-illus-drift-a 7s ease-in-out infinite;
  }

  .landing-illus-float--2 {
    animation: landing-illus-drift-b 8s ease-in-out infinite;
  }

  .landing-illus-float--3 {
    animation: landing-illus-drift-c 9s ease-in-out infinite;
  }

  .landing-illus-pulse {
    animation: landing-illus-pulse 3s ease-in-out infinite;
  }

  .landing-illus-progress {
    animation: landing-illus-progress 2.8s ease-in-out infinite;
    transform-origin: 128px 268px;
  }

  .landing-illus-spin-slow {
    animation: landing-spin 24s linear infinite;
    transform-origin: 180px 160px;
  }

  .landing-illus-radar-sweep {
    animation: landing-radar 4s linear infinite;
    transform-origin: 180px 130px;
  }

  .landing-illus-chart-line {
    stroke-dasharray: 120;
    stroke-dashoffset: 120;
    animation: landing-draw-line 2.5s ease forwards infinite;
  }

  .landing-workflow-line {
    animation: landing-flow-dash 20s linear infinite;
  }

  .landing-illus-orbit {
    animation: landing-spin 30s linear infinite;
    transform-origin: 200px 140px;
  }

  .landing-illus-orbit-reverse {
    animation: landing-spin 22s linear infinite reverse;
    transform-origin: 200px 140px;
  }

  .landing-illus-orbit-node {
    animation: landing-node-float 5s ease-in-out infinite;
    animation-delay: calc(var(--orbit-i, 0) * 0.4s);
  }

  .landing-vision-node {
    animation: landing-vision-pop 0.6s ease backwards;
    animation-delay: calc(var(--vi, 0) * 0.15s + 0.3s);
  }

  .landing-vision-arrow {
    animation: landing-vision-bounce 2s ease-in-out infinite;
  }

  .landing-cta-doc--1 {
    animation: landing-cta-float-a 8s ease-in-out infinite;
  }

  .landing-cta-doc--2 {
    animation: landing-cta-float-b 9s ease-in-out infinite;
  }

  .landing-cta-doc--3 {
    animation: landing-cta-float-c 7s ease-in-out infinite;
  }
}

@keyframes landing-illus-progress {
  0%,
  100% {
    transform: scaleX(0.55);
  }
  50% {
    transform: scaleX(1);
  }
}

@keyframes landing-illus-drift-a {
  0%,
  100% {
    transform: translate(0, 0);
  }
  50% {
    transform: translate(0, -6px);
  }
}

@keyframes landing-illus-drift-b {
  0%,
  100% {
    transform: translate(0, 0);
  }
  50% {
    transform: translate(0, 8px);
  }
}

@keyframes landing-illus-drift-c {
  0%,
  100% {
    transform: translate(4px, -4px);
  }
}

@keyframes landing-illus-pulse {
  0%,
  100% {
    opacity: 1;
  }
  50% {
    opacity: 0.85;
  }
}

@keyframes landing-spin {
  to {
    transform: rotate(360deg);
  }
}

@keyframes landing-radar {
  to {
    transform: rotate(360deg);
  }
}

@keyframes landing-draw-line {
  0% {
    stroke-dashoffset: 120;
  }
  50% {
    stroke-dashoffset: 0;
  }
  100% {
    stroke-dashoffset: -120;
  }
}

@keyframes landing-flow-dash {
  to {
    stroke-dashoffset: -280;
  }
}

@keyframes landing-node-float {
  0%,
  100% {
    transform: translate(0, 0);
  }
  50% {
    transform: translate(0, -4px);
  }
}

@keyframes landing-vision-pop {
  from {
    opacity: 0;
    transform: translateY(8px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes landing-vision-bounce {
  0%,
  100% {
    transform: translateY(0);
  }
  50% {
    transform: translateY(-4px);
  }
}

@keyframes landing-cta-float-a {
  0%,
  100% {
    transform: translate(0, 0) rotate(0deg);
  }
  50% {
    transform: translate(8px, -12px) rotate(3deg);
  }
}

@keyframes landing-cta-float-b {
  0%,
  100% {
    transform: translate(0, 0);
  }
  50% {
    transform: translate(-10px, 8px);
  }
}

@keyframes landing-cta-float-c {
  0%,
  100% {
    transform: rotate(12deg);
  }
  50% {
    transform: rotate(18deg) translateY(-6px);
  }
}

@media (prefers-reduced-motion: reduce) {
  .landing-illus-float--1,
  .landing-illus-float--2,
  .landing-illus-float--3,
  .landing-illus-pulse,
  .landing-illus-progress,
  .landing-illus-spin-slow,
  .landing-illus-radar-sweep,
  .landing-illus-chart-line,
  .landing-workflow-line,
  .landing-illus-orbit,
  .landing-illus-orbit-reverse,
  .landing-illus-orbit-node,
  .landing-vision-arrow,
  .landing-cta-doc--1,
  .landing-cta-doc--2,
  .landing-cta-doc--3 {
    animation: none !important;
  }
}

/* 移动端抽屉（替代 Element Plus Drawer） */
.landing-drawer {
  position: fixed;
  inset: 0;
  z-index: 200;
  pointer-events: none;
}

.landing-drawer.is-open {
  pointer-events: auto;
}

.landing-drawer-mask {
  position: absolute;
  inset: 0;
  background: rgba(15, 23, 42, 0.42);
  opacity: 0;
  transition: opacity 0.22s ease;
}

.landing-drawer.is-open .landing-drawer-mask {
  opacity: 1;
}

.landing-drawer-panel {
  position: absolute;
  top: 0;
  right: 0;
  width: min(300px, 86vw);
  height: 100%;
  padding: 18px 16px 24px;
  background: #fff;
  box-shadow: -12px 0 32px rgba(22, 100, 255, 0.08);
  transform: translateX(100%);
  transition: transform 0.25s cubic-bezier(0.22, 1, 0.36, 1);
  overflow: auto;
}

.landing-drawer.is-open .landing-drawer-panel {
  transform: none;
}

.landing-drawer-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 8px;
}

.landing-drawer-title {
  margin: 0;
  font-size: 16px;
  font-weight: 700;
}

.landing-drawer-close {
  width: 36px;
  height: 36px;
  border: 0;
  border-radius: 8px;
  background: transparent;
  color: #4e5969;
  font-size: 22px;
  cursor: pointer;
}

.landing-drawer-close:hover {
  background: #e8f3ff;
  color: #1664ff;
}

body.landing-drawer-lock {
  overflow: hidden;
}

a.landing-client-download-btn {
  text-decoration: none;
  box-sizing: border-box;
}

.landing-client-download-menu[hidden] {
  display: none !important;
}

.cms-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 10px 16px;
  border-radius: 10px;
  border: 1px solid #e5e6eb;
  background: #fff;
  color: #1d2129;
  text-decoration: none;
  font-weight: 600;
}

.cms-btn-primary {
  background: #1664ff;
  border-color: #1664ff;
  color: #fff;
}

.landing-tutorial-player video {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: contain;
  background: #0d1117;
}

.landing-toast {
  position: fixed;
  left: 50%;
  bottom: 28px;
  z-index: 300;
  transform: translateX(-50%) translateY(12px);
  padding: 10px 16px;
  border-radius: 10px;
  background: rgba(29, 33, 41, 0.92);
  color: #fff;
  font-size: 14px;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.2s ease, transform 0.2s ease;
}

.landing-toast.is-on {
  opacity: 1;
  transform: translateX(-50%) translateY(0);
}

.landing-features-layout > .landing-reveal:last-child,
.landing-position-layout > .landing-reveal:last-child {
  justify-self: center;
}

/* 首页 CMS 最新文章（Nuxt 无此块，沿用 landing 卡片语言） */
.landing-article-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
  gap: 16px;
}

.landing-article-card {
  display: block;
  height: 100%;
  padding: 20px 18px;
  border-radius: var(--landing-radius-lg, 16px);
  background: #fff;
  border: 1px solid rgba(22, 100, 255, 0.1);
  box-shadow: 0 4px 16px rgba(22, 100, 255, 0.05);
  text-decoration: none;
  color: inherit;
  transition: border-color 0.22s ease, box-shadow 0.22s ease, transform 0.22s ease;
}

.landing-article-card:hover {
  border-color: rgba(22, 100, 255, 0.28);
  box-shadow: 0 12px 32px rgba(22, 100, 255, 0.1);
  transform: translateY(-3px);
}

.landing-article-card h3 {
  margin: 8px 0 10px;
  font-size: 17px;
  line-height: 1.4;
  color: #1d2129;
}

.landing-article-card p {
  margin: 0;
  font-size: 14px;
  color: #4e5969;
}

.landing-article-more {
  margin: 20px 0 0;
  text-align: center;
}

/* 内页沿用 landing 顶栏时的文章排版 */
.landing-page .cms-wrap {
  max-width: 1120px;
  margin: 0 auto;
  padding: 0 clamp(16px, 4vw, 24px);
}

.landing-page .cms-pagehead,
.landing-page .cms-article,
.landing-page .cms-section {
  padding-block: 32px 40px;
}

.landing-page .cms-article h1,
.landing-page .cms-pagehead h1 {
  font-size: clamp(26px, 4vw, 34px);
  line-height: 1.35;
  margin: 8px 0 12px;
}

.landing-page .cms-crumb {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  margin: 0 0 18px;
  padding: 0;
  font-size: 13px;
  color: #86909c;
  list-style: none;
}

.landing-page .cms-crumb a {
  color: #1664ff;
  text-decoration: none;
}

.cms-crumb-sep {
  color: #c9cdd4;
}

.landing-page .cms-meta {
  color: #86909c;
  font-size: 13px;
}

.landing-page .cms-rich {
  background: #fff;
  border: 1px solid #e5e6eb;
  border-radius: 16px;
  padding: 24px;
  overflow: auto;
}

.landing-page .cms-rich img {
  max-width: 100%;
}

.landing-page .cms-list {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.landing-page .cms-list-item {
  background: #fff;
  border: 1px solid #e5e6eb;
  border-radius: 14px;
  padding: 18px;
}

.landing-page .cms-list-item h2 {
  margin: 0 0 6px;
  font-size: 20px;
}

.landing-page .cms-list-item h2 a {
  color: inherit;
  text-decoration: none;
}

.landing-page .cms-pager {
  display: flex;
  gap: 16px;
  align-items: center;
  margin-top: 20px;
}

.landing-page .cms-related {
  margin-top: 28px;
}

.landing-page .cms-cover {
  max-width: 100%;
  border-radius: 12px;
}

.landing-page .cms-lead {
  color: #4e5969;
  font-size: 16px;
}

/* 栏目列表 */
.cms-cat {
  padding: 28px 0 64px;
}

.cms-crumb {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  margin: 0 0 18px;
  font-size: 13px;
  color: #86909c;
}

.cms-crumb-sep {
  color: #c9cdd4;
}

.cms-crumb a {
  color: #1664ff;
  text-decoration: none;
}

.cms-crumb a:hover {
  text-decoration: underline;
}

.cms-cat-head {
  max-width: 720px;
  margin-bottom: 22px;
}

.cms-cat-kicker {
  margin: 0 0 8px;
  font-size: 13px;
  font-weight: 600;
  letter-spacing: 0.04em;
  color: #1664ff;
}

.cms-cat-head h1 {
  margin: 0 0 10px;
  font-size: clamp(26px, 4vw, 34px);
  line-height: 1.3;
  letter-spacing: -0.02em;
}

.cms-cat-lead {
  margin: 0 0 8px;
  font-size: 16px;
  line-height: 1.7;
  color: #4e5969;
}

.cms-cat-count {
  margin: 0;
  font-size: 13px;
  color: #86909c;
}

.cms-cat-switch {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin: 0 0 24px;
}

a.cms-cat-chip {
  display: inline-flex;
  align-items: center;
  padding: 7px 14px;
  border-radius: 999px;
  border: 1px solid #e5e6eb;
  background: #fff;
  color: #4e5969;
  font-size: 14px;
  font-weight: 600;
  text-decoration: none;
}

a.cms-cat-chip:hover {
  border-color: rgba(22, 100, 255, 0.35);
  color: #1664ff;
  text-decoration: none;
}

a.cms-cat-chip.is-on {
  background: #1664ff;
  border-color: #1664ff;
  color: #fff;
}

.cms-cat-empty {
  padding: 48px 24px;
  text-align: center;
  background: #fff;
  border: 1px dashed #e5e6eb;
  border-radius: 16px;
  color: #4e5969;
}

.cms-feed {
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.cms-feed-card {
  display: grid;
  grid-template-columns: 200px minmax(0, 1fr);
  gap: 20px;
  align-items: stretch;
  padding: 14px;
  background: #fff;
  border: 1px solid rgba(22, 100, 255, 0.1);
  border-radius: 16px;
  box-shadow: 0 4px 16px rgba(22, 100, 255, 0.04);
  transition: border-color 0.2s ease, box-shadow 0.2s ease, transform 0.2s ease;
}

.cms-feed-card:hover {
  border-color: rgba(22, 100, 255, 0.28);
  box-shadow: 0 12px 32px rgba(22, 100, 255, 0.1);
  transform: translateY(-2px);
}

.cms-feed-thumb {
  display: block;
  overflow: hidden;
  border-radius: 12px;
  background: linear-gradient(145deg, #e8f3ff 0%, #d6e6ff 100%);
  min-height: 132px;
}

.cms-feed-thumb img {
  display: block;
  width: 100%;
  height: 100%;
  min-height: 132px;
  object-fit: cover;
}

.cms-feed-fallback {
  display: flex;
  align-items: center;
  justify-content: center;
  height: 100%;
  min-height: 132px;
  font-size: 40px;
  font-weight: 700;
  color: #1664ff;
  opacity: 0.45;
}

.cms-feed-body {
  display: flex;
  flex-direction: column;
  min-width: 0;
  padding: 6px 8px 6px 0;
}

.cms-feed-title {
  margin: 0 0 8px;
  font-size: 20px;
  line-height: 1.4;
}

.cms-feed-title a {
  color: #1d2129;
  text-decoration: none;
}

.cms-feed-title a:hover {
  color: #1664ff;
}

.cms-feed-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 12px;
  margin: 0 0 8px;
  font-size: 13px;
  color: #86909c;
}

.cms-feed-tag {
  color: #1664ff;
  font-weight: 600;
}

.cms-feed-sum {
  margin: 0 0 12px;
  font-size: 14px;
  line-height: 1.7;
  color: #4e5969;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.cms-feed-more {
  margin-top: auto;
  font-size: 14px;
  font-weight: 600;
  color: #1664ff;
  text-decoration: none;
}

.cms-feed-more:hover {
  text-decoration: underline;
}

.cms-pager {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 16px;
  margin-top: 28px;
  font-size: 14px;
  color: #4e5969;
}

.cms-pager a {
  padding: 8px 14px;
  border-radius: 10px;
  border: 1px solid rgba(22, 100, 255, 0.2);
  background: #fff;
  color: #1664ff;
  text-decoration: none;
  font-weight: 600;
}

.cms-pager a:hover {
  background: #e8f3ff;
}

.cms-pager .is-off {
  padding: 8px 14px;
  color: #c9cdd4;
}

@media (max-width: 720px) {
  .cms-feed-card {
    grid-template-columns: 1fr;
    gap: 12px;
  }

  .cms-feed-thumb,
  .cms-feed-thumb img,
  .cms-feed-fallback {
    min-height: 160px;
  }
}
