:root {
  --brand: #8b3a3a;
  --brand-light: #b85a5a;
  --brand-dark: #5e2424;
  --accent: #c9a227;
  --accent-soft: #e8cf8a;
  --bg: #fbf7f2;
  --bg-alt: #f3ece2;
  --surface: rgba(255, 255, 255, 0.72);
  --surface-solid: #ffffff;
  --text: #2c2622;
  --text-soft: #6b615a;
  --text-muted: #968b82;
  --border: rgba(139, 58, 58, 0.14);
  --shadow-sm: 0 2px 10px rgba(94, 36, 36, 0.06);
  --shadow-md: 0 10px 30px rgba(94, 36, 36, 0.1);
  --shadow-lg: 0 20px 50px rgba(94, 36, 36, 0.16);
  --radius-sm: 10px;
  --radius: 18px;
  --radius-lg: 26px;
  --header-h: 72px;
  --ease: cubic-bezier(0.22, 0.61, 0.36, 1);
  --maxw: 1180px;
}

[data-theme="dark"] {
  --brand: #d97a7a;
  --brand-light: #e89a9a;
  --brand-dark: #a85050;
  --accent: #e8c25a;
  --accent-soft: #8a7333;
  --bg: #16120f;
  --bg-alt: #1e1915;
  --surface: rgba(40, 33, 28, 0.72);
  --surface-solid: #241e19;
  --text: #f0e9e2;
  --text-soft: #c3b8ae;
  --text-muted: #8d8177;
  --border: rgba(217, 122, 122, 0.2);
  --shadow-sm: 0 2px 10px rgba(0, 0, 0, 0.4);
  --shadow-md: 0 10px 30px rgba(0, 0, 0, 0.5);
  --shadow-lg: 0 20px 50px rgba(0, 0, 0, 0.6);
}

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

html {
  scroll-behavior: smooth;
  scroll-padding-top: calc(var(--header-h) + 16px);
  -webkit-text-size-adjust: 100%;
}

body {
  margin: 0;
  font-family: "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", "Noto Sans SC", system-ui, -apple-system, "Segoe UI", sans-serif;
  font-size: 16px;
  line-height: 1.75;
  color: var(--text);
  background-color: var(--bg);
  background-image:
    radial-gradient(circle at 12% 8%, rgba(201, 162, 39, 0.08), transparent 42%),
    radial-gradient(circle at 88% 4%, rgba(139, 58, 58, 0.09), transparent 46%),
    radial-gradient(circle at 50% 100%, rgba(139, 58, 58, 0.06), transparent 55%);
  background-attachment: fixed;
  transition: background-color 0.4s var(--ease), color 0.4s var(--ease);
  overflow-x: hidden;
}

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

a {
  color: var(--brand);
  text-decoration: none;
  transition: color 0.25s var(--ease);
}

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

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

h1, h2, h3, h4 {
  font-family: "Songti SC", "STSong", "Noto Serif SC", Georgia, "Times New Roman", serif;
  line-height: 1.35;
  color: var(--text);
  letter-spacing: 0.01em;
}

h1 { font-size: clamp(1.7rem, 3.6vw, 2.6rem); }
h2 { font-size: clamp(1.4rem, 2.8vw, 2rem); }
h3 { font-size: clamp(1.12rem, 1.9vw, 1.35rem); }

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

ul, ol {
  padding-left: 1.3em;
}

li {
  margin-bottom: 0.4em;
  color: var(--text-soft);
}

blockquote {
  margin: 0;
  padding: 0;
}

.visually-hidden {
  position: absolute !important;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
  border: 0;
}

/* ============ Header ============ */
#site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: var(--surface);
  backdrop-filter: blur(18px) saturate(160%);
  -webkit-backdrop-filter: blur(18px) saturate(160%);
  border-bottom: 1px solid var(--border);
  box-shadow: var(--shadow-sm);
  transition: background 0.4s var(--ease), border-color 0.4s var(--ease);
}

.header-inner {
  max-width: var(--maxw);
  margin: 0 auto;
  min-height: var(--header-h);
  padding: 10px 20px;
  display: flex;
  align-items: center;
  gap: 18px;
  flex-wrap: wrap;
}

.brand-logo {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  flex-shrink: 0;
  color: var(--text);
}

.brand-logo svg {
  transition: transform 0.5s var(--ease);
}

.brand-logo:hover svg {
  transform: rotate(-6deg) scale(1.06);
}

