:root {
  --bg: #f4f6fb;
  --bg-soft: #eef1f8;
  --surface: #ffffff;
  --surface-glass: rgba(255, 255, 255, 0.72);
  --surface-glass-strong: rgba(255, 255, 255, 0.9);
  --border: rgba(15, 27, 61, 0.1);
  --text: #16203a;
  --text-soft: #4c5875;
  --text-muted: #7a859f;
  --brand: #0f1b3d;
  --brand-2: #1c2c5b;
  --accent: #f5c451;
  --accent-2: #7fb3ff;
  --accent-3: #5f7cff;
  --shadow-sm: 0 2px 10px rgba(15, 27, 61, 0.06);
  --shadow-md: 0 10px 30px rgba(15, 27, 61, 0.1);
  --shadow-lg: 0 24px 60px rgba(15, 27, 61, 0.16);
  --radius-sm: 10px;
  --radius-md: 16px;
  --radius-lg: 24px;
  --radius-pill: 999px;
  --gradient-hero: linear-gradient(135deg, #0f1b3d 0%, #1c2c5b 45%, #2a3f7d 100%);
  --gradient-accent: linear-gradient(135deg, #f5c451 0%, #ffdf8a 100%);
  --gradient-cool: linear-gradient(135deg, #5f7cff 0%, #7fb3ff 100%);
  --header-h: 68px;
  --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;
}

html[data-theme="dark"] {
  --bg: #070c1c;
  --bg-soft: #0b1226;
  --surface: #111a33;
  --surface-glass: rgba(17, 26, 51, 0.68);
  --surface-glass-strong: rgba(17, 26, 51, 0.9);
  --border: rgba(127, 179, 255, 0.16);
  --text: #e8eefc;
  --text-soft: #b3c0dd;
  --text-muted: #8592b0;
  --brand: #7fb3ff;
  --brand-2: #a9c8ff;
  --accent: #f5c451;
  --accent-2: #7fb3ff;
  --accent-3: #8fa6ff;
  --shadow-sm: 0 2px 10px rgba(0, 0, 0, 0.35);
  --shadow-md: 0 10px 30px rgba(0, 0, 0, 0.45);
  --shadow-lg: 0 24px 60px rgba(0, 0, 0, 0.55);
  --gradient-hero: linear-gradient(135deg, #060a18 0%, #101a38 50%, #1b2a55 100%);
}

@media (prefers-color-scheme: dark) {
  html:not([data-theme="light"]) {
    --bg: #070c1c;
    --bg-soft: #0b1226;
    --surface: #111a33;
    --surface-glass: rgba(17, 26, 51, 0.68);
    --surface-glass-strong: rgba(17, 26, 51, 0.9);
    --border: rgba(127, 179, 255, 0.16);
    --text: #e8eefc;
    --text-soft: #b3c0dd;
    --text-muted: #8592b0;
    --brand: #7fb3ff;
    --brand-2: #a9c8ff;
    --accent-2: #7fb3ff;
    --accent-3: #8fa6ff;
    --shadow-sm: 0 2px 10px rgba(0, 0, 0, 0.35);
    --shadow-md: 0 10px 30px rgba(0, 0, 0, 0.45);
    --shadow-lg: 0 24px 60px rgba(0, 0, 0, 0.55);
    --gradient-hero: linear-gradient(135deg, #060a18 0%, #101a38 50%, #1b2a55 100%);
  }
}

*,
*::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: var(--bg);
  background-image:
    radial-gradient(1000px 500px at 12% -8%, rgba(95, 124, 255, 0.14), transparent 60%),
    radial-gradient(900px 460px at 92% 4%, rgba(245, 196, 81, 0.12), transparent 60%);
  background-attachment: fixed;
  transition: background-color 0.4s var(--ease), color 0.4s var(--ease);
  overflow-x: hidden;
}

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

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

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

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

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

h1 { font-size: clamp(1.65rem, 4vw, 2.6rem); }
h2 { font-size: clamp(1.35rem, 2.8vw, 1.9rem); }
h3 { font-size: clamp(1.1rem, 2vw, 1.35rem); }
h4 { font-size: 1.05rem; }

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

li::marker {
  color: var(--accent);
}

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

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

blockquote {
  margin: 0;
  padding: 18px 22px;
  border-left: 3px solid var(--accent);
  border-radius: var(--radius-sm);
  background: var(--surface-glass);
  -webkit-backdrop-filter: blur(14px);
  backdrop-filter: blur(14px);
  box-shadow: var(--shadow-sm);
}

blockquote p {
  margin: 0;
  color: var(--text);
}

.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-glass);
  -webkit-backdrop-filter: blur(18px) saturate(160%);
  backdrop-filter: blur(18px) saturate(160%);
  border-bottom: 1px solid var(--border);
  transition: background-color 0.4s var(--ease), box-shadow 0.3s var(--ease);
}

#site-header.is-scrolled {
  box-shadow: var(--shadow-md);
}

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

.brand-logo {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-weight: 800;
  font-size: 1.15rem;
  color: var(--text);
  letter-spacing: 0.02em;
  flex-shrink: 0;
}

.brand-logo svg {
  transition: transform 0.5s var(--ease);
  filter: drop-shadow(0 4px 12px rgba(245, 196, 81, 0.35));
}

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

.brand-logo:hover {
  color: var(--accent);
}

.brand-name {
  background: linear-gradient(100deg, var(--text) 20%, var(--accent) 90%);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
}

#main-nav {
  flex: 1 1 auto;
}

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

