:root {
  --brand: #ff5a5f;
  --brand-dark: #e03e44;
  --brand-light: #ffd6d6;
  --brand-soft: rgba(255, 90, 95, 0.12);
  --accent: #7c5cff;
  --accent-2: #2ec4b6;
  --gradient-hero: linear-gradient(135deg, #ff5a5f 0%, #ff8a5c 40%, #7c5cff 100%);
  --gradient-card: linear-gradient(145deg, rgba(255, 255, 255, 0.9), rgba(255, 255, 255, 0.6));
  --bg: #f7f5f2;
  --bg-elev: #ffffff;
  --bg-soft: #f0ece7;
  --text: #1d1a24;
  --text-soft: #55505e;
  --text-muted: #8a8494;
  --border: rgba(29, 26, 36, 0.1);
  --border-strong: rgba(29, 26, 36, 0.18);
  --glass: rgba(255, 255, 255, 0.55);
  --glass-border: rgba(255, 255, 255, 0.65);
  --shadow-sm: 0 2px 8px rgba(29, 26, 36, 0.06);
  --shadow-md: 0 8px 28px rgba(29, 26, 36, 0.1);
  --shadow-lg: 0 18px 50px rgba(29, 26, 36, 0.14);
  --radius-sm: 10px;
  --radius-md: 16px;
  --radius-lg: 24px;
  --radius-pill: 999px;
  --maxw: 1200px;
  --header-h: 70px;
  --ease: cubic-bezier(0.22, 0.61, 0.36, 1);
  --font: "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", "Noto Sans SC", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
}

@media (prefers-color-scheme: dark) {
  :root {
    --brand: #ff6b70;
    --brand-dark: #ff8a8e;
    --brand-light: #3a2226;
    --brand-soft: rgba(255, 107, 112, 0.16);
    --accent: #9a86ff;
    --accent-2: #4fe0d2;
    --gradient-hero: linear-gradient(135deg, #b8323a 0%, #a84a2e 40%, #5a3fc0 100%);
    --gradient-card: linear-gradient(145deg, rgba(40, 38, 50, 0.9), rgba(30, 28, 40, 0.6));
    --bg: #14131a;
    --bg-elev: #1d1b26;
    --bg-soft: #232030;
    --text: #f2f0f6;
    --text-soft: #c2bdd0;
    --text-muted: #8f8aa0;
    --border: rgba(242, 240, 246, 0.1);
    --border-strong: rgba(242, 240, 246, 0.2);
    --glass: rgba(30, 28, 40, 0.55);
    --glass-border: rgba(242, 240, 246, 0.12);
    --shadow-sm: 0 2px 8px rgba(0, 0, 0, 0.35);
    --shadow-md: 0 8px 28px rgba(0, 0, 0, 0.45);
    --shadow-lg: 0 18px 50px rgba(0, 0, 0, 0.55);
  }
}

*,
*::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: var(--font);
  font-size: 16px;
  line-height: 1.75;
  color: var(--text);
  background-color: var(--bg);
  background-image:
    radial-gradient(1200px 600px at 10% -10%, var(--brand-soft), transparent 60%),
    radial-gradient(900px 500px at 100% 0%, rgba(124, 92, 255, 0.1), transparent 55%);
  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(--brand-dark);
  text-decoration: none;
  transition: color 0.25s var(--ease), opacity 0.25s var(--ease);
}

a:hover,
a:focus-visible {
  color: var(--brand);
  text-decoration: underline;
  text-underline-offset: 3px;
}

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

h1 {
  font-size: clamp(1.7rem, 4.2vw, 2.9rem);
  letter-spacing: -0.02em;
}

h2 {
  font-size: clamp(1.4rem, 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: var(--radius-pill);
  background: linear-gradient(180deg, var(--brand), var(--accent));
}

h3 {
  font-size: clamp(1.15rem, 2vw, 1.4rem);
  margin-top: 1.6em;
}

h4 {
  font-size: 1.05rem;
  margin-top: 1.3em;
  color: var(--text-soft);
}

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

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

li {
  margin: 0.35em 0;
}

strong {
  color: var(--text);
  font-weight: 700;
}

::selection {
  background: var(--brand);
  color: #fff;
}

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

/* ============ Header ============ */
#site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: var(--glass);
  -webkit-backdrop-filter: saturate(180%) blur(18px);
  backdrop-filter: saturate(180%) blur(18px);
  border-bottom: 1px solid var(--border);
  box-shadow: var(--shadow-sm);
}

.header-inner {
  max-width: var(--maxw);
  margin: 0 auto;
  padding: 10px clamp(14px, 3vw, 28px);
  display: flex;
  align-items: center;
  gap: clamp(12px, 2vw, 26px);
  flex-wrap: wrap;
}

.brand {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-shrink: 0;
}

.brand-logo {
  width: 40px;
  height: 40px;
  border-radius: 12px;
  box-shadow: 0 4px 14px rgba(255, 90, 95, 0.35);
  transition: transform 0.4s var(--ease), box-shadow 0.4s var(--ease);
}

.brand:hover .brand-logo {
  transform: rotate(-8deg) scale(1.06);
  box-shadow: 0 6px 20px rgba(255, 90, 95, 0.5);
}

.brand-name {
  font-size: 1.15rem;
  font-weight: 800;
  letter-spacing: -0.01em;
  background: var(--gradient-hero);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  color: transparent;
  white-space: nowrap;
}

/* Nav */
#site-header nav {
  flex: 1 1 auto;
  min-width: 0;
}