.brand-name {
  font-family: "Songti SC", "STSong", serif;
  font-size: 1.3rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  background: linear-gradient(120deg, var(--brand), var(--accent));
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
}

#site-header nav {
  flex: 1 1 auto;
}

.main-nav {
  display: flex;
  align-items: center;
  gap: 4px;
  list-style: none;
  margin: 0;
  padding: 0;
  flex-wrap: wrap;
}

.main-nav li {
  margin: 0;
}

.main-nav a {
  display: inline-block;
  padding: 7px 11px;
  font-size: 0.9rem;
  color: var(--text-soft);
  border-radius: 999px;
  position: relative;
  transition: color 0.25s var(--ease), background 0.25s var(--ease);
}

.main-nav a::after {
  content: "";
  position: absolute;
  left: 50%;
  bottom: 2px;
  width: 0;
  height: 2px;
  background: linear-gradient(90deg, var(--brand), var(--accent));
  border-radius: 2px;
  transform: translateX(-50%);
  transition: width 0.3s var(--ease);
}

.main-nav a:hover,
.main-nav a:focus-visible {
  color: var(--brand);
  background: rgba(139, 58, 58, 0.07);
}

.main-nav a:hover::after {
  width: 60%;
}

.site-search {
  display: flex;
  align-items: center;
  gap: 6px;
  flex-shrink: 0;
}

.site-search input[type="search"] {
  width: 190px;
  padding: 9px 14px;
  font-size: 0.88rem;
  color: var(--text);
  background: var(--bg-alt);
  border: 1px solid var(--border);
  border-radius: 999px;
  transition: width 0.35s var(--ease), border-color 0.25s var(--ease), box-shadow 0.25s var(--ease);
}

.site-search input[type="search"]::placeholder {
  color: var(--text-muted);
}

.site-search input[type="search"]:focus {
  width: 240px;
  outline: none;
  border-color: var(--brand);
  box-shadow: 0 0 0 3px rgba(139, 58, 58, 0.14);
}

.site-search button,
#theme-toggle,
#menu-toggle {
  font-family: inherit;
  font-size: 0.86rem;
  color: #fff;
  background: linear-gradient(135deg, var(--brand), var(--brand-dark));
  border: none;
  border-radius: 999px;
  padding: 9px 16px;
  cursor: pointer;
  white-space: nowrap;
  box-shadow: var(--shadow-sm);
  transition: transform 0.25s var(--ease), box-shadow 0.25s var(--ease), filter 0.25s var(--ease);
}

.site-search button:hover,
#theme-toggle:hover,
#menu-toggle:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
  filter: brightness(1.06);
}

#theme-toggle {
  background: linear-gradient(135deg, var(--accent), #a8861c);
  color: #2c2622;
  font-weight: 600;
}

#menu-toggle {
  display: none;
}

/* ============ Main ============ */
main {
  max-width: var(--maxw);
  margin: 0 auto;
  padding: 0 20px 60px;
}

section {
  margin: 56px 0;
}

section > h2 {
  position: relative;
  padding-left: 18px;
  margin-bottom: 24px;
}

section > h2::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0.18em;
  bottom: 0.18em;
  width: 6px;
  border-radius: 6px;
  background: linear-gradient(180deg, var(--brand), var(--accent));
}

/* ============ Hero ============ */
.hero-section {
  margin-top: 28px;
  display: grid;
  gap: 28px;
}

.hero-slider {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 18px;
}

.slide {
  position: relative;
  overflow: hidden;
  border-radius: var(--radius-lg);
  padding: 30px 26px;
  min-height: 220px;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  color: #fff;
  box-shadow: var(--shadow-md);
  isolation: isolate;
  transition: transform 0.45s var(--ease), box-shadow 0.45s var(--ease);
}

.slide::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  transition: transform 0.7s var(--ease);
}

.slide::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  background: linear-gradient(180deg, rgba(0, 0, 0, 0.05) 0%, rgba(0, 0, 0, 0.42) 100%);
}

