:root {
  --red: #0066cc;
  --red-2: #0052a3;
  --green: #19a45b;
  --dark: #141414;
  --text: #1c1c1c;
  --muted: #6a6a6a;
  --bg: #f6f7f9;
  --line: #e7e7ea;
  --card: #ffffff;
  --shadow: 0 14px 30px rgba(0, 0, 0, 0.08);
  --radius: 10px;
  --radius-sm: 8px;
  --container: 1400px;
  --mobile-gutter: 16px;
  --touch-min: 44px;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html,
body {
  height: 100%;
}

body {
  margin: 0;
  font-family: "Roboto Condensed", system-ui, -apple-system, Segoe UI, Roboto, Arial, sans-serif;
  color: var(--text);
  background: #fff;
  font-size: 16px;
}

body.no-scroll {
  overflow: hidden;
}

a {
  color: inherit;
  text-decoration: none;
}

.container {
  width: min(var(--container), calc(100% - 32px));
  margin: 0 auto;
  padding-left: env(safe-area-inset-left, 0);
  padding-right: env(safe-area-inset-right, 0);
}

/* Top bar */
.topbar {
  background: #fff;
  border-bottom: 1px solid var(--line);
  font-size: 15px;
}
.topbar__inner {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  gap: 12px;
  align-items: center;
  padding: 12px 0;
}
.topbar__left,
.topbar__right {
  display: flex;
  align-items: center;
  gap: 10px;
  color: #333;
}
.topbar__center {
  color: #111;
  font-weight: 700;
  text-align: center;
}
.topbar__link {
  color: #3a3a3a;
}
.topbar__link:hover {
  color: #000;
  text-decoration: underline;
}
.topbar__dot {
  opacity: 0.55;
}

/* Masthead + nav */
.masthead {
  background: #fff;
  position: sticky;
  top: 0;
  z-index: 60;
}
.masthead.is-scrolled {
  box-shadow: 0 10px 24px rgba(0, 0, 0, 0.08);
}
.masthead__inner {
  display: grid;
  grid-template-columns: auto 1fr auto;
  gap: 26px;
  align-items: center;
  padding: 16px 0;
}
.masthead__burger {
  display: none;
}
.icon-btn {
  border: 0;
  background: transparent;
  padding: 10px;
  border-radius: 10px;
  cursor: pointer;
}
.icon-btn:hover {
  background: rgba(0, 0, 0, 0.06);
}
.burger {
  width: 22px;
  height: 16px;
  position: relative;
  display: inline-block;
}
.burger::before,
.burger::after,
.burger span {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  height: 2px;
  background: #111;
  border-radius: 2px;
}
.burger::before {
  top: 0;
}
.burger span {
  top: 7px;
}
.burger::after {
  bottom: 0;
}
.brand {
  display: grid;
  line-height: 1;
  user-select: none;
}
.brand__logo-img {
  display: block;
  height: auto;
  max-height: 52px;
  width: auto;
  object-fit: contain;
}
.masthead__mid {
  display: flex;
  justify-content: center;
  gap: 26px;
  align-items: center;
}
.contact {
  display: grid;
  grid-template-columns: 44px auto;
  gap: 10px;
  align-items: center;
  min-width: 240px;
}
.contact__icon {
  width: 44px;
  height: 44px;
  border-radius: 999px;
  background: rgba(0, 0, 0, 0.08);
  display: grid;
  place-items: center;
}
.contact__icon svg {
  width: 22px;
  height: 22px;
  fill: #111;
  opacity: 0.9;
}
.contact__label {
  font-size: 12px;
  letter-spacing: 0.3px;
  color: #4a4a4a;
  font-weight: 700;
}
.contact__value {
  font-size: 22px;
  font-weight: 900;
  letter-spacing: 0.2px;
  color: #111;
  line-height: 1.05;
}
.masthead__right {
  display: flex;
  align-items: center;
  gap: 18px;
}
.location {
  display: grid;
  grid-template-columns: 44px auto;
  gap: 10px;
  align-items: center;
}
.location__icon {
  width: 44px;
  height: 44px;
  border-radius: 999px;
  background: rgba(0, 0, 0, 0.08);
  display: grid;
  place-items: center;
}
.location__icon svg {
  width: 22px;
  height: 22px;
  fill: #111;
  opacity: 0.9;
}
.location__text {
  display: grid;
  gap: 2px;
}
.location__label {
  font-size: 12px;
  letter-spacing: 0.2px;
  font-weight: 800;
  color: #333;
  line-height: 1.1;
}
.headIcons {
  display: flex;
  align-items: center;
  gap: 10px;
}
.headIcon {
  width: 44px;
  height: 44px;
  border-radius: 999px;
  border: 1px solid var(--line);
  display: grid;
  place-items: center;
  position: relative;
  background: #fff;
}
.headIcon:hover {
  background: rgba(0, 0, 0, 0.04);
}
.headIcon svg {
  width: 22px;
  height: 22px;
  fill: #111;
}
.headIcon__badge {
  position: absolute;
  top: -7px;
  right: -7px;
  height: 20px;
  min-width: 20px;
  padding: 0 6px;
  border-radius: 999px;
  background: var(--red);
  color: #fff;
  font-weight: 900;
  font-size: 12px;
  border: 2px solid #fff;
  display: grid;
  place-items: center;
}
.navline {
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
  background: #fff;
}
.navline__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 10px 0;
  gap: 14px;
}
.primary {
  display: flex;
  gap: 18px;
  flex-wrap: wrap;
}
.primary__link {
  font-weight: 800;
  letter-spacing: 0.3px;
  font-size: 15px;
  color: #111;
}
.primary__link:hover {
  color: var(--red);
}
.stock {
  font-size: 14px;
  color: #444;
  white-space: nowrap;
}
.stock__sep {
  opacity: 0.5;
  margin: 0 6px;
}

