:root {
  --bg: #0b0b14;
  --bg-soft: #12121f;
  --surface: rgba(26, 26, 46, 0.72);
  --surface-solid: #1a1a2e;
  --surface-2: #16213e;
  --surface-3: #0f3460;
  --border: rgba(255, 255, 255, 0.09);
  --border-strong: rgba(255, 255, 255, 0.16);
  --text: #eef0f6;
  --text-soft: #b9bed1;
  --text-muted: #8b91a8;
  --accent: #e94560;
  --accent-2: #ff7a90;
  --accent-3: #7b6cff;
  --accent-soft: rgba(233, 69, 96, 0.14);
  --glow: rgba(233, 69, 96, 0.35);
  --radius-lg: 22px;
  --radius-md: 16px;
  --radius-sm: 12px;
  --radius-pill: 999px;
  --shadow-sm: 0 4px 14px rgba(0, 0, 0, 0.28);
  --shadow-md: 0 14px 40px rgba(0, 0, 0, 0.38);
  --shadow-lg: 0 26px 70px rgba(0, 0, 0, 0.5);
  --blur: saturate(160%) blur(16px);
  --ease: cubic-bezier(0.22, 0.68, 0.35, 1);
  --header-h: 76px;
  --maxw: 1180px;
  --font: "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", "Noto Sans SC", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
}

@media (prefers-color-scheme: light) {
  :root {
    --bg: #f4f5fb;
    --bg-soft: #eceef8;
    --surface: rgba(255, 255, 255, 0.74);
    --surface-solid: #ffffff;
    --surface-2: #f2f3fa;
    --surface-3: #e8eaf6;
    --border: rgba(18, 18, 40, 0.08);
    --border-strong: rgba(18, 18, 40, 0.16);
    --text: #1a1a2e;
    --text-soft: #3d4260;
    --text-muted: #6b7089;
    --accent: #d92b4b;
    --accent-2: #e94560;
    --accent-3: #5b4bdb;
    --accent-soft: rgba(217, 43, 75, 0.1);
    --glow: rgba(217, 43, 75, 0.22);
    --shadow-sm: 0 4px 14px rgba(26, 26, 46, 0.08);
    --shadow-md: 0 14px 40px rgba(26, 26, 46, 0.12);
    --shadow-lg: 0 26px 70px rgba(26, 26, 46, 0.18);
  }
}

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

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

body {
  margin: 0;
  font-family: var(--font);
  font-size: 16px;
  line-height: 1.78;
  color: var(--text);
  background:
    radial-gradient(1200px 620px at 12% -8%, rgba(233, 69, 96, 0.16), transparent 62%),
    radial-gradient(1000px 560px at 92% 4%, rgba(123, 108, 255, 0.16), transparent 60%),
    linear-gradient(180deg, var(--bg) 0%, var(--bg-soft) 52%, var(--bg) 100%);
  background-attachment: fixed;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

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

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

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

a:focus-visible,
button:focus-visible,
input:focus-visible,
summary:focus-visible {
  outline: 2px solid var(--accent-2);
  outline-offset: 3px;
  border-radius: 6px;
}

ul,
ol {
  margin: 0;
  padding: 0;
  list-style: none;
}

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

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

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

h2::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0.16em;
  bottom: 0.16em;
  width: 5px;
  border-radius: var(--radius-pill);
  background: linear-gradient(180deg, var(--accent), var(--accent-3));
  box-shadow: 0 0 18px var(--glow);
}

h3 {
  font-size: clamp(1.08rem, 2vw, 1.3rem);
  color: var(--text);
}

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

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

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

time {
  color: var(--text-muted);
  font-size: 0.86rem;
  font-variant-numeric: tabular-nums;
}

address {
  font-style: normal;
}

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

::-webkit-scrollbar {
  width: 10px;
  height: 10px;
}

::-webkit-scrollbar-track {
  background: transparent;
}

::-webkit-scrollbar-thumb {
  background: linear-gradient(180deg, var(--accent), var(--accent-3));
  border-radius: var(--radius-pill);
  border: 2px solid transparent;
  background-clip: padding-box;
}

