:root {
  --ink: #121820;
  --ink-soft: #293442;
  --muted: #647184;
  --line: #dfe5ec;
  --surface: #ffffff;
  --surface-alt: #f4f7fa;
  --steel: #8c98a5;
  --blue: #1166d9;
  --blue-dark: #0b3f8f;
  --amber: #d98a12;
  --dark: #10151d;
  --shadow: 0 18px 45px rgba(16, 21, 29, 0.12);
  --radius: 8px;
  --container: 1180px;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  color: var(--ink);
  font-family: "PingFang SC", "Microsoft YaHei", "Noto Sans CJK SC", ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Arial, sans-serif;
  background: var(--surface);
  line-height: 1.55;
}

body.no-scroll {
  overflow: hidden;
}

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

a {
  color: inherit;
  text-decoration: none;
}

button,
input,
select,
textarea {
  font: inherit;
}

.site-header {
  align-items: center;
  backdrop-filter: blur(16px);
  background: rgba(255, 255, 255, 0.94);
  border-bottom: 1px solid rgba(223, 229, 236, 0.88);
  display: flex;
  gap: 24px;
  justify-content: space-between;
  left: 0;
  min-height: 76px;
  padding: 14px clamp(18px, 5vw, 54px);
  position: sticky;
  right: 0;
  top: 0;
  z-index: 50;
}

.brand {
  align-items: center;
  display: inline-flex;
  gap: 12px;
  min-width: 210px;
}

.brand-logo {
  flex: 0 0 auto;
  height: auto;
  width: 112px;
}

.brand strong,
.brand small {
  display: block;
}

.brand strong {
  color: var(--ink);
  font-size: 16px;
  line-height: 1.1;
}

.brand small {
  color: var(--muted);
  font-size: 12px;
  margin-top: 2px;
}

.nav-links {
  align-items: center;
  display: flex;
  gap: 22px;
  font-size: 14px;
  font-weight: 700;
}

.nav-links a:not(.nav-cta) {
  color: var(--ink-soft);
}

.nav-links a:not(.nav-cta):hover {
  color: var(--blue);
}

.nav-cta {
  align-items: center;
  background: var(--blue);
  border-radius: 6px;
  color: #fff;
  display: inline-flex;
  min-height: 42px;
  padding: 0 18px;
}

.menu-toggle {
  align-items: center;
  background: transparent;
  border: 1px solid var(--line);
  border-radius: 6px;
  color: var(--ink);
  cursor: pointer;
  display: none;
  height: 42px;
  justify-content: center;
  width: 42px;
}

.menu-toggle svg,
.button svg,
.category-card svg,
.application-grid svg,
.service-panel svg,
.contact-details svg,
.dialog-close svg,
.search-box svg {
  height: 18px;
  stroke-width: 2;
  width: 18px;
}

.hero {
  background-image:
    linear-gradient(90deg, rgba(16, 21, 29, 0.96) 0%, rgba(16, 21, 29, 0.82) 42%, rgba(16, 21, 29, 0.28) 70%, rgba(16, 21, 29, 0.08) 100%),
    url("assets/product-single-magnetic.jpg");
  background-position: center;
  background-size: cover;
  color: #fff;
  min-height: 650px;
  overflow: hidden;
  padding: 112px clamp(20px, 6vw, 76px) 42px;
  position: relative;
}

.hero-content {
  max-width: 720px;
  position: relative;
  z-index: 1;
}

.eyebrow {
  color: var(--blue);
  font-size: 12px;
  font-weight: 800;
  letter-spacing: 0.12em;
  margin: 0 0 14px;
  text-transform: uppercase;
}

.section-dark .eyebrow {
  color: #67c6ff;
}

h1,
h2,
h3,
p {
  margin-top: 0;
}

h1 {
  font-size: 54px;
  line-height: 1.12;
  margin-bottom: 22px;
  max-width: 760px;
}

h2 {
  color: var(--ink);
  font-size: 38px;
  line-height: 1.12;
  margin-bottom: 16px;
}

h3 {
  color: var(--ink);
  font-size: 18px;
  line-height: 1.25;
  margin-bottom: 8px;
}

