:root {
  color-scheme: light;
  --ink: #16211f;
  --muted: #61706d;
  --line: #d8e2de;
  --soft: #f5f8f6;
  --panel: #ffffff;
  --green: #c91623;
  --red: #d71920;
  --blue: #2864ad;
  --amber: #b87916;
  --shadow: 0 14px 40px rgba(22, 33, 31, 0.12);
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  color: var(--ink);
  background: #f1f5f3;
  overflow-x: hidden;
}

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

button {
  cursor: pointer;
}

.utility-bar {
  background: #f7f7f7;
  border-bottom: 1px solid var(--line);
  color: var(--muted);
  font-size: 13px;
}

.utility-inner {
  max-width: 1360px;
  margin: 0 auto;
  min-height: 34px;
  padding: 6px 24px;
  display: flex;
  justify-content: space-between;
  gap: 12px;
  align-items: center;
}

.utility-left,
.utility-links,
.mall-footer nav {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  align-items: center;
}

.utility-links a,
.utility-links button,
.text-button,
.mall-footer button,
.mall-footer a {
  border: 0;
  padding: 0;
  color: var(--muted);
  background: transparent;
  text-decoration: none;
}

.utility-links a:hover,
.utility-links button:hover,
.text-button:hover,
.mall-footer button:hover,
.mall-footer a:hover {
  color: var(--green);
}

.topbar {
  position: sticky;
  top: 0;
  z-index: 20;
  background: rgba(255, 255, 255, 0.96);
  border-bottom: 1px solid var(--line);
  backdrop-filter: blur(12px);
}

.topbar-inner {
  max-width: 1360px;
  margin: 0 auto;
  min-height: 76px;
  padding: 12px 24px;
  display: grid;
  grid-template-columns: 220px minmax(260px, 1fr) auto;
  gap: 18px;
  align-items: center;
}

.brand {
  display: inline-flex;
  gap: 8px;
  align-items: center;
  min-width: 0;
  color: inherit;
  text-decoration: none;
}

.brand-logo {
  flex: 0 0 auto;
  width: 58px;
  height: 42px;
  object-fit: contain;
}

.brand-mark {
  display: grid;
  place-items: center;
  width: 42px;
  height: 42px;
  border-radius: 8px;
  background: var(--green);
  color: #fff;
  font-weight: 800;
}

.brand-copy {
  display: grid;
  align-content: center;
  gap: 2px;
  min-width: 0;
}

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

.brand strong {
  color: #082847;
  font-size: 18px;
  line-height: 1.15;
}

.brand small {
  color: var(--muted);
  font-size: 11px;
  line-height: 1.2;
  white-space: nowrap;
}

.search {
  display: grid;
  grid-template-columns: 86px minmax(0, 1fr) 96px;
  border: 2px solid var(--green);
  border-radius: 8px;
  overflow: hidden;
  background: #fff;
}

.search.search-simple {
  grid-template-columns: minmax(0, 1fr) 96px;
}

.search input {
  min-width: 0;
  border: 0;
  padding: 12px 14px;
  outline: 0;
}

.search button,
.hero-actions button,
.quick-panel button,
.drawer-form button,
.modal-card > button {
  border: 0;
  color: #fff;
  background: var(--green);
  font-weight: 700;
}

.search-assistant {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 86px;
  min-height: 44px;
  padding: 0 10px;
  border: 0;
  border-right: 1px solid rgba(201, 22, 35, 0.2) !important;
  appearance: none;
  color: var(--green) !important;
  background: #fff5f6 !important;
  font: inherit;
  font-weight: 700;
  line-height: 1;
  text-decoration: none;
  white-space: nowrap;
  box-sizing: border-box;
}

.cart-entry,
.quote-entry {
  font-weight: 800;
}

.quote-entry {
  border-color: var(--green) !important;
  color: #fff !important;
  background: var(--green) !important;
}

.mall-nav {
  max-width: 1360px;
  margin: 0 auto;
  min-height: 42px;
  padding: 0 24px 10px;
  display: flex;
  gap: 8px;
  align-items: center;
  overflow-x: auto;
}

.mall-nav a,
.mall-nav button {
  flex: 0 0 auto;
  min-height: 34px;
  border: 0;
  border-radius: 8px;
  padding: 8px 14px;
  color: var(--ink);
  background: transparent;
  text-decoration: none;
  white-space: nowrap;
}

.mall-nav .is-active,
.mall-nav a:hover,
.mall-nav button:hover {
  color: #fff;
  background: var(--green);
}

.account-nav {
  display: flex;
  gap: 8px;
  align-items: center;
}

.account-nav > a {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  box-sizing: border-box;
  font: inherit;
  text-decoration: none;
  white-space: nowrap;
}

.account-nav > a,
.account-nav button,
.account-dropdown a,
.account-dropdown button,
.brand-strip button,
.category-panel button,
.category-panel a,
.scene-grid button,
.pager button,
.drawer-head button,
.tabs button,
.modal-head button,
.catalog-tools select,
.view-toggle button,
.result-filters button,
.search-assist button {
  border: 1px solid var(--line);
  background: #fff;
  color: var(--ink);
  border-radius: 8px;
  min-height: 38px;
  padding: 8px 12px;
}

.account-menu {
  position: relative;
  display: flex;
  align-items: center;
  gap: 8px;
}