/* Mobile nav (overlay + drawer) from index.html – use styles.css */

/* Catalog layout */
.catalog {
  background: #fff;
  padding: 18px 0 34px;
}
.catalog__crumbs {
  display: flex;
  align-items: center;
  gap: 10px;
  color: #555;
  font-size: 14px;
  padding: 10px 0 16px;
}
.crumb {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 28px;
  height: 28px;
  border-radius: 8px;
  border: 1px solid var(--line);
  background: #fff;
}
.crumb:hover {
  background: rgba(0, 0, 0, 0.03);
}
.crumb__home {
  font-size: 16px;
  line-height: 1;
  transform: translateY(-1px);
}
.crumb__sep {
  opacity: 0.7;
}
.crumb__current {
  font-weight: 700;
  color: #111;
}
.catalog__grid {
  display: grid;
  grid-template-columns: 300px 1fr;
  gap: 18px;
  align-items: start;
}

/* Filters */
.filters {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: #fff;
  overflow: hidden;
}
.filters__head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding: 14px 14px;
  border-bottom: 1px solid var(--line);
}
.filters__title {
  font-weight: 900;
  letter-spacing: 0.6px;
  font-size: 16px;
  color: #111;
  position: relative;
  padding-bottom: 8px;
}
.filters__title::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: 0;
  width: 64px;
  height: 2px;
  background: var(--red);
}
.filters__clear {
  border: 0;
  background: transparent;
  color: #444;
  font-weight: 700;
  cursor: pointer;
  padding: 8px 10px;
  border-radius: 10px;
  text-decoration: none;
}
.filters__clear:hover {
  background: rgba(0, 0, 0, 0.04);
}
.filters__form {
  display: block;
}
.filters__submit-wrap {
  padding: 14px;
  border-top: 1px solid var(--line);
}
.filters__apply {
  width: 100%;
  padding: 12px 16px;
  font-weight: 800;
  font-size: 14px;
  color: #fff;
  background: var(--red);
  border: 0;
  border-radius: var(--radius-sm);
  cursor: pointer;
}
.filters__apply:hover {
  background: var(--red-2);
}
.filter {
  border-top: 1px solid var(--line);
}
.filter:first-of-type {
  border-top: 0;
}
.filter__summary {
  list-style: none;
  padding: 12px 14px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  font-weight: 900;
  letter-spacing: 0.3px;
  color: #111;
  background: #fff;
}
.filter__summary::-webkit-details-marker {
  display: none;
}
.filter__summary::after {
  content: "▾";
  font-weight: 900;
  color: #111;
  opacity: 0.75;
}
details[open] > .filter__summary::after {
  transform: rotate(180deg);
}
.filter__body {
  padding: 10px 14px 14px;
  display: grid;
  gap: 10px;
}
.filter__body--scroll {
  max-height: 180px;
  overflow: auto;
}
.check {
  display: flex;
  gap: 10px;
  align-items: center;
  font-size: 15px;
  color: #222;
}
.check input {
  width: 16px;
  height: 16px;
  accent-color: var(--red);
}
.price__range {
  display: grid;
  gap: 10px;
}
.price__vals {
  display: flex;
  gap: 10px;
  align-items: center;
  justify-content: space-between;
}
.price__box {
  display: inline-flex;
  align-items: baseline;
  gap: 6px;
  border: 1px solid var(--line);
  border-radius: 10px;
  padding: 8px 10px;
  min-width: 110px;
  justify-content: center;
  background: #fff;
}
.price__box span {
  font-weight: 900;
  color: #111;
}
.price__box small {
  color: #666;
  font-weight: 700;
}