#main-nav a {
  display: inline-block;
  padding: 8px 12px;
  border-radius: var(--radius-pill);
  font-size: 0.925rem;
  color: var(--text-soft);
  white-space: nowrap;
  transition: background-color 0.25s var(--ease), color 0.25s var(--ease), transform 0.25s var(--ease);
}

#main-nav a:hover,
#main-nav a:focus-visible {
  color: var(--text);
  background: rgba(127, 179, 255, 0.16);
  transform: translateY(-2px);
}

#site-search {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 4px;
  border-radius: var(--radius-pill);
  background: var(--surface-glass-strong);
  border: 1px solid var(--border);
  box-shadow: var(--shadow-sm);
  transition: box-shadow 0.3s var(--ease), border-color 0.3s var(--ease);
}

#site-search:focus-within {
  border-color: var(--accent-2);
  box-shadow: 0 0 0 4px rgba(127, 179, 255, 0.18);
}

#search-input {
  border: 0;
  background: transparent;
  color: var(--text);
  font: inherit;
  font-size: 0.9rem;
  padding: 7px 10px 7px 14px;
  width: 170px;
  outline: none;
  border-radius: var(--radius-pill);
}

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

#site-search button {
  border: 0;
  cursor: pointer;
  font: inherit;
  font-size: 0.875rem;
  font-weight: 600;
  padding: 7px 16px;
  border-radius: var(--radius-pill);
  color: #0f1b3d;
  background: var(--gradient-accent);
  transition: transform 0.25s var(--ease), box-shadow 0.25s var(--ease), filter 0.25s var(--ease);
}

#site-search button:hover {
  transform: translateY(-1px);
  box-shadow: 0 6px 18px rgba(245, 196, 81, 0.4);
  filter: brightness(1.05);
}

#theme-toggle,
#menu-toggle {
  border: 1px solid var(--border);
  background: var(--surface-glass-strong);
  color: var(--text-soft);
  font: inherit;
  font-size: 0.875rem;
  font-weight: 600;
  padding: 8px 14px;
  border-radius: var(--radius-pill);
  cursor: pointer;
  white-space: nowrap;
  transition: transform 0.25s var(--ease), color 0.25s var(--ease), border-color 0.25s var(--ease), background-color 0.25s var(--ease);
}

#theme-toggle:hover,
#menu-toggle:hover {
  color: var(--text);
  border-color: var(--accent-2);
  transform: translateY(-2px);
}

#menu-toggle {
  display: none;
}

/* ---------- Main layout ---------- */
main {
  max-width: 1240px;
  margin: 0 auto;
  padding: 0 20px 80px;
}

