:root {
  --black: #101114;
  --yellow: #f5b400;
  --yellow-dark: #d99a00;
  --blue: #136ff2;
  --green: #10a049;
  --text: #232933;
  --muted: #6b7280;
  --line: #dfe3ea;
  --soft: #f5f7fa;
  --panel: #ffffff;
  --shadow: 0 8px 24px rgba(20, 35, 60, 0.08);
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  color: var(--text);
  background:
    linear-gradient(180deg, #eef2f7 0, #f6f8fb 280px, #f3f5f8 100%),
    #f3f5f8;
  font-family:
    Arial,
    "Microsoft YaHei",
    sans-serif;
  font-size: 18px;
}

button,
input,
select {
  font: inherit;
}

button {
  cursor: pointer;
}

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

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
}

.site-top {
  background: var(--black);
  color: #fff;
  font-size: 12px;
}

.top-inner,
.brand-row,
.menu-row,
.page-shell {
  width: min(1760px, calc(100% - 32px));
  margin: 0 auto;
}

.top-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 30px;
  gap: 16px;
}

.quick-links {
  display: flex;
  align-items: center;
  gap: 16px;
  color: #f4f6f8;
}

.quick-links a:hover {
  color: var(--yellow);
}

.quick-links button {
  border: 0;
  color: #fff;
  background: transparent;
}

.quick-links .currency {
  min-width: 34px;
  height: 20px;
  border-radius: 10px;
  color: #111;
  background: var(--yellow);
  font-weight: 700;
}

.quick-links .lang.is-active {
  color: var(--yellow);
}

.brand-row {
  display: grid;
  grid-template-columns: 260px minmax(280px, 1fr) auto;
  align-items: center;
  gap: 24px;
  min-height: 76px;
  border-left: 1px solid var(--line);
  border-right: 1px solid var(--line);
  background: var(--panel);
}

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

.brand-mark {
  display: grid;
  place-items: center;
  width: 48px;
  height: 42px;
  clip-path: polygon(50% 0, 100% 100%, 0 100%);
  color: #1d2430;
  background: linear-gradient(120deg, var(--yellow) 0 48%, #343b45 48% 100%);
  font-size: 13px;
  font-weight: 800;
}

.brand strong {
  display: block;
  color: #222;
  font-size: 30px;
  line-height: 1;
  letter-spacing: 0;
}

.brand small {
  display: block;
  margin-top: 5px;
  color: #555b66;
  font-size: 11px;
  font-weight: 700;
}

.global-search {
  display: grid;
  grid-template-columns: 1fr 54px;
  justify-self: end;
  width: min(520px, 100%);
  height: 38px;
  border: 1px solid var(--line);
  background: #fff;
}

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

.global-search button {
  border: 0;
  color: #fff;
  background: var(--yellow);
  font-size: 28px;
  line-height: 1;
}

.account-actions {
  display: flex;
  align-items: center;
  gap: 12px;
  white-space: nowrap;
}

.account-actions button,
.account-actions a {
  border: 0;
  background: transparent;
  color: #222;
}

.cart-button {
  position: relative;
  padding-right: 16px;
}

.cart-button b {
  position: absolute;
  top: -12px;
  right: 0;
  display: grid;
  place-items: center;
  min-width: 18px;
  height: 18px;
  border-radius: 50%;
  background: var(--yellow);
  font-size: 11px;
}

.menu-row {
  display: flex;
  align-items: stretch;
  min-height: 44px;
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
  background: #fff;
  box-shadow: 0 6px 16px rgba(18, 27, 45, 0.05);
}

.menu-row a,
.category-button {
  display: flex;
  align-items: center;
  justify-content: center;
  min-width: 112px;
  padding: 0 18px;
  border: 0;
  border-bottom: 3px solid transparent;
  background: #fff;
}

.category-button {
  justify-content: space-between;
  width: 220px;
  color: #111;
  background: var(--yellow);
  font-weight: 700;
}

.category-button::after {
  content: "⌄";
  font-size: 16px;
}

.menu-row a.active,
.menu-row a:hover {
  color: var(--blue);
  border-bottom-color: var(--blue);
}

.page-shell,
.home-page,
.detail-page {
  width: min(1760px, calc(100% - 32px));
  margin: 0 auto;
}

.page-shell {
  display: grid;
  grid-template-columns: 280px minmax(0, 1fr);
  gap: 20px;
  padding: 18px 0 42px;
}

.model-search-page {
  grid-template-columns: 240px minmax(0, 1fr);
  align-items: start;
}

.model-search-page > .content {
  display: contents;
}

.model-search-page > .content > .breadcrumb {
  grid-column: 1 / -1;
}

.model-search-page > .content > .model-query-panel {
  grid-column: 1;
  grid-row: 2;
  position: sticky;
  top: 16px;
  width: 100%;
  box-sizing: border-box;
  padding: 16px;
}

.model-search-page .model-query-head {
  display: block;
  padding-bottom: 14px;
}

.model-search-page .model-query-head h1 {
  margin-bottom: 14px;
}

.model-category-menu {
  display: grid;
  gap: 6px;
  margin-bottom: 14px;
  padding-bottom: 14px;
  border-bottom: 1px dotted #bcc5d2;
}

.model-category-menu a {
  display: block;
  padding: 8px 10px;
  border: 1px solid var(--line);
  color: #344054;
  background: #fff;
  font-size: 13px;
}

.model-category-menu a:hover,
.model-category-menu a.is-active {
  border-color: var(--blue);
  color: #fff;
  background: var(--blue);
}

.model-search-page .model-keyword-search {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 8px;
  width: 100%;
}

.model-search-page .model-keyword-search input,
.model-search-page .model-keyword-search button,
.model-search-page .model-query-fields select {
  width: 100%;
  box-sizing: border-box;
}

.model-search-page .model-query-fields {
  grid-template-columns: minmax(0, 1fr);
  gap: 10px;
  margin-top: 16px;
}

.model-search-page .model-query-fields select:first-child {
  border-color: #9bb8ed;
  background: #f8fbff;
  font-weight: 700;
}

.model-search-page .model-search-results {
  grid-column: 2;
  grid-row: 2;
  min-width: 0;
  margin-top: 0;
}

.model-search-page #modelProductCards {
  margin-top: 18px;
}

.model-search-page .model-search-results:not(.has-product-result) .hero-grid,
.model-search-page .model-search-results:not(.has-product-result) #modelProductResult .table-wrap,
.model-search-page .model-search-results:not(.has-product-result) #modelProductResult .pagination,
.model-search-page .model-search-results:not(.has-product-result) #modelProductResult {
  display: none;
}

.model-search-page .model-fit-panel .table-wrap {
  border: 0;
  border-radius: 0;
}

.model-search-page .model-search-results.has-product-result #modelProductCards {
  display: none;
}

.model-search-page .model-search-results.show-all-products #modelProductResult {
  display: block;
}

.model-search-page .model-search-results.show-all-products #modelProductCards {
  display: grid;
}

.model-search-page .model-search-results.show-all-products #backToModelMatches {
  display: none;
}

.model-search-page #modelProductCards .product-image-card {
  grid-template-rows: 1fr auto auto;
  gap: 8px;
  padding: 16px;
  aspect-ratio: 1 / 1.12;
  min-height: 250px;
}

.model-search-page #modelProductCards .product-image-card strong,
.model-search-page #modelProductCards .product-image-card small {
  width: 100%;
  overflow: hidden;
  text-align: center;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.model-search-page #modelProductCards .product-image-card small {
  color: var(--muted);
}

.model-match-panel {
  margin-top: 18px;
}

.model-match-panel .section-title,
.model-product-heading-actions {
  display: flex;
  align-items: center;
  gap: 10px;
}

.model-product-heading-actions {
  justify-content: flex-end;
}

#modelMatchList {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
}

.model-match-image-card {
  aspect-ratio: 4 / 3;
  min-height: 180px;
}

.model-match-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  padding: 16px;
  border: 1px solid var(--line);
  border-radius: 4px;
  background: #fff;
  box-shadow: var(--shadow);
}

.model-match-main {
  min-width: 0;
}

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

.model-match-previews {
  display: flex;
  flex: 0 0 auto;
  gap: 6px;
}

.model-match-preview {
  width: 38px;
  height: 52px;
}

.model-match-label {
  display: block;
  margin-bottom: 5px;
  color: var(--muted);
  font-size: 12px;
}

.model-match-main strong {
  display: block;
  color: #111827;
  font-size: 18px;
  letter-spacing: 0;
}

.model-match-main p {
  margin: 6px 0 0;
  color: var(--muted);
}

.model-match-meta {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 10px;
  color: var(--muted);
  font-size: 12px;
  text-align: right;
}

.products-layout {
  grid-template-columns: 240px minmax(0, 1fr);
  align-items: start;
}

.sidebar {
  display: grid;
  align-content: start;
  gap: 16px;
}

.content {
  min-width: 0;
}

.panel {
  border: 1px solid var(--line);
  border-radius: 4px;
  background: var(--panel);
  box-shadow: var(--shadow);
}

.panel:hover,
.product-card:hover,
.feature-tile:hover,
.machine-card:hover {
  box-shadow: 0 12px 30px rgba(20, 35, 60, 0.12);
}

.filter-card,
.contact-card {
  padding: 14px;
}

.panel h1,
.panel h2,
.section-title h1,
.section-title h2 {
  margin: 0;
  color: #111827;
  font-size: 15px;
}

.filter-card h2,
.contact-card h2 {
  margin-bottom: 14px;
  padding-bottom: 10px;
  border-bottom: 1px solid var(--line);
  font-size: 13px;
}

.filter-card label {
  display: grid;
  gap: 6px;
  margin-bottom: 10px;
  color: #374151;
  font-size: 12px;
}

.filter-group-title {
  margin: 12px 0 8px;
  padding: 8px 10px;
  border-left: 4px solid var(--yellow);
  background: #f8fafc;
  color: #111827;
  font-weight: 800;
}

.type-pills {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
  margin-bottom: 12px;
}

.related-card {
  padding: 14px;
}

.related-card h2 {
  margin: 0 0 12px;
  padding-bottom: 10px;
  border-bottom: 1px solid var(--line);
  font-size: 13px;
}

.related-mini-list {
  display: grid;
  gap: 10px;
}

.related-mini-list a {
  display: grid;
  grid-template-columns: 36px minmax(0, 1fr);
  gap: 9px;
  align-items: center;
  padding: 9px;
  border: 1px solid var(--line);
  border-radius: 4px;
  background: #fbfcfe;
}

.related-mini-list .filter-thumb {
  width: 30px;
  height: 38px;
}

.related-mini-list strong,
.related-mini-list small {
  display: block;
}

.related-mini-list small {
  margin-top: 3px;
  color: var(--muted);
}

.category-pill {
  min-height: 32px;
  border: 1px solid var(--line);
  border-radius: 4px;
  background: #fff;
  color: #344054;
}

.category-pill.is-active {
  border-color: var(--blue);
  color: #fff;
  background: var(--blue);
}

