@import url('https://fonts.googleapis.com/css2?family=Plus+Jakarta+Sans:wght@400;500;600;700;800&family=Noto+Sans+SC:wght@400;500;700;900&family=Noto+Sans+TC:wght@400;500;700;900&display=swap');

:root {
  --bg: #f8fafc;
  --bg-grid: #e2e8f0;
  --surface: #ffffff;
  --surface-soft: #f8fbff;
  --text: #0f172a;
  --muted: #475569;
  --line: #dbe5f0;
  --primary: #2563eb;
  --primary-soft: #dbeafe;
  --primary-strong: #1d4ed8;
  --accent: #0ea5e9;
  --star: #f59e0b;
  --danger: #dc2626;
  --radius-sm: 12px;
  --radius-md: 16px;
  --radius-lg: 22px;
  --shadow-sm: 0 8px 20px rgba(15, 23, 42, 0.06);
  --shadow-md: 0 16px 32px rgba(15, 23, 42, 0.1);
}

* {
  box-sizing: border-box;
}

html,
body {
  margin: 0;
  padding: 0;
}

body {
  color: var(--text);
  font-family: "Plus Jakarta Sans", "Noto Sans SC", "Noto Sans TC", sans-serif;
  line-height: 1.72;
  background:
    linear-gradient(to right, transparent 0, transparent 23px, var(--bg-grid) 24px, transparent 25px) 0 0 / 24px 24px,
    linear-gradient(to bottom, transparent 0, transparent 23px, var(--bg-grid) 24px, transparent 25px) 0 0 / 24px 24px,
    radial-gradient(1200px 420px at 4% -10%, #e0e7ff, transparent 55%),
    radial-gradient(900px 360px at 92% -12%, #cffafe, transparent 58%),
    var(--bg);
}

a {
  color: var(--primary);
  text-decoration: none;
}

a:hover {
  text-decoration: none;
  opacity: 0.9;
}

.top-notice {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  align-items: center;
  padding: 11px 20px;
  border-bottom: 1px solid var(--line);
  background: #eff6ff;
  color: #1e3a8a;
  font-size: 0.9rem;
}

.top-notice p {
  margin: 0;
}

.star-cta {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 38px;
  padding: 8px 14px;
  border-radius: 999px;
  border: 1px solid #facc15;
  background: linear-gradient(130deg, #f59e0b, #fde047);
  color: #422006;
  font-weight: 800;
  white-space: nowrap;
}

.topbar {
  position: sticky;
  top: 0;
  z-index: 20;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 14px;
  padding: 14px 20px;
  backdrop-filter: blur(10px);
  background: rgba(255, 255, 255, 0.88);
  border-bottom: 1px solid var(--line);
}

.brand {
  display: inline-flex;
  flex-direction: column;
  gap: 1px;
}

.brand-main {
  font-size: 1.35rem;
  font-weight: 800;
  letter-spacing: 0.01em;
  color: var(--text);
}

.brand-sub {
  font-size: 0.84rem;
  color: var(--muted);
}

.topbar nav {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}

.topbar nav > a,
.lang-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 36px;
  padding: 7px 12px;
  border-radius: 999px;
  border: 1px solid var(--line);
  color: #1e293b;
  background: #fff;
  transition: all 160ms ease;
  font-size: 0.9rem;
}

.topbar nav > a:hover,
.lang-link:hover {
  background: var(--surface-soft);
  border-color: #bfdbfe;
  text-decoration: none;
}

.nav-star {
  background: #0f172a !important;
  border-color: #0f172a !important;
  color: #fff !important;
  font-weight: 700;
}

main {
  max-width: 1180px;
  margin: 0 auto;
  padding: 26px 16px 56px;
}

.hero.v3 {
  display: grid;
  grid-template-columns: 1.3fr 1fr;
  gap: 16px;
}

.hero-main,
.hero-aside,
.install-showcase,
.knowledge-map,
.faq-card,
.latest,
.page-wrap,
.article {
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  background: var(--surface);
  box-shadow: var(--shadow-sm);
}

.hero-main,
.hero-aside,
.install-showcase,
.knowledge-map,
.faq-card,
.latest,
.page-wrap,
.article {
  padding: 24px;
}

.hero-main {
  position: relative;
  overflow: hidden;
}

.hero-main::after {
  content: "";
  position: absolute;
  right: -40px;
  bottom: -48px;
  width: 220px;
  height: 220px;
  border-radius: 999px;
  background: radial-gradient(circle, rgba(37, 99, 235, 0.18), transparent 62%);
  pointer-events: none;
}

.hero-kicker {
  display: inline-flex;
  align-items: center;
  padding: 4px 10px;
  border-radius: 999px;
  border: 1px solid #bfdbfe;
  background: #eff6ff;
  color: var(--primary-strong);
  font-size: 0.76rem;
  font-weight: 700;
  letter-spacing: 0.05em;
  text-transform: uppercase;
}

.hero-main h1 {
  margin: 10px 0 8px;
  font-size: clamp(2rem, 6vw, 3.5rem);
  line-height: 1.03;
}

.hero-subtitle {
  margin: 0;
  color: var(--primary-strong);
  font-weight: 700;
}

.hero-copy {
  margin: 12px 0 0;
  max-width: 70ch;
  color: var(--muted);
}

.hero-cta-row {
  margin-top: 18px;
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 44px;
  padding: 10px 14px;
  border-radius: 999px;
  font-weight: 700;
  border: 1px solid transparent;
  transition: transform 160ms ease, box-shadow 160ms ease;
}

.btn:hover {
  transform: translateY(-1px);
  text-decoration: none;
}

.btn.solid {
  color: #fff;
  background: linear-gradient(130deg, #2563eb, #0ea5e9);
  box-shadow: 0 8px 22px rgba(37, 99, 235, 0.28);
}

.btn.soft {
  color: var(--primary-strong);
  border-color: #bfdbfe;
  background: #eff6ff;
}

.btn.text {
  color: #334155;
  border-color: var(--line);
  background: #fff;
}

.quick-command {
  margin-top: 18px;
  padding: 12px;
  border-radius: var(--radius-sm);
  border: 1px solid #bfdbfe;
  background: #f8fbff;
  position: relative;
  z-index: 2;
}

.quick-command-head {
  display: flex;
  justify-content: space-between;
  gap: 8px;
  align-items: center;
  margin-bottom: 8px;
  color: #1e3a8a;
  font-size: 0.85rem;
  font-weight: 700;
}

.quick-command code {
  display: block;
  font-size: 0.9rem;
  line-height: 1.6;
  word-break: break-all;
  color: #0f172a;
}

.copy-trigger {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 31px;
  padding: 6px 10px;
  border-radius: 999px;
  border: 1px solid #bfdbfe;
  background: #fff;
  color: var(--primary-strong);
  font-size: 0.8rem;
  font-weight: 700;
  cursor: pointer;
}

.copy-trigger.is-copied {
  border-color: #86efac;
  color: #166534;
  background: #dcfce7;
}

.copy-trigger.is-failed {
  border-color: #fca5a5;
  color: #991b1b;
  background: #fee2e2;
}

.hero-aside h3 {
  margin: 0 0 8px;
  font-size: 1.18rem;
}

.hero-aside p {
  margin: 0.45rem 0;
  color: var(--muted);
}

.hero-aside strong {
  color: var(--text);
}

.star-giant {
  margin-top: 12px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  min-height: 48px;
  border-radius: var(--radius-sm);
  border: 1px solid #facc15;
  background: linear-gradient(130deg, #f59e0b, #fde047);
  color: #422006;
  font-weight: 800;
}

.install-showcase,
.knowledge-map,
.faq-card,
.latest,
.page-wrap,
.article {
  margin-top: 18px;
}

h2 {
  margin: 0 0 12px;
  font-size: 1.42rem;
}

.feature-grid,
.knowledge-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}

.feature-card,
.knowledge-item {
  display: block;
  padding: 14px;
  border-radius: var(--radius-md);
  border: 1px solid var(--line);
  background: var(--surface-soft);
  color: inherit;
  transition: all 160ms ease;
}

.feature-card:hover,
.knowledge-item:hover {
  border-color: #bfdbfe;
  box-shadow: var(--shadow-sm);
  transform: translateY(-2px);
  text-decoration: none;
}

.feature-card h3,
.knowledge-item h3 {
  margin: 0;
  font-size: 1.02rem;
}

.feature-card p,
.knowledge-item p {
  margin: 8px 0 0;
  color: var(--muted);
}

.faq-detail {
  border: 1px solid var(--line);
  border-radius: var(--radius-md);
  background: var(--surface-soft);
}

.faq-detail + .faq-detail {
  margin-top: 10px;
}

.faq-detail summary {
  cursor: pointer;
  padding: 12px 14px;
  font-weight: 700;
  list-style: none;
}

.faq-detail summary::-webkit-details-marker {
  display: none;
}

.faq-detail summary::after {
  content: "+";
  float: right;
  color: var(--muted);
}

.faq-detail[open] summary::after {
  content: "-";
}

.faq-detail div {
  padding: 0 14px 14px;
  color: var(--muted);
}

.section-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 10px;
}

.latest ul,
.post-list {
  list-style: none;
  padding: 0;
  margin: 10px 0 0;
}

.latest li,
.post-list li {
  padding: 13px 0;
  border-bottom: 1px dashed var(--line);
}

.latest li:last-child,
.post-list li:last-child {
  border-bottom: 0;
}

.latest small,
.post-list span {
  color: var(--muted);
}

.post-list p {
  margin: 6px 0 0;
  color: var(--muted);
}

.meta {
  color: var(--muted);
  margin-top: -6px;
}

.tags span {
  display: inline-flex;
  margin: 4px 6px 4px 0;
  padding: 3px 10px;
  border-radius: 999px;
  border: 1px solid #bfdbfe;
  background: #eff6ff;
  color: var(--primary-strong);
  font-size: 0.82rem;
}

.content h2,
.content h3,
.content h4 {
  margin-top: 1.4em;
  margin-bottom: 0.5em;
  line-height: 1.3;
}

.content img {
  max-width: 100%;
  border-radius: var(--radius-sm);
}

.content table {
  width: 100%;
  border-collapse: collapse;
  border-radius: var(--radius-sm);
  overflow: hidden;
}

.content th,
.content td {
  border: 1px solid var(--line);
  padding: 9px;
}

.content th {
  background: #f1f5f9;
  text-align: left;
}

.content p code,
.content li code,
.content td code {
  padding: 2px 6px;
  border-radius: 7px;
  border: 1px solid #bfdbfe;
  background: #eff6ff;
  color: #1e3a8a;
  font-size: 0.92em;
}

.content pre {
  position: relative;
  overflow-x: auto;
  background: #0b1220;
  color: #e5e7eb;
  border: 1px solid #1f2937;
  border-radius: var(--radius-sm);
  padding: 13px;
}

.content pre code {
  display: block;
  min-width: max-content;
  color: inherit;
  font-size: 0.9rem;
  line-height: 1.6;
}

.copy-code-btn {
  position: absolute;
  top: 8px;
  right: 8px;
  border: 1px solid #334155;
  background: #0f172a;
  color: #cbd5e1;
  border-radius: 999px;
  min-height: 28px;
  padding: 4px 10px;
  font-size: 0.78rem;
  font-weight: 700;
  cursor: pointer;
}

.copy-code-btn:hover {
  border-color: #93c5fd;
  color: #dbeafe;
}

.copy-code-btn.is-copied {
  border-color: #86efac;
  color: #dcfce7;
}

.copy-code-btn.is-failed {
  border-color: #fca5a5;
  color: #fecaca;
}

.content blockquote {
  margin: 1rem 0;
  padding: 10px 14px;
  border-left: 4px solid var(--primary);
  border-radius: 10px;
  background: #eff6ff;
  color: #1e3a8a;
}

.content details {
  margin: 1rem 0;
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  background: var(--surface-soft);
  padding: 8px 10px;
}

.content details summary {
  cursor: pointer;
  font-weight: 700;
}

.content hr {
  border: 0;
  border-top: 1px dashed var(--line);
  margin: 1.5rem 0;
}

.footer {
  margin-top: 30px;
  border-top: 1px solid var(--line);
  padding: 20px;
  text-align: center;
  color: var(--muted);
}

@media (max-width: 980px) {
  .hero.v3 {
    grid-template-columns: 1fr;
  }

  .feature-grid,
  .knowledge-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 760px) {
  .top-notice {
    flex-direction: column;
    align-items: flex-start;
  }

  .topbar {
    position: static;
    padding: 12px;
  }

  main {
    padding: 16px 10px 40px;
  }

  .hero-main,
  .hero-aside,
  .install-showcase,
  .knowledge-map,
  .faq-card,
  .latest,
  .page-wrap,
  .article {
    padding: 16px;
    border-radius: var(--radius-md);
  }
}

@media (prefers-reduced-motion: reduce) {
  * {
    animation: none !important;
    transition: none !important;
    scroll-behavior: auto !important;
  }
}