main > section {
  margin-top: 56px;
  padding: 32px clamp(18px, 3vw, 40px);
  background: var(--surface-glass);
  -webkit-backdrop-filter: blur(16px);
  backdrop-filter: blur(16px);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-sm);
  transition: box-shadow 0.4s var(--ease), transform 0.4s var(--ease), border-color 0.4s var(--ease);
}

main > section:hover {
  box-shadow: var(--shadow-md);
  border-color: rgba(127, 179, 255, 0.3);
}

main > section > h2 {
  position: relative;
  padding-left: 16px;
}

main > section > h2::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0.28em;
  bottom: 0.28em;
  width: 5px;
  border-radius: var(--radius-pill);
  background: var(--gradient-accent);
  box-shadow: 0 0 14px rgba(245, 196, 81, 0.5);
}

/* ---------- Breadcrumb ---------- */
.breadcrumb {
  margin-top: 20px;
}

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

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

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

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

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

/* ---------- Hero ---------- */
#hero {
  position: relative;
  margin-top: 24px;
  padding: clamp(28px, 4vw, 56px);
  border-radius: var(--radius-lg);
  background: var(--gradient-hero);
  color: #e8eefc;
  border: 1px solid rgba(127, 179, 255, 0.22);
  box-shadow: var(--shadow-lg);
  overflow: hidden;
  isolation: isolate;
}

#hero::before {
  content: "";
  position: absolute;
  inset: -30% -10% auto auto;
  width: 520px;
  height: 520px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(245, 196, 81, 0.28), transparent 65%);
  filter: blur(20px);
  z-index: -1;
  animation: heroFloat 14s ease-in-out infinite alternate;
}

#hero::after {
  content: "";
  position: absolute;
  inset: auto auto -40% -12%;
  width: 560px;
  height: 560px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(95, 124, 255, 0.34), transparent 65%);
  filter: blur(24px);
  z-index: -1;
  animation: heroFloat 18s ease-in-out infinite alternate-reverse;
}

@keyframes heroFloat {
  from { transform: translate3d(0, 0, 0) scale(1); }
  to { transform: translate3d(-40px, 30px, 0) scale(1.12); }
}

#hero h1 {
  color: #ffffff;
  text-shadow: 0 6px 30px rgba(0, 0, 0, 0.45);
  max-width: 20em;
}

.hero-lead {
  color: rgba(232, 238, 252, 0.86);
  max-width: 62em;
  font-size: 1.02rem;
}

#hero-carousel {
  display: grid;
  grid-auto-flow: column;
  grid-auto-columns: minmax(280px, 1fr);
  gap: 18px;
  overflow-x: auto;
  padding: 10px 4px 18px;
  margin: 8px -4px 0;
  scroll-snap-type: x mandatory;
  scrollbar-width: thin;
  scrollbar-color: rgba(245, 196, 81, 0.5) transparent;
}

#hero-carousel::-webkit-scrollbar {
  height: 6px;
}

#hero-carousel::-webkit-scrollbar-thumb {
  background: rgba(245, 196, 81, 0.5);
  border-radius: var(--radius-pill);
}

#hero-carousel .slide {
  margin: 0;
  scroll-snap-align: start;
  border-radius: var(--radius-md);
  overflow: hidden;
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.14);
  -webkit-backdrop-filter: blur(10px);
  backdrop-filter: blur(10px);
  box-shadow: 0 14px 40px rgba(0, 0, 0, 0.32);
  transition: transform 0.45s var(--ease), box-shadow 0.45s var(--ease), border-color 0.45s var(--ease);
}

#hero-carousel .slide:hover {
  transform: translateY(-6px) scale(1.01);
  border-color: rgba(245, 196, 81, 0.5);
  box-shadow: 0 24px 60px rgba(0, 0, 0, 0.45);
}

#hero-carousel .slide svg {
  width: 100%;
  height: auto;
}

#hero-carousel figcaption {
  padding: 12px 16px;
  font-size: 0.9rem;
  color: rgba(232, 238, 252, 0.9);
  border-top: 1px solid rgba(255, 255, 255, 0.1);
}

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

.hero-stats .stat {
  padding: 18px 16px;
  border-radius: var(--radius-md);
  text-align: center;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.16);
  -webkit-backdrop-filter: blur(12px);
  backdrop-filter: blur(12px);
  transition: transform 0.35s var(--ease), background-color 0.35s var(--ease), border-color 0.35s var(--ease);
}