.nav-list {
  display: flex;
  flex-wrap: wrap;
  gap: 2px 4px;
  list-style: none;
  margin: 0;
  padding: 0;
}

.nav-list li {
  margin: 0;
}

.nav-list a {
  display: inline-block;
  padding: 6px 11px;
  border-radius: var(--radius-pill);
  font-size: 0.9rem;
  font-weight: 500;
  color: var(--text-soft);
  text-decoration: none;
  white-space: nowrap;
  transition: background 0.25s var(--ease), color 0.25s var(--ease), transform 0.25s var(--ease);
}

.nav-list a:hover,
.nav-list a:focus-visible {
  background: var(--brand-soft);
  color: var(--brand-dark);
  text-decoration: none;
  transform: translateY(-1px);
}

/* Search */
.site-search {
  display: flex;
  align-items: center;
  gap: 6px;
  flex-shrink: 0;
  margin-left: auto;
}

.site-search input[type="search"] {
  width: clamp(140px, 18vw, 220px);
  padding: 8px 14px;
  font-size: 0.9rem;
  font-family: inherit;
  color: var(--text);
  background: var(--bg-elev);
  border: 1px solid var(--border-strong);
  border-radius: var(--radius-pill);
  transition: border-color 0.25s var(--ease), box-shadow 0.25s var(--ease), width 0.3s var(--ease);
  -webkit-appearance: none;
  appearance: none;
}

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

.site-search input[type="search"]:focus {
  outline: none;
  border-color: var(--brand);
  box-shadow: 0 0 0 3px var(--brand-soft);
}

.site-search button {
  padding: 8px 16px;
  font-size: 0.9rem;
  font-family: inherit;
  font-weight: 600;
  color: #fff;
  background: var(--gradient-hero);
  border: none;
  border-radius: var(--radius-pill);
  cursor: pointer;
  transition: transform 0.25s var(--ease), box-shadow 0.25s var(--ease), filter 0.25s var(--ease);
  white-space: nowrap;
}

.site-search button:hover {
  transform: translateY(-1px);
  box-shadow: 0 6px 18px rgba(255, 90, 95, 0.4);
  filter: brightness(1.05);
}

.site-search button:active {
  transform: translateY(0) scale(0.98);
}

/* ============ Main layout ============ */
main {
  max-width: var(--maxw);
  margin: 0 auto;
  padding: clamp(16px, 3vw, 36px) clamp(14px, 3vw, 28px) 40px;
}

main > section {
  margin-bottom: clamp(32px, 5vw, 64px);
  animation: fadeUp 0.7s var(--ease) both;
}

main > section:nth-child(2) { animation-delay: 0.05s; }
main > section:nth-child(3) { animation-delay: 0.1s; }
main > section:nth-child(4) { animation-delay: 0.12s; }
main > section:nth-child(5) { animation-delay: 0.14s; }

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