.hero-copy {
  color: rgba(255, 255, 255, 0.82);
  font-size: 19px;
  max-width: 650px;
}

.hero-actions,
.form-row,
.catalog-toolbar,
.site-footer,
.hero-stats {
  display: flex;
}

.hero-actions {
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 34px;
}

.button {
  align-items: center;
  border-radius: 6px;
  border: 1px solid transparent;
  cursor: pointer;
  display: inline-flex;
  font-weight: 800;
  gap: 8px;
  justify-content: center;
  min-height: 46px;
  padding: 0 18px;
  transition: transform 160ms ease, background 160ms ease, border-color 160ms ease, color 160ms ease;
}

.button:hover {
  transform: translateY(-1px);
}

.button.primary {
  background: var(--blue);
  color: #fff;
}

.button.primary:hover {
  background: var(--blue-dark);
}

.button.secondary {
  background: rgba(255, 255, 255, 0.08);
  border-color: rgba(255, 255, 255, 0.3);
  color: #fff;
}

.hero-stats {
  bottom: 34px;
  gap: 1px;
  left: clamp(20px, 6vw, 76px);
  max-width: 820px;
  position: absolute;
  right: clamp(20px, 6vw, 76px);
  z-index: 1;
}

.hero-stats div {
  background: rgba(255, 255, 255, 0.94);
  border-right: 1px solid var(--line);
  color: var(--ink);
  min-height: 94px;
  padding: 18px;
  width: 25%;
}

.hero-stats div:first-child {
  border-radius: var(--radius) 0 0 var(--radius);
}

.hero-stats div:last-child {
  border-radius: 0 var(--radius) var(--radius) 0;
  border-right: 0;
}

.hero-stats strong {
  display: block;
  font-size: 22px;
  line-height: 1.1;
}

.hero-stats span {
  color: var(--muted);
  display: block;
  font-size: 13px;
  margin-top: 8px;
}

.intro-strip {
  background: var(--ink);
  color: #fff;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
}

.intro-strip div {
  border-right: 1px solid rgba(255, 255, 255, 0.14);
  padding: 26px clamp(20px, 4vw, 48px);
}

.intro-strip div:last-child {
  border-right: 0;
}

.intro-strip span {
  color: #9fb1c8;
  display: block;
  font-size: 12px;
  font-weight: 800;
  letter-spacing: 0.08em;
  margin-bottom: 6px;
  text-transform: uppercase;
}

.intro-strip strong {
  display: block;
  font-size: 17px;
  line-height: 1.3;
}

.section {
  padding: 92px clamp(20px, 5vw, 64px);
}

.section-heading {
  margin: 0 auto 34px;
  max-width: var(--container);
}

.section-heading p:not(.eyebrow) {
  color: var(--muted);
  font-size: 17px;
  max-width: 780px;
}

.section-heading.compact {
  margin-bottom: 24px;
}

.products-section {
  background: var(--surface);
}

.category-grid {
  display: grid;
  gap: 12px;
  grid-template-columns: repeat(7, minmax(0, 1fr));
  margin: 0 auto 24px;
  max-width: var(--container);
}

.category-card {
  align-items: center;
  background: var(--surface-alt);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  color: var(--ink-soft);
  cursor: pointer;
  display: flex;
  flex-direction: column;
  gap: 10px;
  justify-content: center;
  min-height: 104px;
  padding: 14px 10px;
  text-align: center;
}

.category-card span {
  font-size: 13px;
  font-weight: 800;
  line-height: 1.25;
}

.category-card:hover,
.category-card.active {
  background: #eaf3ff;
  border-color: #a8cdfc;
  color: var(--blue-dark);
}

.catalog-toolbar {
  align-items: center;
  gap: 18px;
  justify-content: space-between;
  margin: 0 auto 24px;
  max-width: var(--container);
}

.catalog-toolbar > span {
  color: var(--muted);
  font-size: 14px;
  font-weight: 700;
  white-space: nowrap;
}

.search-box {
  align-items: center;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  color: var(--muted);
  display: flex;
  gap: 10px;
  min-height: 48px;
  padding: 0 14px;
  width: min(620px, 100%);
}

.search-box input {
  border: 0;
  color: var(--ink);
  outline: 0;
  width: 100%;
}