.hero-stats .stat:hover {
  transform: translateY(-5px);
  background: rgba(255, 255, 255, 0.14);
  border-color: rgba(245, 196, 81, 0.55);
}

.hero-stats .num {
  display: block;
  font-size: clamp(1.5rem, 3vw, 2.1rem);
  font-weight: 800;
  letter-spacing: -0.02em;
  color: var(--accent);
  font-variant-numeric: tabular-nums;
  line-height: 1.2;
}

.hero-stats .label {
  display: block;
  margin-top: 4px;
  font-size: 0.85rem;
  color: rgba(232, 238, 252, 0.78);
}

/* ---------- Products / Solutions lists ---------- */
#products ul,
#solutions ul,
#howto ul,
#howto ol,
#brand-intro ul {
  display: grid;
  gap: 10px;
  list-style: none;
  padding: 0;
}

#products ul li,
#solutions ul li,
#howto ul li,
#howto ol li,
#brand-intro ul li {
  position: relative;
  padding: 14px 18px 14px 44px;
  border-radius: var(--radius-md);
  background: var(--surface);
  border: 1px solid var(--border);
  box-shadow: var(--shadow-sm);
  transition: transform 0.3s var(--ease), box-shadow 0.3s var(--ease), border-color 0.3s var(--ease);
}

#products ul li::before,
#solutions ul li::before,
#howto ul li::before,
#howto ol li::before,
#brand-intro ul li::before {
  content: "";
  position: absolute;
  left: 18px;
  top: 50%;
  transform: translateY(-50%);
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background: var(--gradient-accent);
  box-shadow: 0 0 0 4px rgba(245, 196, 81, 0.18);
}

#howto ol {
  counter-reset: howto;
}

#howto ol li {
  counter-increment: howto;
}

#howto ol li::before {
  content: counter(howto);
  width: 22px;
  height: 22px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  font-size: 0.75rem;
  font-weight: 800;
  color: #0f1b3d;
  background: var(--gradient-accent);
  box-shadow: 0 0 0 4px rgba(245, 196, 81, 0.18);
}

#products ul li:hover,
#solutions ul li:hover,
#howto ul li:hover,
#howto ol li:hover,
#brand-intro ul li:hover {
  transform: translateX(4px);
  border-color: rgba(127, 179, 255, 0.4);
  box-shadow: var(--shadow-md);
}

/* ---------- Cases ---------- */
#cases h3 {
  margin-top: 1.4em;
}

#cases blockquote {
  margin: 14px 0;
  transition: transform 0.35s var(--ease), box-shadow 0.35s var(--ease);
}

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

/* ---------- News ---------- */
#news {
  display: grid;
  gap: 18px;
}

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

#news article {
  padding: 22px 24px;
  border-radius: var(--radius-md);
  background: var(--surface);
  border: 1px solid var(--border);
  box-shadow: var(--shadow-sm);
  transition: transform 0.35s var(--ease), box-shadow 0.35s var(--ease), border-color 0.35s var(--ease);
}

#news article:hover {
  transform: translateY(-5px);
  border-color: rgba(245, 196, 81, 0.5);
  box-shadow: var(--shadow-md);
}

#news article h3 {
  margin-bottom: 6px;
}

#news article p:last-child {
  margin-bottom: 0;
}

/* ---------- Articles ---------- */
#articles {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  gap: 18px;
  align-items: start;
}

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

#articles article {
  position: relative;
  padding: 24px 24px 20px;
  border-radius: var(--radius-md);
  background: var(--surface);
  border: 1px solid var(--border);
  box-shadow: var(--shadow-sm);
  overflow: hidden;
  transition: transform 0.35s var(--ease), box-shadow 0.35s var(--ease), border-color 0.35s var(--ease);
}

#articles article::before {
  content: "";
  position: absolute;
  inset: 0 0 auto 0;
  height: 3px;
  background: var(--gradient-cool);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 0.4s var(--ease);
}