@keyframes floatIn {
  from {
    opacity: 0;
    transform: scale(0.96) translateY(14px);
  }
  to {
    opacity: 1;
    transform: scale(1) translateY(0);
  }
}

/* ============ Hero ============ */
#hero {
  position: relative;
  padding: clamp(26px, 5vw, 56px) clamp(18px, 4vw, 48px);
  border-radius: var(--radius-lg);
  background: var(--gradient-hero);
  color: #fff;
  overflow: hidden;
  box-shadow: var(--shadow-lg);
  isolation: isolate;
}

#hero::before {
  content: "";
  position: absolute;
  inset: -40% -20% auto auto;
  width: 520px;
  height: 520px;
  background: radial-gradient(circle, rgba(255, 255, 255, 0.35), transparent 65%);
  border-radius: 50%;
  z-index: -1;
  animation: pulseGlow 9s ease-in-out infinite alternate;
}

#hero::after {
  content: "";
  position: absolute;
  inset: auto auto -50% -15%;
  width: 460px;
  height: 460px;
  background: radial-gradient(circle, rgba(124, 92, 255, 0.5), transparent 65%);
  border-radius: 50%;
  z-index: -1;
  animation: pulseGlow 11s ease-in-out infinite alternate-reverse;
}

@keyframes pulseGlow {
  from { transform: scale(1) translate(0, 0); opacity: 0.75; }
  to { transform: scale(1.15) translate(20px, -20px); opacity: 1; }
}

#hero h1 {
  color: #fff;
  text-shadow: 0 2px 18px rgba(0, 0, 0, 0.18);
  max-width: 20ch;
}

.hero-lead {
  color: rgba(255, 255, 255, 0.94);
  font-size: clamp(0.95rem, 1.6vw, 1.08rem);
  max-width: 72ch;
  margin-bottom: 1.6em;
  text-shadow: 0 1px 8px rgba(0, 0, 0, 0.15);
}

/* Hero banner */
.hero-banner {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: clamp(12px, 2vw, 20px);
  margin: 0 0 1.8em;
}

.banner-slide {
  background: rgba(255, 255, 255, 0.16);
  -webkit-backdrop-filter: blur(12px) saturate(160%);
  backdrop-filter: blur(12px) saturate(160%);
  border: 1px solid rgba(255, 255, 255, 0.35);
  border-radius: var(--radius-md);
  padding: 12px;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.14);
  transition: transform 0.45s var(--ease), box-shadow 0.45s var(--ease), background 0.45s var(--ease);
  animation: floatIn 0.8s var(--ease) both;
  overflow: hidden;
}

.banner-slide:nth-child(2) { animation-delay: 0.12s; }
.banner-slide:nth-child(3) { animation-delay: 0.24s; }

.banner-slide:hover {
  transform: translateY(-6px) scale(1.015);
  box-shadow: 0 18px 40px rgba(0, 0, 0, 0.26);
  background: rgba(255, 255, 255, 0.24);
}

.banner-slide svg {
  width: 100%;
  border-radius: var(--radius-sm);
  margin-bottom: 10px;
  transition: transform 0.5s var(--ease);
}

.banner-slide:hover svg {
  transform: scale(1.03);
}

.banner-slide p {
  margin: 0;
  color: rgba(255, 255, 255, 0.95);
  font-size: 0.88rem;
  line-height: 1.6;
}

/* Hero stats */
.hero-stats {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
  gap: clamp(10px, 2vw, 18px);
}

.stat-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 16px 12px;
  border-radius: var(--radius-md);
  background: rgba(255, 255, 255, 0.18);
  -webkit-backdrop-filter: blur(14px) saturate(170%);
  backdrop-filter: blur(14px) saturate(170%);
  border: 1px solid rgba(255, 255, 255, 0.32);
  transition: transform 0.35s var(--ease), background 0.35s var(--ease);
}

.stat-item:hover {
  transform: translateY(-4px);
  background: rgba(255, 255, 255, 0.28);
}

.stat-num {
  font-size: clamp(1.5rem, 3.4vw, 2.1rem);
  font-weight: 800;
  line-height: 1.2;
  color: #fff;
  letter-spacing: -0.02em;
  font-variant-numeric: tabular-nums;
}

.stat-label {
  font-size: 0.82rem;
  color: rgba(255, 255, 255, 0.9);
  margin-top: 2px;
  text-align: center;
}

