:root {
  --primary: #F5A623;
  --primary-dark: #D98C0A;
  --primary-light: #FFD98A;
  --primary-soft: #FFF3DC;
  --accent: #FF6B6B;
  --accent-2: #7C5CFF;
  --bg: #FFFBF3;
  --bg-alt: #FFF6E8;
  --surface: #FFFFFF;
  --surface-glass: rgba(255, 255, 255, 0.72);
  --text: #2B2115;
  --text-soft: #6B5D4A;
  --text-muted: #9A8B75;
  --border: rgba(180, 150, 100, 0.22);
  --shadow-sm: 0 2px 8px rgba(160, 120, 50, 0.08);
  --shadow-md: 0 8px 24px rgba(160, 120, 50, 0.12);
  --shadow-lg: 0 18px 48px rgba(160, 120, 50, 0.18);
  --radius-sm: 10px;
  --radius-md: 16px;
  --radius-lg: 24px;
  --radius-pill: 999px;
  --grad-hero: linear-gradient(135deg, #FFB347 0%, #F5A623 45%, #FF7E5F 100%);
  --grad-card: linear-gradient(160deg, #FFF8EC 0%, #FFFFFF 100%);
  --grad-accent: linear-gradient(135deg, #7C5CFF 0%, #FF6B6B 100%);
  --font: -apple-system, BlinkMacSystemFont, "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", "Helvetica Neue", Arial, sans-serif;
  --maxw: 1160px;
  --ease: cubic-bezier(0.22, 0.61, 0.36, 1);
}

@media (prefers-color-scheme: dark) {
  :root {
    --primary: #FFB347;
    --primary-dark: #F5A623;
    --primary-light: #6B4E1E;
    --primary-soft: #2A2114;
    --accent: #FF7E7E;
    --accent-2: #9B82FF;
    --bg: #16120C;
    --bg-alt: #1D1810;
    --surface: #221C13;
    --surface-glass: rgba(34, 28, 19, 0.72);
    --text: #F5EEE2;
    --text-soft: #C9BCA6;
    --text-muted: #8F8270;
    --border: rgba(255, 200, 120, 0.14);
    --shadow-sm: 0 2px 8px rgba(0, 0, 0, 0.35);
    --shadow-md: 0 8px 24px rgba(0, 0, 0, 0.45);
    --shadow-lg: 0 18px 48px rgba(0, 0, 0, 0.55);
    --grad-hero: linear-gradient(135deg, #7A4A12 0%, #5C3A10 45%, #3E2A14 100%);
    --grad-card: linear-gradient(160deg, #2A2216 0%, #221C13 100%);
  }
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
}

body {
  margin: 0;
  font-family: var(--font);
  font-size: 16px;
  line-height: 1.75;
  color: var(--text);
  background-color: var(--bg);
  background-image:
    radial-gradient(circle at 12% 8%, rgba(245, 166, 35, 0.10), transparent 42%),
    radial-gradient(circle at 88% 22%, rgba(124, 92, 255, 0.07), transparent 40%),
    radial-gradient(circle at 50% 100%, rgba(255, 107, 107, 0.06), transparent 50%);
  background-attachment: fixed;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  overflow-x: hidden;
}

img,
svg {
  max-width: 100%;
  height: auto;
  display: block;
}

a {
  color: var(--primary-dark);
  text-decoration: none;
  transition: color 0.25s var(--ease), opacity 0.25s var(--ease);
}

a:hover,
a:focus-visible {
  color: var(--accent);
}

h1, h2, h3, h4 {
  margin: 0 0 0.6em;
  line-height: 1.3;
  font-weight: 800;
  letter-spacing: 0.01em;
  color: var(--text);
}

h1 {
  font-size: clamp(1.75rem, 4.2vw, 2.85rem);
  letter-spacing: -0.01em;
}

h2 {
  font-size: clamp(1.35rem, 2.8vw, 2rem);
  position: relative;
  padding-left: 18px;
}

h2::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0.18em;
  bottom: 0.18em;
  width: 6px;
  border-radius: 6px;
  background: var(--grad-hero);
  box-shadow: 0 0 12px rgba(245, 166, 35, 0.45);
}

h3 {
  font-size: clamp(1.05rem, 1.8vw, 1.28rem);
  color: var(--text);
}

p {
  margin: 0 0 1em;
  color: var(--text-soft);
}

ul, ol {
  margin: 0 0 1em;
  padding-left: 1.4em;
  color: var(--text-soft);
}

li {
  margin-bottom: 0.45em;
}

strong {
  color: var(--text);
}

blockquote {
  margin: 0 0 1em;
  padding: 16px 20px;
  border-radius: var(--radius-md);
  background: var(--surface-glass);
  -webkit-backdrop-filter: blur(12px);
  backdrop-filter: blur(12px);
  border: 1px solid var(--border);
  border-left: 4px solid var(--primary);
  box-shadow: var(--shadow-sm);
  transition: transform 0.3s var(--ease), box-shadow 0.3s var(--ease);
}

blockquote:hover {
  transform: translateY(-3px);
  box-shadow: var(--shadow-md);
}

blockquote p {
  margin: 0;
  font-style: italic;
  color: var(--text-soft);
}

address {
  font-style: normal;
}

::selection {
  background: rgba(245, 166, 35, 0.32);
  color: var(--text);
}

:focus-visible {
  outline: 2px solid var(--primary);
  outline-offset: 3px;
  border-radius: 4px;
}

header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: var(--surface-glass);
  -webkit-backdrop-filter: blur(18px) saturate(160%);
  backdrop-filter: blur(18px) saturate(160%);
  border-bottom: 1px solid var(--border);
  box-shadow: 0 4px 20px rgba(160, 120, 50, 0.06);
}

header nav {
  max-width: var(--maxw);
  margin: 0 auto;
  padding: 12px 20px;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 12px 20px;
}

header nav > a {
  font-size: 1.15rem;
  font-weight: 800;
  letter-spacing: 0.02em;
  background: var(--grad-hero);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  color: transparent;
  white-space: nowrap;
}

header nav > a:hover {
  filter: brightness(1.1);
}

header nav ul {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-wrap: wrap;
  gap: 4px 6px;
  flex: 1 1 auto;
}

header nav ul li {
  margin: 0;
}

header nav ul a {
  display: inline-block;
  padding: 6px 12px;
  border-radius: var(--radius-pill);
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--text-soft);
  transition: background 0.25s var(--ease), color 0.25s var(--ease), transform 0.25s var(--ease);
}

header nav ul a:hover {
  color: var(--primary-dark);
  background: var(--primary-soft);
  transform: translateY(-1px);
}

header nav form[role="search"] {
  display: flex;
  align-items: center;
  gap: 6px;
  margin-left: auto;
}

header nav form[role="search"] label {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
}

header nav form[role="search"] input[type="search"] {
  width: 180px;
  padding: 8px 14px;
  font-size: 0.88rem;
  font-family: inherit;
  color: var(--text);
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-pill);
  transition: width 0.3s var(--ease), border-color 0.25s var(--ease), box-shadow 0.25s var(--ease);
}

header nav form[role="search"] input[type="search"]::placeholder {
  color: var(--text-muted);
}

header nav form[role="search"] input[type="search"]:focus {
  width: 220px;
  border-color: var(--primary);
  box-shadow: 0 0 0 3px rgba(245, 166, 35, 0.18);
  outline: none;
}

header nav form[role="search"] button {
  padding: 8px 16px;
  font-size: 0.88rem;
  font-weight: 700;
  font-family: inherit;
  color: #fff;
  background: var(--grad-hero);
  border: none;
  border-radius: var(--radius-pill);
  cursor: pointer;
  white-space: nowrap;
  box-shadow: 0 4px 12px rgba(245, 166, 35, 0.32);
  transition: transform 0.25s var(--ease), box-shadow 0.25s var(--ease), filter 0.25s var(--ease);
}

header nav form[role="search"] button:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 20px rgba(245, 166, 35, 0.42);
  filter: brightness(1.05);
}