.slide-1::before {
  background: linear-gradient(135deg, #8b3a3a 0%, #b85a5a 45%, #c9a227 100%);
}

.slide-2::before {
  background: linear-gradient(135deg, #2f5d6b 0%, #4b8a92 50%, #8fc6b8 100%);
}

.slide-3::before {
  background: linear-gradient(135deg, #4a2f6b 0%, #7a5aa8 50%, #c98fb8 100%);
}

.slide:hover {
  transform: translateY(-6px);
  box-shadow: var(--shadow-lg);
}

.slide:hover::before {
  transform: scale(1.08);
}

.slide h2 {
  color: #fff;
  font-size: clamp(1.15rem, 2vw, 1.45rem);
  margin: 0 0 10px;
  text-shadow: 0 2px 12px rgba(0, 0, 0, 0.3);
}

.slide p {
  color: rgba(255, 255, 255, 0.9);
  font-size: 0.92rem;
  margin-bottom: 16px;
}

.slide a {
  align-self: flex-start;
  display: inline-block;
  padding: 8px 18px;
  font-size: 0.86rem;
  font-weight: 600;
  color: #fff;
  background: rgba(255, 255, 255, 0.18);
  border: 1px solid rgba(255, 255, 255, 0.5);
  border-radius: 999px;
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
  transition: background 0.3s var(--ease), color 0.3s var(--ease), transform 0.3s var(--ease);
}

.slide a:hover {
  background: #fff;
  color: var(--brand-dark);
  transform: translateX(4px);
}

.hero-content {
  background: var(--surface);
  backdrop-filter: blur(20px) saturate(150%);
  -webkit-backdrop-filter: blur(20px) saturate(150%);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: clamp(24px, 4vw, 44px);
  box-shadow: var(--shadow-md);
  position: relative;
  overflow: hidden;
}

.hero-content::before {
  content: "";
  position: absolute;
  top: -60%;
  right: -20%;
  width: 380px;
  height: 380px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(201, 162, 39, 0.16), transparent 70%);
  pointer-events: none;
}

.hero-content h1 {
  margin-top: 0;
  margin-bottom: 18px;
  background: linear-gradient(120deg, var(--brand), var(--accent) 70%, var(--brand-light));
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
}

.hero-content > p {
  font-size: 1rem;
  line-height: 1.85;
  color: var(--text-soft);
}

.hero-stats {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 14px;
  margin-top: 28px;
}

.stat {
  padding: 18px 12px;
  text-align: center;
  border-radius: var(--radius);
  background: linear-gradient(160deg, rgba(139, 58, 58, 0.07), rgba(201, 162, 39, 0.07));
  border: 1px solid var(--border);
  transition: transform 0.35s var(--ease), box-shadow 0.35s var(--ease);
}

.stat:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-md);
}

.stat-num {
  display: block;
  font-family: "Songti SC", "STSong", serif;
  font-size: clamp(1.3rem, 2.4vw, 1.75rem);
  font-weight: 700;
  color: var(--brand);
  line-height: 1.2;
}

.stat-label {
  display: block;
  margin-top: 4px;
  font-size: 0.8rem;
  color: var(--text-muted);
  letter-spacing: 0.04em;
}

/* ============ Breadcrumb ============ */
.breadcrumb {
  margin: 26px 0 0;
}

.breadcrumb ol {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  list-style: none;
  padding: 0;
  margin: 0;
  font-size: 0.84rem;
  color: var(--text-muted);
}

.breadcrumb li {
  margin: 0;
  display: inline-flex;
  align-items: center;
}

.breadcrumb li + li::before {
  content: "›";
  margin-right: 8px;
  color: var(--text-muted);
}

.breadcrumb a {
  color: var(--text-soft);
}

.breadcrumb a:hover {
  color: var(--brand);
}

/* ============ Generic content cards ============ */
#about,
#products,
#solutions,
#applications,
#cases,
#news,
#articles,
#knowledge,
#howto,
#contact,
#sitemap,
#links,
#legal,
#author-info {
  background: var(--surface);
  backdrop-filter: blur(16px) saturate(140%);
  -webkit-backdrop-filter: blur(16px) saturate(140%);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: clamp(22px, 3.6vw, 40px);
  box-shadow: var(--shadow-sm);
  transition: box-shadow 0.4s var(--ease), border-color 0.4s var(--ease);
}

#about:hover,
#products:hover,
#solutions:hover,
#cases:hover,
#news:hover,
#articles:hover,
#knowledge:hover,
#howto:hover,
#contact:hover,
#legal:hover {
  box-shadow: var(--shadow-md);
}

#about h3,
#products h3,
#solutions h3,
#applications h3,
#cases h3,
#knowledge h3,
#howto h3,
#contact h3,
#legal h3 {
  margin-top: 1.6em;
  margin-bottom: 0.5em;
  padding-bottom: 0.35em;
  border-bottom: 1px dashed var(--border);
  color: var(--brand);
}

#about h3:first-of-type {
  margin-top: 1em;
}