.product-grid {
  display: grid;
  gap: 18px;
  grid-template-columns: repeat(3, 1fr);
  margin: 0 auto;
  max-width: var(--container);
}

.product-card {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  display: flex;
  flex-direction: column;
  min-height: 100%;
  overflow: hidden;
  transition: box-shadow 160ms ease, transform 160ms ease, border-color 160ms ease;
}

.product-card:hover {
  border-color: #bdd4ef;
  box-shadow: var(--shadow);
  transform: translateY(-2px);
}

.product-image {
  align-items: center;
  background: #fff;
  display: flex;
  height: 218px;
  justify-content: center;
  overflow: hidden;
  padding: 10px;
}

.product-image img {
  height: 100%;
  object-fit: contain;
  width: 100%;
}

.product-body {
  display: flex;
  flex: 1;
  flex-direction: column;
  padding: 20px;
}

.product-category {
  color: var(--blue);
  font-size: 12px;
  font-weight: 800;
  letter-spacing: 0.08em;
  margin-bottom: 8px;
  text-transform: uppercase;
}

.product-body p {
  color: var(--muted);
  font-size: 14px;
}

.spec-list {
  display: grid;
  gap: 8px;
  margin: 12px 0 18px;
}

.spec-list span {
  align-items: center;
  color: var(--ink-soft);
  display: flex;
  font-size: 13px;
  gap: 8px;
}

.spec-list span::before {
  background: var(--amber);
  border-radius: 999px;
  content: "";
  height: 6px;
  flex: 0 0 6px;
  width: 6px;
}

.card-actions {
  display: flex;
  gap: 10px;
  margin-top: auto;
}

.card-actions .button {
  min-height: 40px;
  padding: 0 13px;
}

.button.outline {
  background: #fff;
  border-color: var(--line);
  color: var(--ink);
}

.button.outline:hover {
  border-color: var(--blue);
  color: var(--blue);
}

.applications {
  background: var(--surface-alt);
}

.application-grid {
  display: grid;
  gap: 16px;
  grid-template-columns: repeat(4, 1fr);
  margin: 0 auto;
  max-width: var(--container);
}

.application-grid article,
.service-panel article {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 22px;
}

.application-grid svg,
.service-panel svg {
  color: var(--blue);
  margin-bottom: 16px;
}

.application-grid p,
.service-panel p {
  color: var(--muted);
  font-size: 14px;
  margin-bottom: 0;
}

.split-section {
  align-items: start;
  display: grid;
  gap: 44px;
  grid-template-columns: minmax(0, 1.02fr) minmax(340px, 0.8fr);
  margin: 0 auto;
  max-width: calc(var(--container) + 128px);
}

.split-copy p:not(.eyebrow) {
  color: var(--muted);
  font-size: 17px;
  max-width: 680px;
}

.process-list {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin: 28px 0;
}

.process-list span {
  background: var(--surface-alt);
  border: 1px solid var(--line);
  border-radius: 999px;
  color: var(--ink-soft);
  font-size: 13px;
  font-weight: 800;
  padding: 8px 12px;
}

.service-panel {
  display: grid;
  gap: 14px;
}

.factory-section {
  background: var(--ink);
}

.factory-section h2,
.factory-section .section-heading p:not(.eyebrow) {
  color: #fff;
}

.factory-section .section-heading p:not(.eyebrow) {
  color: #b7c3d0;
}

.factory-grid {
  display: grid;
  gap: 16px;
  grid-template-columns: 1.2fr 1fr 1fr;
  margin: 0 auto;
  max-width: var(--container);
}

.factory-photo {
  background: #fff;
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: var(--radius);
  margin: 0;
  overflow: hidden;
  position: relative;
}

.factory-photo.large {
  grid-row: span 2;
}

.factory-photo img {
  aspect-ratio: 4 / 3;
  height: 100%;
  object-fit: cover;
  width: 100%;
}

.factory-photo.large img {
  aspect-ratio: 4 / 5;
}

.factory-photo.certificate img {
  object-fit: contain;
  padding: 14px;
}

.factory-photo figcaption {
  background: rgba(16, 21, 29, 0.78);
  bottom: 0;
  color: #fff;
  font-size: 13px;
  font-weight: 800;
  left: 0;
  padding: 10px 12px;
  position: absolute;
  right: 0;
}

