:root {
  --ink: #18202a;
  --muted: #5d6978;
  --line: #dfe5eb;
  --paper: #ffffff;
  --field: #f4f7fa;
  --navy: #123c69;
  --blue: #1c70b7;
  --teal: #168b86;
  --red: #c23b2a;
  --steel: #eef3f7;
  --footer-bg: #0c1219;
  --shadow: 0 18px 50px rgba(16, 33, 48, 0.14);
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  color: var(--ink);
  font-family: "Microsoft YaHei", "PingFang SC", Arial, sans-serif;
  background: #f5f8fb;
  line-height: 1.6;
}

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

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

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

.page-header {
  position: sticky;
  z-index: 20;
  top: 0;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  min-height: 76px;
  padding: 0 clamp(20px, 5vw, 72px);
  color: #ffffff;
  background: rgba(13, 25, 36, 0.96);
  border-bottom: 1px solid rgba(255, 255, 255, 0.14);
}

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

.brand-mark {
  display: grid;
  width: 50px;
  height: 50px;
  flex: 0 0 auto;
  place-items: center;
  border: 2px solid rgba(255, 255, 255, 0.84);
  background: var(--red);
  font-weight: 900;
}

.brand-mark img {
  width: 100%;
  height: 100%;
  object-fit: contain;
}

.brand-text {
  display: grid;
  min-width: 0;
}

.brand-text strong {
  overflow: hidden;
  font-size: 18px;
  line-height: 1.25;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.brand-text small {
  color: rgba(255, 255, 255, 0.7);
  font-size: 11px;
  text-transform: uppercase;
}

.site-nav {
  display: flex;
  align-items: center;
  gap: 26px;
  font-size: 15px;
  font-weight: 800;
}

.nav-toggle {
  display: none;
  width: 42px;
  height: 42px;
  place-items: center;
  border: 1px solid rgba(255, 255, 255, 0.28);
  border-radius: 4px;
  background: rgba(255, 255, 255, 0.1);
}

.nav-toggle span {
  display: block;
  width: 20px;
  height: 2px;
  margin: 4px auto;
  background: #ffffff;
}

.catalog-hero,
.detail-hero {
  padding: 84px clamp(20px, 5vw, 72px);
  color: #ffffff;
  background:
    linear-gradient(90deg, rgba(8, 18, 30, 0.94), rgba(18, 60, 105, 0.84)),
    url("./products/banner-products.jpg") center / cover no-repeat;
}

.catalog-hero h1,
.detail-hero h1 {
  max-width: 900px;
  margin: 0;
  font-size: clamp(36px, 5vw, 62px);
  line-height: 1.12;
}

.catalog-hero p,
.detail-hero p {
  max-width: 740px;
  margin: 18px 0 0;
  color: rgba(255, 255, 255, 0.82);
  font-size: 18px;
}

.kicker {
  margin: 0 0 12px !important;
  color: #ffb2a8 !important;
  font-size: 13px !important;
  font-weight: 900;
  text-transform: uppercase;
}

.category-strip {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 28px;
}

.category-strip span {
  padding: 7px 12px;
  border: 1px solid rgba(255, 255, 255, 0.24);
  border-radius: 999px;
  color: #ffffff;
  background: rgba(255, 255, 255, 0.08);
  font-size: 13px;
  font-weight: 900;
}

.catalog-section,
.detail-layout,
.related-section {
  padding: 64px clamp(20px, 5vw, 72px);
}

.catalog-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 20px;
}

.catalog-card,
.detail-content,
.detail-side,
.related-card {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #ffffff;
  box-shadow: 0 12px 32px rgba(20, 42, 62, 0.08);
}

.catalog-card {
  overflow: hidden;
}

.catalog-image {
  display: block;
  height: 260px;
  background:
    linear-gradient(135deg, rgba(238, 243, 247, 0.82), rgba(255, 255, 255, 0.92)),
    #ffffff;
}

.catalog-image img {
  width: 100%;
  height: 100%;
  padding: 24px;
  object-fit: contain;
}

.catalog-body {
  display: grid;
  gap: 10px;
  padding: 20px;
  border-top: 1px solid var(--line);
}

.catalog-body > span {
  color: var(--teal);
  font-size: 13px;
  font-weight: 900;
}

.catalog-body h2 {
  margin: 0;
  font-size: 22px;
  line-height: 1.3;
}

.catalog-body h2 a:hover,
.detail-link:hover {
  color: var(--blue);
}

.catalog-body p {
  margin: 0;
  color: var(--muted);
}

.catalog-body dl,
.detail-specs {
  display: grid;
  gap: 8px;
  margin: 4px 0 0;
}

.catalog-body dl div,
.detail-specs div {
  display: grid;
  grid-template-columns: 100px minmax(0, 1fr);
  gap: 12px;
  padding-bottom: 8px;
  border-bottom: 1px solid var(--line);
}

dt,
dd {
  margin: 0;
}

dt {
  color: var(--muted);
  font-size: 13px;
}

dd {
  font-weight: 900;
  text-align: right;
}

.detail-link {
  margin-top: 8px;
  color: var(--blue);
  font-weight: 900;
}

.detail-hero {
  display: grid;
  grid-template-columns: minmax(0, 0.92fr) minmax(320px, 0.68fr);
  gap: clamp(28px, 5vw, 72px);
  align-items: center;
}

.back-link {
  display: inline-flex;
  margin-bottom: 18px;
  color: rgba(255, 255, 255, 0.82);
  font-weight: 900;
}

.detail-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 28px;
}