.account-greeting {
  max-width: 190px;
  overflow: hidden;
  color: var(--muted);
  font-size: 13px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.account-dropdown {
  position: absolute;
  top: calc(100% + 8px);
  right: 0;
  z-index: 30;
  width: 190px;
  display: none;
  gap: 6px;
  padding: 8px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  box-shadow: var(--shadow);
}

.account-dropdown.is-open {
  display: grid;
}

.account-dropdown a,
.account-dropdown button {
  min-height: 34px;
  text-align: left;
  text-decoration: none;
}

.account-menu.is-authenticated #dropdown-login-button,
.account-menu:not(.is-authenticated) #logout-button {
  display: none;
}

main {
  max-width: 1360px;
  margin: 0 auto;
  padding: 22px 24px 70px;
}

body.search-mode main,
body.listing-mode main {
  padding-top: 18px;
}

body.listing-mode .home-only {
  display: none;
}

.home-guide-strip {
  display: grid;
  gap: 12px;
  margin-top: 18px;
  padding: 18px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
}

.home-section-head {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  align-items: end;
}

.home-section-head div {
  display: grid;
  gap: 4px;
}

.home-section-head strong {
  font-size: 18px;
}

.home-section-head span,
.home-guide-grid small {
  color: var(--muted);
}

.home-section-head a {
  flex: 0 0 auto;
  color: var(--green);
  font-weight: 800;
  text-decoration: none;
}

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

.home-guide-grid a {
  display: grid;
  gap: 8px;
  min-width: 0;
  min-height: 136px;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 8px;
  color: inherit;
  background: var(--soft);
  text-decoration: none;
}

.home-guide-grid a:hover {
  border-color: rgba(201, 22, 35, 0.36);
  background: #fff;
}

.home-guide-grid span {
  width: fit-content;
  padding: 3px 8px;
  border-radius: 999px;
  color: var(--green);
  background: #fff5f6;
  font-size: 12px;
  font-weight: 800;
}

.home-guide-grid strong {
  font-size: 16px;
  line-height: 1.35;
}

.home-link-hub {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
  margin-top: 18px;
}

.home-link-hub > div {
  display: grid;
  align-content: start;
  gap: 8px;
  min-width: 0;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
}

.home-link-hub strong {
  color: var(--ink);
}

.home-link-hub a {
  color: var(--green);
  font-weight: 700;
  text-decoration: none;
  overflow-wrap: anywhere;
}

.home-link-hub a:hover {
  text-decoration: underline;
}

.pager {
  margin-top: 18px;
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 12px;
}

.drawer {
  position: fixed;
  top: 0;
  right: 0;
  z-index: 40;
  width: min(460px, 100vw);
  height: 100vh;
  background: #fff;
  box-shadow: var(--shadow);
  transform: translateX(105%);
  transition: transform 0.2s ease;
  display: grid;
  grid-template-rows: auto 1fr auto;
}

.drawer.is-open {
  transform: translateX(0);
}

