

.install-guide {
  margin: 20px 0 0;
  padding: 14px;
  border-radius: 8px;
  background: #fff;
  border: 1px solid var(--line);
  box-shadow: 0 8px 22px rgba(16, 24, 40, 0.06);
  color: #344054;
  font-size: 14px;
  font-weight: 800;
  line-height: 1.45;
}
.install-guide b { color: var(--red); }
@media (max-width: 680px) {
  .topbar {
    display: grid !important;
    grid-template-columns: 1fr !important;
    align-items: start !important;
    gap: 8px !important;
    height: auto !important;
    min-height: 0 !important;
    max-height: none !important;
    padding: 8px 12px 9px !important;
    overflow: visible !important;
  }
  .brand { height: 34px !important; min-height: 34px !important; }
  .search-wrap {
    width: 100% !important;
    max-width: none !important;
    min-width: 0 !important;
    flex: none !important;
  }
  .search-wrap input { height: 38px !important; font-size: 14px !important; }
  .cart-toggle {
    position: static !important;
    width: 100% !important;
    min-width: 0 !important;
    min-height: 36px !important;
    height: 36px !important;
    margin: 0 !important;
    padding: 0 10px !important;
    box-shadow: none !important;
  }
  .install-guide { font-size: 12.5px; padding: 11px; }
}

:root {
  --red: #f51f2b;
  --yellow: #ffd61e;
  --blue: #00a6ff;
  --ink: #171717;
  --muted: #667085;
  --line: #e5e7eb;
  --soft: #fff8d8;
  --page: #f6f7fb;
}
* { box-sizing: border-box; }
body {
  margin: 0;
  font-family: Inter, Arial, Helvetica, sans-serif;
  color: var(--ink);
  background: var(--page);
}
a { color: inherit; text-decoration: none; }
.topbar {
  position: sticky;
  top: 0;
  z-index: 10;
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 14px;
  padding: 10px clamp(14px, 3vw, 30px);
  background: var(--red);
  color: #fff;
  border-bottom: 4px solid var(--yellow);
}
.brand {
  display: flex;
  align-items: center;
  gap: 10px;
  min-width: max-content;
  font-weight: 900;
  letter-spacing: 0;
}
.logo-mark {
  display: grid;
  place-items: center;
  width: 34px;
  height: 34px;
  background: var(--yellow);
  color: var(--red);
  border-radius: 8px;
  font-weight: 900;
}
.brand span:last-child {
  font-size: 12px;
  letter-spacing: 0;
}
.search-wrap { flex: 1 1 280px; max-width: 780px; min-width: 180px; }
.search-wrap input {
  width: 100%;
  height: 42px;
  border: 0;
  border-radius: 8px;
  padding: 0 14px;
  font-size: 15px;
  outline: 2px solid transparent;
}
.search-wrap input:focus { outline-color: var(--blue); }
.shell { width: min(1180px, calc(100% - 28px)); margin: 22px auto 44px; }
.breadcrumb { display: flex; gap: 8px; color: var(--muted); font-size: 13px; margin-bottom: 12px; }
.page-head {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  align-items: end;
  margin-bottom: 18px;
}
h1 { margin: 0; font-size: clamp(24px, 4vw, 38px); line-height: 1.05; letter-spacing: 0; }
.subtext { margin: 8px 0 0; color: var(--muted); font-size: 14px; }

.order-guide {
  margin: 0 0 16px;
  padding: 12px 14px;
  border: 1px solid #ffd61e;
  border-radius: 8px;
  background: #fff8d8;
  color: #171717;
  font-size: 14px;
  font-weight: 800;
  line-height: 1.45;
}
.order-guide b { color: var(--red); }

