:root {
  color-scheme: light;
  --blue: #1664a3;
  --blue-deep: #0d3558;
  --green: #268060;
  --gold: #c9821b;
  --red: #d63f2f;
  --ink: #182536;
  --muted: #607184;
  --line: #dce6ee;
  --bg: #f2f6f9;
  --card: #ffffff;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: Arial, "PingFang SC", "Microsoft YaHei", sans-serif;
  line-height: 1.55;
  overflow-x: hidden;
}

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

.topbar {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  padding: 8px 16px;
  background: var(--blue-deep);
  color: #fff;
  font-size: 13px;
}

.site-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
  max-width: 1120px;
  margin: 0 auto;
  padding: 20px 16px 16px;
}

.site-header.compact {
  padding-bottom: 8px;
}

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

.mark {
  display: grid;
  place-items: center;
  width: 48px;
  height: 48px;
  border-radius: 8px;
  background: linear-gradient(135deg, var(--blue), var(--green));
  color: white;
  font-size: 27px;
  font-weight: 700;
}

h1,
h2,
h3,
p,
ul {
  margin: 0;
}

h1 {
  font-size: 24px;
  letter-spacing: 0;
}

h2 {
  font-size: 24px;
}

.brand p,
.intro,
.note,
.shop-info p,
.product-card p,
.hint,
footer p {
  color: var(--muted);
}

.header-actions {
  display: flex;
  align-items: center;
  gap: 10px;
  font-weight: 700;
}

.quote-link,
.primary,
.pay-button {
  display: inline-flex;
  justify-content: center;
  align-items: center;
  min-height: 42px;
  padding: 0 18px;
  border: 0;
  border-radius: 6px;
  background: var(--gold);
  color: white;
  font-weight: 700;
  font-size: 15px;
}

.nav {
  display: flex;
  justify-content: center;
  gap: 2px;
  background: var(--blue);
  color: white;
  box-shadow: 0 2px 8px rgba(13, 53, 88, .16);
}

.nav a {
  padding: 12px 18px;
  font-weight: 700;
}

.nav a:hover {
  background: rgba(255, 255, 255, .14);
}

main {
  max-width: 1120px;
  margin: 0 auto;
  padding: 18px 16px 88px;
}

.hero {
  min-height: 360px;
  display: grid;
  grid-template-columns: 1.35fr .75fr;
  align-items: center;
  gap: 28px;
  padding: 42px;
  background:
    linear-gradient(110deg, rgba(13, 53, 88, .94), rgba(22, 100, 163, .78)),
    repeating-linear-gradient(90deg, rgba(255,255,255,.22) 0 7px, transparent 7px 24px);
  color: white;
  overflow: hidden;
}

.eyebrow {
  display: inline-flex;
  margin-bottom: 12px;
  color: #ffe2ad;
  font-weight: 700;
}

.eyebrow.dark {
  color: var(--gold);
}

.hero h2 {
  max-width: 680px;
  font-size: 38px;
  line-height: 1.22;
}

.hero p {
  max-width: 660px;
  margin: 16px 0 24px;
  color: rgba(255, 255, 255, .9);
}

.hero-buttons {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
}

.secondary {
  display: inline-flex;
  align-items: center;
  min-height: 42px;
  padding: 0 18px;
  border: 1px solid rgba(255,255,255,.62);
  border-radius: 6px;
  color: white;
  font-weight: 700;
}

.hero-card {
  display: grid;
  gap: 10px;
  padding: 24px;
  border: 1px solid rgba(255,255,255,.4);
  border-radius: 8px;
  background: rgba(255,255,255,.13);
}

.hero-card strong {
  font-size: 22px;
}

.section {
  margin-top: 18px;
  padding: 24px;
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: 8px;
}

.section-title {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
  margin-bottom: 18px;
}

.section-title a {
  color: var(--blue);
  font-weight: 700;
}

.text-link {
  display: inline-flex;
  margin-top: 14px;
  color: var(--blue);
  font-weight: 700;
}

.product-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 14px;
}

.product-card {
  border: 1px solid var(--line);
  border-radius: 8px;
  overflow: hidden;
  background: #fff;
}

.product-body {
  padding: 14px;
}

.product-body h3 {
  margin: 8px 0 8px;
  font-size: 17px;
}

.tag {
  display: inline-flex;
  padding: 3px 8px;
  border-radius: 999px;
  background: #e9f3ef;
  color: var(--green);
  font-size: 12px;
  font-weight: 700;
}

.price {
  margin-top: 10px;
  color: var(--red);
  font-size: 19px;
  font-weight: 700;
}