header nav form[role="search"] button:active {
  transform: translateY(0);
}

main {
  max-width: var(--maxw);
  margin: 0 auto;
  padding: 0 20px 40px;
}

main > section {
  margin: 0 0 28px;
  padding: 32px clamp(18px, 3.5vw, 40px);
  background: var(--grad-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-sm);
  animation: fadeUp 0.7s var(--ease) both;
  animation-timeline: view();
  animation-range: entry 0% cover 28%;
  transition: box-shadow 0.35s var(--ease), transform 0.35s var(--ease), border-color 0.35s var(--ease);
}

@supports not (animation-timeline: view()) {
  main > section {
    animation: fadeUp 0.7s var(--ease) both;
  }
}

main > section:hover {
  box-shadow: var(--shadow-md);
  border-color: rgba(245, 166, 35, 0.35);
}

@keyframes fadeUp {
  from {
    opacity: 0;
    transform: translateY(28px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }
  *,
  *::before,
  *::after {
    animation-duration: 0.001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.001ms !important;
  }
}

#hero {
  position: relative;
  margin: 28px 0 28px;
  padding: clamp(36px, 6vw, 72px) clamp(20px, 4vw, 56px);
  background: var(--grad-hero);
  border: none;
  border-radius: clamp(24px, 4vw, 36px);
  overflow: hidden;
  color: #fff;
  box-shadow: var(--shadow-lg);
}