.drawer-head,
.modal-head {
  padding: 16px;
  border-bottom: 1px solid var(--line);
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.drawer-body {
  overflow: auto;
  padding: 14px;
  display: grid;
  align-content: start;
  gap: 10px;
}

.cart-line,
.order-line {
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 10px;
  display: grid;
  gap: 6px;
}

.cart-select {
  display: grid;
  grid-template-columns: 18px minmax(0, 1fr);
  gap: 8px;
  align-items: start;
}

.cart-select input {
  margin-top: 3px;
}

.cart-line-controls {
  display: flex;
  justify-content: space-between;
  gap: 8px;
  align-items: center;
}

.cart-line-controls input {
  width: 88px;
}

.cart-summary {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  padding: 12px 14px;
  border-top: 1px solid var(--line);
  color: var(--muted);
  background: #fff7f7;
}

.cart-summary strong {
  color: var(--red);
}

.drawer-form,
.modal-card {
  padding: 14px;
  display: grid;
  gap: 10px;
  border-top: 1px solid var(--line);
}

.drawer-form {
  grid-template-columns: 1fr 1fr;
}

.drawer-form button:first-child {
  border: 1px solid var(--line);
  color: var(--ink);
  background: #fff;
}

.drawer-form input,
.modal-card input {
  min-height: 40px;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 9px 10px;
}

.modal {
  position: fixed;
  inset: 0;
  z-index: 50;
  display: none;
  place-items: center;
  padding: 18px;
  background: rgba(13, 21, 19, 0.42);
}

.modal.is-open {
  display: grid;
}

.modal-card {
  width: min(560px, 100%);
  background: #fff;
  border-radius: 8px;
  border: 1px solid var(--line);
  box-shadow: var(--shadow);
}

.auth-card {
  width: min(460px, 100%);
}

.modal-card.auth-card .auth-fields {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 14px;
}

.auth-field {
  display: grid;
  gap: 6px;
  color: var(--muted);
  font-size: 13px;
}

.auth-field b {
  color: var(--red);
}

.auth-field input {
  color: var(--ink);
  font-size: 15px;
}

.auth-field-hidden {
  position: absolute;
  left: -10000px;
  width: 1px;
  height: 1px;
  overflow: hidden;
}

.captcha-field {
  gap: 8px;
}

.captcha-row {
  display: flex;
  align-items: center;
  gap: 10px;
}

.captcha-image {
  width: 118px;
  height: 40px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #f8fafc;
  overflow: hidden;
  flex: 0 0 auto;
}

.captcha-image svg {
  display: block;
  width: 100%;
  height: 100%;
}

.captcha-refresh {
  min-height: 36px;
  padding: 0 12px;
  border-color: var(--line);
  background: #fff;
  color: var(--green);
  font-weight: 800;
}

.auth-links {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  align-items: center;
  min-height: 28px;
}

.link-button {
  min-height: 28px;
  border: 0;
  padding: 0;
  background: transparent;
  color: var(--green);
  font-weight: 700;
}

.tabs {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
}

.tabs button.is-active {
  border-color: var(--green);
  color: var(--green);
  background: #eef8f4;
}

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

.is-hidden {
  display: none !important;
}

.toast {
  position: fixed;
  left: 50%;
  bottom: 26px;
  z-index: 80;
  transform: translate(-50%, 130%);
  background: #14211e;
  color: #fff;
  padding: 10px 14px;
  border-radius: 8px;
  opacity: 0;
  transition: 0.2s ease;
}

.toast.is-open {
  opacity: 1;
  transform: translate(-50%, 0);
}

.float-toolbar {
  position: fixed;
  right: 18px;
  top: 42%;
  z-index: 35;
  display: grid;
  gap: 8px;
}

.float-toolbar button {
  width: 74px;
  min-height: 42px;
  border: 1px solid var(--line);
  border-radius: 8px;
  color: var(--ink);
  background: #fff;
  box-shadow: 0 10px 22px rgba(22, 33, 31, 0.1);
}

.float-toolbar button:first-child,
.float-toolbar button:hover {
  border-color: var(--green);
  color: #fff;
  background: var(--green);
}

.payment-info {
  display: grid;
  gap: 6px;
  margin: 10px 12px 12px;
  padding: 12px;
  border: 1px solid #f0d9d9;
  border-radius: 8px;
  background: #fff8f8;
}

.checkout-summary .payment-info {
  margin: 10px 0 0;
}

.payment-info strong {
  color: var(--green);
}

.payment-info span,
.payment-info small {
  overflow-wrap: anywhere;
  color: var(--muted);
  font-size: 13px;
}

.payment-info span {
  color: var(--ink);
  font-weight: 700;
}

.checkout-main {
  max-width: 1180px;
}

.product-detail-panel {
  display: grid;
  grid-template-columns: 360px minmax(0, 1fr);
  gap: 18px;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
}

.ssr-product-summary {
  grid-column: 1 / -1;
  display: grid;
  grid-template-columns: 220px minmax(0, 1fr);
  gap: 18px;
  align-items: start;
}

.ssr-product-summary img {
  width: 220px;
  height: 220px;
  object-fit: contain;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  padding: 12px;
}

.ssr-product-copy {
  display: grid;
  gap: 12px;
  min-width: 0;
}

.ssr-product-copy p {
  margin: 0;
  color: var(--green);
  font-weight: 800;
}

.ssr-product-copy h1 {
  margin: 0;
  font-size: 26px;
  line-height: 1.25;
  overflow-wrap: anywhere;
}

.ssr-product-copy dl {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
  margin: 0;
}

.ssr-product-copy dl > div {
  min-width: 0;
  padding: 10px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--soft);
}

.ssr-product-copy dt {
  color: var(--muted);
  font-size: 12px;
}

.ssr-product-copy dd {
  margin: 4px 0 0;
  font-weight: 700;
  overflow-wrap: anywhere;
}

.detail-image-wrap {
  position: relative;
  min-width: 0;
  border: 1px solid var(--line);
  border-radius: 8px;
  overflow: hidden;
  background: #fff;
}

.detail-gallery {
  display: grid;
  grid-template-columns: 68px minmax(0, 1fr);
  gap: 10px;
  align-items: start;
  min-width: 0;
}

.detail-gallery-thumbs {
  display: grid;
  gap: 8px;
  max-height: 360px;
  overflow-y: auto;
  padding-right: 2px;
  scrollbar-width: thin;
}

.detail-gallery-thumb {
  width: 64px;
  height: 64px;
  padding: 4px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
}

.detail-gallery-thumb.is-active {
  border-color: var(--green);
  box-shadow: 0 0 0 1px var(--green);
}

.detail-gallery-thumb img {
  width: 100%;
  height: 100%;
  object-fit: contain;
}

.detail-main-image-button {
  display: block;
  width: 100%;
  padding: 0;
  border: 0;
  background: #fff;
  cursor: zoom-in;
}

.detail-image-wrap img {
  display: block;
  width: 100%;
  height: 360px;
  padding: 14px;
  object-fit: contain;
  background: #fff;
}

.detail-gallery-arrow {
  position: absolute;
  top: 50%;
  z-index: 2;
  width: 34px;
  height: 44px;
  border-radius: 8px;
  color: #fff;
  background: rgba(15, 23, 42, 0.58);
  transform: translateY(-50%);
}

.detail-gallery-arrow.is-prev { left: 8px; }
.detail-gallery-arrow.is-next { right: 8px; }

.detail-image-counter {
  position: absolute;
  right: 10px;
  bottom: 10px;
  padding: 4px 8px;
  border-radius: 999px;
  color: #fff;
  background: rgba(15, 23, 42, 0.68);
  font-size: 12px;
}