.filter-card select,
.filter-card input {
  width: 100%;
  min-height: 34px;
  border: 1px solid #cfd5df;
  border-radius: 3px;
  padding: 0 9px;
  color: #2b313b;
  background: #fff;
}

.primary,
.chat-button {
  width: 100%;
  min-height: 36px;
  border: 0;
  border-radius: 4px;
  color: #fff;
  background: var(--blue);
  font-weight: 700;
}

.contact-card {
  background: linear-gradient(#fff, #f9fafc);
}

.contact-card a {
  display: block;
  position: relative;
  margin: 12px 0;
  padding-left: 28px;
  color: #1f2937;
  font-size: 13px;
  line-height: 1.55;
}

.dot {
  position: absolute;
  left: 0;
  top: 2px;
  width: 18px;
  height: 18px;
  border-radius: 50%;
}

.green {
  background: #1fc461;
}

.light {
  background: #51d36d;
}

.blue {
  background: #4e91ff;
}

.breadcrumb {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-bottom: 12px;
  color: #6b7280;
  font-size: 12px;
}

.breadcrumb a {
  color: #2563eb;
  font-weight: 700;
}

.breadcrumb a:hover {
  color: var(--yellow-dark);
}

.model-query-panel {
  padding: 20px;
}

.model-query-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  padding-bottom: 14px;
  border-bottom: 1px dotted #bcc5d2;
}

.model-query-head h1 {
  flex: 0 0 auto;
  font-size: 22px;
}

.model-keyword-search {
  display: grid;
  grid-template-columns: minmax(240px, 360px) 120px;
  justify-content: end;
  width: min(100%, 500px);
}

.model-keyword-search input,
.model-query-fields select {
  min-width: 0;
  min-height: 40px;
  border: 1px solid #c9d0db;
  border-radius: 0;
  padding: 0 12px;
  color: #1f2937;
  background: #fff;
}

.model-keyword-search button {
  min-height: 40px;
  border: 0;
  color: #fff;
  background: var(--blue);
  font-weight: 800;
}

.model-query-fields {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
  margin-top: 20px;
}

.model-search-status {
  margin: 16px 0 0;
  color: var(--muted);
}

.model-search-results {
  margin-top: 20px;
}

.model-detail-layout {
  display: grid;
  grid-template-columns: minmax(300px, 0.9fr) minmax(420px, 1.1fr);
  gap: 20px;
  align-items: start;
}

.model-machine-card {
  overflow: hidden;
  padding: 0;
}

.model-machine-card .machine-photo {
  display: grid;
  place-items: center;
  min-height: 390px;
  border: 0;
}

.model-empty-image {
  padding: 12px 18px;
  border: 1px dashed #b8c2d1;
  color: var(--muted);
  background: rgba(255, 255, 255, 0.86);
}

.model-machine-card .thumb-row {
  margin: 12px;
}

.model-detail-column {
  display: grid;
  gap: 16px;
  min-width: 0;
}

.model-equipment-card {
  overflow: hidden;
  padding: 0;
}

.equipment-card-heading {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  min-height: 46px;
  padding: 0 16px;
  border-bottom: 1px solid var(--line);
  background: #f7f8fa;
}

.equipment-card-heading h2 {
  margin: 0;
  color: #1f2937;
  font-size: 18px;
}

.equipment-card-heading span {
  color: var(--muted);
  font-size: 12px;
}

.model-equipment-card dl {
  margin: 0;
}

.model-equipment-card dl > div {
  display: grid;
  grid-template-columns: 132px minmax(0, 1fr);
  min-height: 38px;
  border-bottom: 1px solid var(--line);
}

.model-equipment-card dl > div:last-child {
  border-bottom: 0;
}

.model-equipment-card dt,
.model-equipment-card dd {
  display: flex;
  align-items: center;
  margin: 0;
  padding: 8px 12px;
}

.model-equipment-card dt {
  color: #1f2937;
  background: #f4f5f7;
  font-weight: 700;
}

.model-equipment-card dd {
  color: #374151;
}

.model-fit-panel {
  min-width: 0;
  padding: 0 12px 12px;
}

.model-fit-panel .section-title {
  margin: 0 -12px 8px;
  padding: 12px;
  border-bottom: 1px solid var(--line);
}

.model-fit-table {
  min-width: 0;
}

.model-fit-table th,
.model-fit-table td {
  padding: 10px 12px;
}

.model-fit-table th:first-child,
.model-fit-table td:first-child {
  width: 58%;
}

.model-fit-table td a {
  color: #087edb;
}

.model-search-results[hidden],
#modelSearchOverview[hidden] {
  display: none;
}

.hero-grid {
  display: grid;
  grid-template-columns: minmax(360px, 0.92fr) minmax(400px, 1.08fr);
  gap: 20px;
}

.machine-gallery {
  min-width: 0;
}

.machine-photo {
  min-height: 292px;
  border: 1px solid var(--line);
  background-image: url("./assets/excavator.png");
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
  background-color: #dbeafe;
}

.thumb-row {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 10px;
  margin-top: 10px;
}

.thumb-row span {
  height: 52px;
  border: 2px solid #fff;
  outline: 1px solid var(--line);
  background-image: url("./assets/excavator.png");
  background-size: cover;
  background-position: center;
}

.thumb-row span:nth-child(2) {
  outline-color: var(--blue);
}

.thumb-row span:nth-child(3) {
  background-position: 35% center;
}

.thumb-row span:nth-child(4) {
  background-position: 55% center;
}

.thumb-row span:nth-child(5) {
  background-position: 70% center;
}

.equipment-card {
  overflow: hidden;
}

.equipment-card h1 {
  display: grid;
  place-items: center;
  min-height: 34px;
  padding: 8px 16px;
  color: #fff;
  border-bottom: 1px solid #3d68f3;
  background: #4d6df4;
}

.equipment-card dl {
  margin: 0;
}

.equipment-card div {
  display: grid;
  grid-template-columns: minmax(160px, 1fr) minmax(220px, 1fr);
  min-height: 28px;
  border-bottom: 0;
}

.equipment-card div:nth-child(even) {
  background: #f7f7f7;
}

.equipment-card div:last-child {
  border-bottom: 0;
}

.equipment-card dt,
.equipment-card dd {
  display: flex;
  align-items: center;
  margin: 0;
  padding: 6px 16px;
}

.equipment-card dt {
  border-right: 1px solid rgba(255, 255, 255, 0.6);
  color: #111827;
  font-weight: 700;
}

.equipment-card dd {
  color: #273140;
}

.results-section {
  margin-top: 18px;
}

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

.section-title span {
  color: var(--muted);
  font-size: 12px;
}

.table-wrap {
  overflow-x: auto;
  border: 1px solid var(--line);
  border-radius: 4px;
  background: #fff;
}

table {
  width: 100%;
  min-width: 900px;
  border-collapse: collapse;
}