/* ============ Header ============ */

#site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 14px 22px;
  padding: 14px clamp(16px, 4vw, 40px);
  background: var(--surface);
  -webkit-backdrop-filter: var(--blur);
  backdrop-filter: var(--blur);
  border-bottom: 1px solid var(--border);
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.18);
}

#site-header::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: -1px;
  height: 1px;
  background: linear-gradient(90deg, transparent, var(--accent), var(--accent-3), transparent);
  opacity: 0.7;
}

.brand-row {
  display: flex;
  align-items: center;
  gap: 12px;
  flex: 0 0 auto;
}

.brand-row > a {
  display: inline-flex;
  border-radius: 14px;
  transition: transform 0.35s var(--ease), box-shadow 0.35s var(--ease);
  box-shadow: 0 6px 20px rgba(233, 69, 96, 0.28);
}

.brand-row > a:hover {
  transform: rotate(-6deg) scale(1.06);
  box-shadow: 0 10px 28px rgba(233, 69, 96, 0.45);
}

.brand-text {
  display: flex;
  flex-direction: column;
  line-height: 1.3;
}

.brand-text strong {
  font-size: 1.06rem;
  letter-spacing: 0.02em;
  background: linear-gradient(92deg, var(--text), var(--accent-2));
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
}

.brand-text span {
  font-size: 0.74rem;
  color: var(--text-muted);
  letter-spacing: 0.02em;
}

#main-nav {
  flex: 1 1 auto;
  min-width: 0;
}

#main-nav ul {
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
  justify-content: center;
}

#main-nav a {
  display: inline-block;
  padding: 7px 13px;
  border-radius: var(--radius-pill);
  font-size: 0.88rem;
  color: var(--text-soft);
  border: 1px solid transparent;
  transition: color 0.25s var(--ease), background 0.25s var(--ease),
    border-color 0.25s var(--ease), transform 0.25s var(--ease);
}

#main-nav a:hover,
#main-nav a:focus-visible {
  color: #fff;
  background: linear-gradient(135deg, var(--accent), var(--accent-3));
  border-color: transparent;
  transform: translateY(-2px);
  box-shadow: 0 8px 22px var(--glow);
}

#site-search {
  display: flex;
  align-items: center;
  gap: 8px;
  flex: 0 1 320px;
  min-width: 0;
  padding: 5px 5px 5px 14px;
  border-radius: var(--radius-pill);
  background: var(--surface-2);
  border: 1px solid var(--border);
  transition: border-color 0.3s var(--ease), box-shadow 0.3s var(--ease);
}

#site-search:focus-within {
  border-color: var(--accent);
  box-shadow: 0 0 0 4px var(--accent-soft);
}

#site-search label {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
}

#site-search input {
  flex: 1 1 auto;
  min-width: 0;
  padding: 7px 0;
  border: 0;
  background: transparent;
  color: var(--text);
  font-family: inherit;
  font-size: 0.9rem;
}

#site-search input::placeholder {
  color: var(--text-muted);
}

#site-search input:focus {
  outline: none;
}

#site-search button {
  flex: 0 0 auto;
  padding: 8px 18px;
  border: 0;
  border-radius: var(--radius-pill);
  font-family: inherit;
  font-size: 0.86rem;
  font-weight: 600;
  color: #fff;
  cursor: pointer;
  background: linear-gradient(135deg, var(--accent), var(--accent-3));
  box-shadow: 0 6px 18px var(--glow);
  transition: transform 0.25s var(--ease), box-shadow 0.25s var(--ease), filter 0.25s var(--ease);
}

#site-search button:hover {
  transform: translateY(-1px);
  filter: brightness(1.08);
  box-shadow: 0 10px 26px var(--glow);
}

#site-search button:active {
  transform: translateY(0) scale(0.97);
}

/* ============ Layout ============ */

main {
  display: block;
  width: 100%;
  max-width: var(--maxw);
  margin: 0 auto;
  padding: clamp(18px, 3vw, 34px) clamp(14px, 4vw, 32px) 60px;
}