/* ============ News ============ */
.news-list {
  list-style: none;
  padding: 0;
  margin: 0;
  display: grid;
  gap: 16px;
}

.news-list li {
  position: relative;
  margin: 0;
  padding: 18px 20px;
  background: var(--surface-solid);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: var(--shadow-sm);
  transition: transform 0.35s var(--ease), box-shadow 0.35s var(--ease), border-color 0.35s var(--ease);
}

.news-list li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 18px;
  bottom: 18px;
  width: 4px;
  border-radius: 4px;
  background: linear-gradient(180deg, var(--brand), var(--accent));
  opacity: 0;
  transition: opacity 0.35s var(--ease);
}

.news-list li:hover {
  transform: translateX(6px);
  box-shadow: var(--shadow-md);
  border-color: var(--brand-light);
}

.news-list li:hover::before {
  opacity: 1;
}

.news-list h3 {
  margin: 0 0 6px;
  font-size: 1.05rem;
  border: none;
  padding: 0;
  color: var(--text);
}

.news-list h3 a {
  color: var(--text);
}

.news-list h3 a:hover {
  color: var(--brand);
}

.news-list time {
  display: inline-block;
  font-size: 0.78rem;
  color: var(--text-muted);
  padding: 2px 10px;
  border-radius: 999px;
  background: var(--bg-alt);
  margin-bottom: 8px;
}

.news-list p {
  margin: 0;
  font-size: 0.92rem;
}

/* ============ Articles ============ */
#articles > p {
  margin-bottom: 24px;
}

#articles article {
  position: relative;
  padding: 22px 24px;
  margin-bottom: 16px;
  background: var(--surface-solid);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: var(--shadow-sm);
  transition: transform 0.35s var(--ease), box-shadow 0.35s var(--ease);
}

#articles article::after {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: inherit;
  background: linear-gradient(130deg, transparent 60%, rgba(201, 162, 39, 0.09));
  opacity: 0;
  transition: opacity 0.4s var(--ease);
  pointer-events: none;
}

#articles article:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-md);
}

#articles article:hover::after {
  opacity: 1;
}

#articles h3 {
  margin: 0 0 6px;
  font-size: 1.08rem;
  color: var(--text);
}

#articles article > p:first-of-type {
  margin: 0 0 8px;
}

#articles time {
  font-size: 0.78rem;
  color: var(--text-muted);
}

#articles article > p:last-of-type {
  font-size: 0.93rem;
  margin-bottom: 12px;
}

#articles article > a {
  display: inline-block;
  font-size: 0.86rem;
  font-weight: 600;
  padding: 6px 16px;
  border-radius: 999px;
  color: var(--brand);
  background: rgba(139, 58, 58, 0.08);
  transition: background 0.3s var(--ease), color 0.3s var(--ease), transform 0.3s var(--ease);
}

#articles article > a:hover {
  background: var(--brand);
  color: #fff;
  transform: translateX(4px);
}

/* ============ Cases / blockquote ============ */
#cases blockquote {
  display: grid;
  gap: 14px;
  margin-top: 20px;
}

#cases blockquote p {
  position: relative;
  margin: 0;
  padding: 18px 22px 18px 46px;
  background: linear-gradient(135deg, rgba(139, 58, 58, 0.06), rgba(201, 162, 39, 0.06));
  border-left: 4px solid var(--brand);
  border-radius: var(--radius-sm);
  font-style: italic;
  color: var(--text-soft);
  transition: transform 0.35s var(--ease), background 0.35s var(--ease);
}

#cases blockquote p::before {
  content: "“";
  position: absolute;
  left: 14px;
  top: 4px;
  font-family: Georgia, serif;
  font-size: 2.4rem;
  line-height: 1;
  color: var(--accent);
  opacity: 0.7;
}

#cases blockquote p:hover {
  transform: translateX(6px);
  background: linear-gradient(135deg, rgba(139, 58, 58, 0.1), rgba(201, 162, 39, 0.1));
}

/* ============ FAQ ============ */
#faq {
  display: grid;
  gap: 12px;
}

#faq > h2 {
  margin-bottom: 8px;
}

#faq details {
  background: var(--surface);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 4px 20px;
  box-shadow: var(--shadow-sm);
  transition: box-shadow 0.35s var(--ease), border-color 0.35s var(--ease), background 0.35s var(--ease);
}

#faq details[open] {
  border-color: var(--brand-light);
  box-shadow: var(--shadow-md);
  background: var(--surface-solid);
}