thead th {
  height: 40px;
  padding: 0 12px;
  border-right: 1px solid #454a53;
  color: #fff;
  background: linear-gradient(#3e4249, #25282e);
  font-size: 12px;
  font-weight: 700;
  text-align: left;
}

tbody td {
  min-height: 68px;
  padding: 10px 12px;
  border-right: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
  background: #fff;
  vertical-align: middle;
}

tbody tr:hover td {
  background: #fffdf3;
}

.product-cell {
  display: grid;
  grid-template-columns: 44px minmax(130px, 1fr);
  align-items: center;
  gap: 10px;
  font-weight: 700;
}

.product-cell small {
  display: block;
  margin-top: 2px;
  color: #606b78;
  font-weight: 400;
}

.filter-thumb {
  display: grid;
  place-items: center;
  width: 36px;
  height: 48px;
  border: 1px solid #ccd3df;
  border-radius: 4px;
  background: linear-gradient(90deg, #f6c957 0 38%, #fff 38% 70%, #d7dce4 70%);
  color: #262a31;
  font-size: 9px;
  font-weight: 800;
  box-shadow: inset -8px 0 0 rgba(33, 43, 54, 0.1);
}

.filter-thumb.white {
  background: linear-gradient(90deg, #e9eef5 0 18%, #fff 18% 75%, #d7dce4 75%);
}

.stock {
  color: var(--green);
  font-weight: 800;
}

.row-actions {
  display: flex;
  gap: 8px;
  white-space: nowrap;
}

.add-cart,
.view-detail {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 32px;
  border-radius: 3px;
  padding: 0 12px;
  font-size: 12px;
}

.add-cart {
  border: 1px solid var(--yellow-dark);
  background: var(--yellow);
  color: #161616;
  font-weight: 800;
}

.view-detail {
  border: 1px solid var(--line);
  background: #fff;
}

.pagination {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 10px;
  padding: 14px 0;
  color: #4b5563;
}

.pagination button,
.pagination select,
.pagination input {
  height: 32px;
  border: 1px solid var(--line);
  border-radius: 3px;
  background: #fff;
}

.pagination button {
  min-width: 32px;
}

.pagination .page-active {
  color: #fff;
  background: var(--blue);
  border-color: var(--blue);
}

.pagination input {
  width: 52px;
  text-align: center;
}

.float-actions {
  position: fixed;
  right: 0;
  bottom: 42px;
  z-index: 10;
  display: grid;
  gap: 4px;
  width: 72px;
}

.float-actions button {
  min-height: 46px;
  border: 0;
  border-radius: 4px 0 0 4px;
  color: #fff;
  background: var(--blue);
  font-size: 12px;
  box-shadow: 0 6px 18px rgba(19, 111, 242, 0.25);
}

.float-actions button:last-child {
  min-height: 36px;
  background: #fff;
  color: #111827;
  border: 1px solid var(--line);
}

.contact-modal[hidden] {
  display: none;
}

.contact-modal {
  position: fixed;
  inset: 0;
  z-index: 40;
}

.contact-modal-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(15, 23, 42, 0.34);
}

.contact-dialog {
  position: absolute;
  top: 50%;
  left: 50%;
  width: min(520px, calc(100vw - 32px));
  max-height: calc(100vh - 48px);
  overflow: auto;
  transform: translate(-50%, -50%);
  border: 1px solid var(--line);
  border-radius: 6px;
  background: #fff;
  box-shadow: 0 24px 70px rgba(15, 23, 42, 0.26);
}

.contact-close {
  position: absolute;
  top: 10px;
  right: 10px;
  display: grid;
  place-items: center;
  width: 30px;
  height: 30px;
  border: 1px solid var(--line);
  border-radius: 50%;
  background: #fff;
  color: #111827;
  font-size: 20px;
}

.contact-dialog-body {
  padding: 22px;
}

.service-head {
  display: grid;
  grid-template-columns: 40px minmax(0, 1fr);
  gap: 12px;
  padding-right: 30px;
}

.service-head h2 {
  margin: 0 0 6px;
  font-size: 18px;
}

.service-head p {
  margin: 0;
  color: var(--muted);
  line-height: 1.6;
}

.service-dot,
.wechat-icon {
  display: grid;
  place-items: center;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  color: #fff;
  background: var(--blue);
  font-weight: 800;
}

.service-dot::after {
  content: "";
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background: #24d164;
  box-shadow: 0 0 0 6px rgba(36, 209, 100, 0.18);
}

.wechat-icon {
  background: #18b85d;
}

.order-icon {
  display: grid;
  place-items: center;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  color: #111827;
  background: var(--yellow);
  font-weight: 800;
}

.chat-window {
  display: grid;
  gap: 10px;
  margin: 18px 0;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 4px;
  background: #f8fafc;
}

.chat-message {
  max-width: 88%;
  border-radius: 6px;
  padding: 9px 11px;
  line-height: 1.55;
}

.chat-message.support {
  justify-self: start;
  background: #fff;
  border: 1px solid var(--line);
}

.chat-message.user {
  justify-self: end;
  color: #fff;
  background: var(--blue);
}

.chat-input-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 76px;
  gap: 8px;
}

.chat-input-row input {
  min-width: 0;
  min-height: 38px;
  border: 1px solid var(--line);
  border-radius: 4px;
  padding: 0 10px;
}

.wechat-contact-box {
  display: grid;
  grid-template-columns: 116px minmax(0, 1fr);
  gap: 16px;
  align-items: center;
  margin-top: 18px;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 4px;
  background: #fbfcfe;
}

.wechat-contact-box p {
  margin: 6px 0;
}

.qr-placeholder {
  display: grid;
  place-items: center;
  width: 104px;
  height: 104px;
  border: 1px solid #bac3d1;
  background:
    linear-gradient(90deg, #111 10px, transparent 10px) 0 0 / 26px 26px,
    linear-gradient(#111 10px, transparent 10px) 0 0 / 26px 26px,
    #fff;
  color: #111827;
  font-weight: 800;
  text-align: center;
}

.proof-preview {
  display: grid;
  grid-template-columns: 160px minmax(0, 1fr);
  gap: 14px;
  margin-top: 18px;
}

.proof-paper {
  display: grid;
  gap: 7px;
  min-height: 190px;
  padding: 14px;
  border: 1px solid #bac3d1;
  border-radius: 4px;
  background:
    linear-gradient(135deg, rgba(19, 111, 242, 0.08), transparent 45%),
    #fff;
  color: #344054;
  font-size: 12px;
}

.proof-paper b {
  color: #111827;
}

.order-detail-list {
  margin: 18px 0 0;
  border: 1px solid var(--line);
  border-radius: 4px;
  overflow: hidden;
}

.proof-preview .order-detail-list {
  margin: 0;
}

.order-detail-list div {
  display: grid;
  grid-template-columns: 92px minmax(0, 1fr);
  border-bottom: 1px solid var(--line);
}

.order-detail-list div:last-child {
  border-bottom: 0;
}

.order-detail-list dt,
.order-detail-list dd {
  margin: 0;
  padding: 10px 12px;
  line-height: 1.6;
}

.order-detail-list dt {
  background: #fbfcfe;
  font-weight: 800;
}

.confirm-box {
  display: grid;
  gap: 10px;
  margin-top: 18px;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 4px;
  background: #fbfcfe;
}

.confirm-box p {
  margin: 0;
  color: var(--muted);
  line-height: 1.7;
}

.refund-form {
  display: grid;
  gap: 12px;
  margin-top: 18px;
}

.refund-form p {
  margin: 0;
  color: var(--muted);
  line-height: 1.7;
}

.refund-form label {
  display: grid;
  gap: 7px;
  color: #374151;
}

.refund-form input,
.refund-form select,
.refund-form textarea {
  width: 100%;
  border: 1px solid var(--line);
  border-radius: 4px;
  padding: 9px 10px;
}

.refund-form textarea {
  min-height: 96px;
  resize: vertical;
}

.modal-action-row {
  display: flex;
  justify-content: flex-end;
  gap: 10px;
  margin-top: 18px;
}

.home-page,
.detail-page {
  padding: 18px 0 42px;
}

.home-hero {
  position: relative;
  display: grid;
  min-height: 430px;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 4px;
  background:
    linear-gradient(90deg, rgba(17, 24, 39, 0.02) 0%, rgba(17, 24, 39, 0.36) 46%, rgba(17, 24, 39, 0.92) 100%),
    url("./assets/excavator.png") center / cover no-repeat;
}

.home-hero-image {
  display: none;
}

.home-hero-copy {
  display: grid;
  align-content: center;
  gap: 18px;
  justify-self: end;
  width: min(560px, 52%);
  padding: 58px 44px;
  color: #fff;
  text-shadow: 0 2px 12px rgba(0, 0, 0, 0.42);
}

.home-hero-copy h1 {
  margin: 0;
  font-size: 34px;
  line-height: 1.22;
  letter-spacing: 0;
}

.home-hero-copy p {
  margin: 0;
  color: #f1f5f9;
  font-size: 16px;
  line-height: 1.8;
}

.hero-search {
  display: grid;
  grid-template-columns: minmax(130px, 1fr) minmax(130px, 1fr) 120px;
  gap: 10px;
}

.hero-search select,
.hero-search a,
.primary-link {
  min-height: 38px;
  border-radius: 4px;
}

.hero-search select {
  min-width: 0;
  border: 1px solid #cfd5df;
  padding: 0 10px;
}

.primary-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 1px solid var(--yellow-dark);
  padding: 0 16px;
  color: #111;
  background: var(--yellow);
  font-weight: 800;
}

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

.feature-tile,
.product-card,
.news-card,
.admin-card {
  border: 1px solid var(--line);
  border-radius: 4px;
  background: #fff;
  box-shadow: var(--shadow);
}

.feature-tile {
  display: grid;
  gap: 8px;
  min-height: 96px;
  padding: 18px;
  border-top: 4px solid var(--yellow);
}

.feature-tile strong {
  font-size: 16px;
}

.feature-tile span {
  color: var(--muted);
  line-height: 1.6;
}

.home-layout {
  display: grid;
  grid-template-columns: 260px minmax(0, 1fr);
  gap: 20px;
  margin-top: 18px;
}

.category-list {
  display: grid;
  align-content: start;
  padding: 16px;
}

.category-list h2 {
  margin-bottom: 12px;
  padding-bottom: 10px;
  border-bottom: 1px solid var(--line);
}

.category-list a {
  padding: 12px 0;
  border-bottom: 1px solid var(--line);
}

.category-list a:hover,
.section-title a {
  color: var(--blue);
}

.home-main {
  min-width: 0;
}

.product-category-sidebar {
  position: sticky;
  top: 16px;
}

.product-category-menu {
  overflow: hidden;
  padding: 18px 20px;
}

.product-category-list {
  display: grid;
  border-top: 1px solid #20242b;
}

.product-category-list a {
  display: grid;
  place-items: center;
  min-height: 62px;
  border-bottom: 1px solid #20242b;
  color: #111827;
  font-weight: 800;
  text-align: center;
  transition:
    color 0.18s ease,
    background 0.18s ease;
}

.product-category-list a:hover,
.product-category-list a:focus-visible {
  color: var(--blue);
  background: #f4f7fb;
}

.products-layout .product-grid {
  margin-top: 18px;
}

.product-toolbar,
.status-tabs {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px;
  margin: 12px 0 16px;
}

.category-overview {
  display: grid;
  grid-template-columns: 1fr;
  gap: 14px;
  margin-bottom: 16px;
}

.category-block {
  padding: 16px;
}

.category-block-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 14px;
  margin-bottom: 12px;
}

.category-block-head h2 {
  margin: 0;
  font-size: 16px;
}

.category-block-head span {
  color: var(--muted);
}

.category-links,
.machine-links {
  display: grid;
  gap: 10px;
}

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

.machine-links {
  grid-template-columns: repeat(5, minmax(0, 1fr));
}

.category-links a,
.machine-links a {
  display: grid;
  gap: 4px;
  min-height: 66px;
  border: 1px solid var(--line);
  border-radius: 4px;
  padding: 12px;
  background: #fbfcfe;
}

.category-links a {
  border-left: 4px solid var(--yellow);
  font-weight: 800;
}

.category-links small,
.machine-links small {
  color: var(--muted);
  font-weight: 400;
}

.machine-result-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  padding: 18px;
}

.machine-result-head h1 {
  margin-bottom: 8px;
  font-size: 18px;
}

.machine-result-head p {
  margin: 0;
  color: var(--muted);
  line-height: 1.7;
}

.machine-current {
  display: grid;
  min-width: 190px;
  gap: 4px;
  padding: 14px;
  border: 1px solid #d7dde8;
  border-left: 4px solid var(--yellow);
  border-radius: 4px;
  background: #fbfcfe;
}

.machine-current span,
.machine-current small {
  color: var(--muted);
}

.machine-current strong {
  font-size: 20px;
}

.tab {
  min-height: 34px;
  border: 1px solid var(--line);
  border-radius: 4px;
  padding: 0 14px;
  background: #fff;
}

.tab.is-active {
  color: #fff;
  border-color: var(--blue);
  background: var(--blue);
}

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

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

.product-image-card {
  display: grid;
  place-items: center;
  aspect-ratio: 4 / 3;
  min-height: 210px;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 4px;
  background: #f7f9fc;
  box-shadow: var(--shadow);
  transition:
    transform 0.18s ease,
    border-color 0.18s ease,
    box-shadow 0.18s ease;
}

.product-image-card:hover {
  border-color: var(--blue);
  box-shadow: 0 10px 22px rgba(30, 51, 82, 0.14);
  transform: translateY(-2px);
}

.product-image-card:focus-visible {
  outline: 3px solid rgba(31, 111, 235, 0.28);
  outline-offset: 2px;
}

.product-image-preview {
  width: 112px;
  height: 152px;
  border-radius: 6px;
  font-size: 18px;
  transition: transform 0.18s ease;
}

.product-image-card:hover .product-image-preview {
  transform: scale(1.04);
}

.products-layout #productCards .product-image-card {
  grid-template-rows: auto auto auto;
  aspect-ratio: auto;
  min-height: 270px;
  align-content: center;
  gap: 8px;
  padding: 22px 14px 18px;
  text-align: center;
}

.products-layout #productCards .product-image-card strong {
  color: #111827;
  font-size: 17px;
}

.products-layout #productCards .product-card-number {
  color: #4b5563;
  font-size: 14px;
  font-weight: 700;
}

.product-card {
  display: grid;
  gap: 9px;
  padding: 18px;
  transition:
    transform 0.18s ease,
    box-shadow 0.18s ease;
}

.product-card:hover {
  transform: translateY(-2px);
}

.product-card-main {
  display: grid;
  gap: 8px;
}

.product-card .filter-thumb {
  width: 48px;
  height: 62px;
}

.home-main .product-card .filter-thumb {
  width: 88px;
  height: 114px;
}

.home-main .product-card strong {
  font-size: 17px;
}

.product-card strong {
  font-size: 16px;
}

.product-card small,
.product-card span,
.product-card em,
.product-card i {
  color: var(--muted);
  font-style: normal;
}

.mini-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.mini-tags em,
.detail-badges span {
  display: inline-flex;
  align-items: center;
  min-height: 22px;
  border-radius: 11px;
  padding: 0 8px;
  color: #8a5700;
  background: #fff3cf;
  font-size: 12px;
  font-style: normal;
}