.product-description {
  grid-column: 1 / -1;
  margin-top: 8px;
  border-top: 1px solid var(--line);
}

.product-description-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 18px 4px 12px;
}

.product-description-head h2 { margin: 0; font-size: 22px; }
.product-description-head span { color: var(--muted); font-size: 13px; }

.product-description-images {
  display: grid;
  justify-items: center;
  gap: 10px;
  min-height: 40px;
}

.product-description-images img {
  display: block;
  width: auto;
  max-width: 100%;
  height: auto;
  background: #fff;
}

.product-image-lightbox {
  position: fixed;
  inset: 0;
  z-index: 1200;
  display: grid;
  place-items: center;
  padding: 40px;
  background: rgba(2, 6, 23, 0.88);
}

.product-image-lightbox img {
  max-width: min(1200px, 94vw);
  max-height: 90vh;
  object-fit: contain;
}

.product-image-lightbox-close {
  position: absolute;
  top: 18px;
  right: 22px;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  color: #fff;
  background: rgba(255, 255, 255, 0.16);
  font-size: 30px;
}

.detail-info {
  display: grid;
  align-content: start;
  gap: 12px;
  min-width: 0;
}

.detail-info h1 {
  margin: 0;
  font-size: 24px;
  line-height: 1.32;
  letter-spacing: 0;
  overflow-wrap: anywhere;
}

.detail-price-row {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  align-items: center;
  padding: 10px 12px;
  border-radius: 8px;
  background: #fff6f5;
}

.detail-price-row strong {
  color: var(--red);
  font-size: 26px;
}

.detail-price-row span {
  color: var(--amber);
  font-weight: 700;
}

.detail-freight-policy {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 12px;
  align-items: center;
  padding: 10px 12px;
  border: 1px solid rgba(215, 25, 32, 0.32);
  border-radius: 8px;
  background: #fff8f8;
  color: var(--muted);
  line-height: 1.55;
}

.detail-freight-policy strong {
  display: inline-flex;
  flex: 0 0 auto;
  align-items: center;
  min-height: 24px;
  padding: 3px 8px;
  border-radius: 6px;
  background: var(--green);
  color: #fff;
  font-size: 13px;
}

.detail-freight-policy span {
  flex: 1 1 280px;
  min-width: 0;
  overflow-wrap: anywhere;
}

.detail-specs {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
  margin: 0;
}

.detail-specs div {
  display: grid;
  gap: 5px;
  padding: 9px 10px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--soft);
}

.detail-specs dt {
  color: var(--muted);
  font-size: 12px;
}

.detail-specs dd {
  min-width: 0;
  margin: 0;
  overflow-wrap: anywhere;
  font-weight: 700;
}

.detail-buy-row {
  display: grid;
  grid-template-columns: 120px 1fr 1fr 1fr;
  gap: 10px;
  align-items: end;
}

.detail-buy-row label {
  display: grid;
  gap: 6px;
  color: var(--muted);
  font-size: 13px;
}

.detail-buy-row input {
  min-width: 0;
  min-height: 44px;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 9px 10px;
  background: #fff;
}

.detail-buy-row button {
  min-height: 44px;
  border: 1px solid var(--green);
  border-radius: 8px;
  background: var(--green);
  color: #fff;
  font-weight: 800;
}

.detail-buy-row button:first-of-type {
  color: var(--green);
  background: #eef8f4;
}

.detail-note {
  display: grid;
  gap: 6px;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  color: var(--muted);
  background: var(--soft);
}

.detail-note strong {
  color: var(--ink);
}