main > section {
  position: relative;
  margin-bottom: clamp(22px, 3.4vw, 38px);
  padding: clamp(20px, 3.4vw, 38px);
  border-radius: var(--radius-lg);
  background: var(--surface);
  -webkit-backdrop-filter: var(--blur);
  backdrop-filter: var(--blur);
  border: 1px solid var(--border);
  box-shadow: var(--shadow-md);
  overflow: hidden;
  animation: rise-in 0.75s var(--ease) both;
  animation-timeline: view();
  animation-range: entry 0% cover 26%;
}

main > section::before {
  content: "";
  position: absolute;
  inset: 0 0 auto 0;
  height: 1px;
  background: linear-gradient(90deg, transparent, var(--border-strong), transparent);
  pointer-events: none;
}

main > section:hover {
  border-color: var(--border-strong);
  transition: border-color 0.4s var(--ease);
}

@keyframes rise-in {
  from {
    opacity: 0;
    transform: translateY(28px) scale(0.985);
  }
  to {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

@supports not (animation-timeline: view()) {
  main > section {
    animation: none;
  }
}

/* ============ Hero ============ */

#hero {
  padding: clamp(24px, 4vw, 46px);
  background:
    radial-gradient(680px 340px at 88% -10%, rgba(233, 69, 96, 0.34), transparent 66%),
    radial-gradient(620px 380px at 0% 110%, rgba(123, 108, 255, 0.3), transparent 64%),
    linear-gradient(140deg, rgba(26, 26, 46, 0.94), rgba(15, 52, 96, 0.86) 55%, rgba(22, 33, 62, 0.94));
  border: 1px solid var(--border-strong);
  box-shadow: var(--shadow-lg), inset 0 1px 0 rgba(255, 255, 255, 0.06);
}

#hero::after {
  content: "";
  position: absolute;
  top: -40%;
  right: -12%;
  width: 420px;
  height: 420px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(233, 69, 96, 0.35), transparent 68%);
  filter: blur(28px);
  pointer-events: none;
  animation: float-glow 12s ease-in-out infinite alternate;
}

@keyframes float-glow {
  from {
    transform: translate3d(0, 0, 0) scale(1);
    opacity: 0.7;
  }
  to {
    transform: translate3d(-40px, 30px, 0) scale(1.14);
    opacity: 1;
  }
}

#hero-title {
  position: relative;
  z-index: 1;
  max-width: 24ch;
  margin-bottom: 0.5em;
  background: linear-gradient(96deg, #ffffff 8%, #ffd6de 44%, #b9b2ff 92%);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  text-shadow: 0 10px 40px rgba(0, 0, 0, 0.28);
}

#hero > p {
  position: relative;
  z-index: 1;
  max-width: 74ch;
  font-size: clamp(0.94rem, 1.5vw, 1.02rem);
  color: rgba(238, 240, 246, 0.82);
}

/* Carousel */

#hero-carousel {
  position: relative;
  z-index: 1;
  display: grid;
  grid-auto-flow: column;
  grid-auto-columns: minmax(280px, 1fr);
  gap: 18px;
  margin: 26px 0 22px;
  padding-bottom: 10px;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  scrollbar-width: thin;
  -webkit-overflow-scrolling: touch;
}

#hero-carousel .slide {
  position: relative;
  display: flex;
  flex-direction: column;
  scroll-snap-align: center;
  padding: 0 0 18px;
  border-radius: var(--radius-md);
  overflow: hidden;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.12);
  -webkit-backdrop-filter: blur(10px) saturate(150%);
  backdrop-filter: blur(10px) saturate(150%);
  box-shadow: var(--shadow-sm);
  transition: transform 0.45s var(--ease), box-shadow 0.45s var(--ease),
    border-color 0.45s var(--ease);
}

#hero-carousel .slide:hover {
  transform: translateY(-8px);
  border-color: rgba(233, 69, 96, 0.55);
  box-shadow: 0 24px 54px rgba(0, 0, 0, 0.45), 0 0 0 1px rgba(233, 69, 96, 0.25);
}

#hero-carousel .slide svg {
  width: 100%;
  height: auto;
  aspect-ratio: 2 / 1;
  object-fit: cover;
  transition: transform 0.6s var(--ease), filter 0.6s var(--ease);
}