#hero::before {
  content: "";
  position: absolute;
  inset: 0;
  background:
    radial-gradient(circle at 85% 15%, rgba(255, 255, 255, 0.32), transparent 45%),
    radial-gradient(circle at 10% 90%, rgba(255, 255, 255, 0.18), transparent 40%);
  pointer-events: none;
}

#hero::after {
  content: "";
  position: absolute;
  top: -60px;
  right: -60px;
  width: 260px;
  height: 260px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.14);
  filter: blur(8px);
  animation: floatY 7s ease-in-out infinite;
  pointer-events: none;
}

@keyframes floatY {
  0%, 100% { transform: translateY(0) scale(1); }
  50% { transform: translateY(22px) scale(1.06); }
}

#hero > * {
  position: relative;
  z-index: 1;
}

#hero h1 {
  color: #fff;
  text-shadow: 0 2px 16px rgba(120, 70, 0, 0.28);
  margin-bottom: 0.5em;
}

#hero > p {
  max-width: 760px;
  color: rgba(255, 255, 255, 0.94);
  font-size: clamp(0.95rem, 1.5vw, 1.06rem);
  line-height: 1.9;
  text-shadow: 0 1px 8px rgba(120, 70, 0, 0.2);
}

#hero figure {
  margin: 28px 0 0;
  background: rgba(255, 255, 255, 0.22);
  -webkit-backdrop-filter: blur(16px) saturate(150%);
  backdrop-filter: blur(16px) saturate(150%);
  border: 1px solid rgba(255, 255, 255, 0.4);
  border-radius: var(--radius-lg);
  padding: 14px;
  box-shadow: 0 10px 32px rgba(120, 70, 0, 0.25);
  transition: transform 0.4s var(--ease), box-shadow 0.4s var(--ease);
}

#hero figure:hover {
  transform: translateY(-6px) scale(1.008);
  box-shadow: 0 20px 48px rgba(120, 70, 0, 0.32);
}

#hero figure svg {
  width: 100%;
  border-radius: var(--radius-md);
}

#hero figcaption {
  margin-top: 12px;
  text-align: center;
  font-size: 0.86rem;
  color: rgba(255, 255, 255, 0.92);
  letter-spacing: 0.02em;
}

nav[aria-label="面包屑"] {
  margin: 0 0 20px;
}

nav[aria-label="面包屑"] ol {
  list-style: none;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 6px;
  margin: 0;
  padding: 10px 18px;
  background: var(--surface-glass);
  -webkit-backdrop-filter: blur(12px);
  backdrop-filter: blur(12px);
  border: 1px solid var(--border);
  border-radius: var(--radius-pill);
  font-size: 0.86rem;
  box-shadow: var(--shadow-sm);
}

nav[aria-label="面包屑"] ol li {
  margin: 0;
  display: flex;
  align-items: center;
  color: var(--text-muted);
}

nav[aria-label="面包屑"] ol li + li::before {
  content: "/";
  margin-right: 6px;
  color: var(--text-muted);
  opacity: 0.6;
}

nav[aria-label="面包屑"] ol li[aria-current="page"] {
  color: var(--primary-dark);
  font-weight: 700;
}

nav[aria-label="页面锚点导航"] {
  margin: 0 0 28px;
}

nav[aria-label="页面锚点导航"] ul {
  list-style: none;
  margin: 0;
  padding: 16px;
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  background: var(--surface-glass);
  -webkit-backdrop-filter: blur(14px);
  backdrop-filter: blur(14px);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-sm);
}

nav[aria-label="页面锚点导航"] ul li {
  margin: 0;
}

nav[aria-label="页面锚点导航"] ul a {
  display: inline-block;
  padding: 6px 14px;
  font-size: 0.84rem;
  font-weight: 600;
  color: var(--text-soft);
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-pill);
  transition: all 0.25s var(--ease);
}