.about-section {
  background: linear-gradient(180deg, #fff 0%, #f4f7fa 100%);
}

.about-card {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: 0 16px 38px rgba(16, 21, 29, 0.08);
  margin: 0 auto;
  max-width: var(--container);
  padding: clamp(28px, 5vw, 58px);
}

.about-card p:not(.eyebrow) {
  color: var(--muted);
  font-size: 17px;
  max-width: 930px;
}

.about-metrics {
  display: grid;
  gap: 14px;
  grid-template-columns: repeat(2, 1fr);
  margin-top: 28px;
}

.about-metrics div {
  border-left: 4px solid var(--blue);
  background: var(--surface-alt);
  padding: 18px 20px;
}

.about-metrics strong,
.about-metrics span {
  display: block;
}

.about-metrics span {
  color: var(--muted);
  font-size: 14px;
  margin-top: 4px;
}

.contact-section {
  align-items: start;
  background: #fff;
  display: grid;
  gap: 44px;
  grid-template-columns: 0.82fr 1fr;
  margin: 0 auto;
  max-width: calc(var(--container) + 128px);
}

.contact-copy p:not(.eyebrow) {
  color: var(--muted);
  font-size: 17px;
}

.contact-details {
  display: grid;
  gap: 13px;
  margin-top: 28px;
}

.contact-details a,
.contact-details span {
  align-items: start;
  color: var(--ink-soft);
  display: flex;
  gap: 12px;
}

.contact-details svg {
  color: var(--blue);
  flex: 0 0 auto;
  margin-top: 3px;
}

.rfq-form {
  background: var(--surface-alt);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  display: grid;
  gap: 16px;
  padding: clamp(22px, 4vw, 34px);
}

.form-row {
  gap: 16px;
}

.form-row label {
  flex: 1;
}

.rfq-form label {
  color: var(--ink-soft);
  display: grid;
  font-size: 13px;
  font-weight: 800;
  gap: 7px;
}

.rfq-form input,
.rfq-form select,
.rfq-form textarea {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 6px;
  color: var(--ink);
  min-height: 44px;
  outline: 0;
  padding: 10px 12px;
  width: 100%;
}

.rfq-form textarea {
  resize: vertical;
}

.rfq-form input:focus,
.rfq-form select:focus,
.rfq-form textarea:focus {
  border-color: var(--blue);
  box-shadow: 0 0 0 3px rgba(17, 102, 217, 0.12);
}

.form-submit {
  margin-top: 4px;
  width: fit-content;
}

.form-status {
  color: var(--blue-dark);
  font-size: 14px;
  font-weight: 700;
  margin: 0;
}

.site-footer {
  align-items: center;
  background: var(--ink);
  color: #fff;
  justify-content: space-between;
  padding: 28px clamp(20px, 5vw, 64px);
}

.site-footer strong,
.site-footer span {
  display: block;
}

.site-footer span {
  color: #9fb1c8;
  font-size: 13px;
  margin-top: 3px;
}

.site-footer div:last-child {
  display: flex;
  flex-wrap: wrap;
  gap: 18px;
}

.site-footer a {
  color: #d8e0ea;
  font-size: 14px;
  font-weight: 800;
}

.product-dialog {
  border: 0;
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  max-width: min(980px, calc(100vw - 32px));
  padding: 0;
  width: 980px;
}

.product-dialog::backdrop {
  background: rgba(9, 14, 20, 0.66);
}

.dialog-close {
  align-items: center;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 999px;
  cursor: pointer;
  display: flex;
  height: 40px;
  justify-content: center;
  position: absolute;
  right: 14px;
  top: 14px;
  width: 40px;
  z-index: 2;
}

.dialog-body {
  display: grid;
  grid-template-columns: 0.95fr 1.05fr;
  min-height: 560px;
}

.dialog-media {
  background: var(--surface-alt);
  display: flex;
  flex-direction: column;
}

.dialog-media img {
  flex: 1;
  height: 100%;
  object-fit: cover;
  width: 100%;
}

.dialog-content {
  padding: 42px;
}

.dialog-content p {
  color: var(--muted);
}

.dialog-specs {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  display: grid;
  margin: 22px 0;
  overflow: hidden;
}

.dialog-specs div {
  display: grid;
  grid-template-columns: 0.45fr 0.55fr;
}

.dialog-specs div + div {
  border-top: 1px solid var(--line);
}

.dialog-specs dt,
.dialog-specs dd {
  margin: 0;
  padding: 10px 12px;
}

.dialog-specs dt {
  background: var(--surface-alt);
  color: var(--ink-soft);
  font-size: 13px;
  font-weight: 800;
}

.dialog-specs dd {
  color: var(--muted);
  font-size: 13px;
}

.related-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 20px;
}