.count-pill {
  display: inline-flex;
  align-items: center;
  height: 34px;
  padding: 0 12px;
  border-radius: 8px;
  background: #fff;
  border: 1px solid var(--line);
  font-weight: 700;
  color: var(--muted);
  white-space: nowrap;
}
.vehicle-grid, .product-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(230px, 1fr));
  gap: 14px;
}
.vehicle-card, .product-card {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 8px;
  overflow: hidden;
  box-shadow: 0 8px 22px rgba(16, 24, 40, 0.06);
}
.vehicle-card { padding: 16px; display: grid; gap: 12px; }
.vehicle-code { color: var(--red); font-weight: 900; font-size: 15px; }
.vehicle-name { font-size: 22px; font-weight: 900; line-height: 1.15; }
.vehicle-meta { color: var(--muted); font-size: 13px; }
.open-button, .whatsapp-button, .copy-button {
  display: inline-flex;
  justify-content: center;
  align-items: center;
  min-height: 38px;
  border-radius: 8px;
  border: 0;
  padding: 0 12px;
  font-weight: 900;
  cursor: pointer;
}
.open-button { background: var(--blue); color: #fff; }
.product-image {
  display: block;
  width: 100%;
  aspect-ratio: 4 / 3;
  object-fit: contain;
  background: #f2f4f7;
  border-bottom: 1px solid var(--line);
  cursor: zoom-in;
}
.lightbox {
  position: fixed;
  inset: 0;
  z-index: 100;
  display: none;
  align-items: center;
  justify-content: center;
  padding: 18px;
  background: rgba(10, 12, 18, 0.86);
}
.lightbox.open { display: flex; }
.lightbox img {
  max-width: min(100%, 980px);
  max-height: 88vh;
  object-fit: contain;
  background: #fff;
  border-radius: 8px;
}
.lightbox button {
  position: fixed;
  top: 14px;
  right: 14px;
  width: 42px;
  height: 42px;
  border: 0;
  border-radius: 999px;
  background: #fff;
  color: #111827;
  font-size: 24px;
  font-weight: 900;
  cursor: pointer;
}
.product-info { padding: 12px; display: grid; gap: 8px; }
.code-row { display: grid; gap: 6px; }
.product-code { font-size: 17px; font-weight: 900; color: var(--red); white-space: nowrap; }
.product-color { font-size: 14px; font-weight: 900; color: #344054; line-height: 1.25; }
.badge { font-size: 11px; font-weight: 900; color: #101828; background: var(--yellow); padding: 4px 7px; border-radius: 8px; }
.product-title { font-size: 15px; font-weight: 900; line-height: 1.25; }
.meta-line { color: #344054; font-size: 13px; line-height: 1.35; }
.actions { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; margin-top: 1px; }
.actions .whatsapp-button, .actions .copy-button {
  min-height: 34px;
  border-radius: 7px;
  padding: 0 8px;
  font-size: 13px;
  line-height: 1.05;
  text-align: center;
  white-space: normal;
}
.whatsapp-button { background: #16a34a; color: #fff; }
.copy-button { background: #111827; color: #fff; }
.group-summary { display: flex; justify-content: space-between; align-items: center; gap: 8px; padding: 12px 12px 0; }
.group-count { color: var(--muted); font-size: 12px; font-weight: 800; }
.group-list { display: grid; gap: 10px; padding: 12px; }
.group-row { border-top: 1px solid var(--line); padding-top: 10px; display: grid; gap: 7px; }
.group-row:first-child { border-top: 0; padding-top: 0; }
.group-top { display: flex; align-items: flex-start; justify-content: space-between; gap: 8px; }
.group-code { color: var(--red); font-size: 16px; font-weight: 900; white-space: nowrap; }
.group-item { font-size: 14px; font-weight: 900; line-height: 1.25; }
.group-detail { color: var(--muted); font-size: 12.5px; line-height: 1.35; }
.row-actions { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.empty { display: none; padding: 28px; text-align: center; color: var(--muted); background: #fff; border: 1px dashed var(--line); border-radius: 8px; }
.hidden { display: none !important; }

.cart-toggle {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 44px;
  min-width: 128px;
  margin-left: auto;
  padding: 0 14px;
  border: 2px solid #fff;
  border-radius: 8px;
  background: var(--yellow);
  color: #111827;
  box-shadow: 0 8px 18px rgba(17, 24, 39, 0.22);
  font-weight: 900;
  cursor: pointer;
  white-space: nowrap;
}
.cart-toggle span {
  display: inline-grid;
  place-items: center;
  min-width: 26px;
  height: 26px;
  padding: 0 7px;
  border-radius: 999px;
  background: var(--red);
  color: #fff;
}
.qty-order { display: grid; grid-template-columns: 72px 1fr; gap: 8px; }
.qty-order input {
  width: 100%;
  min-height: 38px;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 0 8px;
  font-weight: 900;
  text-align: center;
}
.qty-order .add-button {
  -webkit-appearance: none;
  appearance: none;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 46px;
  width: 100%;
  border: 0;
  border-radius: 8px;
  background: linear-gradient(180deg, #17b8ff 0%, #008ee6 100%);
  color: #fff;
  box-shadow: 0 8px 16px rgba(0, 166, 255, 0.28);
  font: 900 16px/1.1 Inter, Arial, Helvetica, sans-serif;
  text-align: center;
  cursor: pointer;
  touch-action: manipulation;
}
.qty-order .add-button:hover { filter: brightness(1.04); }
.qty-order .add-button:active { transform: translateY(1px); box-shadow: 0 4px 10px rgba(0, 166, 255, 0.24); }
.cart-backdrop {
  position: fixed;
  inset: 0;
  z-index: 80;
  display: none;
  background: rgba(15, 23, 42, 0.35);
}
.cart-backdrop.open { display: block; }
.cart-panel {
  position: fixed;
  top: 0;
  right: 0;
  z-index: 90;
  width: min(420px, 100%);
  height: 100vh;
  display: grid;
  grid-template-rows: auto 1fr auto;
  background: #fff;
  box-shadow: -18px 0 42px rgba(15, 23, 42, 0.22);
  transform: translateX(100%);
  transition: transform 0.2s ease;
}
.cart-panel.open { transform: translateX(0); }
.cart-head, .cart-foot { padding: 14px; border-bottom: 1px solid var(--line); }
.cart-foot { border-top: 1px solid var(--line); border-bottom: 0; display: grid; gap: 10px; }
.cart-head { display: flex; justify-content: space-between; align-items: center; gap: 10px; }
.cart-head h2 { margin: 0; font-size: 20px; }
.cart-close {
  width: 38px;
  height: 38px;
  border: 0;
  border-radius: 8px;
  background: #f2f4f7;
  font-size: 22px;
  font-weight: 900;
  cursor: pointer;
}
.cart-items { overflow: auto; padding: 12px 14px; display: grid; align-content: start; gap: 10px; }
.cart-item { border: 1px solid var(--line); border-radius: 8px; padding: 10px; display: grid; gap: 6px; }
.cart-item-code { color: var(--red); font-weight: 900; }
.cart-item-title { font-weight: 900; font-size: 14px; }
.cart-item-meta { color: #344054; font-size: 13px; }
.cart-item-bottom { display: flex; justify-content: space-between; align-items: center; gap: 8px; }
.cart-item-bottom input { width: 76px; min-height: 34px; border: 1px solid var(--line); border-radius: 8px; text-align: center; font-weight: 900; }
.remove-button { border: 0; background: #fee2e2; color: #991b1b; border-radius: 8px; min-height: 34px; padding: 0 10px; font-weight: 900; cursor: pointer; }
.send-order { display: flex; justify-content: center; align-items: center; min-height: 44px; border-radius: 8px; background: #16a34a; color: #fff; font-weight: 900; }
.send-order.disabled { pointer-events: none; opacity: 0.45; }
.clear-order { min-height: 40px; border-radius: 8px; border: 1px solid var(--line); background: #fff; font-weight: 900; cursor: pointer; }
.cart-empty { color: var(--muted); text-align: center; padding: 22px 10px; }
.cart-note { color: var(--muted); font-size: 12px; text-align: center; font-weight: 800; }

@media (max-width: 680px) {
  .topbar { align-items: stretch; flex-direction: column; padding-bottom: 14px; }
  .brand { justify-content: space-between; }
  .cart-toggle {
    position: static;
    width: 100%;
    min-width: 0;
    margin-left: 0;
    box-shadow: 0 5px 12px rgba(17, 24, 39, 0.18);
  }
  .qty-order { grid-template-columns: 1fr; }
  .page-head { align-items: start; flex-direction: column; }
  .vehicle-grid, .product-grid { grid-template-columns: 1fr; }
  .shell { width: min(100% - 20px, 1180px); margin-top: 14px; }

  .product-info { gap: 10px; }
  .qty-order {
    display: grid;
    grid-template-columns: 74px minmax(0, 1fr);
    gap: 8px;
    align-items: stretch;
  }
  .qty-order input {
    width: 100%;
    min-height: 46px;
    justify-self: stretch;
    font-size: 16px;
  }
  .add-button {
    width: 100%;
    min-height: 46px;
    font-size: 15px;
    padding: 0 8px;
    white-space: nowrap;
    touch-action: manipulation;
    pointer-events: auto;
  }
  .actions { grid-template-columns: 1fr 1fr; }

  .order-guide {
    margin-bottom: 12px;
    padding: 10px 11px;
    font-size: 12.5px;
    line-height: 1.45;
    font-weight: 800;
    word-break: normal;
    overflow-wrap: anywhere;
  }
  .order-guide b { display: block; margin-bottom: 3px; }

  .qty-order {
    grid-template-columns: 92px minmax(0, 1fr) !important;
    gap: 10px !important;
    align-items: stretch !important;
  }
  .qty-order input {
    min-height: 46px !important;
    height: 46px !important;
    border-radius: 8px !important;
    font-size: 16px !important;
  }
  .qty-order .add-button {
    min-height: 46px !important;
    height: 46px !important;
    border-radius: 8px !important;
    background: linear-gradient(180deg, #17b8ff 0%, #008ee6 100%) !important;
    color: #fff !important;
    font-size: 15px !important;
    font-weight: 900 !important;
    box-shadow: 0 8px 16px rgba(0, 166, 255, 0.28) !important;
  }
}