#hero-carousel .slide:hover svg {
  transform: scale(1.045);
  filter: saturate(120%) brightness(1.06);
}

#hero-carousel .slide h2 {
  margin: 16px 18px 0.45em;
  padding-left: 0;
  font-size: clamp(1rem, 1.7vw, 1.16rem);
  line-height: 1.45;
  color: #fff;
}

#hero-carousel .slide h2::before {
  display: none;
}

#hero-carousel .slide p {
  margin: 0 18px;
  font-size: 0.88rem;
  color: rgba(238, 240, 246, 0.74);
}

/* Stats */

#hero-stats {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
  gap: 12px;
  margin: 0;
}

#hero-stats p {
  margin: 0;
  padding: 16px 18px;
  border-radius: var(--radius-sm);
  font-size: 0.84rem;
  color: rgba(238, 240, 246, 0.72);
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.1);
  -webkit-backdrop-filter: blur(8px);
  backdrop-filter: blur(8px);
  transition: transform 0.35s var(--ease), background 0.35s var(--ease),
    border-color 0.35s var(--ease);
}

#hero-stats p:hover {
  transform: translateY(-4px);
  background: rgba(233, 69, 96, 0.16);
  border-color: rgba(233, 69, 96, 0.42);
}

#hero-stats strong {
  display: block;
  font-size: clamp(1.4rem, 3vw, 1.85rem);
  line-height: 1.2;
  margin-bottom: 2px;
  font-variant-numeric: tabular-nums;
  background: linear-gradient(100deg, #fff, var(--accent-2));
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
}

/* ============ Breadcrumb ============ */

#breadcrumb {
  padding: 0 4px;
  margin-bottom: 18px;
}

#breadcrumb ol {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  font-size: 0.84rem;
  color: var(--text-muted);
}

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

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

#breadcrumb a {
  color: var(--text-soft);
  padding: 3px 8px;
  border-radius: var(--radius-pill);
  transition: background 0.25s var(--ease), color 0.25s var(--ease);
}

#breadcrumb a:hover {
  color: var(--accent-2);
  background: var(--accent-soft);
}

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

/* ============ Content sections ============ */

#intro p,
#brand p,
#products p,
#advantages p,
#solutions p,
#applications p,
#cases p,
#knowledge p,
#contact p,
#legal p,
#author p {
  max-width: 82ch;
}

#intro h3,
#brand h3,
#products h3,
#advantages h3,
#solutions h3,
#applications h3,
#cases h3,
#knowledge h3,
#howto h3,
#contact h3,
#legal h3 {
  margin-top: 1.5em;
  padding-bottom: 0.4em;
  border-bottom: 1px dashed var(--border);
}

#intro h3:first-of-type,
#brand h3:first-of-type,
#products h3:first-of-type,
#advantages h3:first-of-type,
#solutions h3:first-of-type,
#applications h3:first-of-type,
#cases h3:first-of-type,
#knowledge h3:first-of-type,
#howto h3:first-of-type,
#contact h3:first-of-type,
#legal h3:first-of-type {
  margin-top: 0.6em;
}

#intro h4,
#products h4 {
  display: inline-block;
  padding: 3px 12px;
  border-radius: var(--radius-pill);
  background: var(--accent-soft);
  color: var(--accent-2);
  font-size: 0.84rem;
  font-weight: 600;
  letter-spacing: 0.02em;
}

#products h3,
#advantages h3,
#solutions h3 {
  position: relative;
  padding-left: 14px;
  border-bottom: 0;
}

#products h3::before,
#advantages h3::before,
#solutions h3::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0.42em;
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--accent), var(--accent-3));
  box-shadow: 0 0 12px var(--glow);
}

#products h3,
#products h4,
#solutions h3,
#applications h3,
#cases h3,
#knowledge h3 {
  transition: color 0.3s var(--ease);
}

#products h3:hover,
#solutions h3:hover,
#applications h3:hover,
#cases h3:hover,
#knowledge h3:hover {
  color: var(--accent-2);
}

/* ============ Testimonials ============ */