.product-card b {
  color: #111827;
  font-size: 18px;
}

.detail-hero,
.product-media-grid,
.checkout-grid,
.two-column,
.admin-grid,
.news-grid {
  display: grid;
  gap: 18px;
}

.detail-hero {
  grid-template-columns: minmax(360px, 0.92fr) minmax(400px, 1.08fr);
  align-items: start;
  padding: 22px;
}

.detail-visual {
  display: grid;
  place-items: center;
  align-content: center;
  gap: 18px;
  min-height: 320px;
  border: 1px solid var(--line);
  background:
    linear-gradient(135deg, rgba(245, 180, 0, 0.18), transparent 42%),
    #f8fafc;
}

.filter-thumb.giant {
  width: 164px;
  height: 230px;
  font-size: 30px;
}

.detail-carousel {
  position: relative;
  display: grid;
  grid-template-columns: 34px minmax(0, 1fr) 34px;
  align-items: center;
  width: 100%;
  min-height: 320px;
  padding: 0 10px 30px;
}

.detail-carousel-stage {
  position: relative;
  display: grid;
  min-height: 260px;
  place-items: center;
}

.detail-carousel-slide {
  display: none;
  grid-area: 1 / 1;
  animation: detail-carousel-fade 240ms ease;
}

.detail-carousel-slide.is-active {
  display: grid;
}

.detail-carousel-slide-detail {
  transform: scale(1.08) rotate(-2deg);
  filter: saturate(0.92) brightness(1.04);
}

.detail-carousel-slide-structure {
  transform: scale(0.94) rotate(2deg);
  filter: contrast(1.08);
}

.detail-carousel-slide-package {
  transform: scale(1.02);
  filter: saturate(0.78) brightness(0.98);
}

.detail-carousel-slide-size {
  transform: scale(0.98) rotate(-1deg);
  filter: contrast(1.04) saturate(0.88);
}

.detail-carousel-control {
  z-index: 2;
  display: grid;
  width: 32px;
  height: 32px;
  place-items: center;
  border: 1px solid #c9d1dc;
  border-radius: 50%;
  color: #374151;
  background: rgba(255, 255, 255, 0.92);
  font-size: 25px;
  line-height: 1;
  cursor: pointer;
}

.detail-carousel-control:hover {
  color: #111827;
  border-color: var(--yellow-dark);
  background: #fff8dc;
}

.detail-carousel-counter {
  position: absolute;
  right: 8px;
  bottom: 0;
  color: #6b7280;
  font-size: 12px;
}

.detail-carousel-dots {
  position: absolute;
  right: 0;
  bottom: 0;
  left: 0;
  display: flex;
  justify-content: center;
  gap: 7px;
}

.detail-carousel-dot {
  width: 8px;
  height: 8px;
  padding: 0;
  border: 0;
  border-radius: 50%;
  background: #cbd5e1;
  cursor: pointer;
}

.detail-carousel-dot.is-active {
  width: 22px;
  border-radius: 8px;
  background: var(--yellow-dark);
}

@keyframes detail-carousel-fade {
  from { opacity: 0; transform: scale(0.96); }
  to { opacity: 1; }
}

.detail-info h1 {
  margin: 0 0 8px;
  font-size: 26px;
}

.detail-info h1 small {
  display: block;
  margin-top: 6px;
  color: var(--muted);
  font-size: 18px;
  font-weight: 400;
}

.sku {
  color: var(--muted);
}

.price-line {
  display: flex;
  align-items: center;
  gap: 18px;
  margin: 18px 0;
  color: #111827;
  font-size: 24px;
  font-weight: 800;
}

.price-line span {
  color: var(--green);
  font-size: 18px;
}

.compact-list {
  margin: 0;
  border: 1px solid var(--line);
  background: #fff;
}

.detail-parameter-card {
  margin: 16px 0 18px;
  border: 1px solid var(--line);
}

.sku-panel {
  margin: 16px 0;
  padding: 14px;
  border: 1px solid #d7dde8;
  border-radius: 4px;
  background: #fbfcfe;
}

.sku-panel h2 {
  margin-bottom: 10px;
}

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

.sku-option {
  display: grid;
  gap: 5px;
  min-height: 68px;
  border: 1px solid var(--line);
  border-radius: 4px;
  padding: 10px;
  text-align: left;
  background: #fff;
}

.sku-option span {
  color: var(--muted);
  font-size: 12px;
}

.sku-option.is-active {
  border-color: var(--yellow-dark);
  outline: 2px solid rgba(245, 180, 0, 0.28);
}

.check-list {
  margin: 12px 0 0;
  padding-left: 18px;
  color: #4b5563;
  line-height: 1.8;
}

.product-media-grid {
  grid-template-columns: minmax(0, 1.2fr) minmax(320px, 0.8fr);
  margin-top: 18px;
}

.product-video-card,
.product-qr-card {
  overflow: hidden;
}

.product-video-frame {
  position: relative;
  display: grid;
  min-height: 260px;
  align-content: center;
  justify-items: center;
  gap: 18px;
  margin: 0 20px 20px;
  border-radius: 4px;
  color: #fff;
  background:
    linear-gradient(135deg, rgba(17, 24, 39, 0.9), rgba(17, 24, 39, 0.48)),
    linear-gradient(135deg, rgba(245, 180, 0, 0.34), transparent 46%),
    #111827;
}

.product-video-frame .filter-thumb {
  transform: scale(1.4);
  box-shadow: 0 18px 36px rgba(0, 0, 0, 0.26);
}

.video-play {
  display: grid;
  width: 56px;
  height: 56px;
  place-items: center;
  border: 2px solid rgba(255, 255, 255, 0.86);
  border-radius: 50%;
  color: #111827;
  background: var(--yellow);
  font-size: 20px;
  font-weight: 900;
}

.video-caption {
  display: grid;
  gap: 4px;
  text-align: center;
}

.video-caption small {
  color: #dbe3ef;
}

.product-qr-content {
  display: grid;
  grid-template-columns: 148px minmax(0, 1fr);
  gap: 18px;
  align-items: center;
  padding: 0 20px 20px;
}

.product-qr {
  display: grid;
  grid-template-columns: repeat(6, 1fr);
  gap: 6px;
  width: 148px;
  height: 148px;
  border: 10px solid #fff;
  outline: 1px solid var(--line);
  background: #fff;
  box-shadow: var(--shadow);
}

.product-qr span {
  background: #111827;
}

.product-qr span:nth-child(2n),
.product-qr span:nth-child(5n),
.product-qr span:nth-child(13),
.product-qr span:nth-child(24),
.product-qr span:nth-child(31) {
  background: #fff;
}

.product-qr-content strong {
  color: #111827;
  font-size: 18px;
}

.product-qr-content p {
  margin: 8px 0;
  color: #374151;
}

.product-qr-content small {
  display: block;
  color: var(--muted);
  line-break: anywhere;
}

.related-list {
  display: grid;
  gap: 10px;
  margin-top: 12px;
}

.related-list a {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 4px;
  background: #fbfcfe;
}

.related-list span,
.link {
  color: var(--blue);
}

.compact-list div {
  display: grid;
  grid-template-columns: 110px minmax(0, 1fr);
  border-bottom: 1px solid var(--line);
}

.compact-list div:last-child {
  border-bottom: 0;
}

.compact-list dt,
.compact-list dd {
  margin: 0;
  padding: 11px 12px;
}

.compact-list dt {
  background: #fbfcfe;
  font-weight: 700;
}

.buy-row {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 18px;
}

.detail-page .buy-row {
  width: max-content;
  max-width: 100%;
  align-items: center;
  gap: 14px;
}

.detail-page .buy-row input {
  width: 66px;
  min-height: 38px;
}

.detail-page .buy-row .add-cart,
.detail-page .buy-row .primary-link {
  min-height: 38px;
  padding: 0 16px;
  border-radius: 4px;
  font-size: 16px;
  line-height: 1;
  white-space: nowrap;
}

.buy-row input,
.cart-table input {
  width: 76px;
  min-height: 34px;
  border: 1px solid var(--line);
  border-radius: 4px;
  text-align: center;
}

.two-column,
.checkout-grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
  margin-top: 18px;
}

.detail-page > .two-column:last-child {
  grid-template-columns: 1fr;
}

.info-panel,
.form-panel,
.contact-large {
  padding: 20px;
}

.info-panel p,
.contact-large p,
.news-card p,
.admin-card p {
  color: #4b5563;
  line-height: 1.75;
}

.form-panel {
  display: grid;
  gap: 13px;
}

.form-panel label {
  display: grid;
  gap: 7px;
  color: #374151;
}

.form-panel input,
.form-panel textarea {
  min-height: 38px;
  border: 1px solid var(--line);
  border-radius: 4px;
  padding: 8px 10px;
}

.form-panel textarea {
  min-height: 90px;
  resize: vertical;
}

.choice {
  display: flex !important;
  grid-template-columns: none;
  align-items: center;
  gap: 8px;
}

.choice input {
  min-height: auto;
  width: auto;
}

.bank-box {
  display: grid;
  gap: 6px;
  padding: 12px;
  border: 1px dashed #bac3d1;
  border-radius: 4px;
  background: #fbfcfe;
  color: #4b5563;
}

.bank-box[hidden],
#uploadBox[hidden] {
  display: none !important;
}

.deposit-summary {
  display: grid;
  gap: 10px;
  padding: 14px;
  border: 1px solid #f0c04e;
  border-radius: 4px;
  background: #fff8de;
}

.deposit-summary div {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.deposit-summary strong {
  color: #111827;
  font-size: 18px;
}

.deposit-summary .is-highlight {
  padding: 10px;
  border-radius: 4px;
  background: #fff;
}

.deposit-summary p {
  margin: 0;
  color: #6b5a26;
  line-height: 1.7;
}

.padded {
  padding: 18px;
}

.summary-bar {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 22px;
  padding: 18px;
}

.order-list {
  display: grid;
  gap: 12px;
  padding: 0 18px 18px;
}

.order-card {
  display: grid;
  grid-template-columns: 180px 88px minmax(0, 1fr) auto auto;
  align-items: center;
  gap: 12px;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 4px;
}

.order-card p {
  margin: 0;
  color: #4b5563;
}

.order-detail-page {
  display: grid;
  gap: 16px;
  width: min(1320px, calc(100% - 160px));
}

.order-status-panel {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto auto;
  gap: 16px;
  align-items: center;
  padding: 20px;
  border-top: 4px solid var(--blue);
}

.order-status-panel h1 {
  margin: 4px 0 6px;
  font-size: 26px;
}

.order-status-panel p {
  margin: 0;
  color: var(--muted);
}

.order-detail-actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 8px;
}

.order-detail-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 360px;
  gap: 16px;
  align-items: start;
}

.payment-plan-panel,
.order-doc-panel {
  overflow: hidden;
}

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

.payment-step,
.payment-total-card {
  display: grid;
  gap: 6px;
  min-height: 112px;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 4px;
  background: #fbfcfe;
}

