:root {
  --purchase-blue: #0a4d9c;
  --purchase-blue-dark: #073c7a;
  --purchase-blue-light: #eaf2fb;
  --purchase-red: #d92323;
  --purchase-ink: #222b36;
  --purchase-muted: #77808c;
  --purchase-line: #dfe5ec;
  --purchase-surface: #ffffff;
  --purchase-bg: #f4f6f9;
}

body.purchase-cart-open { overflow: hidden; }
.purchase-page { background: var(--purchase-bg); }
.purchase-page .purchase-catalog {
  position: relative;
  float: none;
  width: 100%;
  min-width: 0;
}
.purchase-catalog.is-loading { min-height: 180px; }
.purchase-catalog.is-loading::after {
  content: "正在筛选…";
  position: absolute;
  z-index: 20;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--purchase-blue);
  background: rgba(244, 246, 249, .82);
  font-size: 15px;
  font-weight: 700;
}

.purchase-filter-panel {
  margin-bottom: 20px;
  overflow: hidden;
  border: 1px solid var(--purchase-line);
  border-radius: 4px;
  background: var(--purchase-surface);
}
.purchase-filter-row {
  display: grid;
  grid-template-columns: 72px minmax(0, 1fr) 54px;
  align-items: start;
  min-height: 54px;
  padding: 8px 16px;
  border-bottom: 1px solid var(--purchase-line);
}
.purchase-filter-row:last-child { border-bottom: 0; }
.purchase-filter-row strong { padding-top: 9px; color: var(--purchase-ink); font-size: 15px; }
.purchase-filter-options { display: flex; flex-wrap: wrap; max-height: 38px; overflow: hidden; }
.purchase-filter-row.is-open .purchase-filter-options { max-height: none; }
.purchase-filter-option {
  display: inline-flex;
  align-items: center;
  min-height: 38px;
  margin-right: 5px;
  padding: 0 12px;
  color: #4d5661;
  font-size: 14px;
  white-space: nowrap;
}
.purchase-filter-option:hover,
.purchase-filter-option.is-active { color: var(--purchase-blue); font-weight: 700; }
.purchase-filter-more {
  min-height: 38px;
  border: 0;
  color: #68717c;
  background: transparent;
  cursor: pointer;
}
.purchase-filter-more:hover { color: var(--purchase-blue); }