#articles article:hover {
  transform: translateY(-6px);
  border-color: rgba(127, 179, 255, 0.45);
  box-shadow: var(--shadow-md);
}

#articles article:hover::before {
  transform: scaleX(1);
}

#articles article h3 {
  font-size: 1.08rem;
  margin-bottom: 4px;
}

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

#articles article a {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-weight: 600;
  font-size: 0.9rem;
  color: var(--accent-3);
}

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

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

/* ---------- FAQ ---------- */
#faq details {
  border-radius: var(--radius-md);
  background: var(--surface);
  border: 1px solid var(--border);
  box-shadow: var(--shadow-sm);
  margin-bottom: 12px;
  overflow: hidden;
  transition: border-color 0.3s var(--ease), box-shadow 0.3s var(--ease), transform 0.3s var(--ease);
}

#faq details:hover {
  border-color: rgba(127, 179, 255, 0.4);
  box-shadow: var(--shadow-md);
}

#faq details[open] {
  border-color: rgba(245, 196, 81, 0.5);
}

#faq summary {
  position: relative;
  cursor: pointer;
  list-style: none;
  padding: 16px 52px 16px 20px;
  font-weight: 600;
  color: var(--text);
  transition: background-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.1rem;
  font-weight: 700;
  color: #0f1b3d;
  background: var(--gradient-accent);
  transition: transform 0.35s var(--ease);
}

#faq details[open] summary::after {
  transform: translateY(-50%) rotate(45deg);
}

#faq summary:hover {
  background: rgba(127, 179, 255, 0.08);
}

#faq details p {
  margin: 0;
  padding: 0 20px 18px;
  font-size: 0.95rem;
  animation: fadeSlide 0.4s var(--ease);
}

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

/* ---------- Contact ---------- */
#contact address {
  font-style: normal;
  display: grid;
  gap: 10px;
  padding: 20px 22px;
  border-radius: var(--radius-md);
  background: var(--surface);
  border: 1px solid var(--border);
  box-shadow: var(--shadow-sm);
  margin-bottom: 18px;
}

#contact address p {
  margin: 0;
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  align-items: baseline;
}

#contact address a {
  font-weight: 600;
  word-break: break-all;
}

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

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

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

#sitemap a:hover,
#links a:hover {
  color: #0f1b3d;
  background: var(--gradient-accent);
  border-color: transparent;
  transform: translateY(-3px);
  box-shadow: 0 10px 24px rgba(245, 196, 81, 0.32);
}

/* ---------- Footer ---------- */
#site-footer {
  position: relative;
  padding: 56px 20px 40px;
  background: var(--gradient-hero);
  color: rgba(232, 238, 252, 0.82);
  border-top: 1px solid rgba(127, 179, 255, 0.2);
}

#site-footer::before {
  content: "";
  position: absolute;
  inset: 0;
  background-image:
    radial-gradient(2px 2px at 20% 30%, rgba(255, 255, 255, 0.6), transparent),
    radial-gradient(2px 2px at 70% 20%, rgba(245, 196, 81, 0.7), transparent),
    radial-gradient(1.5px 1.5px at 45% 70%, rgba(127, 179, 255, 0.8), transparent),
    radial-gradient(1.5px 1.5px at 85% 60%, rgba(255, 255, 255, 0.5), transparent);
  background-size: 100% 100%;
  opacity: 0.7;
  pointer-events: none;
}

#site-footer > section,
#site-footer > nav {
  position: relative;
  max-width: 1240px;
  margin: 0 auto 26px;
  padding: 24px clamp(18px, 3vw, 32px);
  border-radius: var(--radius-md);
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.12);
  -webkit-backdrop-filter: blur(14px);
  backdrop-filter: blur(14px);
  transition: background-color 0.35s var(--ease), border-color 0.35s var(--ease);
}

#site-footer > section:hover {
  background: rgba(255, 255, 255, 0.1);
  border-color: rgba(245, 196, 81, 0.4);
}

#site-footer h2 {
  color: #ffffff;
  font-size: 1.05rem;
  letter-spacing: 0.02em;
}

#site-footer p {
  color: rgba(232, 238, 252, 0.78);
  margin-bottom: 0.5em;
}