.payment-step span {
  display: grid;
  place-items: center;
  width: 24px;
  height: 24px;
  border-radius: 50%;
  color: #fff;
  background: #9aa4b2;
  font-weight: 800;
}

.payment-step strong,
.payment-total-card strong {
  color: #111827;
}

.payment-step p,
.payment-step small,
.payment-total-card p,
.payment-total-card span {
  margin: 0;
  color: var(--muted);
}

.payment-step.is-current {
  border-color: var(--yellow-dark);
  background: #fff8de;
}

.payment-step.is-current span {
  background: var(--yellow-dark);
}

.payment-step.is-done {
  border-color: #9fe0b8;
  background: #f0fff6;
}

.payment-step.is-done span {
  background: var(--green);
}

.payment-total-card {
  border-color: #bcd3ff;
  background: #f2f7ff;
}

.payment-total-card strong {
  font-size: 24px;
}

.order-items-table {
  overflow-x: auto;
  padding: 0 18px 18px;
}

.order-summary-panel {
  padding: 18px;
}

.order-summary-panel h2 {
  margin: 0 0 14px;
}

.order-summary-panel .order-detail-list {
  margin-top: 0;
}

.order-total-box {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-top: 14px;
  padding: 14px;
  border: 1px solid #f0c04e;
  border-radius: 4px;
  background: #fff8de;
}

.order-total-box strong {
  color: #111827;
  font-size: 24px;
}

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

.order-doc-card {
  display: grid;
  grid-template-columns: 42px minmax(0, 1fr) auto;
  gap: 12px;
  align-items: center;
  min-height: 106px;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 4px;
  background: #fff;
}

.order-doc-card p {
  margin: 4px 0;
  color: #4b5563;
  line-height: 1.55;
}

.order-doc-card small {
  color: var(--muted);
}

.order-doc-card.is-pending {
  background: #f8fafc;
  opacity: 0.72;
}

.order-doc-card button:disabled {
  cursor: not-allowed;
}

.doc-icon {
  display: grid;
  place-items: center;
  width: 42px;
  height: 42px;
  border-radius: 4px;
  color: #fff;
  background: var(--blue);
  font-size: 12px;
  font-weight: 800;
}

.document-preview {
  margin-top: 18px;
}

.document-image,
.document-file {
  display: grid;
  gap: 10px;
  min-height: 220px;
  padding: 18px;
  border: 1px solid #bac3d1;
  border-radius: 4px;
  background:
    linear-gradient(135deg, rgba(19, 111, 242, 0.08), transparent 42%),
    repeating-linear-gradient(0deg, #fff, #fff 32px, #f7f9fc 32px, #f7f9fc 64px);
}

.document-image b,
.document-file strong {
  color: #111827;
  font-size: 18px;
}

.document-file {
  place-items: center;
  text-align: center;
}

.order-timeline-panel {
  overflow: hidden;
}

.order-timeline {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
  gap: 0;
  margin: 0;
  padding: 0 18px 18px;
  list-style: none;
}

.order-timeline li {
  position: relative;
  display: grid;
  grid-template-columns: 26px minmax(0, 1fr);
  gap: 8px;
  align-items: start;
  min-height: 44px;
}

.order-timeline li::before {
  content: "";
  position: absolute;
  top: 8px;
  left: 8px;
  right: 0;
  height: 2px;
  background: #d9e2ef;
}

.order-timeline li:last-child::before {
  display: none;
}

.order-timeline li span {
  position: relative;
  z-index: 1;
  width: 18px;
  height: 18px;
  border: 3px solid #fff;
  border-radius: 50%;
  background: var(--blue);
  box-shadow: 0 0 0 1px var(--blue);
}

.order-timeline li p {
  margin: 0;
  color: #344054;
  font-weight: 700;
  line-height: 1.45;
}

.refund-panel {
  overflow: hidden;
}

.refund-workbench {
  display: grid;
  gap: 16px;
  padding: 0 18px 18px;
}

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

.refund-type-card {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  gap: 4px 10px;
  min-height: 92px;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 4px;
  background: #fbfcfe;
}

.refund-type-card input {
  grid-row: span 2;
  margin-top: 3px;
}

.refund-type-card strong {
  color: #111827;
}

.refund-type-card span {
  color: var(--muted);
  font-size: 12px;
  line-height: 1.6;
}

.refund-item-list {
  display: grid;
  gap: 10px;
}

.refund-item {
  display: grid;
  grid-template-columns: auto 44px minmax(0, 1fr) auto;
  gap: 10px;
  align-items: center;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 4px;
  background: #fff;
}

.refund-item small {
  display: block;
  margin-top: 3px;
  color: var(--muted);
}

.refund-item.is-disabled {
  opacity: 0.58;
}

.refund-submit-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 14px;
  border: 1px solid #dce3ee;
  border-radius: 4px;
  background: #fbfcfe;
}

.refund-submit-row b {
  color: #111827;
  font-size: 20px;
}

.badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 26px;
  border-radius: 13px;
  padding: 0 10px;
  font-size: 12px;
  font-weight: 800;
}

.warning {
  color: #8a5700;
  background: #fff3cf;
}

.blue-badge {
  color: #0b4db3;
  background: #dceaff;
}

.green-badge {
  color: #087333;
  background: #d9f8e5;
}

.gray-badge {
  color: #475467;
  background: #eef2f7;
}

.admin-dashboard {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 14px;
  margin-bottom: 16px;
}

.metric-card {
  display: grid;
  gap: 6px;
  padding: 18px;
  border: 1px solid var(--line);
  border-top: 4px solid var(--blue);
  border-radius: 4px;
  background: #fff;
  box-shadow: var(--shadow);
}

.metric-card strong {
  font-size: 28px;
}

.metric-card span {
  color: var(--muted);
}

.admin-review {
  margin-top: 18px;
}

.empty-state {
  padding: 22px;
  color: var(--muted);
  text-align: center;
}

tr.empty-state td {
  text-align: center;
}

.table-wrap .add-cart + .view-detail,
.table-wrap .view-detail + .view-detail {
  margin-left: 8px;
}

.news-grid,
.admin-grid {
  grid-template-columns: repeat(3, minmax(0, 1fr));
  margin-top: 16px;
}

.machine-category-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 18px;
  margin-top: 16px;
}

.machine-card {
  overflow: hidden;
  padding-bottom: 18px;
}

.machine-card-image {
  min-height: 170px;
  background-image: url("./assets/excavator.png");
  background-size: cover;
  background-position: center;
}

.machine-card-image.komatsu {
  filter: saturate(0.9) hue-rotate(8deg);
}

.machine-card-image.hitachi {
  filter: saturate(0.82) hue-rotate(-10deg);
}

.machine-card h2,
.machine-card p,
.machine-card .primary-link {
  margin-left: 18px;
  margin-right: 18px;
}

.machine-card h2 {
  margin-top: 16px;
}

.machine-card p {
  color: #4b5563;
  line-height: 1.75;
}

.machine-search-panel {
  margin-top: 18px;
  padding: 20px;
}

.news-card,
.admin-card {
  padding: 20px;
}

.news-card b {
  color: var(--yellow-dark);
}

.news-card h2,
.admin-card h2 {
  margin: 10px 0;
}

.active-account {
  color: var(--blue) !important;
  font-weight: 800;
}

.auth-page {
  min-height: calc(100vh - 150px);
}

.auth-shell {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 420px;
  gap: 20px;
  align-items: stretch;
}

.auth-visual {
  display: grid;
  align-content: center;
  min-height: 480px;
  padding: 56px;
  border: 1px solid var(--line);
  border-radius: 4px;
  color: #fff;
  background:
    linear-gradient(90deg, rgba(17, 24, 39, 0.9), rgba(17, 24, 39, 0.55)),
    url("./assets/excavator.png") center / cover no-repeat;
  box-shadow: var(--shadow);
}

.auth-kicker {
  width: max-content;
  margin-bottom: 18px;
  border-left: 4px solid var(--yellow);
  padding-left: 10px;
  color: var(--yellow);
  font-weight: 800;
}

.auth-visual h1 {
  max-width: 520px;
  margin: 0;
  font-size: 34px;
  line-height: 1.25;
  letter-spacing: 0;
}

.auth-visual p {
  max-width: 560px;
  margin: 16px 0 0;
  color: #e5e7eb;
  font-size: 16px;
  line-height: 1.8;
}

.auth-panel {
  display: grid;
  align-content: start;
  gap: 16px;
  padding: 24px;
}

.auth-tabs {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 8px;
  padding: 4px;
  border: 1px solid var(--line);
  border-radius: 4px;
  background: #f8fafc;
}

.auth-tab {
  min-height: 38px;
  border: 0;
  border-radius: 3px;
  background: transparent;
  color: #4b5563;
  font-weight: 800;
}

.auth-tab.is-active {
  color: #111827;
  background: var(--yellow);
}

.auth-form-head {
  display: grid;
  gap: 6px;
  padding-top: 4px;
}

.auth-form-head h2 {
  margin: 0;
  color: #111827;
  font-size: 22px;
}

.auth-form-head span {
  color: var(--muted);
}

.auth-field {
  display: grid;
  gap: 8px;
  color: #374151;
  font-weight: 700;
}

.auth-field input,
.auth-field textarea {
  width: 100%;
  min-height: 42px;
  border: 1px solid #cfd5df;
  border-radius: 4px;
  padding: 0 12px;
  color: #111827;
  background: #fff;
  outline: none;
}

.auth-field textarea {
  min-height: 86px;
  padding: 10px 12px;
  resize: vertical;
}

.register-fields {
  display: grid;
  gap: 16px;
}

.register-fields[hidden] {
  display: none;
}

.auth-field input:focus,
.auth-field textarea:focus {
  border-color: var(--blue);
  box-shadow: 0 0 0 3px rgba(19, 111, 242, 0.12);
}

.code-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 116px;
  gap: 10px;
}

.code-row .view-detail {
  min-height: 42px;
  padding: 0 10px;
  white-space: nowrap;
}

.auth-consent {
  color: #4b5563;
  font-size: 13px;
  line-height: 1.5;
}

.auth-message {
  min-height: 20px;
  margin: 0;
  color: var(--muted);
  line-height: 1.5;
}

.auth-message.is-error {
  color: #c03525;
}

.auth-message.is-success {
  color: var(--green);
  font-weight: 800;
}

.profile-login-prompt {
  display: grid;
  grid-template-columns: 52px minmax(0, 1fr);
  gap: 18px;
  align-items: start;
  padding: 28px;
}

.profile-icon {
  display: grid;
  width: 52px;
  height: 52px;
  place-items: center;
  border-radius: 50%;
  color: #111827;
  background: var(--yellow);
  font-size: 24px;
  font-weight: 900;
}

.profile-login-prompt h1,
.profile-head h1 {
  margin: 0;
  color: #111827;
  font-size: 28px;
  letter-spacing: 0;
}

.profile-login-prompt p,
.profile-head p {
  margin: 8px 0 0;
  color: var(--muted);
}

.profile-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 18px;
}

.profile-head {
  display: grid;
  grid-template-columns: 64px minmax(0, 1fr) auto;
  gap: 16px;
  align-items: center;
  padding: 24px;
}