.related-tags span {
  background: #eef5ff;
  border: 1px solid #cfe2fb;
  border-radius: 999px;
  color: var(--blue-dark);
  font-size: 12px;
  font-weight: 800;
  padding: 6px 10px;
}

.empty-state {
  border: 1px dashed var(--line);
  border-radius: var(--radius);
  color: var(--muted);
  grid-column: 1 / -1;
  padding: 36px;
  text-align: center;
}

@media (max-width: 1040px) {
  h1 {
    font-size: 48px;
  }

  h2 {
    font-size: 32px;
  }

  .category-grid {
    grid-template-columns: repeat(4, 1fr);
  }

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

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

  .split-section,
  .contact-section {
    grid-template-columns: 1fr;
  }

  .factory-photo.large {
    grid-row: auto;
  }
}

@media (max-width: 820px) {
  .site-header {
    min-height: 70px;
  }

  .menu-toggle {
    display: inline-flex;
  }

  .nav-links {
    align-items: stretch;
    background: #fff;
    border-bottom: 1px solid var(--line);
    box-shadow: var(--shadow);
    display: none;
    flex-direction: column;
    gap: 0;
    left: 0;
    padding: 8px 20px 20px;
    position: absolute;
    right: 0;
    top: 70px;
  }

  .nav-links.open {
    display: flex;
  }

  .nav-links a {
    padding: 13px 0;
  }

  .nav-cta {
    justify-content: center;
    margin-top: 8px;
  }

  .hero {
    min-height: 720px;
    padding-top: 82px;
  }

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

  .hero-stats div,
  .hero-stats div:first-child,
  .hero-stats div:last-child {
    border-radius: 0;
    width: auto;
  }

  .hero-stats div:nth-child(1) {
    border-radius: var(--radius) 0 0 0;
  }

  .hero-stats div:nth-child(2) {
    border-radius: 0 var(--radius) 0 0;
  }

  .hero-stats div:nth-child(3) {
    border-radius: 0 0 0 var(--radius);
  }

  .hero-stats div:nth-child(4) {
    border-radius: 0 0 var(--radius) 0;
  }

  .intro-strip {
    grid-template-columns: 1fr;
  }

  .intro-strip div {
    border-bottom: 1px solid rgba(255, 255, 255, 0.14);
    border-right: 0;
  }

  .intro-strip div:last-child {
    border-bottom: 0;
  }

  .dialog-body {
    grid-template-columns: 1fr;
  }

  .dialog-media img {
    max-height: 300px;
  }
}

@media (max-width: 640px) {
  .brand {
    min-width: auto;
  }

  .brand-logo {
    width: 88px;
  }

  .brand small {
    display: none;
  }

  h1 {
    font-size: 38px;
  }

  h2 {
    font-size: 28px;
  }

  .hero {
    background-position: 62% center;
  }

  .hero-copy {
    font-size: 16px;
  }

  .button {
    width: 100%;
  }

  .hero-actions {
    max-width: 320px;
  }

  .category-grid,
  .product-grid,
  .application-grid,
  .factory-grid,
  .about-metrics {
    grid-template-columns: 1fr;
  }

  .catalog-toolbar,
  .form-row,
  .site-footer {
    align-items: stretch;
    flex-direction: column;
  }

  .product-image {
    height: 210px;
  }

  .card-actions {
    flex-direction: column;
  }

  .form-submit {
    width: 100%;
  }

  .dialog-content {
    padding: 26px;
  }

  .dialog-specs div {
    grid-template-columns: 1fr;
  }
}