/* Results / toolbar */
.results__head {
  display: grid;
  gap: 10px;
  padding: 8px 0 14px;
}
.results__title {
  margin: 0;
  font-size: 40px;
  letter-spacing: 0.4px;
  text-align: center;
  font-weight: 700;
}
.results__toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  flex-wrap: wrap;
  border-top: 1px solid var(--line);
  padding-top: 12px;
}
.chip {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: #1a4a7a;
  font-size: 14px;
}
.chip__count {
  display: inline-grid;
  place-items: center;
  width: 18px;
  height: 18px;
  border-radius: 999px;
  background: var(--red);
  color: #fff;
  font-size: 12px;
  font-weight: 900;
}
.toolbar {
  display: flex;
  align-items: center;
  gap: 10px;
}
.toolbar__field {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  border: 1px solid var(--line);
  border-radius: 10px;
  padding: 6px 10px;
  background: #fff;
}
.toolbar__label {
  font-size: 13px;
  color: #555;
  font-weight: 700;
}
.toolbar__select {
  border: 0;
  background: transparent;
  font: inherit;
  font-weight: 700;
  color: #111;
  cursor: pointer;
  padding: 6px 0;
}

/* Cards */
.products {
  display: grid;
  gap: 22px;
  align-items: stretch;
}
.products--catalog {
  grid-template-columns: repeat(4, 1fr);
}
.card {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--card);
  overflow: hidden;
  box-shadow: 0 6px 18px rgba(0, 0, 0, 0.04);
  position: relative;
  cursor: pointer;
  display: grid;
  grid-template-rows: auto 220px auto auto 60px auto auto auto;
  width: 100%;
  min-width: 0;
  height: 500px;
  transition: transform 180ms ease, box-shadow 180ms ease, border-color 180ms ease;
}

/* Full-card link: clicking anywhere on the card (except actions) opens the product page */
.card__link {
  position: absolute;
  inset: 0;
  z-index: 0;
  text-indent: -9999px;
  overflow: hidden;
}

.card__ribbons,
.card__image,
.card__brand,
.card__title,
.card__msrp,
.card__price {
  position: relative;
  z-index: 1;
  pointer-events: none;
}

.card__actions {
  position: relative;
  z-index: 2;
}