#faq details:hover {
  border-color: var(--brand-light);
}

#faq summary {
  cursor: pointer;
  padding: 16px 32px 16px 0;
  font-weight: 600;
  font-size: 0.98rem;
  color: var(--text);
  list-style: none;
  position: relative;
  transition: color 0.25s var(--ease);
}

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

#faq summary::after {
  content: "+";
  position: absolute;
  right: 0;
  top: 50%;
  transform: translateY(-50%);
  width: 26px;
  height: 26px;
  line-height: 24px;
  text-align: center;
  font-size: 1.1rem;
  color: var(--brand);
  border: 1px solid var(--border);
  border-radius: 50%;
  transition: transform 0.35s var(--ease), background 0.35s var(--ease), color 0.35s var(--ease);
}

#faq details[open] summary::after {
  content: "−";
  background: var(--brand);
  color: #fff;
  border-color: var(--brand);
  transform: translateY(-50%) rotate(180deg);
}

#faq summary:hover {
  color: var(--brand);
}

#faq details p {
  margin: 0 0 16px;
  font-size: 0.94rem;
  animation: fadeSlide 0.4s var(--ease);
}

@keyframes fadeSlide {
  from {
    opacity: 0;
    transform: translateY(-6px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* ============ HowTo ============ */
#howto ol {
  counter-reset: howto;
  list-style: none;
  padding: 0;
  display: grid;
  gap: 10px;
}

#howto ol li {
  counter-increment: howto;
  position: relative;
  padding: 12px 16px 12px 52px;
  background: var(--surface-solid);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  font-size: 0.94rem;
  transition: transform 0.3s var(--ease), box-shadow 0.3s var(--ease);
}

#howto ol li::before {
  content: counter(howto);
  position: absolute;
  left: 14px;
  top: 50%;
  transform: translateY(-50%);
  width: 26px;
  height: 26px;
  line-height: 26px;
  text-align: center;
  font-size: 0.82rem;
  font-weight: 700;
  color: #fff;
  background: linear-gradient(135deg, var(--brand), var(--accent));
  border-radius: 50%;
}

#howto ol li:hover {
  transform: translateX(5px);
  box-shadow: var(--shadow-sm);
}

/* ============ Contact / Sitemap / Links ============ */
#contact ul,
#sitemap ul,
#links ul {
  list-style: none;
  padding: 0;
  display: grid;
  gap: 8px;
}

#contact ul li,
#sitemap ul li,
#links ul li {
  position: relative;
  padding: 10px 14px 10px 34px;
  background: var(--surface-solid);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  font-size: 0.93rem;
  transition: transform 0.3s var(--ease), border-color 0.3s var(--ease), box-shadow 0.3s var(--ease);
}

#contact ul li::before,
#sitemap ul li::before,
#links ul li::before {
  content: "";
  position: absolute;
  left: 14px;
  top: 50%;
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--brand), var(--accent));
  transform: translateY(-50%);
}

#contact ul li:hover,
#sitemap ul li:hover,
#links ul li:hover {
  transform: translateX(5px);
  border-color: var(--brand-light);
  box-shadow: var(--shadow-sm);
}

#sitemap ul {
  grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
}

#links ul {
  grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
}

/* ============ Author info ============ */
#author-info {
  background: linear-gradient(135deg, rgba(139, 58, 58, 0.08), rgba(201, 162, 39, 0.08));
}

#author-info p:last-child {
  margin-bottom: 0;
  font-size: 0.82rem;
  color: var(--text-muted);
}

/* ============ Footer ============ */
footer {
  background: linear-gradient(160deg, var(--brand-dark), #3a1717);
  color: rgba(255, 255, 255, 0.82);
  padding: 40px 20px 32px;
  margin-top: 40px;
  position: relative;
  overflow: hidden;
}

footer::before {
  content: "";
  position: absolute;
  top: -120px;
  right: -80px;
  width: 320px;
  height: 320px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(201, 162, 39, 0.22), transparent 70%);
  pointer-events: none;
}

footer > p {
  max-width: var(--maxw);
  margin: 0 auto 18px;
  text-align: center;
  font-size: 0.88rem;
  color: rgba(255, 255, 255, 0.75);
}

footer nav ul {
  max-width: var(--maxw);
  margin: 0 auto;
  padding: 0;
  list-style: none;
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 8px 22px;
}

footer nav li {
  margin: 0;
}