.profile-avatar {
  display: grid;
  width: 64px;
  height: 64px;
  place-items: center;
  border-radius: 50%;
  color: #111827;
  background: var(--yellow);
  font-size: 22px;
  font-weight: 900;
}

.profile-grid {
  display: grid;
  grid-template-columns: minmax(0, 0.9fr) minmax(0, 1.1fr);
  gap: 18px;
  margin-top: 18px;
}

.profile-info-list {
  display: grid;
  gap: 12px;
  margin: 0;
  padding: 0 20px 20px;
}

.profile-info-list div {
  display: grid;
  grid-template-columns: 92px minmax(0, 1fr);
  gap: 14px;
  padding-bottom: 12px;
  border-bottom: 1px solid var(--line);
}

.profile-info-list dt {
  color: var(--muted);
}

.profile-info-list dd {
  margin: 0;
  color: #111827;
  font-weight: 700;
}

.profile-stats {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
  padding: 0 20px 18px;
}

.profile-stats a {
  display: grid;
  gap: 4px;
  border: 1px solid var(--line);
  border-radius: 4px;
  padding: 14px;
  color: inherit;
  background: #f8fafc;
}

.profile-stats a:hover {
  border-color: var(--blue);
  box-shadow: 0 0 0 3px rgba(19, 111, 242, 0.08);
}

.profile-stats strong {
  color: #111827;
  font-size: 24px;
}

.profile-stats span {
  color: var(--muted);
  font-size: 13px;
}

.profile-order-list {
  display: grid;
  gap: 10px;
  padding: 0 20px 20px;
}

.profile-order-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  border: 1px solid var(--line);
  border-radius: 4px;
  padding: 14px;
  color: inherit;
  background: #fff;
}

.profile-order-item span {
  display: grid;
  gap: 4px;
}

.profile-order-item small {
  color: var(--muted);
}

.address-panel {
  margin-top: 18px;
}

.address-list {
  display: grid;
  gap: 12px;
  padding: 0 20px 20px;
}

.address-card {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 16px;
  align-items: center;
  border: 1px solid var(--line);
  border-radius: 4px;
  padding: 16px;
  background: #fff;
}

.address-card.is-default {
  border-left: 4px solid var(--blue);
}

.address-card strong {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
  color: #111827;
}

.address-card p {
  margin: 8px 0 4px;
  color: #374151;
}

.address-card small {
  color: var(--muted);
  line-height: 1.6;
}

.address-actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 8px;
}