nav[aria-label="页面锚点导航"] ul a:hover {
  color: #fff;
  background: var(--grad-hero);
  border-color: transparent;
  transform: translateY(-2px);
  box-shadow: 0 6px 16px rgba(245, 166, 35, 0.3);
}

#news article,
#articles article {
  padding: 20px 22px;
  margin-bottom: 16px;
  background: var(--surface-glass);
  -webkit-backdrop-filter: blur(10px);
  backdrop-filter: blur(10px);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-sm);
  transition: transform 0.3s var(--ease), box-shadow 0.3s var(--ease), border-color 0.3s var(--ease);
}

#news article:hover,
#articles article:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-md);
  border-color: rgba(245, 166, 35, 0.4);
}

#news article h3,
#articles article h3 {
  margin-bottom: 0.35em;
  transition: color 0.25s var(--ease);
}

#news article:hover h3,
#articles article:hover h3 {
  color: var(--primary-dark);
}

#news article p,
#articles article p {
  font-size: 0.94rem;
}

#articles article a {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  margin-top: 6px;
  padding: 7px 16px;
  font-size: 0.86rem;
  font-weight: 700;
  color: #fff;
  background: var(--grad-hero);
  border-radius: var(--radius-pill);
  box-shadow: 0 4px 12px rgba(245, 166, 35, 0.28);
  transition: transform 0.25s var(--ease), box-shadow 0.25s var(--ease), filter 0.25s var(--ease);
}

#articles article a::after {
  content: "→";
  transition: transform 0.25s var(--ease);
}

#articles article a:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 20px rgba(245, 166, 35, 0.4);
  filter: brightness(1.06);
  color: #fff;
}

#articles article a:hover::after {
  transform: translateX(4px);
}

#howto ol,
#howto ul {
  background: var(--surface-glass);
  -webkit-backdrop-filter: blur(8px);
  backdrop-filter: blur(8px);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  padding: 18px 20px 18px 40px;
  box-shadow: var(--shadow-sm);
}

#howto ol li::marker {
  color: var(--primary-dark);
  font-weight: 800;
}

#howto ul li::marker {
  color: var(--primary);
}

#faq h3 {
  margin-top: 1.4em;
  padding: 12px 16px;
  background: var(--primary-soft);
  border-left: 4px solid var(--primary);
  border-radius: var(--radius-sm);
  font-size: 1rem;
  transition: background 0.25s var(--ease), transform 0.25s var(--ease);
}

#faq h3:hover {
  background: rgba(245, 166, 35, 0.22);
  transform: translateX(3px);
}

#faq p {
  padding-left: 4px;
  font-size: 0.95rem;
}

#contact address ul {
  list-style: none;
  padding: 20px 22px;
  margin: 0 0 1em;
  background: var(--surface-glass);
  -webkit-backdrop-filter: blur(10px);
  backdrop-filter: blur(10px);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-sm);
}

#contact address ul li {
  position: relative;
  padding-left: 22px;
  font-size: 0.94rem;
}

#contact address ul li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0.62em;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--grad-hero);
  box-shadow: 0 0 8px rgba(245, 166, 35, 0.5);
}

#sitemap ul,
#links ul {
  list-style: none;
  padding: 0;
  margin: 0;
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

#sitemap ul li,
#links ul li {
  margin: 0;
}

#sitemap ul a,
#links ul a {
  display: inline-block;
  padding: 6px 14px;
  font-size: 0.86rem;
  font-weight: 600;
  color: var(--text-soft);
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-pill);
  transition: all 0.25s var(--ease);
}

#sitemap ul a:hover,
#links ul a:hover {
  color: var(--primary-dark);
  border-color: var(--primary);
  background: var(--primary-soft);
  transform: translateY(-2px);
  box-shadow: var(--shadow-sm);
}

footer {
  margin-top: 20px;
  padding: 48px 20px 32px;
  background: linear-gradient(180deg, var(--bg-alt) 0%, var(--bg) 100%);
  border-top: 1px solid var(--border);
}

footer > section {
  max-width: var(--maxw);
  margin: 0 auto 24px;
  padding: 24px 26px;
  background: var(--surface-glass);
  -webkit-backdrop-filter: blur(14px);
  backdrop-filter: blur(14px);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-sm);
  transition: transform 0.3s var(--ease), box-shadow 0.3s var(--ease);
}

footer > section:hover {
  transform: translateY(-3px);
  box-shadow: var(--shadow-md);
}