/* ============ Breadcrumb ============ */
#breadcrumb {
  margin: 0 0 clamp(20px, 3vw, 32px);
}

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

#breadcrumb li {
  margin: 0;
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

#breadcrumb li + li::before {
  content: "/";
  color: var(--text-muted);
  opacity: 0.6;
}

#breadcrumb a {
  color: var(--text-soft);
  text-decoration: none;
  padding: 2px 6px;
  border-radius: var(--radius-sm);
  transition: background 0.25s var(--ease), color 0.25s var(--ease);
}

#breadcrumb a:hover {
  background: var(--brand-soft);
  color: var(--brand-dark);
  text-decoration: none;
}

#breadcrumb [aria-current="page"] {
  color: var(--brand-dark);
  font-weight: 600;
}

/* ============ Content sections (cards) ============ */
#intro,
#about,
#products,
#solutions,
#cases,
#news,
#articles,
#knowledge,
#faq,
#howto,
#contact,
#sitemap,
#links,
#privacy,
#disclaimer,
#copyright {
  background: var(--gradient-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: clamp(20px, 3.5vw, 40px);
  box-shadow: var(--shadow-md);
  -webkit-backdrop-filter: blur(10px);
  backdrop-filter: blur(10px);
  transition: box-shadow 0.4s var(--ease), transform 0.4s var(--ease), border-color 0.4s var(--ease);
}

#intro:hover,
#about:hover,
#products:hover,
#solutions:hover,
#cases:hover,
#news:hover,
#articles:hover,
#knowledge:hover,
#faq:hover,
#howto:hover,
#contact:hover {
  box-shadow: var(--shadow-lg);
  border-color: var(--border-strong);
}

/* Section headings spacing */
#intro h2, #about h2, #products h2, #solutions h2, #cases h2,
#news h2, #articles h2, #knowledge h2, #faq h2, #howto h2,
#contact h2, #sitemap h2, #links h2, #privacy h2, #disclaimer h2, #copyright h2 {
  margin-bottom: 1em;
}

#intro h3, #about h3, #products h3, #solutions h3, #cases h3,
#knowledge h3, #howto h3, #contact h3 {
  color: var(--text);
  border-bottom: 1px dashed var(--border-strong);
  padding-bottom: 0.4em;
}

/* ============ News / Articles cards ============ */
#news article,
#articles article {
  position: relative;
  background: var(--bg-elev);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  padding: clamp(14px, 2.2vw, 22px);
  margin-bottom: 14px;
  box-shadow: var(--shadow-sm);
  transition: transform 0.35s var(--ease), box-shadow 0.35s var(--ease), border-color 0.35s var(--ease);
  overflow: hidden;
}

#news article::before,
#articles article::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0;
  bottom: 0;
  width: 4px;
  background: linear-gradient(180deg, var(--brand), var(--accent));
  opacity: 0;
  transition: opacity 0.35s var(--ease);
}

#news article:hover,
#articles article:hover {
  transform: translateY(-3px);
  box-shadow: var(--shadow-md);
  border-color: var(--brand);
}

#news article:hover::before,
#articles article:hover::before {
  opacity: 1;
}

#news article h3,
#articles article h3 {
  margin-top: 0;
  font-size: clamp(1.02rem, 1.6vw, 1.2rem);
  transition: color 0.3s var(--ease);
}

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

#news article p,
#articles article p {
  margin-bottom: 0.6em;
  font-size: 0.94rem;
}

#news article p:first-of-type,
#articles article p:first-of-type {
  font-size: 0.8rem;
  color: var(--text-muted);
  font-weight: 500;
}

#articles article a {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  font-size: 0.88rem;
  font-weight: 600;
  padding: 5px 14px;
  border-radius: var(--radius-pill);
  background: var(--brand-soft);
  color: var(--brand-dark);
  text-decoration: none;
  transition: background 0.3s var(--ease), color 0.3s var(--ease), transform 0.3s var(--ease), box-shadow 0.3s var(--ease);
}

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

#articles article a:hover {
  background: var(--brand);
  color: #fff;
  text-decoration: none;
  transform: translateX(2px);
  box-shadow: 0 4px 14px rgba(255, 90, 95, 0.35);
}

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