@media (max-width: 1080px) {
  .utility-inner,
  .mall-footer {
    grid-template-columns: 1fr;
  }

  .topbar-inner {
    grid-template-columns: 1fr;
  }

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

  .category-panel {
    grid-template-columns: 1fr;
  }

  .category-tree {
    grid-column: 1 / -1;
  }

  .category-primary-row {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .category-flyout {
    top: calc(100% + 8px);
    left: 0;
    width: min(760px, calc(100vw - 48px));
  }

  .panel-title {
    grid-column: 1 / -1;
  }

  .member-panel {
    grid-template-columns: 1fr 1fr;
  }

  .product-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  body.listing-mode .product-grid.view-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .product-list-head,
  .product-row {
    grid-template-columns: minmax(0, 1.45fr) 130px 150px 140px;
  }

  .product-row-detail {
    grid-template-columns: 112px minmax(0, 1fr);
  }

  .product-row img {
    width: 112px;
    height: 112px;
  }

  .account-layout {
    grid-template-columns: 1fr;
  }

  .account-sidebar {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .account-sidebar section {
    border-bottom: 0;
    padding-bottom: 0;
  }

  .recommend-list {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .profile-placeholders {
    grid-template-columns: 1fr;
  }

  .service-card {
    grid-template-columns: 1fr;
  }

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

  .filter-keyword {
    grid-column: 1 / -1;
  }

  .order-table {
    overflow-x: auto;
  }

  .order-table-head,
  .order-grid-row {
    min-width: 980px;
  }

  .product-detail-panel,
  .checkout-layout {
    grid-template-columns: 1fr;
  }

  .detail-image-wrap {
    max-width: 420px;
  }

  .detail-image-wrap img {
    height: 320px;
  }

  .checkout-summary {
    position: static;
  }
}

@media (max-width: 760px) {
  .topbar-inner,
  main,
  .utility-inner,
  .mall-nav,
  .mall-footer {
    padding-left: 14px;
    padding-right: 14px;
  }

  .utility-inner {
    align-items: flex-start;
    flex-direction: column;
  }

  .utility-left,
  .utility-links {
    width: 100%;
  }

  .utility-links a,
  .utility-links button,
  .text-button,
  .text-link {
    min-width: 44px;
    min-height: 44px;
    display: inline-flex;
    align-items: center;
  }

  .topbar {
    overflow-x: hidden;
  }

  .topbar-inner {
    width: 100%;
    max-width: 100%;
    min-height: auto;
    grid-template-columns: minmax(0, 1fr);
    gap: 10px;
    align-items: stretch;
  }

  .brand {
    width: 100%;
    min-width: 0;
    min-height: 44px;
  }

  .brand-copy small {
    white-space: normal;
  }

  .search {
    width: 100%;
    min-width: 0;
    grid-template-columns: minmax(0, 1fr) 74px;
  }

  .search input,
  .search button {
    min-height: 44px;
  }

  .search.search-simple {
    grid-template-columns: minmax(0, 1fr) 74px;
  }

  .search-assistant {
    grid-column: 1 / -1;
    border-right: 0 !important;
    border-bottom: 1px solid rgba(201, 22, 35, 0.2) !important;
  }

  .account-nav {
    display: grid;
    width: 100%;
    min-width: 0;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 8px;
  }

  .category-panel {
    min-height: 68px;
  }

  .account-greeting {
    display: none;
  }

  .account-menu,
  .account-menu > button,
  .account-nav > button,
  .account-nav > a,
  .nav-button {
    width: 100%;
    max-width: none;
    min-height: 44px;
    justify-content: center;
    white-space: normal;
    overflow-wrap: anywhere;
    text-align: center;
  }

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

  .mall-nav {
    max-width: 100%;
    overflow-x: visible;
    flex-wrap: wrap;
    gap: 6px;
    padding-top: 8px;
    padding-bottom: 8px;
  }

  .mall-nav a,
  .mall-nav button {
    flex: 1 1 86px;
    min-width: 0;
    min-height: 44px;
    justify-content: center;
    white-space: normal;
    text-align: center;
  }

  .hero-main {
    grid-template-columns: 1fr;
    padding: 18px;
  }

  .hero-copy h1 {
    font-size: 32px;
  }

  .category-panel {
    display: flex;
    max-height: none;
    max-width: 100%;
    min-width: 0;
    overflow-x: hidden;
    overflow-y: visible;
    flex-wrap: wrap;
    contain: layout paint;
  }

  .category-tree,
  .category-primary-row,
  .category-group {
    display: flex;
    flex: 0 0 auto;
  }

  .category-tree {
    flex-wrap: wrap;
    max-width: 100%;
    min-width: 0;
    width: 100%;
    overflow-x: visible;
  }

  .category-primary-row {
    max-width: 100%;
    min-width: 0;
    width: 100%;
    overflow-x: auto;
    overflow-y: hidden;
    flex-wrap: nowrap;
    -webkit-overflow-scrolling: touch;
    overscroll-behavior-inline: contain;
  }

  .category-group {
    position: static;
    flex: 0 0 auto;
    min-width: 0;
    max-width: none;
  }

  .category-panel .panel-title {
    display: none;
  }

  .category-panel button,
  .category-panel a {
    white-space: nowrap;
  }

  .category-panel .category-parent {
    min-height: 38px;
  }

  .category-panel .category-parent span {
    display: block;
    overflow: visible;
    white-space: nowrap;
    line-height: inherit;
  }

  .category-panel .category-child {
    margin-left: 0;
  }

  .category-flyout {
    display: none !important;
  }

  .category-mobile-children {
    display: flex;
    flex: 1 0 100%;
    gap: 8px;
    overflow-x: auto;
    padding-top: 8px;
  }

  .category-active-children {
    padding: 8px;
  }

  .category-active-list {
    overflow-x: auto;
    flex-wrap: nowrap;
  }

  .member-panel,
  .scene-grid {
    grid-template-columns: 1fr;
  }

  .brand-strip {
    max-width: 100%;
    overflow-x: visible;
    flex-wrap: wrap;
  }

  .brand-strip button {
    flex: 1 1 calc(33.333% - 8px);
    min-width: 86px;
    min-height: 44px;
    white-space: normal;
  }

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

  body.listing-mode .product-grid.view-grid,
  .product-grid.view-list {
    grid-template-columns: 1fr;
  }

  .search-result-head,
  .result-filters {
    grid-template-columns: 1fr;
  }

  .filter-row {
    grid-template-columns: 1fr;
    gap: 6px;
  }

  .filter-inline {
    align-items: stretch;
  }

  .filter-price-row input,
  .filter-extra-row select,
  #clear-result-filters {
    flex: 1 1 100%;
    width: 100%;
  }

  .filter-options {
    max-height: 130px;
    overflow: auto;
  }

  .search-result-head {
    align-items: start;
    flex-direction: column;
  }

  .filter-check {
    padding-bottom: 0;
  }

  .catalog-tools {
    width: 100%;
    justify-content: stretch;
  }

  .catalog-tools select,
  .view-toggle {
    flex: 1 1 100%;
  }

  .view-toggle {
    display: grid;
    grid-template-columns: 1fr 1fr;
  }

  .product-list-head {
    display: none;
  }

  .product-row {
    grid-template-columns: 1fr;
    align-items: start;
    padding: 12px;
  }

  .product-row-detail {
    grid-template-columns: 96px minmax(0, 1fr);
  }

  .product-row img {
    width: 96px;
    height: 96px;
  }

  .product-row-price,
  .product-row-stock,
  .product-row-actions {
    justify-items: stretch;
  }

  .product-row-actions {
    grid-template-columns: 88px minmax(0, 1fr);
  }

  .product-row-actions .product-detail-link {
    grid-column: 1 / -1;
  }

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

  .product-card {
    grid-template-columns: 128px 1fr;
    grid-template-rows: auto;
  }

  .product-card img {
    height: 100%;
    min-height: 166px;
  }

  .catalog-head {
    align-items: start;
    gap: 10px;
    flex-direction: column;
  }

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

  .account-sidebar {
    display: flex;
    overflow-x: auto;
  }

  .account-sidebar section {
    min-width: 150px;
  }

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

  .recommend-list {
    grid-template-columns: 1fr;
  }

  .inline-form,
  .service-card,
  .mall-footer {
    grid-template-columns: 1fr;
  }

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

  .order-table {
    overflow: visible;
  }

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

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

  .order-meta-row {
    display: grid;
    gap: 6px;
  }

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

  .account-pager {
    justify-content: center;
  }

  .product-detail-panel {
    padding: 12px;
  }

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

  .detail-gallery-thumbs {
    grid-auto-flow: column;
    grid-auto-columns: 58px;
    grid-template-columns: none;
    max-height: none;
    overflow-x: auto;
    overflow-y: hidden;
    order: 2;
    padding: 2px 0 4px;
  }

  .detail-gallery-thumb {
    width: 56px;
    height: 56px;
  }

  .product-description-head {
    padding-top: 16px;
  }

  .product-image-lightbox {
    padding: 20px;
  }

  .detail-image-wrap {
    max-width: none;
  }

  .detail-image-wrap img {
    height: min(72vw, 300px);
    padding: 10px;
  }

  .detail-info h1 {
    font-size: 21px;
  }

  .detail-specs,
  .detail-buy-row,
  .checkout-fields,
  .settings-form,
  .checkout-line {
    grid-template-columns: 1fr;
  }

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

  .checkout-actions {
    display: grid;
  }

  .drawer:not(.is-open) {
    display: none;
  }

  .float-toolbar {
    left: 10px;
    right: auto;
    bottom: 10px;
    top: auto;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    width: calc(100% - 20px);
    max-width: 370px;
  }

  .float-toolbar button {
    width: auto;
    min-height: 44px;
    font-size: 12px;
    white-space: normal;
  }
}


.settings-card-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}

.text-link {
  color: var(--muted);
  text-decoration: none;
}

.text-link:hover {
  color: var(--green);
}

.mall-footer {
  max-width: 1360px;
  margin: 0 auto 32px;
  padding: 18px 24px;
  display: grid;
  grid-template-columns: minmax(220px, 0.8fr) minmax(0, 1.2fr);
  gap: 18px;
  border-top: 1px solid var(--line);
  color: var(--muted);
}

.mall-footer div {
  display: grid;
  gap: 6px;
}

.footer-icp {
  grid-column: 1 / -1;
  justify-items: center;
  text-align: center;
}

.mall-footer strong {
  color: var(--ink);
}

.seo-landing-page {
  background: #eef4f1;
}

.seo-main {
  max-width: 1360px;
  margin: 0 auto;
  padding: 22px 24px 42px;
}

.inquiry-preview-card { width: min(1040px, calc(100vw - 32px)); max-height: min(86vh, 860px); overflow: auto; }
.inquiry-preview-modal > .modal-backdrop { position: absolute; inset: 0; }
.inquiry-preview-card { position: relative; z-index: 1; }
.inquiry-preview-card .modal-head > div { display: grid; gap: 4px; }
.inquiry-preview-card .modal-head small { color: var(--muted); font-weight: 500; }
.inquiry-preview-summary { display: flex; gap: 10px; flex-wrap: wrap; margin: 12px 0; }
.inquiry-preview-summary span { border: 1px solid var(--line); border-radius: 999px; padding: 6px 10px; color: var(--muted); }
.inquiry-preview-summary strong { color: var(--ink); }
.inquiry-preview-lines { display: grid; gap: 10px; }
.inquiry-preview-line { border: 1px solid var(--line); border-radius: 10px; padding: 12px; background: #fff; }
.inquiry-preview-line > header { display: flex; align-items: center; gap: 10px; margin-bottom: 10px; }
.inquiry-preview-line > header strong { min-width: 0; flex: 1; }
.inquiry-line-no { display: grid; place-items: center; width: 28px; height: 28px; border-radius: 50%; background: #eef4f1; color: var(--green); font-weight: 800; }
.inquiry-match-status { border-radius: 999px; padding: 4px 9px; font-size: 12px; font-weight: 800; }
.inquiry-match-status.exact { background: #dcfce7; color: #166534; }
.inquiry-match-status.pending { background: #dbeafe; color: #1d4ed8; }
.inquiry-match-status.unmatched { background: #fef3c7; color: #92400e; }
.inquiry-candidate-row { display: grid; grid-template-columns: minmax(320px, 2fr) minmax(100px, .5fr) minmax(220px, 1fr); gap: 10px; }
.inquiry-preview-message { min-height: 22px; color: var(--muted); }
.inquiry-preview-card .modal-actions { display: flex; justify-content: flex-end; gap: 8px; }
.inquiry-preview-card .modal-actions .primary { background: var(--green); border-color: var(--green); color: #fff; }
.inquiry-account-lines { display: grid; gap: 6px; margin: 5px 0; }
.inquiry-account-lines > div { display: grid; grid-template-columns: minmax(220px,1fr) auto; gap: 4px 12px; border-left: 3px solid #d8e5df; padding-left: 9px; }
.inquiry-account-lines small { color: var(--muted); }
.inquiry-account-lines strong { grid-column: 1 / -1; color: var(--green); font-size: 12px; }

@media (max-width: 760px) {
  .inquiry-preview-card { width: calc(100vw - 16px); max-height: 92vh; padding: 14px; }
  .inquiry-candidate-row { grid-template-columns: 1fr; }
  .inquiry-preview-line > header { align-items: flex-start; flex-wrap: wrap; }
}

.seo-breadcrumb {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
  margin-bottom: 12px;
  color: var(--muted);
  font-size: 13px;
}

.seo-breadcrumb a,
.seo-related-links a,
.seo-link-cloud a,
.seo-chip-row a,
.seo-info-grid a {
  color: inherit;
  text-decoration: none;
}

.seo-breadcrumb a {
  color: var(--green);
  font-weight: 700;
}

.seo-hero-panel {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(280px, 360px);
  gap: 18px;
  align-items: stretch;
  margin-bottom: 18px;
  padding: 24px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  box-shadow: 0 10px 26px rgba(22, 33, 31, 0.08);
}

.seo-hero-panel > div:first-child {
  display: grid;
  align-content: center;
  gap: 12px;
  min-width: 0;
}

.seo-hero-panel p,
.seo-section p,
.seo-product-card span,
.seo-product-card small,
.seo-muted,
.seo-info-grid span,
.seo-point-list,
.seo-cta-box span {
  color: var(--muted);
}

.seo-hero-panel p {
  margin: 0;
  color: var(--green);
  font-weight: 800;
}

.seo-hero-panel h1 {
  margin: 0;
  max-width: 880px;
  font-size: 34px;
  line-height: 1.18;
  overflow-wrap: anywhere;
}

.seo-hero-panel span,
.seo-section p,
.seo-faq p {
  line-height: 1.7;
}

.seo-chip-row,
.seo-related-links,
.seo-link-cloud {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.seo-chip-row a,
.seo-chip-row span,
.seo-link-cloud a,
.seo-related-links a,
.button {
  min-height: 36px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 8px 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  color: var(--ink);
  font-weight: 700;
  text-decoration: none;
}

.seo-chip-row a:first-child,
.button.primary {
  border-color: var(--green);
  background: var(--green);
  color: #fff;
}

.button.secondary {
  color: var(--green);
}

.seo-link-cloud a span {
  color: var(--muted);
  font-size: 12px;
}

.seo-cta-box {
  display: grid;
  align-content: center;
  gap: 12px;
  padding: 18px;
  border: 1px solid #ead0d2;
  border-radius: 8px;
  background: #fff7f8;
}

.seo-cta-box strong {
  font-size: 20px;
}

.seo-cta-box > div {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.seo-section {
  margin-top: 14px;
  padding: 20px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
}

.seo-section h2 {
  margin: 0 0 12px;
  font-size: 22px;
}

.seo-article {
  display: grid;
  gap: 0;
}

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

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

.seo-info-grid a {
  display: grid;
  gap: 6px;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #f8fbfa;
}

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

.seo-product-card {
  display: grid;
  grid-template-columns: 76px minmax(0, 1fr);
  grid-template-rows: auto auto auto auto;
  gap: 5px 12px;
  min-width: 0;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  color: var(--ink);
  text-decoration: none;
}

.seo-product-card:hover,
.seo-info-grid a:hover,
.seo-link-cloud a:hover,
.seo-related-links a:hover {
  border-color: var(--green);
  box-shadow: 0 8px 22px rgba(22, 33, 31, 0.08);
}

.seo-product-image {
  grid-row: 1 / 5;
  width: 76px;
  height: 76px;
  display: grid;
  place-items: center;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
}

.seo-product-image img {
  max-width: 68px;
  max-height: 68px;
  object-fit: contain;
}

.seo-product-card strong {
  overflow-wrap: anywhere;
  line-height: 1.35;
}

.seo-lead-form {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}

.seo-lead-form label {
  display: grid;
  gap: 6px;
  min-width: 0;
  color: var(--muted);
  font-weight: 700;
}

.seo-lead-form label:nth-of-type(3),
.seo-lead-form small {
  grid-column: 1 / -1;
}

.seo-lead-form input,
.seo-lead-form textarea {
  width: 100%;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 10px 12px;
  font: inherit;
  color: var(--ink);
  background: #fff;
}

.seo-lead-form button {
  min-height: 40px;
  border: 1px solid var(--green);
  border-radius: 8px;
  background: var(--green);
  color: #fff;
  font-weight: 800;
}

.seo-lead-form small {
  min-height: 20px;
  color: var(--green);
  font-weight: 700;
}

.seo-product-card b {
  color: var(--red);
}

.seo-faq {
  display: grid;
  gap: 10px;
}

.seo-faq details {
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #f8fbfa;
}

.seo-faq summary {
  cursor: pointer;
  font-weight: 800;
}

.seo-faq p {
  margin: 8px 0 0;
}

.seo-script-list,
.seo-point-list {
  margin: 0;
  padding-left: 20px;
  line-height: 1.8;
}

.seo-footer {
  max-width: 1360px;
}

@media (max-width: 980px) {
  .seo-hero-panel,
  .seo-info-grid,
  .seo-product-grid,
  .seo-guide-grid,
  .seo-lead-form {
    grid-template-columns: 1fr;
  }

  .home-link-hub {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .home-guide-grid {
    grid-template-columns: 1fr;
  }

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

  .seo-main {
    padding: 16px 14px 34px;
  }

  .seo-hero-panel h1 {
    font-size: 28px;
  }
}

@media (max-width: 640px) {
  .seo-hero-panel,
  .seo-section {
    padding: 16px;
  }

  .home-link-hub {
    grid-template-columns: 1fr;
  }

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

  .ssr-product-summary img {
    width: 100%;
    max-width: 260px;
    height: 220px;
  }

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

  .seo-product-card {
    grid-template-columns: 64px minmax(0, 1fr);
  }

  .seo-product-image {
    width: 64px;
    height: 64px;
  }

  .seo-product-image img {
    max-width: 56px;
    max-height: 56px;
  }
}

/* 2026-07 mobile first-screen and fixed-toolbar safety overrides. */
.mobile-menu-toggle,
.mobile-menu-secondary {
  display: none;
}

.account-page .float-toolbar {
  display: none;
}

@media (max-width: 760px) {
  .utility-bar {
    display: none;
  }

  .topbar-inner {
    min-height: 0;
    padding: 8px 14px;
    grid-template-columns: minmax(0, 1fr) 48px;
    gap: 8px;
  }

  .brand {
    grid-column: 1;
    grid-row: 1;
    min-height: 48px;
  }

  .brand-logo {
    width: 52px;
    height: 38px;
  }

  .brand-copy small {
    white-space: nowrap;
  }

  .mobile-menu-toggle {
    display: grid;
    grid-column: 2;
    grid-row: 1;
    width: 48px;
    height: 48px;
    padding: 7px 9px 5px;
    border: 1px solid var(--line);
    border-radius: 8px;
    color: var(--ink);
    background: #fff;
    align-content: center;
    justify-items: stretch;
    gap: 3px;
  }

  .mobile-menu-toggle span {
    display: block;
    height: 2px;
    border-radius: 2px;
    background: currentColor;
  }

  .mobile-menu-toggle b {
    font-size: 10px;
    line-height: 1;
  }

  .topbar.is-mobile-menu-open .mobile-menu-toggle {
    border-color: var(--green);
    color: #fff;
    background: var(--green);
  }

  .search {
    grid-column: 1 / -1;
    grid-row: 2;
  }

  .search input,
  .search button,
  .search-assistant {
    min-height: 48px;
  }

  .account-nav {
    grid-column: 1 / -1;
    grid-row: 3;
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .account-menu,
  .account-nav > .nav-button {
    display: none;
  }

  .account-nav > button,
  .account-nav > a {
    min-height: 48px;
  }

  .mall-nav {
    display: none;
    max-width: 100%;
    max-height: calc(100vh - 180px);
    padding: 8px 14px 12px;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 8px;
    overflow-x: hidden;
    overflow-y: auto;
    overscroll-behavior: contain;
  }

  .topbar.is-mobile-menu-open .mall-nav {
    display: grid;
  }

  .mall-nav > a,
  .mall-nav > button {
    width: 100%;
    min-height: 48px;
    padding: 10px 8px;
  }

  .mobile-menu-secondary {
    grid-column: 1 / -1;
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 8px;
    padding-top: 4px;
    border-top: 1px solid var(--line);
  }

  .mobile-menu-secondary a,
  .mobile-menu-secondary button {
    min-height: 48px;
    border: 1px solid var(--line);
    border-radius: 8px;
    padding: 10px 8px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    color: var(--muted);
    background: #fff;
    text-align: center;
    text-decoration: none;
  }

  .mobile-menu-secondary .mobile-hotline {
    grid-column: 1 / -1;
  }

  .hero-actions button,
  .quick-panel button,
  .seo-cta-box .button,
  .seo-hero-actions a,
  .seo-hero-actions button,
  .seo-lead-form button {
    min-height: 48px;
  }

  .seo-main {
    padding-top: 10px;
  }

  .seo-hero-panel,
  .seo-section {
    padding: 14px;
  }

  .seo-hero-panel h1 {
    margin-top: 0;
    font-size: 26px;
    line-height: 1.18;
  }

  body.has-float-toolbar {
    padding-bottom: calc(70px + env(safe-area-inset-bottom));
  }

  .float-toolbar {
    bottom: calc(10px + env(safe-area-inset-bottom));
  }

  .float-toolbar button {
    min-height: 48px;
  }

  .toast {
    bottom: calc(72px + env(safe-area-inset-bottom));
  }
}