.stock-pill {
  display: inline-flex;
  margin-top: 10px;
  padding: 3px 8px;
  border-radius: 999px;
  background: #f8f1e6;
  color: #8a5514;
  font-size: 12px;
  font-weight: 700;
}

.sales-note {
  margin-top: 8px;
  color: var(--muted);
  font-size: 13px;
}

.product-image {
  height: 150px;
  background-color: #d4e0e9;
  background-size: cover;
  background-position: center;
}

.screw {
  background-image:
    radial-gradient(circle at 68% 34%, #71869a 0 9px, #dfe8ef 10px 16px, transparent 17px),
    radial-gradient(circle at 35% 65%, #71869a 0 8px, #dfe8ef 9px 15px, transparent 16px),
    repeating-linear-gradient(35deg, #9db1c2 0 7px, #edf4f8 7px 15px);
}

.anchor {
  background-image:
    linear-gradient(90deg, transparent 0 20%, #728a9e 21% 28%, transparent 29% 42%, #728a9e 43% 50%, transparent 51%),
    repeating-linear-gradient(0deg, #dce7ef 0 12px, #a5b8c7 12px 18px);
}

.hinge {
  background-image:
    linear-gradient(90deg, #eef4f7 0 42%, #8096a9 42% 48%, #eef4f7 48% 100%),
    repeating-linear-gradient(0deg, #b5c6d4 0 10px, #f3f7fa 10px 22px);
}

.lock {
  background-image:
    radial-gradient(circle at 36% 45%, #f4f7fa 0 18px, #73889a 19px 27px, transparent 28px),
    linear-gradient(135deg, #4a5968 0 36%, #9aaebb 36% 60%, #e6eef3 60%);
}

.drill {
  background-image:
    repeating-linear-gradient(120deg, #596d7f 0 8px, #cbd8e1 8px 14px, #f4f8fb 14px 22px),
    linear-gradient(135deg, #a8bbc9, #edf4f8);
}

.cutter {
  background-image:
    radial-gradient(circle at 50% 50%, #f4f8fb 0 18px, #7c92a4 19px 28px, #e5edf3 29px 54px, #7c92a4 55px 60px, transparent 61px),
    linear-gradient(135deg, #b8c8d4, #eef5f9);
}

.sealant {
  background-image:
    linear-gradient(90deg, transparent 0 22%, #f7fbff 23% 56%, transparent 57%),
    linear-gradient(135deg, #7e94a5, #e5eef4);
}

.angle {
  background-image:
    linear-gradient(135deg, transparent 0 34%, #879dad 35% 49%, transparent 50%),
    linear-gradient(45deg, transparent 0 42%, #c9d7e1 43% 62%, transparent 63%),
    linear-gradient(135deg, #eef5f9, #afc1ce);
}

.shop-list {
  display: grid;
  gap: 14px;
}

.shop-item {
  display: grid;
  grid-template-columns: 160px 1fr 150px;
  gap: 16px;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
}

.shop-item .product-image {
  height: 150px;
  border-radius: 6px;
}

.shop-info h3 {
  margin: 8px 0;
}

.shop-info ul {
  margin-top: 10px;
  padding-left: 18px;
  color: var(--muted);
}

.buy-box {
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 8px;
  text-align: right;
}

.buy-box strong {
  color: var(--red);
  font-size: 24px;
}

.buy-box span {
  color: var(--muted);
}

.buy-box em {
  color: var(--green);
  font-style: normal;
  font-size: 13px;
  font-weight: 700;
}

.buy-box small {
  color: var(--muted);
  font-size: 13px;
}

.buy-box a {
  display: inline-flex;
  justify-content: center;
  align-items: center;
  min-height: 38px;
  border-radius: 6px;
  background: var(--blue);
  color: white;
  font-weight: 700;
}

.split {
  display: grid;
  grid-template-columns: 1fr 360px;
  gap: 24px;
}

.intro {
  margin-top: 12px;
}

.merchant-info {
  display: grid;
  gap: 10px;
  margin-top: 16px;
  padding: 16px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #f8fbfd;
}

.merchant-info div,
.merchant-table {
  display: grid;
  grid-template-columns: 150px 1fr;
  gap: 8px 14px;
}

.merchant-info span,
.merchant-table span {
  color: var(--muted);
}

.merchant-info strong,
.merchant-table strong {
  word-break: break-word;
}

.merchant-table {
  padding: 16px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
}

.merchant-hero {
  display: grid;
  grid-template-columns: 1fr 320px;
  align-items: center;
  gap: 24px;
}

.merchant-seal {
  display: grid;
  gap: 8px;
  padding: 22px;
  border: 1px solid #efd8b3;
  border-radius: 8px;
  background: #fff8ef;
}

.merchant-seal strong {
  color: #8a5514;
}

.merchant-seal span {
  color: var(--ink);
  font-size: 20px;
  font-weight: 700;
  word-break: break-all;
}

.license-frame {
  margin: 0;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
}

.license-frame img {
  display: block;
  width: 100%;
  height: auto;
  border-radius: 6px;
}

.license-frame figcaption {
  margin-top: 10px;
  color: var(--muted);
  text-align: center;
  font-size: 14px;
}

.review-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 14px;
}

.review-card {
  display: grid;
  gap: 8px;
  padding: 16px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
}

.review-card strong {
  color: var(--blue-deep);
}

.review-card p {
  color: var(--muted);
}

.service-list {
  display: grid;
  gap: 12px;
}

.service-list div {
  display: grid;
  gap: 4px;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 8px;
}

.service-list span {
  color: var(--muted);
}

.bottom-action {
  position: fixed;
  left: 0;
  right: 0;
  bottom: 0;
  padding: 12px 16px;
  background: rgba(255, 255, 255, .96);
  border-top: 1px solid var(--line);
}

.bottom-action .primary {
  width: 100%;
}

.order {
  margin: 18px auto;
  width: 100%;
  max-width: 620px;
  padding: 22px;
  background: white;
  border: 1px solid var(--line);
  border-radius: 8px;
}

.order.wide {
  max-width: 860px;
}

.order-items {
  margin-top: 16px;
  border: 1px solid var(--line);
  border-radius: 8px;
  overflow: hidden;
}

.order-row {
  display: grid;
  grid-template-columns: 1fr 88px 72px 88px;
  gap: 10px;
  padding: 12px;
  border-top: 1px solid var(--line);
}

.order-row:first-child {
  border-top: 0;
}

.order-row.head {
  background: #f4f8fb;
  color: var(--muted);
  font-weight: 700;
}

.line,
.amount {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  padding: 14px 0;
  border-bottom: 1px solid var(--line);
}

.line span,
.amount span,
.detail-grid span {
  color: var(--muted);
}

.line strong,
.amount strong {
  flex: 1 1 auto;
  min-width: 0;
  word-break: break-all;
  text-align: right;
}

.amount strong {
  color: var(--red);
  font-size: 28px;
}

.pay-button {
  width: 100%;
  margin-top: 18px;
  background: #1677ff;
}

.hint {
  margin-top: 12px;
  font-size: 13px;
}

.detail {
  margin-top: 14px;
}

.detail-grid {
  display: grid;
  grid-template-columns: 94px 1fr;
  gap: 10px 14px;
  margin-top: 16px;
  padding-top: 16px;
  border-top: 1px solid var(--line);
}

footer {
  padding: 24px 16px 34px;
  text-align: center;
  color: var(--muted);
  background: white;
  border-top: 1px solid var(--line);
}

footer strong {
  display: block;
  margin-bottom: 8px;
  color: var(--ink);
}

@media (max-width: 780px) {
  .topbar,
  .site-header {
    align-items: flex-start;
    flex-direction: column;
  }

  h1 {
    font-size: 18px;
  }

  .brand p {
    font-size: 14px;
  }

  .header-actions {
    width: 100%;
    align-items: stretch;
    flex-direction: column;
  }

  .header-actions a,
  .header-actions .quote-link {
    width: 100%;
    justify-content: center;
  }

  .nav {
    overflow-x: auto;
    justify-content: flex-start;
  }

  .nav a {
    flex: 0 0 auto;
    padding: 11px 14px;
  }

  .hero {
    grid-template-columns: 1fr;
    min-height: auto;
    padding: 26px 18px;
  }

  .hero h2 {
    font-size: 28px;
  }

  .product-grid {
    grid-template-columns: 1fr;
  }

  .review-grid {
    grid-template-columns: 1fr;
  }

  .section {
    padding: 20px;
  }

  .section-title {
    align-items: flex-start;
    flex-direction: column;
  }

  .shop-item {
    grid-template-columns: 1fr;
  }

  .buy-box {
    text-align: left;
  }

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

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

  .order-row {
    grid-template-columns: 1fr;
  }

  .order-row.head {
    display: none;
  }

  .line,
  .amount {
    align-items: flex-start;
    flex-direction: column;
    gap: 4px;
  }

  .line strong,
  .amount strong {
    text-align: left;
  }

  .merchant-info div,
  .merchant-table {
    grid-template-columns: 1fr;
  }
}