/* ============ Cases quotes ============ */
#cases p {
  font-size: 0.96rem;
}

#cases h3 + p {
  border-left: 3px solid var(--brand);
  padding-left: 14px;
  background: var(--brand-soft);
  border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
  padding: 10px 14px;
}

/* ============ FAQ ============ */
#faq details {
  background: var(--bg-elev);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  padding: 0;
  margin-bottom: 10px;
  overflow: hidden;
  transition: box-shadow 0.3s var(--ease), border-color 0.3s var(--ease), background 0.3s var(--ease);
}

#faq details:hover {
  border-color: var(--border-strong);
  box-shadow: var(--shadow-sm);
}

#faq details[open] {
  border-color: var(--brand);
  box-shadow: 0 6px 22px rgba(255, 90, 95, 0.14);
  background: var(--bg-elev);
}

#faq summary {
  position: relative;
  list-style: none;
  cursor: pointer;
  padding: 14px 48px 14px 18px;
  font-weight: 600;
  font-size: 0.98rem;
  color: var(--text);
  transition: color 0.25s var(--ease), background 0.25s var(--ease);
  user-select: none;
}

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

#faq summary::after {
  content: "+";
  position: absolute;
  right: 16px;
  top: 50%;
  transform: translateY(-50%);
  width: 26px;
  height: 26px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.15rem;
  font-weight: 700;
  line-height: 1;
  color: var(--brand-dark);
  background: var(--brand-soft);
  border-radius: 50%;
  transition: transform 0.35s var(--ease), background 0.35s var(--ease), color 0.35s var(--ease);
}

#faq details[open] summary {
  color: var(--brand-dark);
  background: var(--brand-soft);
}

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

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

/* ============ HowTo steps ============ */
#howto ol {
  counter-reset: howto;
  list-style: none;
  padding-left: 0;
}

#howto ol li {
  counter-increment: howto;
  position: relative;
  padding: 12px 14px 12px 52px;
  margin-bottom: 8px;
  background: var(--bg-elev);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  font-size: 0.94rem;
  transition: transform 0.3s var(--ease), border-color 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;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.82rem;
  font-weight: 700;
  color: #fff;
  background: var(--gradient-hero);
  border-radius: 50%;
  box-shadow: 0 2px 8px rgba(255, 90, 95, 0.35);
}

#howto ol li:hover {
  transform: translateX(4px);
  border-color: var(--brand);
  box-shadow: var(--shadow-sm);
}

/* ============ Contact list ============ */
#contact ul {
  list-style: none;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 10px;
}

#contact ul li {
  margin: 0;
  padding: 12px 16px;
  background: var(--bg-elev);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  font-size: 0.92rem;
  transition: transform 0.3s var(--ease), border-color 0.3s var(--ease), box-shadow 0.3s var(--ease);
  word-break: break-word;
}

#contact ul li:hover {
  transform: translateY(-3px);
  border-color: var(--brand);
  box-shadow: var(--shadow-sm);
}

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

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

#sitemap a,
#links a {
  display: inline-block;
  padding: 7px 15px;
  font-size: 0.88rem;
  font-weight: 500;
  color: var(--text-soft);
  background: var(--bg-elev);
  border: 1px solid var(--border);
  border-radius: var(--radius-pill);
  text-decoration: none;
  transition: background 0.3s var(--ease), color 0.3s var(--ease), border-color 0.3s var(--ease), transform 0.3s var(--ease);
}

#sitemap a:hover,
#links a:hover {
  background: var(--brand);
  color: #fff;
  border-color: var(--brand);
  text-decoration: none;
  transform: translateY(-2px);
}

/* ============ Footer ============ */
#site-footer {
  margin-top: 20px;
  background: var(--bg-elev);
  border-top: 1px solid var(--border);
  color: var(--text-soft);
}

.footer-inner {
  max-width: var(--maxw);
  margin: 0 auto;
  padding: clamp(28px, 4vw, 48px) clamp(14px, 3vw, 28px);
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: clamp(20px, 3vw, 36px);
  align-items: start;
}

.footer-inner p {
  margin: 0 0 8px;
  font-size: 0.9rem;
  color: var(--text-soft);
}