#site-footer p:last-child {
  margin-bottom: 0;
}

#site-footer strong {
  color: var(--accent);
}

#site-footer time {
  color: rgba(232, 238, 252, 0.9);
}

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

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

#site-footer nav ul {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  list-style: none;
  margin: 0;
  padding: 0;
}

#site-footer nav a {
  display: inline-block;
  padding: 7px 14px;
  border-radius: var(--radius-pill);
  font-size: 0.875rem;
  border: 1px solid rgba(255, 255, 255, 0.18);
  transition: transform 0.25s var(--ease), background-color 0.25s var(--ease), color 0.25s var(--ease);
}

#site-footer nav a:hover {
  color: #0f1b3d;
  background: var(--gradient-accent);
  border-color: transparent;
  transform: translateY(-2px);
}

/* ---------- Back to top ---------- */
#back-to-top {
  position: fixed;
  right: 22px;
  bottom: 22px;
  z-index: 90;
  border: 0;
  cursor: pointer;
  font: inherit;
  font-size: 0.85rem;
  font-weight: 700;
  padding: 12px 18px;
  border-radius: var(--radius-pill);
  color: #0f1b3d;
  background: var(--gradient-accent);
  box-shadow: 0 12px 30px rgba(245, 196, 81, 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.3s var(--ease);
}

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

#back-to-top:hover {
  box-shadow: 0 18px 40px rgba(245, 196, 81, 0.55);
  transform: translateY(-3px);
}

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

.reveal.is-visible {
  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;
  }
  .reveal {
    opacity: 1;
    transform: none;
  }
}

/* ---------- Responsive ---------- */
@media (max-width: 1080px) {
  .header-inner {
    gap: 12px;
  }
  #search-input {
    width: 130px;
  }
  #main-nav a {
    padding: 7px 9px;
    font-size: 0.88rem;
  }
}

@media (max-width: 900px) {
  #menu-toggle {
    display: inline-block;
  }

  #main-nav {
    order: 10;
    flex: 1 1 100%;
    max-height: 0;
    overflow: hidden;
    opacity: 0;
    transition: max-height 0.45s var(--ease), opacity 0.35s var(--ease);
  }

  #main-nav.is-open {
    max-height: 520px;
    opacity: 1;
  }

  #main-nav ul {
    flex-direction: column;
    align-items: stretch;
    gap: 2px;
    padding: 10px 0 14px;
    border-top: 1px solid var(--border);
  }

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

  #site-search {
    order: 11;
    flex: 1 1 100%;
    margin-bottom: 12px;
  }

  #search-input {
    width: 100%;
    flex: 1 1 auto;
  }

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

  #hero-carousel {
    grid-auto-columns: minmax(320px, 1fr);
  }
}

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

  body {
    font-size: 15px;
  }

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

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

  main {
    padding: 0 14px 64px;
  }

  main > section {
    margin-top: 34px;
    padding: 24px 18px;
    border-radius: var(--radius-md);
  }

  #hero {
    padding: 26px 18px 30px;
    border-radius: var(--radius-md);
  }

  #hero-carousel {
    grid-auto-columns: minmax(260px, 1fr);
    gap: 12px;
  }

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

  #contact address p {
    flex-direction: column;
    gap: 2px;
  }

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

  #site-footer {
    padding: 40px 14px 28px;
  }

  #site-footer > section,
  #site-footer > nav {
    padding: 20px 16px;
    margin-bottom: 16px;
  }
}

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

  #theme-toggle,
  #menu-toggle {
    padding: 7px 11px;
    font-size: 0.8rem;
  }

  #site-search button {
    padding: 7px 12px;
  }

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

  #faq summary {
    padding: 14px 48px 14px 16px;
    font-size: 0.95rem;
  }

  #faq details p {
    padding: 0 16px 16px;
  }
}

/* ---------- Print ---------- */
@media print {
  #site-header,
  #back-to-top,
  #hero-carousel,
  #site-footer nav {
    display: none !important;
  }
  body {
    background: #fff;
    color: #000;
  }
  main > section {
    box-shadow: none;
    border: 1px solid #ccc;
    break-inside: avoid;
  }
}