#testimonials {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 16px;
}

#testimonials h2 {
  grid-column: 1 / -1;
}

#testimonials blockquote {
  position: relative;
  margin: 0;
  padding: 22px 22px 18px;
  border-radius: var(--radius-md);
  background: linear-gradient(160deg, var(--surface-2), var(--surface-3));
  border: 1px solid var(--border);
  box-shadow: var(--shadow-sm);
  transition: transform 0.4s var(--ease), box-shadow 0.4s var(--ease),
    border-color 0.4s var(--ease);
}

#testimonials blockquote::before {
  content: "“";
  position: absolute;
  top: 2px;
  left: 14px;
  font-size: 3.2rem;
  line-height: 1;
  font-family: Georgia, serif;
  color: var(--accent);
  opacity: 0.35;
  pointer-events: none;
}

#testimonials blockquote:hover {
  transform: translateY(-6px);
  border-color: rgba(233, 69, 96, 0.4);
  box-shadow: 0 20px 44px rgba(0, 0, 0, 0.32);
}

#testimonials blockquote p {
  position: relative;
  margin: 0 0 12px;
  font-size: 0.94rem;
  color: var(--text);
}

#testimonials blockquote footer {
  font-size: 0.82rem;
  color: var(--text-muted);
  border-top: 1px dashed var(--border);
  padding-top: 10px;
}

/* ============ News & Articles ============ */

#news article,
#articles article {
  position: relative;
  padding: 18px 20px;
  margin-bottom: 14px;
  border-radius: var(--radius-md);
  background: var(--surface-2);
  border: 1px solid var(--border);
  transition: transform 0.35s var(--ease), border-color 0.35s var(--ease),
    box-shadow 0.35s var(--ease), background 0.35s var(--ease);
}

#news article::after,
#articles article::after {
  content: "";
  position: absolute;
  left: 0;
  top: 16px;
  bottom: 16px;
  width: 3px;
  border-radius: var(--radius-pill);
  background: linear-gradient(180deg, var(--accent), var(--accent-3));
  opacity: 0;
  transition: opacity 0.35s var(--ease);
}

#news article:hover,
#articles article:hover {
  transform: translateX(6px);
  border-color: rgba(233, 69, 96, 0.38);
  box-shadow: var(--shadow-md);
}

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

#news article h3,
#articles article h3 {
  margin-bottom: 0.35em;
  font-size: clamp(1rem, 1.8vw, 1.12rem);
  transition: color 0.3s var(--ease);
}

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

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

#articles article a {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 0.86rem;
  font-weight: 600;
  padding: 5px 14px;
  border-radius: var(--radius-pill);
  color: var(--accent-2);
  background: var(--accent-soft);
  border: 1px solid rgba(233, 69, 96, 0.24);
  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 {
  color: #fff;
  background: linear-gradient(135deg, var(--accent), var(--accent-3));
  border-color: transparent;
  transform: translateX(3px);
  box-shadow: 0 8px 20px var(--glow);
}

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

/* ============ FAQ ============ */

#faq details {
  margin-bottom: 12px;
  border-radius: var(--radius-md);
  background: var(--surface-2);
  border: 1px solid var(--border);
  overflow: hidden;
  transition: border-color 0.35s var(--ease), box-shadow 0.35s var(--ease),
    background 0.35s var(--ease);
}

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

#faq details[open] {
  border-color: rgba(233, 69, 96, 0.42);
  box-shadow: 0 12px 34px rgba(0, 0, 0, 0.24);
  background: linear-gradient(160deg, var(--surface-2), rgba(233, 69, 96, 0.06));
}

#faq summary {
  position: relative;
  padding: 15px 52px 15px 20px;
  font-weight: 600;
  font-size: 0.95rem;
  color: var(--text);
  cursor: pointer;
  list-style: none;
  transition: color 0.3s var(--ease);
}

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

#faq summary::after {
  content: "+";
  position: absolute;
  right: 18px;
  top: 50%;
  transform: translateY(-50%);
  width: 26px;
  height: 26px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  font-size: 1.05rem;
  font-weight: 400;
  color: var(--accent-2);
  background: var(--accent-soft);
  transition: transform 0.35s var(--ease), background 0.35s var(--ease),
    color 0.35s var(--ease);
}