.footer-brand strong {
  font-size: 1.05rem;
  background: var(--gradient-hero);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  color: transparent;
}

.footer-legal a {
  color: var(--text-soft);
  font-size: 0.88rem;
  text-decoration: none;
  transition: color 0.25s var(--ease);
}

.footer-legal a:hover {
  color: var(--brand-dark);
  text-decoration: underline;
}

.footer-contact,
.footer-legal {
  font-size: 0.88rem;
}

/* ============ Back to top ============ */
#back-to-top {
  position: fixed;
  right: clamp(14px, 3vw, 28px);
  bottom: clamp(14px, 3vw, 28px);
  z-index: 90;
  padding: 10px 16px;
  font-family: inherit;
  font-size: 0.85rem;
  font-weight: 600;
  color: #fff;
  background: var(--gradient-hero);
  border: none;
  border-radius: var(--radius-pill);
  cursor: pointer;
  box-shadow: 0 8px 24px rgba(255, 90, 95, 0.4);
  opacity: 0;
  visibility: hidden;
  transform: translateY(16px);
  transition: opacity 0.35s var(--ease), transform 0.35s var(--ease), visibility 0.35s var(--ease), box-shadow 0.35s var(--ease);
}

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

#back-to-top:hover {
  transform: translateY(-3px);
  box-shadow: 0 12px 30px rgba(255, 90, 95, 0.55);
}

#back-to-top:active {
  transform: translateY(0) scale(0.97);
}

/* ============ Reduced motion ============ */
@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;
  }
}

/* ============ Responsive ============ */
@media (max-width: 900px) {
  .header-inner {
    gap: 10px;
  }

  #site-header nav {
    order: 3;
    flex-basis: 100%;
  }

  .nav-list {
    gap: 2px;
  }

  .nav-list a {
    padding: 5px 9px;
    font-size: 0.84rem;
  }

  .site-search {
    margin-left: auto;
  }

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

@media (max-width: 640px) {
  :root {
    --header-h: 60px;
  }

  body {
    font-size: 15px;
  }

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

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

  .brand-logo {
    width: 34px;
    height: 34px;
  }

  .site-search {
    order: 2;
    flex-basis: 100%;
    margin-left: 0;
  }

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

  #site-header nav {
    order: 3;
  }

  .nav-list {
    flex-wrap: nowrap;
    overflow-x: auto;
    padding-bottom: 4px;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
  }

  .nav-list::-webkit-scrollbar {
    display: none;
  }

  .nav-list a {
    padding: 5px 10px;
    font-size: 0.82rem;
  }

  #hero {
    padding: 22px 16px;
    border-radius: var(--radius-md);
  }

  #hero h1 {
    max-width: none;
  }

  .hero-banner {
    grid-template-columns: 1fr;
  }

  .hero-stats {
    grid-template-columns: repeat(3, 1fr);
    gap: 8px;
  }

  .stat-item {
    padding: 12px 6px;
  }

  .stat-label {
    font-size: 0.72rem;
  }

  #intro,
  #about,
  #products,
  #solutions,
  #cases,
  #news,
  #articles,
  #knowledge,
  #faq,
  #howto,
  #contact,
  #sitemap,
  #links,
  #privacy,
  #disclaimer,
  #copyright {
    padding: 18px 16px;
    border-radius: var(--radius-md);
  }

  h2 {
    padding-left: 14px;
  }

  h2::before {
    width: 5px;
  }

  #faq summary {
    padding: 12px 44px 12px 14px;
    font-size: 0.92rem;
  }

  #faq summary::after {
    right: 12px;
    width: 24px;
    height: 24px;
  }

  #howto ol li {
    padding: 10px 12px 10px 46px;
  }

  #howto ol li::before {
    left: 12px;
    width: 24px;
    height: 24px;
  }

  .footer-inner {
    grid-template-columns: 1fr;
  }

  #back-to-top {
    padding: 9px 14px;
    font-size: 0.8rem;
  }
}

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

  .stat-num {
    font-size: 1.4rem;
  }
}

/* ============ Print ============ */
@media print {
  #site-header,
  #back-to-top,
  .site-search,
  #hero::before,
  #hero::after {
    display: none !important;
  }

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

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

  a {
    color: #000;
    text-decoration: underline;
  }
}