footer > section h2 {
  font-size: 1.05rem;
  padding-left: 14px;
}

footer > section h2::before {
  width: 4px;
}

footer > section p {
  font-size: 0.9rem;
  color: var(--text-muted);
  margin-bottom: 0;
}

footer > p {
  max-width: var(--maxw);
  margin: 0 auto;
  text-align: center;
}

footer > p a {
  display: inline-block;
  padding: 10px 26px;
  font-size: 0.9rem;
  font-weight: 700;
  color: #fff;
  background: var(--grad-hero);
  border-radius: var(--radius-pill);
  box-shadow: 0 6px 18px rgba(245, 166, 35, 0.32);
  transition: transform 0.25s var(--ease), box-shadow 0.25s var(--ease), filter 0.25s var(--ease);
}

footer > p a:hover {
  color: #fff;
  transform: translateY(-3px);
  box-shadow: 0 10px 26px rgba(245, 166, 35, 0.44);
  filter: brightness(1.06);
}

@media (max-width: 900px) {
  header nav {
    gap: 10px 14px;
  }

  header nav ul {
    order: 3;
    flex-basis: 100%;
    justify-content: flex-start;
    overflow-x: auto;
    flex-wrap: nowrap;
    padding-bottom: 4px;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
  }

  header nav ul::-webkit-scrollbar {
    display: none;
  }

  header nav ul a {
    white-space: nowrap;
  }

  header nav form[role="search"] {
    margin-left: auto;
  }

  header nav form[role="search"] input[type="search"] {
    width: 140px;
  }

  header nav form[role="search"] input[type="search"]:focus {
    width: 170px;
  }
}

@media (max-width: 640px) {
  body {
    font-size: 15px;
    line-height: 1.72;
  }

  header nav {
    padding: 10px 14px;
  }

  header nav > a {
    font-size: 1.02rem;
  }

  header nav form[role="search"] {
    flex: 1 1 100%;
    margin-left: 0;
  }

  header nav form[role="search"] input[type="search"] {
    flex: 1 1 auto;
    width: 100%;
  }

  header nav form[role="search"] input[type="search"]:focus {
    width: 100%;
  }

  main {
    padding: 0 14px 32px;
  }

  #hero {
    margin: 18px 0 20px;
    padding: 32px 20px;
    border-radius: 22px;
  }

  main > section {
    padding: 26px 18px;
    border-radius: var(--radius-md);
    margin-bottom: 20px;
  }

  h2 {
    padding-left: 14px;
  }

  h2::before {
    width: 5px;
  }

  nav[aria-label="面包屑"] ol {
    padding: 8px 14px;
    font-size: 0.8rem;
  }

  nav[aria-label="页面锚点导航"] ul {
    padding: 12px;
    gap: 6px;
  }

  nav[aria-label="页面锚点导航"] ul a {
    font-size: 0.78rem;
    padding: 5px 11px;
  }

  #news article,
  #articles article {
    padding: 16px 16px;
  }

  #howto ol,
  #howto ul {
    padding: 16px 16px 16px 34px;
  }

  #contact address ul {
    padding: 16px 18px;
  }

  footer {
    padding: 34px 14px 24px;
  }

  footer > section {
    padding: 20px 18px;
  }
}

@media (min-width: 1024px) {
  #articles {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 18px;
    align-items: start;
  }

  #articles > h2 {
    grid-column: 1 / -1;
  }

  #articles article {
    margin-bottom: 0;
    height: 100%;
    display: flex;
    flex-direction: column;
  }

  #articles article a {
    align-self: flex-start;
    margin-top: auto;
  }

  #news {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 18px;
    align-items: start;
  }

  #news > h2 {
    grid-column: 1 / -1;
  }

  #news article {
    margin-bottom: 0;
    height: 100%;
  }

  #cases,
  #reviews {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 0 24px;
  }

  #cases > h2,
  #reviews > h2 {
    grid-column: 1 / -1;
  }

  #reviews > p:last-child {
    grid-column: 1 / -1;
  }
}

@media (min-width: 1280px) {
  #articles {
    grid-template-columns: repeat(2, 1fr);
  }

  main > section {
    margin-bottom: 32px;
  }
}

@media print {
  header,
  footer,
  nav[aria-label="页面锚点导航"],
  nav[aria-label="面包屑"] {
    display: none;
  }

  body {
    background: #fff;
    color: #000;
  }

  main > section {
    box-shadow: none;
    border: 1px solid #ccc;
    break-inside: avoid;
  }
}