.card::after {
  content: "";
  position: absolute;
  inset: 0;
  background: rgba(0, 102, 204, 0.035);
  opacity: 0;
  pointer-events: none;
  transition: opacity 180ms ease, background 180ms ease;
}
.card:hover {
  border-color: rgba(0, 102, 204, 0.55);
  box-shadow: 0 16px 34px rgba(0, 0, 0, 0.1);
}
.card:hover::after {
  opacity: 1;
}
.card:active {
  border-color: rgba(0, 82, 163, 0.75);
  box-shadow: 0 10px 22px rgba(0, 0, 0, 0.12);
}
.card:active::after {
  opacity: 1;
  background: rgba(0, 102, 204, 0.08);
}
.card__ribbons {
  padding: 10px 10px 0;
  display: grid;
  gap: 6px;
}
.ribbon {
  display: inline-flex;
  width: fit-content;
  padding: 6px 10px;
  border-radius: 4px;
  font-weight: 900;
  font-size: 12px;
  letter-spacing: 0.2px;
  color: #1c1c1c;
}
.ribbon--red {
  background: var(--red, #c0392b);
  color: #fff;
}
.ribbon--mint {
  background: #b9f0d6;
  color: #0b5c3a;
}
.ribbon--violet {
  background: #d8c7ff;
  color: #3c1f7a;
}
.ribbon--orange {
  background: #ffc59b;
  color: #7b2c00;
}
.ribbon--blue {
  background: #c7e0ff;
  color: #0a3d7a;
}
.card__image {
  padding: 10px 12px 0;
  display: grid;
  place-items: center;
  min-height: 210px;
  overflow: hidden;
}
.card__image img {
  display: block;
  max-width: 100%;
  max-height: 200px;
  width: auto;
  height: auto;
  object-fit: contain;
  border-radius: 14px;
}
.card__image img.card__img--wide {
  max-height: 170px;
}
.product-img {
  width: 100%;
  height: 102px;
  border-radius: 14px;
  background: radial-gradient(180px 70px at 18% 18%, rgba(255, 255, 255, 0.95), rgba(255, 255, 255, 0.18)),
    linear-gradient(135deg, #f1f2f5, #dfe2e8);
  border: 1px solid #d5d7dd;
  position: relative;
}
.product-img::after {
  content: "";
  position: absolute;
  left: 22px;
  right: 22px;
  top: 38px;
  height: 8px;
  border-radius: 999px;
  background: rgba(0, 0, 0, 0.06);
}
.product-img--alt {
  background: radial-gradient(180px 70px at 18% 18%, rgba(255, 255, 255, 0.95), rgba(255, 255, 255, 0.12)),
    linear-gradient(135deg, #f4f6fa, #d7deec);
}
.product-img--wide {
  height: 86px;
}
.card__stars {
  display: flex;
  justify-content: center;
  gap: 2px;
  color: #f6c300;
  padding: 8px 0 4px;
}
.star {
  font-size: 16px;
}
.card__brand {
  text-align: center;
  font-weight: 700;
  color: #333;
  margin-bottom: 6px;
}
.card__title {
  font-size: 15px;
  padding: 0 12px;
  margin: 0;
  color: #1c1c1c;
  line-height: 1.25;
  height: 3.75em;
  min-height: 54px;
  overflow: hidden;
  text-overflow: ellipsis;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
}
.card__msrp {
  padding: 10px 12px 0;
  color: #8b8b8b;
  font-size: 12px;
}
.card__price {
  padding: 8px 12px 0;
  font-size: 24px;
  color: var(--red);
  display: flex;
  gap: 8px;
  align-items: baseline;
  flex-wrap: wrap;
}
.card__price span {
  font-size: 20px;
  color: var(--red);
  font-weight: 800;
}
.card__actions {
  padding: 12px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 10px;
}
.buy {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  height: 44px;
  padding: 0 14px 0 10px;
  border-radius: 10px;
  border: 0;
  cursor: pointer;
  background: #12a857;
  color: #fff;
  font-weight: 900;
  letter-spacing: 0.4px;
}
.buy:hover {
  filter: brightness(0.98);
}
.buy__icon {
  width: 34px;
  height: 34px;
  border-radius: 9px;
  background: rgba(0, 0, 0, 0.12);
  display: grid;
  place-items: center;
}
.buy__icon svg {
  width: 18px;
  height: 18px;
  fill: #fff;
}
/* Pagination */
.results__footer {
  margin-top: 16px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  flex-wrap: wrap;
}
.pagination {
  display: flex;
  gap: 14px;
  align-items: center;
  flex-wrap: wrap;
  margin-top: 24px;
  padding-top: 20px;
  border-top: 1px solid var(--line);
}
.pagination__link {
  display: inline-flex;
  align-items: center;
  padding: 8px 14px;
  border-radius: var(--radius-sm);
  border: 1px solid var(--line);
  background: #fff;
  color: var(--text);
  font-weight: 700;
  text-decoration: none;
  transition: background 0.15s ease, border-color 0.15s ease;
}
.pagination__link:hover {
  background: var(--bg);
  border-color: var(--red);
  color: var(--red);
}
.pagination__info {
  font-size: 14px;
  color: var(--muted);
  font-weight: 600;
}
.pageBtn {
  width: 34px;
  height: 34px;
  border-radius: 8px;
  border: 1px solid var(--line);
  display: grid;
  place-items: center;
  color: #111;
  background: #fff;
  font-weight: 800;
}
.pageBtn:hover {
  background: rgba(0, 0, 0, 0.03);
}
.pageBtn.is-active {
  background: var(--red);
  color: #fff;
  border-color: var(--red);
}
.pageDots {
  color: #777;
  font-weight: 800;
}
.results__count {
  color: #555;
  font-size: 14px;
  white-space: normal;
  overflow-wrap: anywhere;
}
.results__desc {
  margin: 16px 0 0;
  color: #333;
  line-height: 1.55;
  font-size: 15px;
}

/* Reveal (used by script.js) */
.reveal {
  opacity: 0;
  transform: translateY(14px);
  transition: opacity 520ms ease, transform 520ms ease;
  transition-delay: var(--reveal-delay, 0ms);
}
.reveal.is-visible {
  opacity: 1;
  transform: translateY(0);
}
@media (prefers-reduced-motion: reduce) {
  * {
    scroll-behavior: auto !important;
    transition: none !important;
    animation: none !important;
  }
}

/* Footer */
.footer {
  background: #0f0f10;
  color: #e9e9e9;
}
.footer__nav-wrap {
  padding: 28px 0;
}
.footer__nav {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: 10px 24px;
}
.footer__link {
  color: #cfcfd3;
  font-size: 15px;
  font-weight: 700;
  letter-spacing: 0.3px;
}
.footer__link:hover {
  color: #fff;
  text-decoration: underline;
}
.footer a {
  color: #cfcfd3;
  font-size: 14px;
}
.footer a:hover {
  color: #fff;
  text-decoration: underline;
}
.footer__bottom {
  border-top: 1px solid rgba(255, 255, 255, 0.08);
  padding: 12px 0;
}
.footer__bottomInner {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  align-items: center;
  color: #b8b8be;
  font-size: 13px;
}
.footer__brand {
  font-weight: 900;
  letter-spacing: 2px;
  color: #fff;
  opacity: 0.85;
}

/* To top */
.toTop {
  position: fixed;
  right: 18px;
  bottom: 18px;
  height: 44px;
  width: 44px;
  border-radius: 999px;
  border: 0;
  background: #fff;
  box-shadow: var(--shadow);
  cursor: pointer;
  font-weight: 900;
  z-index: 65;
}
.toTop:hover {
  transform: translateY(-1px);
}

@media (max-width: 1150px) {
  .products--catalog {
    grid-template-columns: repeat(3, 1fr);
  }
}
@media (max-width: 920px) {
  .topbar__inner {
    grid-template-columns: 1fr;
    text-align: center;
  }
  .topbar__left,
  .topbar__right {
    justify-content: center;
    flex-wrap: wrap;
  }
  .masthead__inner {
    grid-template-columns: auto 1fr auto;
  }
  .masthead__mid {
    justify-content: flex-start;
    gap: 14px;
  }
  .contact {
    min-width: 0;
  }
  .contact__value {
    font-size: 18px;
  }
  .location {
    display: none;
  }
  .navline__inner {
    gap: 10px;
  }
  .primary {
    display: none;
  }
  .catalog__grid {
    grid-template-columns: 1fr;
  }
}
@media (max-width: 760px) {
  .container {
    width: calc(100% - var(--mobile-gutter) * 2);
    max-width: 100%;
  }
  .topbar__inner { padding: 10px 0; }
  .topbar__center { font-size: 13px; }
  .masthead__inner { padding: 12px 0; gap: 12px; }
  .masthead__burger {
    display: inline-grid;
    min-width: var(--touch-min);
    min-height: var(--touch-min);
  }
  .masthead__mid { display: none; }
  .brand__logo-img { max-height: 42px; }
  .headIcon {
    min-width: var(--touch-min);
    min-height: var(--touch-min);
  }
  .navline__inner { padding: 8px 0; flex-wrap: wrap; justify-content: center; }
  .stock { font-size: 13px; white-space: normal; }
  .filters { display: none; }
  .catalog__grid { gap: 14px; }

  /* Prevent toolbar from forcing horizontal overflow on very small screens */
  .results { min-width: 0; }
  .results__toolbar {
    flex-direction: column;
    align-items: stretch;
  }
  .chip {
    width: 100%;
    min-width: 0;
    white-space: normal;
    flex-wrap: wrap;
  }
  .toolbar {
    width: 100%;
    min-width: 0;
    flex-wrap: wrap;
    justify-content: space-between;
  }
  .toolbar__field {
    flex: 1 1 140px;
    min-width: 0;
    justify-content: space-between;
  }
  .toolbar__select {
    max-width: 100%;
    min-width: 0;
  }
  .results__footer {
    flex-direction: column;
    align-items: stretch;
  }
  .pagination {
    flex-wrap: wrap;
    justify-content: center;
  }
  .results__count {
    text-align: center;
  }

  .products--catalog {
    grid-template-columns: 1fr;
    gap: 16px;
  }
  .card {
    height: auto;
    min-height: 0;
    grid-template-rows: auto auto auto auto auto auto auto auto;
  }
  .card__ribbons { padding: 8px 10px 0; }
  .card__title { font-size: 14px; padding: 0 10px; -webkit-line-clamp: 3; }
  .card__price { font-size: 20px; padding: 6px 10px 0; }
  .card__actions { padding: 10px; }
  .buy { min-height: var(--touch-min); flex: 1; }
  .results__title {
    font-size: 26px;
    margin: 12px 0 14px;
  }
  .footer__nav-wrap { padding: 22px 0; }
  .footer__nav { gap: 8px 18px; }
  .footer__link { font-size: 14px; }
  .footer__bottomInner { flex-wrap: wrap; justify-content: center; text-align: center; }
  .toTop {
    right: calc(18px + env(safe-area-inset-right, 0));
    bottom: calc(18px + env(safe-area-inset-bottom, 0));
    min-width: var(--touch-min);
    min-height: var(--touch-min);
  }
}
@media (max-width: 440px) {
  .container { width: calc(100% - 20px); }
  .brand__logo-img { max-height: 38px; }
  .results__title { font-size: 22px; margin: 10px 0 12px; }
  .card__title { font-size: 13px; }
  .card__price { font-size: 18px; }
  .footer__nav-wrap { padding: 18px 0; }
  .footer__link { font-size: 13px; }
}