.primary-action,
.secondary-action,
.cart-action {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 48px;
  border: 0;
  border-radius: 4px;
  padding: 0 22px;
  font: inherit;
  font-weight: 900;
  cursor: pointer;
}

.primary-action {
  color: #ffffff;
  background: var(--red);
}

.secondary-action {
  border: 1px solid rgba(255, 255, 255, 0.42);
  color: #ffffff;
}

.cart-action {
  color: #ffffff;
  background: var(--teal);
}

.detail-main-image {
  min-height: 360px;
  display: grid;
  place-items: center;
  border: 1px solid rgba(255, 255, 255, 0.16);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.94);
}

.detail-main-image img {
  max-height: 320px;
  padding: 26px;
  object-fit: contain;
}

.detail-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(330px, 0.42fr);
  gap: 24px;
  align-items: start;
}

.detail-content,
.detail-side {
  padding: 26px;
}

.detail-content h2,
.detail-side h2,
.related-section h2 {
  margin: 0 0 14px;
  font-size: 26px;
  line-height: 1.25;
}

.detail-content p {
  margin: 0 0 18px;
  color: var(--muted);
  font-size: 17px;
}

.product-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin: 18px 0 28px;
}

.product-tags span {
  padding: 5px 9px;
  border-radius: 4px;
  color: var(--navy);
  background: var(--field);
  font-size: 13px;
  font-weight: 900;
}

.detail-gallery {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
}

.detail-gallery img,
.related-card img {
  width: 100%;
  height: 180px;
  padding: 18px;
  object-fit: contain;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #ffffff;
}

.inquiry-form {
  display: grid;
  grid-template-columns: 1fr;
  gap: 14px;
}

.inquiry-cart-box {
  display: grid;
  gap: 10px;
  border: 1px solid #d7e0ea;
  border-radius: 8px;
  padding: 14px;
  background: #f7fafc;
}

.cart-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.cart-head button,
.inquiry-cart-box li button {
  min-height: 30px;
  border: 1px solid #cbd5df;
  border-radius: 4px;
  padding: 0 10px;
  color: var(--navy);
  background: #ffffff;
  font-size: 13px;
  font-weight: 900;
  cursor: pointer;
}

.inquiry-cart-box p,
.inquiry-cart-box ul {
  margin: 0;
}

.inquiry-cart-box ul {
  display: grid;
  gap: 8px;
  padding: 0;
  list-style: none;
}

.inquiry-cart-box li {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  border-bottom: 1px solid #e3e9f0;
  padding-bottom: 8px;
}

.inquiry-form label {
  display: grid;
  gap: 7px;
  font-size: 14px;
  font-weight: 900;
}

.inquiry-form input,
.inquiry-form select,
.inquiry-form textarea {
  width: 100%;
  min-height: 44px;
  border: 1px solid #cbd5df;
  border-radius: 4px;
  padding: 10px 12px;
  color: var(--ink);
  background: #ffffff;
}

.inquiry-form textarea {
  resize: vertical;
}

.inquiry-form > button {
  min-height: 48px;
  border: 0;
  border-radius: 4px;
  color: #ffffff;
  background: var(--red);
  font-weight: 900;
}

.form-note {
  min-height: 20px;
  margin: 0;
  color: var(--teal);
  font-size: 14px;
  font-weight: 900;
}

.related-section {
  padding-top: 0;
}

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

.related-card {
  display: grid;
  gap: 12px;
  padding: 14px;
}

.related-card span {
  font-weight: 900;
}

.detail-empty {
  min-height: 60vh;
  display: grid;
  place-content: center;
  gap: 16px;
  text-align: center;
}

.page-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  padding: 32px clamp(20px, 5vw, 72px);
  color: rgba(255, 255, 255, 0.76);
  background: var(--footer-bg);
}

.page-footer strong {
  color: #ffffff;
}

.page-footer p {
  margin: 6px 0 0;
}

.page-footer a {
  color: #ffffff;
  font-weight: 900;
}

@media (max-width: 1100px) {
  .catalog-grid,
  .related-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .detail-hero,
  .detail-layout {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 760px) {
  .page-header {
    min-height: 68px;
    padding: 0 16px;
  }

  .brand-mark {
    width: 44px;
    height: 44px;
  }

  .brand-text strong {
    max-width: 230px;
    font-size: 16px;
  }

  .brand-text small {
    display: none;
  }

  .nav-toggle {
    display: block;
  }

  .site-nav {
    position: absolute;
    top: 68px;
    right: 16px;
    left: 16px;
    display: none;
    flex-direction: column;
    align-items: stretch;
    gap: 0;
    padding: 8px;
    border-radius: 8px;
    background: rgba(13, 25, 36, 0.98);
  }

  .site-nav.is-open {
    display: flex;
  }

  .site-nav a {
    padding: 12px;
  }

  .catalog-hero,
  .detail-hero,
  .catalog-section,
  .detail-layout,
  .related-section {
    padding: 48px 16px;
  }

  .catalog-hero h1,
  .detail-hero h1 {
    font-size: 34px;
  }

  .catalog-grid,
  .related-grid,
  .detail-gallery {
    grid-template-columns: 1fr;
  }

  .catalog-image {
    height: 230px;
  }

  .detail-main-image {
    min-height: 280px;
  }

  .detail-main-image img {
    max-height: 250px;
  }

  .detail-content,
  .detail-side {
    padding: 18px;
  }

  .detail-actions {
    display: grid;
  }

  .page-footer {
    align-items: flex-start;
    flex-direction: column;
  }
}