#faq details[open] summary {
  color: var(--accent-2);
}

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

#faq details p {
  margin: 0;
  padding: 0 20px 18px;
  font-size: 0.92rem;
  color: var(--text-soft);
  animation: fade-slide 0.4s var(--ease) both;
}

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

/* ============ HowTo ============ */

#howto ol {
  counter-reset: step;
  display: grid;
  gap: 12px;
  margin: 0 0 1em;
}

#howto ol li {
  position: relative;
  counter-increment: step;
  padding: 14px 18px 14px 58px;
  border-radius: var(--radius-md);
  background: var(--surface-2);
  border: 1px solid var(--border);
  font-size: 0.94rem;
  color: var(--text-soft);
  transition: transform 0.35s var(--ease), border-color 0.35s var(--ease),
    box-shadow 0.35s var(--ease);
}

#howto ol li::before {
  content: counter(step, decimal-leading-zero);
  position: absolute;
  left: 16px;
  top: 50%;
  transform: translateY(-50%);
  width: 30px;
  height: 30px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  font-size: 0.78rem;
  font-weight: 700;
  color: #fff;
  background: linear-gradient(135deg, var(--accent), var(--accent-3));
  box-shadow: 0 6px 16px var(--glow);
}

#howto ol li:hover {
  transform: translateX(6px);
  border-color: rgba(233, 69, 96, 0.4);
  box-shadow: var(--shadow-sm);
}

/* ============ Contact ============ */

#contact address {
  display: grid;
  gap: 10px;
  margin: 0 0 1.4em;
  padding: 20px 22px;
  border-radius: var(--radius-md);
  background: linear-gradient(150deg, var(--surface-2), var(--surface-3));
  border: 1px solid var(--border);
}

#contact address p {
  margin: 0;
  font-size: 0.92rem;
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: baseline;
}

#contact address p::before {
  content: "";
  flex: 0 0 auto;
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--accent);
  box-shadow: 0 0 10px var(--glow);
}

#contact address a {
  font-weight: 600;
  border-bottom: 1px dashed rgba(233, 69, 96, 0.4);
  transition: border-color 0.25s var(--ease), color 0.25s var(--ease);
}

#contact address a:hover {
  border-bottom-color: var(--accent);
}

/* ============ Sitemap & Links ============ */

#sitemap ul,
#links ul {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

#sitemap a,
#links a {
  display: inline-block;
  padding: 8px 16px;
  border-radius: var(--radius-pill);
  font-size: 0.86rem;
  color: var(--text-soft);
  background: var(--surface-2);
  border: 1px solid var(--border);
  transition: transform 0.28s var(--ease), color 0.28s var(--ease),
    background 0.28s var(--ease), border-color 0.28s var(--ease),
    box-shadow 0.28s var(--ease);
}

#sitemap a:hover,
#links a:hover {
  color: #fff;
  background: linear-gradient(135deg, var(--accent), var(--accent-3));
  border-color: transparent;
  transform: translateY(-3px);
  box-shadow: 0 10px 24px var(--glow);
}

/* ============ Footer ============ */

#site-footer {
  position: relative;
  margin-top: 20px;
  padding: clamp(28px, 4vw, 48px) clamp(16px, 4vw, 40px) 26px;
  background:
    radial-gradient(700px 320px at 8% 0%, rgba(233, 69, 96, 0.14), transparent 62%),
    radial-gradient(700px 320px at 96% 10%, rgba(123, 108, 255, 0.14), transparent 60%),
    var(--surface);
  -webkit-backdrop-filter: var(--blur);
  backdrop-filter: var(--blur);
  border-top: 1px solid var(--border);
}

#site-footer::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 1px;
  background: linear-gradient(90deg, transparent, var(--accent), var(--accent-3), transparent);
}

#site-footer section {
  max-width: var(--maxw);
  margin: 0 auto 26px;
  padding-bottom: 22px;
  border-bottom: 1px dashed var(--border);
}

#site-footer section:last-of-type {
  border-bottom: 0;
  padding-bottom: 0;
}