.purchase-product {
  margin-bottom: 20px;
  overflow: hidden;
  border: 1px solid var(--purchase-line);
  border-radius: 4px;
  background: var(--purchase-surface);
  box-shadow: 0 8px 24px rgba(27, 48, 74, .04);
}
.purchase-summary {
  display: grid;
  grid-template-columns: 90px minmax(0, 1fr) auto;
  gap: 18px;
  align-items: center;
  padding: 20px;
}
.purchase-thumb {
  display: flex;
  width: 90px;
  height: 90px;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  border: 1px solid #edf0f4;
  background: #fff;
}
.purchase-thumb img { max-width: 100%; max-height: 100%; object-fit: contain; }
.purchase-thumb .cdwl-no-image { min-height: 90px; padding: 8px; text-align: center; }
.purchase-summary-copy h2 { margin-bottom: 8px; font-size: 20px; font-weight: 700; }
.purchase-summary-copy h2 a:hover { color: var(--purchase-blue); }
.purchase-alias { margin-bottom: 9px; color: var(--purchase-muted); }
.purchase-alias b { color: #4f5965; font-weight: 400; }
.purchase-chemistry { display: flex; flex-wrap: wrap; gap: 10px 30px; }
.purchase-chemistry div { display: flex; color: var(--purchase-muted); }
.purchase-chemistry dd { color: #3e4854; }
.purchase-item-toggle {
  min-width: 64px;
  min-height: 40px;
  border: 1px solid var(--purchase-blue);
  border-radius: 3px;
  color: var(--purchase-blue);
  background: #fff;
  cursor: pointer;
}
.purchase-item-toggle:hover { color: #fff; background: var(--purchase-blue); }
.purchase-product.is-collapsed .purchase-specification { display: none; }

.purchase-table-scroll { width: 100%; overflow-x: auto; }
.purchase-table { width: 100%; min-width: 860px; table-layout: fixed; }
.purchase-table th {
  height: 44px;
  padding: 8px 6px;
  border-top: 2px solid var(--purchase-blue);
  color: var(--purchase-ink);
  background: var(--purchase-blue-light);
  font-weight: 700;
  text-align: center;
}
.purchase-table td {
  min-height: 58px;
  padding: 12px 6px;
  border-bottom: 1px solid #edf0f4;
  color: #525c67;
  text-align: center;
  vertical-align: middle;
}
.purchase-table td:first-child a { color: var(--purchase-blue); font-weight: 700; }
.purchase-table .purchase-price { color: var(--purchase-red); font-weight: 700; }
.purchase-quantity { display: inline-flex; height: 34px; align-items: stretch; border: 1px solid #bbc4cf; border-radius: 3px; background: #fff; }
.purchase-quantity button { width: 30px; border: 0; color: #44505c; background: #f7f9fb; cursor: pointer; font-size: 17px; }
.purchase-quantity input { width: 38px; border: 0; outline: 0; text-align: center; -moz-appearance: textfield; }
.purchase-quantity input::-webkit-inner-spin-button,
.purchase-quantity input::-webkit-outer-spin-button { margin: 0; -webkit-appearance: none; }
.purchase-add-button {
  display: inline-flex;
  min-width: 66px;
  height: 38px;
  align-items: center;
  justify-content: center;
  gap: 4px;
  overflow: hidden;
  border: 0;
  border-radius: 3px;
  color: #fff;
  background: var(--purchase-blue);
  cursor: pointer;
}
.purchase-add-button:hover { background: var(--purchase-blue-dark); }
.purchase-add-button.is-added { background: var(--purchase-red); }

.purchase-cart-art { position: relative; display: inline-block; width: 25px; height: 25px; overflow: hidden; flex: 0 0 auto; }
.purchase-cart-art img { position: absolute; width: 36px; height: auto; left: -9px; top: -7px; max-width: none; }

.purchase-detail-product { padding: 0; }
.purchase-detail-hero { display: grid; grid-template-columns: minmax(320px, 39%) minmax(0, 1fr); gap: 44px; padding: 42px; }
.purchase-detail-image { display: flex; min-height: 360px; align-items: center; justify-content: center; overflow: hidden; border: 1px solid var(--purchase-line); background: #fff; }
.purchase-detail-image img { display: block; max-width: 100%; max-height: 420px; object-fit: contain; }
.purchase-detail-image .cdwl-detail-no-image { min-height: 360px; }
.purchase-detail-copy { align-self: center; }
.purchase-detail-copy h1 { margin-bottom: 7px; color: var(--purchase-ink); font-size: 30px; line-height: 1.35; font-weight: 700; }
.purchase-detail-en { margin-bottom: 24px; color: var(--purchase-muted); font-size: 16px; }
.purchase-detail-meta { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 0; border-top: 1px solid var(--purchase-line); }
.purchase-detail-meta div { display: flex; min-height: 48px; align-items: center; padding: 8px 0; border-bottom: 1px solid var(--purchase-line); }
.purchase-detail-meta div:nth-child(odd) { padding-right: 20px; }
.purchase-detail-meta dt { color: var(--purchase-muted); }
.purchase-detail-meta dd { color: #37424f; font-weight: 700; }
.purchase-detail-description { margin: 22px 0; color: var(--purchase-muted); line-height: 1.8; }
.purchase-consult-button {
  min-width: 180px;
  height: 46px;
  border: 1px solid var(--purchase-blue);
  border-radius: 3px;
  color: #fff;
  background: var(--purchase-blue);
  cursor: pointer;
  font-size: 16px;
}
.purchase-consult-button:hover { background: var(--purchase-blue-dark); }
.purchase-detail-body { overflow: hidden; border: 1px solid var(--purchase-line); background: #fff; }
.purchase-detail-tabs { height: 54px; border-bottom: 1px solid var(--purchase-line); background: #f7f9fb; }
.purchase-detail-tabs button { width: 180px; height: 54px; border: 0; color: #fff; background: var(--purchase-blue); font-size: 17px; font-weight: 700; }
.purchase-detail-content { min-height: 220px; padding: 35px 42px; color: #4e5864; }
.purchase-detail-content .table-responsive { width: 100%; overflow-x: auto; }
.purchase-detail-content table {
  width: 100%;
  min-width: 560px;
  border: 1px solid #aeb6c2;
  border-collapse: collapse !important;
  border-spacing: 0;
  background: #fff;
}
.purchase-detail-content table th,
.purchase-detail-content table td {
  padding: 11px 14px;
  border: 1px solid #c4cbd3 !important;
  color: #46515d;
  line-height: 1.65;
  text-align: left;
  vertical-align: middle;
}
.purchase-detail-content table th {
  color: #2f3945;
  background: #f3f5f7;
  font-weight: 700;
}
.purchase-detail-pagination { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; margin-top: 20px; padding: 18px 22px; border: 1px solid var(--purchase-line); background: #fff; }
.purchase-detail-pagination span:last-child { text-align: right; }

.purchase-cart-float {
  position: relative;
  display: block;
  width: 44px;
  height: 44px;
  margin: 0 0 2px;
  overflow: visible;
  border: 0;
  background: var(--purchase-blue);
  cursor: pointer;
}
.purchase-cart-float:hover { background: var(--purchase-blue-dark); }
.purchase-cart-float .purchase-cart-art { position: absolute; width: 44px; height: 44px; inset: 0; }
.purchase-cart-float .purchase-cart-art img { width: 63px; left: -16px; top: -12px; }
.purchase-cart-badge {
  position: absolute;
  top: -7px;
  right: -7px;
  z-index: 3;
  min-width: 20px;
  height: 20px;
  padding: 0 5px;
  border: 2px solid #fff;
  border-radius: 12px;
  color: #fff;
  background: var(--purchase-red);
  font-size: 11px;
  line-height: 16px;
  text-align: center;
}

.purchase-cart-overlay { position: fixed; inset: 0; z-index: 100000; background: rgba(7, 25, 48, .55); }
.purchase-cart-overlay[hidden] { display: none; }
.purchase-cart-drawer { position: absolute; top: 0; right: 0; display: flex; width: min(520px, 92vw); height: 100vh; height: 100dvh; max-height: 100%; flex-direction: column; overflow: hidden; background: #fff; box-shadow: -12px 0 40px rgba(0, 0, 0, .18); }
.purchase-cart-header { display: flex; flex: 0 0 auto; align-items: center; justify-content: space-between; padding: 24px 28px; color: #fff; background: var(--purchase-blue); }
.purchase-cart-header p { margin-bottom: 3px; color: rgba(255,255,255,.72); font-size: 13px; letter-spacing: .08em; }
.purchase-cart-header h2 { font-size: 24px; font-weight: 700; }
.purchase-cart-close { min-width: 64px; min-height: 40px; border: 1px solid rgba(255,255,255,.55); border-radius: 3px; color: #fff; background: transparent; cursor: pointer; }
.purchase-cart-lines { padding: 0 28px; }
.purchase-cart-line { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 15px; align-items: center; padding: 17px 0; border-bottom: 1px solid var(--purchase-line); }
.purchase-cart-line-copy strong { display: block; margin-bottom: 4px; color: var(--purchase-ink); font-size: 15px; }
.purchase-cart-line-copy span { color: var(--purchase-muted); font-size: 13px; }
.purchase-cart-line-controls { display: flex; align-items: center; gap: 3px; }
.purchase-cart-line-controls button { min-width: 32px; height: 32px; padding: 0 7px; border: 1px solid var(--purchase-line); color: #46515d; background: #fff; cursor: pointer; }
.purchase-cart-line-controls button:last-child { margin-left: 5px; color: var(--purchase-red); }
.purchase-cart-line-controls span { min-width: 26px; text-align: center; }
.purchase-cart-empty { margin: 22px 28px 0; padding: 18px; color: var(--purchase-muted); background: var(--purchase-bg); line-height: 1.7; }
.purchase-cart-empty[hidden] { display: none; }
.purchase-inquiry-form { display: flex; min-height: 0; flex: 1 1 auto; flex-direction: column; }
.purchase-cart-scroll { min-height: 0; flex: 1 1 auto; overflow-x: hidden; overflow-y: auto; overscroll-behavior: contain; scrollbar-color: #8b99aa #eef1f4; scrollbar-gutter: stable; scrollbar-width: thin; }
.purchase-cart-scroll::-webkit-scrollbar { width: 8px; }
.purchase-cart-scroll::-webkit-scrollbar-track { background: #eef1f4; }
.purchase-cart-scroll::-webkit-scrollbar-thumb { border: 2px solid #eef1f4; border-radius: 8px; background: #8b99aa; }
.purchase-inquiry-fields { padding: 24px 28px 8px; }
.purchase-inquiry-form label { position: relative; display: block; margin-bottom: 16px; }
.purchase-field-required { position: relative; display: block; }
.purchase-field-required::after { content: "*"; position: absolute; top: 11px; right: 13px; z-index: 1; color: var(--purchase-red); font-size: 16px; line-height: 20px; pointer-events: none; }
.purchase-inquiry-form input,
.purchase-inquiry-form textarea { width: 100%; padding: 11px 13px; border: 1px solid #cfd6df; border-radius: 3px; color: var(--purchase-ink); background: #fff; font: inherit; outline: 0; resize: vertical; }
.purchase-field-required input,
.purchase-field-required textarea { padding-right: 32px; }
.purchase-inquiry-form input:focus,
.purchase-inquiry-form textarea:focus { border-color: var(--purchase-blue); box-shadow: 0 0 0 3px rgba(10, 77, 156, .12); }
.purchase-inquiry-form textarea[readonly] { color: #4b5662; background: #f7f9fb; }
.purchase-checkcode { display: flex !important; gap: 10px; }
.purchase-checkcode-input { min-width: 0; flex: 1 1 auto; }
.purchase-checkcode img { width: 120px; height: 42px; object-fit: cover; cursor: pointer; }
.purchase-inquiry-footer { flex: 0 0 auto; padding: 16px 28px 20px; border-top: 1px solid var(--purchase-line); background: #fff; box-shadow: 0 -8px 24px rgba(27, 48, 74, .07); }
.purchase-inquiry-submit { width: 100%; height: 48px; border: 0; border-radius: 3px; color: #fff; background: var(--purchase-blue); cursor: pointer; font-size: 16px; font-weight: 700; }
.purchase-inquiry-submit:hover { background: var(--purchase-blue-dark); }
.purchase-form-note { margin-top: 12px; color: var(--purchase-muted); font-size: 12px; line-height: 1.6; }
.purchase-toast { position: fixed; left: 50%; bottom: 40px; z-index: 100001; transform: translateX(-50%); padding: 12px 20px; border-radius: 3px; color: #fff; background: rgba(7, 25, 48, .9); box-shadow: 0 6px 22px rgba(0,0,0,.18); }
.purchase-toast[hidden] { display: none; }

@media (max-width: 1079px) {
  .purchase-detail-hero { grid-template-columns: 1fr; gap: 26px; }
  .purchase-detail-image { min-height: 320px; }
}

@media (max-width: 767px) {
  body { padding-bottom: 44px; }
  .purchase-filter-row { grid-template-columns: 58px minmax(0, 1fr) 48px; padding: 7px 10px; }
  .purchase-filter-option { min-height: 36px; padding: 0 8px; }
  .purchase-summary { grid-template-columns: 72px minmax(0, 1fr); gap: 12px; padding: 15px; }
  .purchase-thumb { width: 72px; height: 72px; }
  .purchase-thumb .cdwl-no-image { min-height: 72px; font-size: 12px; }
  .purchase-summary-copy h2 { font-size: 17px; }
  .purchase-chemistry { display: grid; grid-template-columns: 1fr; gap: 4px; }
  .purchase-item-toggle { grid-column: 1 / -1; width: 100%; }
  .purchase-table { min-width: 0; }
  .purchase-table thead { display: none; }
  .purchase-table tbody,
  .purchase-table tr,
  .purchase-table td { display: block; width: 100%; }
  .purchase-table tr { padding: 8px 15px 16px; }
  .purchase-table td { display: grid; grid-template-columns: 100px minmax(0, 1fr); align-items: center; min-height: 46px; padding: 7px 0; text-align: right; }
  .purchase-table td::before { content: attr(data-label); color: #717a85; text-align: left; font-weight: 700; }
  .purchase-table td:last-child { border-bottom: 0; }
  .purchase-table td:last-child .purchase-add-button { justify-self: end; min-width: 112px; }
  .purchase-table td .purchase-quantity { justify-self: end; }
  .purchase-detail-hero { padding: 20px; }
  .purchase-detail-image { min-height: 260px; }
  .purchase-detail-copy h1 { font-size: 24px; }
  .purchase-detail-meta { grid-template-columns: 1fr; }
  .purchase-detail-meta div:nth-child(odd) { padding-right: 0; }
  .purchase-consult-button { width: 100%; }
  .purchase-detail-tabs button { width: 145px; }
  .purchase-detail-content { padding: 24px 20px; }
  .purchase-detail-pagination { grid-template-columns: 1fr; }
  .purchase-detail-pagination span:last-child { text-align: left; }
  .f_pf1 { position: fixed; top: auto; bottom: 0; z-index: 99998; }
  .f_pf1 .tela > a,
  .f_pf1 .pfpro,
  .f_pf1 .pflxwm,
  .f_pf1 a.totop,
  .f_pf1 .purchase-cart-float { width: 20%; }
  .purchase-cart-float { float: left; margin-bottom: 0; }
  .purchase-cart-float .purchase-cart-art { left: 50%; transform: translateX(-50%); }
  .purchase-cart-badge { right: calc(50% - 28px); }
  .purchase-cart-drawer { top: auto; bottom: 0; width: 100%; height: min(88vh, 760px); height: min(88dvh, 760px); border-radius: 12px 12px 0 0; }
  .purchase-cart-header { padding: 18px 20px; }
  .purchase-cart-header h2 { font-size: 21px; }
  .purchase-cart-lines { padding: 0 20px; }
  .purchase-cart-line { grid-template-columns: 1fr; }
  .purchase-cart-line-controls { justify-content: flex-end; }
  .purchase-cart-empty { margin: 18px 20px 0; }
  .purchase-inquiry-fields { padding: 20px 20px 4px; }
  .purchase-inquiry-footer { padding: 14px 20px 16px; }
  .purchase-toast { bottom: 62px; width: calc(100% - 40px); text-align: center; }
}