@media (max-width: 1100px) {
  .brand-row {
    grid-template-columns: 1fr;
    gap: 14px;
    padding: 14px 0;
  }

  .global-search {
    justify-self: stretch;
  }

  .menu-row {
    overflow-x: auto;
  }

  .hero-grid,
  .model-detail-layout,
  .home-hero,
  .home-layout,
  .detail-hero,
  .product-media-grid,
  .auth-shell,
  .profile-grid,
  .order-status-panel,
  .order-detail-grid,
  .payment-plan-grid,
  .order-doc-grid,
  .checkout-grid,
  .two-column,
  .news-grid,
  .admin-grid,
  .machine-category-grid,
  .admin-dashboard,
  .sku-options,
  .refund-type-grid {
    grid-template-columns: 1fr;
  }

  .order-detail-actions {
    justify-content: flex-start;
  }

  .products-layout .product-grid.wide {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 900px) {
  .model-search-page {
    grid-template-columns: 1fr;
  }

  .model-search-page > .content {
    display: contents;
  }

  .model-search-page > .content > .model-query-panel,
  .model-search-page .model-search-results {
    position: static;
    margin-top: 18px;
  }

  .model-search-page {
    grid-template-columns: 190px minmax(0, 1fr);
    gap: 14px;
  }

  .page-shell {
    grid-template-columns: 1fr;
  }

  .page-shell.model-search-page {
    grid-template-columns: 190px minmax(0, 1fr);
    gap: 14px;
  }

  .page-shell.products-layout {
    grid-template-columns: 190px minmax(0, 1fr);
    gap: 14px;
  }

  .products-layout .content {
    order: 0;
  }

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

  .category-links,
  .machine-links {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .machine-result-head {
    align-items: stretch;
    flex-direction: column;
  }

  .model-query-head {
    align-items: stretch;
    flex-direction: column;
  }

  .model-keyword-search {
    justify-content: stretch;
    width: 100%;
  }

  .model-query-fields {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .model-match-row {
    align-items: stretch;
    flex-direction: column;
  }

  #modelMatchList {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .model-match-visual {
    align-items: flex-start;
  }

  .model-match-meta {
    justify-content: flex-start;
    text-align: left;
  }
}

@media (max-width: 720px) {
  .top-inner,
  .brand-row,
  .menu-row,
  .page-shell,
  .order-detail-page {
    width: min(100% - 20px, 1400px);
  }

  .top-inner,
  .quick-links,
  .account-actions,
  .pagination {
    flex-wrap: wrap;
  }

  .brand strong {
    font-size: 24px;
  }

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

  .machine-photo {
    min-height: 220px;
  }

  .model-machine-card .machine-photo {
    min-height: 250px;
  }

  .model-keyword-search,
  .model-query-fields {
    grid-template-columns: 1fr;
  }

  .equipment-card div {
    grid-template-columns: 130px 1fr;
  }

  .model-equipment-card dl > div {
    grid-template-columns: 118px minmax(0, 1fr);
  }

  .float-actions {
    display: none;
  }

  .home-hero-copy {
    width: 100%;
    padding: 24px;
    background: linear-gradient(90deg, rgba(17, 24, 39, 0.7), rgba(17, 24, 39, 0.46));
  }

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

  .auth-visual {
    min-height: 260px;
    padding: 28px;
  }

  .auth-visual h1 {
    font-size: 26px;
  }

  .profile-head {
    grid-template-columns: 56px minmax(0, 1fr);
  }

  .profile-head .view-detail {
    grid-column: 1 / -1;
    justify-self: start;
  }

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

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

  .address-actions {
    justify-content: flex-start;
  }

  .hero-search,
  .quick-grid,
  .product-grid,
  .product-grid.wide,
  #modelMatchList,
  .product-qr-content,
  .category-links,
  .machine-links,
  .code-row {
    grid-template-columns: 1fr;
  }

  .order-card {
    grid-template-columns: 1fr;
    align-items: start;
  }

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

  .order-timeline li::before {
    left: 8px;
    right: auto;
    top: 18px;
    bottom: -18px;
    width: 2px;
    height: auto;
  }

  .refund-item {
    grid-template-columns: auto 44px minmax(0, 1fr);
  }

  .refund-item strong {
    grid-column: 3;
  }

  .order-doc-card {
    grid-template-columns: 42px minmax(0, 1fr);
  }

  .order-doc-card button {
    grid-column: 2;
    justify-self: start;
  }
}

.model-product-gallery {
  margin-top: 0;
}

.model-product-gallery .section-title {
  margin-bottom: 12px;
}

.model-product-gallery .product-grid.wide {
  grid-template-columns: repeat(3, minmax(220px, 1fr));
  gap: 14px;
}


.model-category-machine-card {
  display: grid;
  grid-template-rows: auto auto;
  align-content: start;
  aspect-ratio: auto;
  min-height: 0;
  padding: 0;
}

.model-machine-card-preview {
  position: static;
  display: block;
  width: 100%;
  aspect-ratio: 355 / 202;
  background-color: #f7f9fc;
  background-position: center;
  background-repeat: no-repeat;
  background-size: cover;
}

.model-machine-card-code {
  display: block;
  padding: 8px 10px 9px;
  color: #18202b;
  font-size: 15px;
  line-height: 1.2;
  text-align: center;
}
/* Model search follows the compact catalogue layout used by the reference page. */
.model-search-page {
  display: grid;
  grid-template-columns: 240px minmax(0, 1fr);
  align-items: start;
  gap: 18px;
  padding-top: 14px;
}

.model-search-page > .model-category-sidebar {
  grid-column: 1;
  grid-row: 1;
}

.model-category-sidebar .product-category-list a.is-active {
  color: var(--blue);
  background: #f4f7fb;
}

.model-search-page > .model-content {
  grid-column: 2;
  grid-row: 1;
  min-width: 0;
}

.model-search-page > .content,
.model-search-page > .content > .model-search-results {
  display: block;
}

.model-sidebar {
  gap: 10px;
}

.model-filter-card,
.model-contact-card {
  padding: 10px;
  border-radius: 2px;
  box-shadow: none;
}

.model-filter-title {
  display: flex;
  align-items: baseline;
  gap: 6px;
  margin: 0 0 10px;
  padding: 0 0 8px;
  border-bottom: 1px solid var(--line);
}

.model-filter-title h2 {
  margin: 0;
  padding: 0;
  border: 0;
  font-size: 13px;
}

.model-filter-title span {
  color: #7a818b;
  font-size: 9px;
}

.model-category-menu {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 5px;
  margin: 0 0 10px;
  padding: 0 0 10px;
  border-bottom: 1px solid var(--line);
}

.model-category-menu a {
  min-height: 28px;
  padding: 5px 4px;
  border: 1px solid var(--line);
  border-radius: 2px;
  color: #4b5563;
  background: #fff;
  font-size: 11px;
  text-align: center;
}

.model-category-menu a:hover,
.model-category-menu a.is-active {
  border-color: var(--yellow);
  color: #202020;
  background: #fff6d9;
}

.model-filter-card label {
  gap: 4px;
  margin-bottom: 8px;
  color: #555e6c;
  font-size: 10px;
}

.model-filter-card select,
.model-filter-card input {
  min-height: 30px;
  border-radius: 2px;
  padding: 0 7px;
  font-size: 11px;
}

.model-filter-card .model-submit {
  min-height: 34px;
  margin-top: 2px;
  border-radius: 2px;
  background: var(--blue);
  font-size: 11px;
}

.model-filter-card .model-search-status {
  margin: 7px 0 0;
  color: var(--muted);
  font-size: 10px;
  text-align: center;
}

.model-contact-card {
  background: #fff;
}

.model-contact-card .model-filter-title {
  margin-bottom: 6px;
}

.model-contact-card a {
  margin: 9px 0;
  padding-left: 26px;
  font-size: 11px;
}

.model-contact-card .dot {
  top: 1px;
  width: 17px;
  height: 17px;
}

.model-contact-card .chat-button {
  min-height: 34px;
  border-radius: 2px;
  font-size: 11px;
}

.model-content .breadcrumb {
  margin: 0 0 9px;
  font-size: 12px;
}

.model-search-page .model-search-results {
  margin-top: 0;
}

.model-search-page .model-search-results:not(.has-product-result) #modelProductResult,
.model-search-page .model-search-results:not(.has-product-result) #modelProductResult .table-wrap,
.model-search-page .model-search-results:not(.has-product-result) #modelProductResult .pagination {
  display: block;
}

.model-search-page .model-detail-layout {
  grid-template-columns: minmax(300px, 0.78fr) minmax(360px, 1fr);
  gap: 0;
  align-items: stretch;
}

.model-search-page .model-machine-card {
  border-right: 0;
  border-radius: 2px 0 0 2px;
  box-shadow: none;
}

.model-search-page .model-machine-card .machine-photo {
  min-height: 0;
  aspect-ratio: 1.74;
  border: 0;
  background-size: cover;
}

.model-search-page .model-machine-card .thumb-row {
  margin: 8px;
  gap: 8px;
}

.model-search-page .model-machine-card .thumb-row span {
  height: 44px;
}

.model-search-page .model-equipment-card {
  border-radius: 0 2px 2px 0;
  box-shadow: none;
}

.model-search-page .equipment-card-heading {
  min-height: 36px;
  padding: 0 10px;
  background: #f7f8fa;
}

.model-search-page .equipment-card-heading h2 {
  font-size: 12px;
}

.model-search-page .equipment-card-heading span {
  font-size: 10px;
}

.model-search-page .model-equipment-card dl > div {
  grid-template-columns: 142px minmax(0, 1fr);
  min-height: 30px;
}

.model-search-page .model-equipment-card dt,
.model-search-page .model-equipment-card dd {
  padding: 6px 10px;
  font-size: 11px;
}

.model-search-page .model-equipment-card dt {
  background: #f8f9fb;
  font-weight: 400;
}

.model-results-section {
  margin-top: 12px;
}

.model-results-section .section-title {
  margin-bottom: 6px;
}

.model-results-section .section-title h2 {
  font-size: 12px;
}

.model-results-section .table-wrap {
  border-radius: 2px;
}

.model-results-section table {
  min-width: 760px;
  table-layout: fixed;
}

.model-results-section thead th {
  height: 34px;
  padding: 0 8px;
  font-size: 10px;
  text-align: center;
}

.model-results-section thead th small {
  display: inline;
  font-size: 8px;
  font-weight: 400;
}

.model-results-section thead th:nth-child(1) { width: 22%; }
.model-results-section thead th:nth-child(2) { width: 13%; }
.model-results-section thead th:nth-child(3) { width: 15%; }
.model-results-section thead th:nth-child(4) { width: 14%; }
.model-results-section thead th:nth-child(5) { width: 10%; }
.model-results-section thead th:nth-child(6) { width: 12%; }
.model-results-section thead th:nth-child(7) { width: 14%; }

.model-results-section tbody td {
  min-height: 58px;
  padding: 7px 8px;
  font-size: 10px;
}

.model-results-section .product-cell {
  grid-template-columns: 34px minmax(0, 1fr);
  gap: 7px;
  font-size: 10px;
}

.model-results-section .product-cell .filter-thumb {
  width: 28px;
  height: 38px;
}

.model-results-section .row-actions {
  justify-content: center;
  gap: 4px;
}

.model-results-section .add-cart,
.model-results-section .view-detail {
  min-height: 25px;
  padding: 0 6px;
  font-size: 9px;
}

.model-results-section .pagination {
  padding: 9px 0 0;
  font-size: 10px;
}

.model-results-section .pagination button,
.model-results-section .pagination select,
.model-results-section .pagination input {
  height: 27px;
  font-size: 10px;
}

@media (max-width: 900px) {
  .model-search-page,
  .page-shell.model-search-page {
    grid-template-columns: 190px minmax(0, 1fr);
    gap: 12px;
  }

  .model-search-page .model-detail-layout {
    grid-template-columns: 1fr;
  }

  .model-search-page .model-machine-card,
  .model-search-page .model-equipment-card {
    border: 1px solid var(--line);
    border-radius: 2px;
  }

  .model-search-page .model-equipment-card {
    border-top: 0;
    border-radius: 0 0 2px 2px;
  }

  .model-search-page .model-machine-card {
    border-radius: 2px 2px 0 0;
  }
}

@media (max-width: 720px) {
  .model-search-page,
  .page-shell.model-search-page {
    grid-template-columns: 1fr;
    gap: 12px;
  }

  .model-search-page > .model-category-sidebar,
  .model-search-page > .model-content {
    grid-column: 1;
    grid-row: auto;
  }

  .model-category-menu {
    grid-template-columns: repeat(5, minmax(0, 1fr));
  }

  .model-search-page .model-machine-card .machine-photo {
    min-height: 220px;
  }

  .model-search-page .model-equipment-card dl > div {
    grid-template-columns: 120px minmax(0, 1fr);
  }
}

.model-page-heading {
  margin-bottom: 14px;
}

.model-page-heading .breadcrumb {
  margin: 0 0 12px;
}

.model-page-heading .section-title {
  margin: 0;
}

.model-page-heading .section-title h1 {
  margin: 0;
  color: #18202b;
  font-size: 15px;
  font-weight: 700;
}

.model-search-page .model-detail-layout {
  grid-template-columns: minmax(0, 1fr) minmax(0, 1.1fr);
  gap: 12px;
  align-items: start;
}

.model-search-page .model-machine-card {
  border-right: 1px solid var(--line);
  border-radius: 2px;
}

.model-search-page .model-machine-card .machine-photo {
  aspect-ratio: 1.18;
  min-height: 0;
  background-size: cover;
}

.model-search-page .model-detail-column {
  display: grid;
  gap: 12px;
  min-width: 0;
}

.model-search-page .model-equipment-card {
  border-radius: 2px;
}

.model-search-page .equipment-card-heading {
  display: none;
}

.model-search-page .model-equipment-card dl > div {
  grid-template-columns: 132px minmax(0, 1fr);
  min-height: 40px;
  border-bottom: 1px solid var(--line);
}

.model-search-page .model-equipment-card dt,
.model-search-page .model-equipment-card dd {
  padding: 9px 14px;
  font-size: 15px;
}

.model-search-page .model-equipment-card dt {
  background: #f5f5f5;
  color: #111827;
  font-weight: 700;
}

.model-search-page .model-fit-panel {
  padding: 0;
  border: 0;
  border-radius: 0;
  box-shadow: none;
  background: transparent;
}

.model-search-page .model-fit-panel .table-wrap {
  overflow-x: hidden;
  background: transparent;
}

.model-search-page .model-fit-panel .section-title {
  margin: 0 0 4px;
  padding: 0 0 9px;
  border-bottom: 0;
}

.model-search-page .model-fit-panel .section-title h2 {
  color: #111827;
  font-size: 19px;
}

.model-search-page .model-fit-table {
  width: 100%;
  min-width: 0;
  table-layout: fixed;
  background: transparent;
}

.model-search-page .model-fit-table thead th {
  height: 34px;
  padding: 0 10px;
  color: #111827;
  background: rgba(223, 227, 234, 0.42);
  border-right: 0;
  font-size: 16px;
  text-align: left;
}

.model-search-page .model-fit-table th:nth-child(1),
.model-search-page .model-fit-table td:nth-child(1) {
  width: 22%;
}

.model-search-page .model-fit-table th:nth-child(2),
.model-search-page .model-fit-table td:nth-child(2) {
  width: 16%;
}

.model-search-page .model-fit-table th:nth-child(3),
.model-search-page .model-fit-table td:nth-child(3) {
  width: 18%;
}

.model-search-page .model-fit-table th:nth-child(4),
.model-search-page .model-fit-table td:nth-child(4) {
  width: 20%;
}

.model-search-page .model-fit-table th:nth-child(5),
.model-search-page .model-fit-table td:nth-child(5) {
  width: 24%;
}

.model-search-page .model-fit-table td {
  min-height: 38px;
  padding: 8px 10px;
  border-right: 0;
  font-size: 14px;
  line-height: 1.35;
  vertical-align: middle;
  overflow-wrap: anywhere;
  background: transparent;
}

.model-search-page .model-fit-table td a {
  color: #007dcc;
}

.model-search-page .model-fit-table td a:hover {
  color: #005e9b;
  text-decoration: underline;
}

.model-search-page .model-results-section {
  display: none;
}

@media (max-width: 900px) {
  .model-search-page .model-detail-layout {
    grid-template-columns: 1fr;
  }

  .model-search-page .model-machine-card .machine-photo {
    aspect-ratio: 1.5;
  }
}

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

@media (max-width: 720px) {
  .model-product-gallery .product-grid.wide {
    grid-template-columns: 1fr;
  }

  .model-page-heading {
    align-items: flex-start;
    flex-direction: column;
    gap: 4px;
  }

  .model-page-heading h1 {
    font-size: 20px;
  }

  .model-search-page .model-equipment-card dl > div {
    grid-template-columns: 110px minmax(0, 1fr);
  }
}

/* Model detail gallery and the full-width matching-products table. */
.model-search-page .model-machine-card {
  overflow: hidden;
  padding: 0;
}

.model-search-page .machine-carousel {
  display: grid;
  gap: 8px;
  padding: 0 0 8px;
}

.model-search-page .model-machine-card .machine-photo {
  position: relative;
  min-height: 0;
  aspect-ratio: 1.74;
  border: 0;
  background-color: #dbeafe;
  background-repeat: no-repeat;
  background-size: cover;
  transition: background-position 0.2s ease;
}

.machine-carousel-control {
  position: absolute;
  top: 50%;
  z-index: 1;
  display: grid;
  width: 34px;
  height: 46px;
  place-items: center;
  border: 0;
  color: #fff;
  background: rgba(17, 24, 39, 0.46);
  font-size: 28px;
  line-height: 1;
  transform: translateY(-50%);
}

.machine-carousel-control:hover {
  background: rgba(17, 24, 39, 0.72);
}

.machine-carousel-control.prev {
  left: 0;
}

.machine-carousel-control.next {
  right: 0;
}

.machine-carousel-thumbs {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 8px;
  padding: 0 8px;
}

.machine-carousel-thumb {
  min-width: 0;
  padding: 2px;
  border: 1px solid var(--line);
  background: #fff;
}

.machine-carousel-thumb span {
  display: block;
  width: 100%;
  aspect-ratio: 1.74;
  background-repeat: no-repeat;
  background-size: cover;
}

.machine-carousel-thumb.is-active {
  border-color: var(--blue);
  outline: 2px solid rgba(19, 111, 242, 0.22);
}

.model-search-page .model-fit-panel {
  margin-top: 14px;
  padding: 0;
  border: 0;
  background: transparent;
  box-shadow: none;
}

.model-search-page .model-fit-panel .section-title {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  margin: 0 0 10px;
  padding: 0;
  border: 0;
}

.model-search-page .model-fit-panel .section-title h2 {
  color: #111827;
  font-size: 18px;
}

.model-search-page .model-fit-panel .table-wrap {
  overflow-x: hidden;
  border: 0;
  background: transparent;
}

.model-search-page .model-fit-table {
  width: 100%;
  min-width: 0;
  table-layout: fixed;
  border-collapse: collapse;
}

.model-search-page .model-fit-table thead th {
  height: 40px;
  padding: 0 12px;
  border-right: 1px solid #484d56;
  color: #fff;
  background: #30343b;
  font-size: 13px;
  font-weight: 700;
  text-align: left;
}

.model-search-page .model-fit-table thead th:last-child {
  border-right: 0;
}

.model-search-page .model-fit-table th:nth-child(1),
.model-search-page .model-fit-table td:nth-child(1) { width: 27%; }
.model-search-page .model-fit-table th:nth-child(2),
.model-search-page .model-fit-table td:nth-child(2) { width: 14%; }
.model-search-page .model-fit-table th:nth-child(3),
.model-search-page .model-fit-table td:nth-child(3) { width: 14%; }
.model-search-page .model-fit-table th:nth-child(4),
.model-search-page .model-fit-table td:nth-child(4) { width: 15%; }
.model-search-page .model-fit-table th:nth-child(5),
.model-search-page .model-fit-table td:nth-child(5) { width: 19%; }
.model-search-page .model-fit-table th:nth-child(6),
.model-search-page .model-fit-table td:nth-child(6) { width: 15%; }

.model-search-page .model-fit-table tbody td {
  min-height: 66px;
  padding: 9px 12px;
  border-right: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
  color: #1f2937;
  background: #fff;
  font-size: 13px;
  line-height: 1.45;
  vertical-align: middle;
  overflow-wrap: anywhere;
}

.model-search-page .model-fit-table tbody td:last-child {
  border-right: 0;
}

.model-fit-product-cell {
  display: flex;
  align-items: center;
  gap: 10px;
  min-width: 0;
}

.model-fit-product-cell .filter-thumb {
  flex: 0 0 34px;
  width: 34px;
  height: 46px;
  font-size: 10px;
}

.model-fit-product-cell a {
  min-width: 0;
}

.model-fit-product-cell strong {
  color: #1f2937;
  font-weight: 700;
}

.model-search-page .model-fit-table td a {
  color: #087edb;
}

.model-search-page .model-fit-table .model-fit-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.model-search-page .model-fit-table .add-cart,
.model-search-page .model-fit-table .view-detail {
  min-height: 30px;
  padding: 0 8px;
  font-size: 11px;
  white-space: nowrap;
}

@media (max-width: 900px) {
  .model-search-page .model-fit-table thead th,
  .model-search-page .model-fit-table tbody td {
    padding-left: 8px;
    padding-right: 8px;
  }

  .model-fit-product-cell {
    gap: 6px;
  }

  .model-fit-product-cell .filter-thumb {
    flex-basis: 28px;
    width: 28px;
    height: 38px;
  }
}

/* Keep the product image dominant on tablet-sized detail pages. */
@media (min-width: 860px) and (max-width: 1100px) {
  .detail-page .detail-hero {
    grid-template-columns: minmax(360px, 0.92fr) minmax(400px, 1.08fr);
    align-items: start;
  }

  .detail-page .detail-visual,
  .detail-page .detail-info {
    min-width: 0;
  }

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

/* Match the machine-query gallery: image stage above, thumbnail strip below. */
.detail-page .detail-carousel {
  display: grid;
  grid-template-columns: 1fr;
  gap: 8px;
  min-height: 0;
  padding: 0 0 8px;
}

.detail-page .detail-carousel-stage {
  min-height: 0;
  aspect-ratio: 1.74;
  overflow: hidden;
  border: 0;
}

.detail-page .detail-visual {
  min-height: 0;
  align-content: start;
}

.detail-page .detail-carousel-stage .machine-carousel-control {
  position: absolute;
  top: 50%;
  z-index: 2;
  display: grid;
  width: 34px;
  height: 46px;
  place-items: center;
  border: 0;
  color: #fff;
  background: rgba(17, 24, 39, 0.46);
  font-size: 28px;
  line-height: 1;
  transform: translateY(-50%);
}

.detail-page .detail-carousel-stage .machine-carousel-control:hover {
  background: rgba(17, 24, 39, 0.72);
}

.detail-page .detail-carousel-stage .machine-carousel-control.prev {
  left: 0;
}

.detail-page .detail-carousel-stage .machine-carousel-control.next {
  right: 0;
}

.detail-page .detail-carousel-thumbs {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 8px;
  padding: 0 8px;
}

.detail-page .detail-carousel-thumb {
  min-width: 0;
  padding: 2px;
  border: 1px solid var(--line);
  background: #fff;
}

.detail-page .detail-carousel-thumb-preview {
  display: grid;
  width: 100%;
  min-height: 0;
  aspect-ratio: 1.74;
  place-items: center;
  background: #eef3f9;
}

.detail-page .detail-carousel-thumb-preview .filter-thumb {
  width: 26px;
  height: 38px;
  font-size: 7px;
}

.detail-page .detail-carousel-thumb.is-active {
  border-color: var(--blue);
  outline: 2px solid rgba(19, 111, 242, 0.22);
}

@media (max-width: 720px) {
  .detail-page .detail-carousel-stage {
    min-height: 0;
  }
}

/* Use the same desktop image footprint as the machine-query gallery. */
@media (min-width: 1200px) {
  .detail-page .detail-hero {
    grid-template-columns: minmax(0, 708px) minmax(0, 780px);
    max-width: 1530px;
    margin-right: auto;
    margin-left: auto;
  }

  .detail-page .detail-carousel-stage {
    width: 708px;
    max-width: 100%;
  }
}

/* Homepage: company, production, product range, and new releases. */
.home-company-page {
  display: grid;
  gap: 46px;
}

.company-intro-section {
  display: grid;
  grid-template-columns: minmax(0, 1.08fr) minmax(360px, 0.92fr);
  min-height: 430px;
  overflow: hidden;
  border: 1px solid var(--line);
  background: #fff;
}

.company-intro-image {
  min-height: 430px;
  background:
    linear-gradient(90deg, rgba(17, 24, 39, 0.06), rgba(17, 24, 39, 0.12)),
    url("./assets/excavator.png") center / cover no-repeat;
}

.company-intro-copy {
  display: grid;
  align-content: center;
  gap: 16px;
  padding: 42px;
}

.home-section-kicker {
  margin: 0;
  color: #a36a00;
  font-size: 12px;
  font-weight: 800;
}

.company-intro-copy h1,
.home-section-heading h2 {
  margin: 0;
  color: #111827;
  letter-spacing: 0;
}

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

.company-intro-copy > p:not(.home-section-kicker) {
  margin: 0;
  color: #4b5563;
  font-size: 16px;
  line-height: 1.85;
}

.company-metrics {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
  margin-top: 8px;
  padding-top: 20px;
  border-top: 1px solid var(--line);
}

.company-metrics div {
  display: grid;
  gap: 4px;
}

.company-metrics strong {
  color: #111827;
  font-size: 26px;
}

.company-metrics span {
  color: var(--muted);
  font-size: 13px;
}

.home-content-section {
  min-width: 0;
}

.home-section-heading {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 24px;
  margin-bottom: 18px;
  padding-bottom: 14px;
  border-bottom: 2px solid #20242b;
}

.home-section-heading > div {
  display: grid;
  gap: 5px;
}

.home-section-heading h2 {
  font-size: 25px;
}

.home-section-heading > p {
  max-width: 620px;
  margin: 0;
  color: var(--muted);
  line-height: 1.7;
  text-align: right;
}

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

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

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

.production-card > div:last-child {
  padding: 18px;
}

.production-card strong {
  color: #111827;
  font-size: 18px;
}

.production-card p {
  margin: 8px 0 0;
  color: var(--muted);
  line-height: 1.65;
}

.production-visual {
  position: relative;
  display: flex;
  min-height: 210px;
  align-items: center;
  justify-content: center;
  gap: 12px;
  overflow: hidden;
  background:
    linear-gradient(#d8dee7 1px, transparent 1px),
    linear-gradient(90deg, #d8dee7 1px, transparent 1px),
    #edf1f5;
  background-size: 28px 28px;
}

.production-visual::before {
  position: absolute;
  right: 0;
  bottom: 24px;
  left: 0;
  height: 14px;
  background: #4b5563;
  content: "";
}

.production-visual span {
  z-index: 1;
  display: block;
  border: 3px solid #6b7280;
  background: #f4bd23;
  box-shadow: 0 8px 0 #374151;
}

.production-pleating .production-visual span {
  width: 28px;
  height: 116px;
  transform: skewY(-12deg);
}

.production-assembly .production-visual span {
  width: 74px;
  height: 104px;
  border-radius: 4px 4px 18px 18px;
}

.production-testing .production-visual span {
  width: 82px;
  height: 82px;
  border-radius: 50%;
  background: #f8fafc;
}

.production-testing .production-visual span:nth-child(2) {
  width: 112px;
  height: 126px;
  border-radius: 4px;
  background: #f4bd23;
}

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

.product-showcase-grid > a {
  display: grid;
  min-height: 250px;
  place-items: center;
  align-content: center;
  gap: 20px;
  border: 1px solid var(--line);
  color: #111827;
  background: #f8fafc;
}

.product-showcase-grid > a:hover {
  border-color: var(--yellow-dark);
  background: #fffdf4;
}

.product-showcase-grid strong {
  font-size: 17px;
}

.filter-thumb.home-product-visual {
  width: 92px;
  height: 138px;
  font-size: 16px;
}

.filter-thumb.home-product-visual.tall {
  width: 82px;
  height: 154px;
}

.filter-thumb.home-product-visual.slim {
  width: 72px;
  height: 148px;
}

.filter-thumb.home-product-visual.wide {
  width: 112px;
  height: 126px;
}

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

.new-product-card {
  position: relative;
  display: grid;
  grid-template-columns: 130px minmax(0, 1fr);
  min-height: 220px;
  align-items: center;
  gap: 20px;
  overflow: hidden;
  border: 1px solid var(--line);
  padding: 24px;
  color: inherit;
  background: #fff;
}

.new-product-card:hover {
  border-color: var(--blue);
}

.new-product-card > div {
  display: grid;
  gap: 7px;
}

.new-product-card strong {
  color: #111827;
  font-size: 19px;
}

.new-product-card small {
  color: var(--blue);
  font-weight: 700;
}

.new-product-card p {
  margin: 4px 0 0;
  color: var(--muted);
  line-height: 1.65;
}

.new-product-badge {
  position: absolute;
  top: 0;
  left: 0;
  padding: 6px 12px;
  color: #111827;
  background: var(--yellow);
  font-size: 12px;
  font-weight: 800;
}

@media (max-width: 1100px) {
  .company-intro-section {
    grid-template-columns: 1fr 1fr;
  }

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

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

@media (max-width: 760px) {
  .home-company-page {
    gap: 34px;
  }

  .company-intro-section,
  .production-grid {
    grid-template-columns: 1fr;
  }

  .company-intro-image {
    min-height: 280px;
  }

  .company-intro-copy {
    padding: 26px 22px;
  }

  .company-metrics {
    grid-template-columns: 1fr;
  }

  .home-section-heading {
    align-items: flex-start;
    flex-direction: column;
    gap: 8px;
  }

  .home-section-heading > p {
    text-align: left;
  }

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

  .new-product-card {
    grid-template-columns: 100px minmax(0, 1fr);
    padding: 20px;
  }

  .new-product-card .home-product-visual {
    transform: scale(0.82);
  }
}

@media (max-width: 480px) {
  .product-showcase-grid {
    grid-template-columns: 1fr;
  }
}