#site-footer h2 {
  font-size: 1.12rem;
  margin-bottom: 0.8em;
}

#site-footer h3 {
  font-size: 0.96rem;
  margin-top: 1.1em;
  color: var(--text-soft);
}

#site-footer p {
  font-size: 0.88rem;
  margin-bottom: 0.6em;
  color: var(--text-muted);
}

#site-footer p a {
  color: var(--accent-2);
}

#copyright {
  max-width: var(--maxw);
  margin: 0 auto;
  padding-top: 18px;
  text-align: center;
  font-size: 0.82rem;
  color: var(--text-muted);
  letter-spacing: 0.02em;
}

/* ============ Back to top ============ */

#back-to-top {
  position: fixed;
  right: clamp(14px, 3vw, 28px);
  bottom: clamp(14px, 3vw, 28px);
  z-index: 90;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 11px 18px;
  border-radius: var(--radius-pill);
  font-size: 0.82rem;
  font-weight: 600;
  color: #fff;
  background: linear-gradient(135deg, var(--accent), var(--accent-3));
  border: 1px solid rgba(255, 255, 255, 0.18);
  box-shadow: 0 12px 32px var(--glow);
  -webkit-backdrop-filter: blur(8px);
  backdrop-filter: blur(8px);
  transition: transform 0.3s var(--ease), box-shadow 0.3s var(--ease),
    filter 0.3s var(--ease);
}

#back-to-top::before {
  content: "↑";
  margin-right: 6px;
  font-size: 0.95rem;
  transition: transform 0.3s var(--ease);
}

#back-to-top:hover {
  transform: translateY(-4px);
  filter: brightness(1.08);
  box-shadow: 0 18px 42px var(--glow);
  color: #fff;
}

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

/* ============ Responsive ============ */

@media (max-width: 1024px) {
  #main-nav ul {
    justify-content: flex-start;
  }

  #site-search {
    flex: 1 1 240px;
  }
}

@media (max-width: 860px) {
  :root {
    --header-h: 64px;
  }

  #site-header {
    gap: 12px;
    padding: 12px 16px;
  }

  #main-nav {
    order: 3;
    flex: 1 1 100%;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
  }

  #main-nav::-webkit-scrollbar {
    display: none;
  }

  #main-nav ul {
    flex-wrap: nowrap;
    justify-content: flex-start;
    gap: 6px;
    padding-bottom: 2px;
  }

  #main-nav a {
    white-space: nowrap;
  }

  #site-search {
    order: 2;
    flex: 1 1 auto;
    max-width: 100%;
  }

  #hero-carousel {
    grid-auto-columns: minmax(260px, 84%);
  }
}

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

  .brand-text span {
    display: none;
  }

  .brand-text strong {
    font-size: 0.98rem;
  }

  #hero {
    padding: 20px 16px 22px;
  }

  #hero-title {
    max-width: none;
  }

  #hero-carousel {
    grid-auto-columns: minmax(240px, 90%);
    gap: 12px;
  }

  #hero-stats {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 10px;
  }

  #hero-stats p {
    padding: 12px 14px;
  }

  main {
    padding-left: 12px;
    padding-right: 12px;
  }

  main > section {
    border-radius: var(--radius-md);
    padding: 18px 16px;
  }

  h2 {
    padding-left: 14px;
  }

  #testimonials {
    grid-template-columns: 1fr;
  }

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

  #howto ol li {
    padding: 12px 14px 12px 52px;
  }

  #sitemap a,
  #links a {
    padding: 7px 13px;
    font-size: 0.82rem;
  }

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

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

  #site-search button {
    padding: 8px 13px;
  }
}

/* ============ Motion & a11y ============ */

@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;
    scroll-behavior: auto !important;
  }
}

@media print {
  #site-header,
  #back-to-top,
  #hero-carousel,
  #hero-stats,
  #links {
    display: none !important;
  }

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

  main > section {
    box-shadow: none;
    border: 1px solid #ddd;
    background: #fff;
    -webkit-backdrop-filter: none;
    backdrop-filter: none;
    animation: none;
  }
}