footer nav a {
  color: rgba(255, 255, 255, 0.82);
  font-size: 0.88rem;
  position: relative;
  padding-bottom: 2px;
}

footer nav a::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: 0;
  width: 0;
  height: 1px;
  background: var(--accent);
  transition: width 0.3s var(--ease);
}

footer nav a:hover {
  color: #fff;
}

footer nav a:hover::after {
  width: 100%;
}

/* ============ Back to top ============ */
#back-to-top {
  position: fixed;
  right: 22px;
  bottom: 22px;
  z-index: 90;
  font-family: inherit;
  font-size: 0.82rem;
  font-weight: 600;
  color: #fff;
  background: linear-gradient(135deg, var(--brand), var(--brand-dark));
  border: none;
  border-radius: 999px;
  padding: 12px 18px;
  cursor: pointer;
  box-shadow: var(--shadow-md);
  opacity: 0;
  visibility: hidden;
  transform: translateY(14px);
  transition: opacity 0.35s var(--ease), transform 0.35s var(--ease), visibility 0.35s var(--ease), filter 0.25s var(--ease);
}

#back-to-top.is-visible {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}

#back-to-top:hover {
  filter: brightness(1.1);
  transform: translateY(-3px);
}

/* ============ Scroll reveal ============ */
.reveal {
  opacity: 0;
  transform: translateY(26px);
  transition: opacity 0.7s var(--ease), transform 0.7s var(--ease);
}

.reveal.is-visible {
  opacity: 1;
  transform: translateY(0);
}

/* ============ Responsive ============ */
@media (max-width: 1024px) {
  .hero-slider {
    grid-template-columns: 1fr;
  }

  .slide {
    min-height: 180px;
  }

  .site-search input[type="search"] {
    width: 150px;
  }

  .site-search input[type="search"]:focus {
    width: 190px;
  }
}

@media (max-width: 900px) {
  .header-inner {
    gap: 12px;
  }

  #menu-toggle {
    display: inline-block;
    margin-left: auto;
  }

  #site-header nav {
    order: 10;
    flex-basis: 100%;
    display: none;
  }

  #site-header.nav-open nav {
    display: block;
    animation: fadeSlide 0.35s var(--ease);
  }

  .main-nav {
    flex-direction: column;
    align-items: stretch;
    gap: 2px;
    padding: 8px 0 4px;
    border-top: 1px solid var(--border);
    margin-top: 6px;
  }

  .main-nav a {
    display: block;
    padding: 10px 14px;
    border-radius: var(--radius-sm);
  }

  .main-nav a::after {
    display: none;
  }

  .site-search {
    order: 11;
    flex-basis: 100%;
    display: none;
  }

  #site-header.nav-open .site-search {
    display: flex;
    padding-bottom: 10px;
  }

  .site-search input[type="search"],
  .site-search input[type="search"]:focus {
    width: 100%;
    flex: 1 1 auto;
  }

  .hero-stats {
    grid-template-columns: repeat(2, 1fr);
  }
}

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

  .header-inner {
    padding: 10px 14px;
  }

  .brand-name {
    font-size: 1.12rem;
  }

  main {
    padding: 0 14px 48px;
  }

  section {
    margin: 36px 0;
  }

  .hero-section {
    margin-top: 18px;
    gap: 18px;
  }

  .slide {
    padding: 22px 18px;
    min-height: 160px;
  }

  .hero-content {
    padding: 22px 18px;
  }

  .hero-stats {
    gap: 10px;
  }

  .stat {
    padding: 14px 8px;
  }

  #about,
  #products,
  #solutions,
  #applications,
  #cases,
  #news,
  #articles,
  #knowledge,
  #howto,
  #contact,
  #sitemap,
  #links,
  #legal,
  #author-info {
    padding: 20px 16px;
    border-radius: var(--radius);
  }

  #articles article,
  .news-list li {
    padding: 16px 16px;
  }

  #faq details {
    padding: 2px 16px;
  }

  #sitemap ul,
  #links ul {
    grid-template-columns: 1fr;
  }

  #back-to-top {
    right: 14px;
    bottom: 14px;
    padding: 10px 14px;
    font-size: 0.78rem;
  }

  footer {
    padding: 32px 14px 26px;
  }
}

@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;
  }

  .reveal {
    opacity: 1;
    transform: none;
  }
}

@media print {
  #site-header,
  #back-to-top,
  footer nav,
  .hero-slider,
  .site-search {
    display: none !important;
  }

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

  section {
    break-inside: avoid;
  }
}