/* Techtonix shared components — loaded after tokens.css and style.css.
   Anything reused across 2+ public pages lives here instead of being re-implemented per page. */

/* ---------- Page-load preloader (markup injected by header.php) ---------- */
#tx-preloader {
  position: fixed;
  inset: 0;
  z-index: 9999;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--tx-bg);
  transition: opacity .35s ease, visibility .35s ease;
}
#tx-preloader.tx-preloader--hidden {
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
}
.tx-preloader__stage {
  position: relative;
  width: 84px;
  height: 84px;
  display: flex;
  align-items: center;
  justify-content: center;
}
.tx-preloader__ring {
  position: absolute;
  inset: 0;
  border-radius: 50%;
  border: 3px solid var(--tx-border);
  border-top-color: var(--tx-accent);
  border-right-color: var(--tx-accent-2);
  animation: tx-preloader-spin .9s linear infinite;
}
.tx-preloader__icon {
  width: 50px;
  height: 50px;
  object-fit: contain;
  animation: tx-preloader-pulse 1.4s ease-in-out infinite;
}
@keyframes tx-preloader-spin {
  to { transform: rotate(360deg); }
}
@keyframes tx-preloader-pulse {
  0%, 100% { transform: scale(1); opacity: 1; }
  50% { transform: scale(.86); opacity: .7; }
}
@media (prefers-reduced-motion: reduce) {
  .tx-preloader__ring { animation: none; opacity: .7; }
  .tx-preloader__icon { animation: none; }
}

/* ---------- Nav ---------- */
.custom-navbar {
  background: var(--tx-surface) !important;
  border-bottom: 1px solid var(--tx-border);
}
.custom-navbar .navbar-brand {
  color: var(--tx-text);
}
.custom-navbar .custom-navbar-nav li a {
  color: var(--tx-text) !important;
  opacity: 1 !important;
}
.custom-navbar .custom-navbar-nav li a:hover,
.custom-navbar .custom-navbar-nav li.active a {
  color: var(--tx-accent) !important;
}
@media (min-width: 768px) {
  .custom-navbar .custom-navbar-nav li a:before {
    background: var(--tx-accent);
  }
}
.custom-navbar .lang-toggle .text-white-50 {
  color: var(--tx-text-muted) !important;
}
@media (max-width: 767px) {
  .custom-navbar .navbar-collapse {
    background: var(--tx-surface);
    border: 1px solid var(--tx-border);
    border-radius: var(--tx-radius-md);
    box-shadow: var(--tx-shadow-md);
    padding: var(--tx-space-2) var(--tx-space-3);
    margin-top: var(--tx-space-3);
  }
  .custom-navbar .custom-navbar-nav li {
    border-bottom: 1px solid var(--tx-border);
  }
  .custom-navbar .custom-navbar-nav li:last-child,
  .custom-navbar .custom-navbar-nav li.lang-toggle {
    border-bottom: none;
  }
  .custom-navbar .custom-navbar-nav li a {
    padding: var(--tx-space-3) var(--tx-space-1);
    display: block;
  }
  .custom-navbar .custom-navbar-nav li.active a {
    font-weight: var(--tx-fw-semibold);
  }
}

/* ---------- Fixed bottom tab bar (mobile only) ---------- */
.tx-bottom-nav {
  position: fixed;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 1040;
  display: flex;
  background: var(--tx-surface);
  border-top: 1px solid var(--tx-border);
  box-shadow: 0 -2px 12px rgba(20, 20, 20, 0.06);
  padding-bottom: env(safe-area-inset-bottom, 0);
}
.tx-bottom-nav__item {
  flex: 1 1 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 1px;
  padding: 6px 4px 5px;
  color: var(--tx-text-muted);
  text-decoration: none !important;
  font-size: 9px;
  font-weight: var(--tx-fw-medium);
}
.tx-bottom-nav__item i { font-size: .9rem; }
.tx-bottom-nav__item.active { color: var(--tx-accent); }
/* Every public page includes this bar via partials/nav.php, so this can apply
   unconditionally on mobile widths rather than depending on :has() (not supported on
   older Android WebViews, which this phone-first site can't assume away). */
@media (max-width: 767px) {
  body { padding-bottom: 48px; }
}

/* ---------- Mobile header icon row (theme / language / search) ---------- */
.tx-nav-icons {
  display: flex;
  align-items: center;
  gap: 4px;
  margin-left: auto;
  margin-right: var(--tx-space-2);
}
.tx-nav-icon-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 38px;
  height: 38px;
  background: none;
  border: none;
  padding: 0;
  color: var(--tx-text);
  font-size: 1.1rem;
  text-decoration: none !important;
}
.tx-nav-icon-btn:hover { color: var(--tx-accent); }
/* Language button carries text alongside its icon (current language code), so it can't be
   the same fixed square as the icon-only theme/search buttons — width:auto + a bit of
   padding instead. */
.tx-nav-lang-btn {
  width: auto;
  padding: 0 10px;
  gap: 4px;
  font-size: .78rem;
  font-weight: var(--tx-fw-semibold);
  border-radius: var(--tx-radius-pill);
  background: var(--tx-bg-alt);
}
.tx-nav-lang-btn i { font-size: .9rem; }

/* Search popup anchored just under the header (near the search icon that opens it),
   not Bootstrap's default vertical-center — a search box floating in the middle of the
   screen read as disconnected from the icon that triggered it. */
.tx-search-modal-dialog {
  margin-top: 64px;
}

/* ---------- Logo (real brand lockup image — wordmark + tagline baked into the PNG,
   replacing the earlier placeholder inline-SVG hexagon mark) ---------- */
.tx-logo {
  display: flex;
  align-items: center;
  text-decoration: none !important;
}
.tx-logo__img {
  height: 32px;
  width: auto;
  display: block;
}
@media (max-width: 576px) {
  .tx-logo__img { height: 26px; }
}

/* ---------- Buttons ---------- */
.btn-tx-primary,
.btn-tx-secondary,
.btn-tx-ghost,
.btn-tx-outline,
.btn-tx-whatsapp {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: var(--tx-space-2);
  font-weight: var(--tx-fw-semibold);
  padding: 12px 28px;
  border-radius: var(--tx-radius-pill);
  border: 1px solid transparent;
  transition: background .2s ease, color .2s ease, border-color .2s ease, box-shadow .2s ease;
  text-decoration: none;
}
.btn-tx-primary {
  background: var(--tx-accent);
  color: var(--tx-text-on-dark);
}
.btn-tx-primary:hover { background: var(--tx-accent-hover); color: var(--tx-text-on-dark); }

.btn-tx-secondary {
  background: var(--tx-text);
  color: var(--tx-text-on-dark);
}
.btn-tx-secondary:hover { background: #000; color: var(--tx-text-on-dark); }

.btn-tx-ghost {
  background: transparent;
  color: var(--tx-text);
  border-color: var(--tx-border);
}
.btn-tx-ghost:hover { border-color: var(--tx-accent); color: var(--tx-accent); }

.btn-tx-outline {
  background: var(--tx-surface);
  color: var(--tx-text);
  border-color: var(--tx-border);
}
.btn-tx-outline:hover { border-color: var(--tx-accent); color: var(--tx-accent); }

.btn-tx-whatsapp {
  background: var(--tx-whatsapp);
  color: #ffffff;
}
.btn-tx-whatsapp:hover { background: var(--tx-whatsapp-dark); color: #ffffff; }

.btn-tx-primary:focus-visible,
.btn-tx-secondary:focus-visible,
.btn-tx-ghost:focus-visible,
.btn-tx-outline:focus-visible,
.btn-tx-whatsapp:focus-visible {
  outline: none;
  box-shadow: var(--tx-shadow-focus);
}

/* ---------- Product card (replaces .product-item / .product-item-sm / .similar-product) ---------- */
.tx-product-card {
  display: block;
  background: var(--tx-surface);
  border: 1px solid var(--tx-border);
  border-radius: var(--tx-radius-md);
  overflow: hidden;
  text-decoration: none;
  color: var(--tx-text);
  transition: box-shadow .2s ease, transform .2s ease;
  height: 100%;
}
.tx-product-card:hover {
  box-shadow: var(--tx-shadow-md);
  transform: translateY(-2px);
  color: var(--tx-text);
}
.tx-product-card__image-wrap {
  display: block;
  position: relative;
  aspect-ratio: 1 / 1;
  background: var(--tx-surface-2);
  overflow: hidden;
}
.tx-product-card__image {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}
.tx-product-card__badges {
  position: absolute;
  top: var(--tx-space-2);
  left: var(--tx-space-2);
  display: flex;
  flex-direction: column;
  gap: 4px;
}
.tx-pill-badge {
  display: inline-block;
  font-size: 9px;
  font-weight: var(--tx-fw-semibold);
  padding: 2px 6px;
  border-radius: var(--tx-radius-sm);
  color: #fff;
  line-height: 1.4;
}
.tx-pill-badge--new { background: var(--tx-text); }
.tx-pill-badge--popular { background: var(--tx-accent); }
.tx-product-card__arrow {
  position: absolute;
  bottom: var(--tx-space-2);
  right: var(--tx-space-2);
  width: 28px;
  height: 28px;
  border-radius: 50%;
  background: rgba(255,255,255,.92);
  color: var(--tx-text);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: .7rem;
  box-shadow: var(--tx-shadow-sm);
}
.tx-product-card__body {
  display: block;
  padding: var(--tx-space-2) var(--tx-space-3) var(--tx-space-3);
}
.tx-product-card__eyebrow {
  display: block;
  font-size: 9px;
  font-weight: var(--tx-fw-semibold);
  color: var(--tx-accent);
  margin-bottom: 1px;
  line-height: 1.3;
}
.tx-product-card__title {
  display: block;
  font-size: var(--tx-fs-sm);
  font-weight: var(--tx-fw-semibold);
  color: var(--tx-text);
  line-height: 1.25;
  margin-bottom: 2px;
  overflow: hidden;
  text-overflow: ellipsis;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  min-height: 2.1em;
}
.tx-product-card__specs {
  display: block;
  font-size: 11px;
  line-height: 1.3;
  color: var(--tx-text-muted);
  margin-bottom: 2px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.tx-product-card__price {
  display: block;
  font-size: var(--tx-fs-base);
  font-weight: var(--tx-fw-bold);
  color: var(--tx-accent);
  line-height: 1.2;
}
.tx-product-card__stock {
  display: flex;
  align-items: center;
  gap: 4px;
  font-size: 10px;
  font-weight: var(--tx-fw-medium);
  margin-top: 2px;
}
.tx-dot {
  width: 5px;
  height: 5px;
  border-radius: 50%;
  flex-shrink: 0;
}
.tx-product-card__stock--in { color: var(--tx-success); }
.tx-product-card__stock--in .tx-dot { background: var(--tx-success); }
.tx-product-card__stock--out { color: var(--tx-danger); }
.tx-product-card__stock--out .tx-dot { background: var(--tx-danger); }

/* Homepage rail size — same shell, tighter layout, not a separate component */
.tx-product-card--sm {
  display: flex;
  flex-direction: row;
  align-items: stretch;
}
.tx-product-card--sm .tx-product-card__image-wrap {
  flex: 0 0 96px;
  width: 96px;
  aspect-ratio: 1 / 1;
}
.tx-product-card--sm .tx-product-card__body {
  padding: var(--tx-space-2) var(--tx-space-3);
  display: flex;
  flex-direction: column;
  justify-content: center;
}
.tx-product-card--sm .tx-product-card__title {
  -webkit-line-clamp: 2;
  min-height: 0;
}

/* ---------- Section rhythm ---------- */
.tx-section {
  padding-block: var(--tx-space-8);
  background: var(--tx-bg);
}
.tx-section--alt {
  background: var(--tx-bg-alt);
}
@media (max-width: 576px) {
  /* 64px of padding above and below every section adds up fast on a phone — six sections
     on the homepage alone meant ~768px of pure whitespace before any real content. Cut to
     something that still reads as a section break without pushing everything off-screen. */
  .tx-section { padding-block: var(--tx-space-5); }
}

/* ---------- Info / stat card (trust bar, why-choose, contact info cards) ----------
   Sized to match the hero's compact mobile text (eyebrow ~9px, paragraph ~.8rem) —
   these cards carry one icon + a short title + a line of body text, not a full section,
   so they shouldn't compete with real content for space. Category tiles are a separate
   component (.tx-category-tile) and are deliberately not touched here. */
.tx-info-card {
  background: var(--tx-surface);
  border: 1px solid var(--tx-border);
  border-radius: var(--tx-radius-sm);
  padding: var(--tx-space-3);
  height: 100%;
}
.tx-info-card__icon {
  width: 32px;
  height: 32px;
  border-radius: var(--tx-radius-sm);
  background: var(--tx-accent-2-soft);
  color: var(--tx-accent-2-hover);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: .9rem;
  margin-bottom: var(--tx-space-2);
}
/* Alternate magenta/turquoise icon chips across a row — each card is the lone child of its
   own grid column, so the alternation is keyed off the column's position, not the card's.
   Every step uses a direct-child combinator deliberately: a plain descendant selector here
   would also match through an unrelated ANCESTOR row higher up the tree (e.g. a 4-card grid
   nested inside one column of an outer 2-column row) and make every icon match via that
   outer row's own odd/even position instead of the inner grid's — direct-child at each step
   keeps the match scoped to the one row actually doing the alternating. */
.row > div:nth-child(odd) > .tx-info-card > .tx-info-card__icon {
  background: var(--tx-accent-soft);
  color: var(--tx-accent);
}
.tx-info-card__title {
  font-size: var(--tx-fs-sm);
  font-weight: var(--tx-fw-semibold);
  color: var(--tx-text);
  margin-bottom: 2px;
}
.tx-info-card a,
.tx-pdp-panel a {
  color: var(--tx-text);
}
.tx-info-card a:hover,
.tx-pdp-panel a:hover {
  color: var(--tx-accent);
}
.tx-info-card__body {
  font-size: var(--tx-fs-xs);
  color: var(--tx-text-muted);
  margin-bottom: 0;
}
/* This must come after the base .tx-info-card* rules above — same specificity, so with
   non-media and media rules tied, source order decides, and a media block placed earlier
   in the file loses to a later non-media rule at every width. */
@media (max-width: 576px) {
  .tx-info-card { padding: var(--tx-space-2); }
  .tx-info-card__icon { width: 26px; height: 26px; font-size: .75rem; margin-bottom: var(--tx-space-1); }
  .tx-info-card__title { font-size: .78rem; }
  .tx-info-card__body { font-size: .72rem; }
}

/* ---------- WhatsApp float (moved out of whatsapp-float.php's own inline <style>,
   same separate pulse-span technique as before — only colors/shadow tokenized) ---------- */
.tx-whatsapp-float {
  position: fixed;
  bottom: 22px;
  right: 22px;
  width: 58px;
  height: 58px;
  border-radius: 50%;
  background: var(--tx-whatsapp);
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 28px;
  box-shadow: var(--tx-shadow-md);
  z-index: 1050;
  transition: transform .15s ease, box-shadow .15s ease;
}
/* productdetails.php can render this as a <button> (modal-trigger or disabled state) instead
   of an <a> — strip the browser's default button chrome so it looks identical either way. */
button.tx-whatsapp-float {
  border: none;
  padding: 0;
  font-family: inherit;
}
.tx-whatsapp-float:hover {
  color: #fff;
  background: var(--tx-whatsapp-dark);
  transform: scale(1.08);
}
.tx-whatsapp-float-pulse {
  position: absolute;
  inset: 0;
  border-radius: 50%;
  background: var(--tx-whatsapp);
  opacity: .55;
  animation: tx-whatsapp-pulse 2.2s ease-out infinite;
  z-index: -1;
}
@keyframes tx-whatsapp-pulse {
  0%   { transform: scale(1); opacity: .55; }
  100% { transform: scale(1.9); opacity: 0; }
}
@media (max-width: 576px) {
  .tx-whatsapp-float { width: 52px; height: 52px; font-size: 25px; right: 16px; }
}
@media (max-width: 767px) {
  /* Lifted clear of the fixed bottom tab bar (58px) rather than sitting on top of it. */
  .tx-whatsapp-float { bottom: calc(58px + env(safe-area-inset-bottom, 0) + 14px); }
}

/* ---------- Sort + Filter row ---------- */
.tx-sort-filter-row {
  display: flex;
  align-items: center;
  gap: var(--tx-space-3);
  margin-bottom: var(--tx-space-3);
}
.tx-sort-filter-row .dropdown-sort {
  margin-bottom: 0;
  flex: 1 1 auto;
}
.tx-sort-filter-row .dropbtn {
  width: 100%;
  min-width: 0;
}
.tx-filter-btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  white-space: nowrap;
  background: var(--tx-surface);
  color: var(--tx-text);
  border: 1px solid var(--tx-border);
  border-radius: var(--tx-radius-sm);
  padding: 10px 16px;
  font-size: var(--tx-fs-sm);
  font-weight: var(--tx-fw-semibold);
  box-shadow: var(--tx-shadow-sm);
}
.tx-filter-btn:hover { border-color: var(--tx-accent); color: var(--tx-accent); }
@media (max-width: 576px) {
  .tx-sort-filter-row { gap: var(--tx-space-2); }
  .tx-filter-btn { padding: 9px 12px; font-size: 13px; }
}

/* ---------- Sort dropdown (relocated from header.php, which is <head>-only and had no
   business holding page-specific component CSS; stray #007bff — not a brand color — fixed
   to var(--tx-accent) in the process) ---------- */
.dropdown-sort {
  position: relative;
  display: inline-block;
  margin-bottom: 12px;
  font-family: var(--tx-font-family, "Inter", sans-serif);
  font-size: var(--tx-fs-sm);
}
.dropbtn {
  background-color: var(--tx-surface);
  color: var(--tx-text);
  padding: 6px 14px;
  font-size: var(--tx-fs-sm);
  border: 1px solid var(--tx-border);
  border-radius: var(--tx-radius-sm);
  cursor: pointer;
  transition: all .2s;
  min-width: 140px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  box-shadow: var(--tx-shadow-sm);
}
.dropbtn:hover {
  border-color: var(--tx-accent);
  box-shadow: var(--tx-shadow-md);
}
.arrow {
  display: inline-block;
  margin-left: 6px;
  transition: transform .2s;
}
.dropdown-sort:hover .arrow,
.dropdown-sort.is-open .arrow { transform: rotate(180deg); }
.dropdown-content {
  display: none;
  position: absolute;
  background-color: var(--tx-surface);
  min-width: 160px;
  box-shadow: var(--tx-shadow-md);
  border-radius: var(--tx-radius-sm);
  z-index: 1000;
  margin-top: 6px;
  overflow: hidden;
}
.dropdown-content a {
  color: var(--tx-text);
  padding: 10px 14px;
  text-decoration: none;
  display: block;
  font-size: var(--tx-fs-sm);
  transition: background .2s;
}
.dropdown-content a:hover,
.dropdown-content a.active {
  background-color: var(--tx-accent);
  color: #fff;
}
/* :hover keeps this working for mouse users; .is-open (toggled by JS on click/tap)
   is what makes it actually usable on phones, where :hover doesn't fire reliably */
.dropdown-sort:hover .dropdown-content,
.dropdown-sort.is-open .dropdown-content { display: block; }
.desktop-space { display: inline; }

/* ---------- Filter pills ---------- */
.filter-buttons { margin-top: 20px; }
.btn-filter {
  font-weight: var(--tx-fw-semibold);
  font-size: var(--tx-fs-sm);
  padding: 8px 18px;
  border-radius: var(--tx-radius-sm);
  margin: 4px;
  background-color: var(--tx-surface);
  color: var(--tx-text);
  border: 1px solid var(--tx-border);
  transition: all .2s ease;
}
.btn-filter:hover { background-color: var(--tx-accent); color: #fff; border-color: var(--tx-accent); }
.btn-filter.active { background-color: var(--tx-accent); color: #fff; border-color: var(--tx-accent); }
.btn-filter:focus { outline: none; box-shadow: var(--tx-shadow-focus); }

/* ---------- Extra shop filters: in-stock toggle + price range ---------- */
.tx-extra-filters {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: var(--tx-space-3);
  margin-top: var(--tx-space-3);
  padding-top: var(--tx-space-3);
  border-top: 1px solid var(--tx-border);
}
.tx-price-range { display: flex; align-items: center; gap: 6px; }
.tx-price-range input[type="number"] {
  width: 92px;
  padding: 6px 8px;
  border: 1px solid var(--tx-border);
  border-radius: var(--tx-radius-sm);
  font-size: var(--tx-fs-sm);
  color: var(--tx-text);
}
.tx-price-range input[type="number"]:focus { outline: none; border-color: var(--tx-accent); }
.tx-price-range__sep { color: var(--tx-text-muted); font-size: var(--tx-fs-sm); }
.tx-price-apply {
  padding: 6px 12px;
  border-radius: var(--tx-radius-sm);
  border: 1px solid var(--tx-accent);
  background: var(--tx-accent-soft);
  color: var(--tx-accent);
  font-size: var(--tx-fs-sm);
  font-weight: var(--tx-fw-semibold);
}
.tx-price-apply:hover { background: var(--tx-accent); color: #fff; }
@media (max-width: 576px) {
  .tx-extra-filters { gap: var(--tx-space-2); }
  .tx-price-range input[type="number"] { width: 76px; font-size: 12px; padding: 5px 6px; }
  .tx-price-apply { padding: 5px 10px; font-size: 12px; }
}

/* ---------- Pagination (token pass of the existing rules) ---------- */
.pagination { border-radius: var(--tx-radius-sm); }
.pagination .page-item .page-link {
  color: var(--tx-text);
  font-weight: var(--tx-fw-semibold);
  padding: 10px 20px;
  border: 1px solid var(--tx-border);
  border-radius: var(--tx-radius-pill);
  background-color: var(--tx-surface);
  transition: background-color .2s, color .2s;
}
.pagination .page-item.active .page-link { color: #fff; background-color: var(--tx-accent); border-color: var(--tx-accent); }
.pagination .page-item .page-link:hover { background-color: var(--tx-accent); color: #fff; border-color: var(--tx-accent); }
.pagination .page-item .page-link:focus { outline: none; box-shadow: var(--tx-shadow-focus); }

/* ---------- Product detail page panels — white cards holding the gallery and the
   title/price/CTA/description content, matching the reference look of one continuous light
   surface for actual product info on an otherwise dark page. ---------- */
.tx-pdp-panel {
  background: var(--tx-surface);
  border: 1px solid var(--tx-border);
  border-radius: var(--tx-radius-lg);
  box-shadow: var(--tx-shadow-sm);
  padding: var(--tx-space-5);
  color: var(--tx-text);
  height: 100%;
}
.tx-pdp-panel h1, .tx-pdp-panel h2, .tx-pdp-panel h3,
.tx-pdp-panel h4, .tx-pdp-panel h5, .tx-pdp-panel h6 {
  color: var(--tx-text);
}
.tx-pdp-panel .text-secondary,
.tx-pdp-panel .text-muted {
  color: var(--tx-text-muted) !important;
}
.tx-pdp-panel--gallery {
  padding: var(--tx-space-4);
}
.branch-stock-row {
  border-color: var(--tx-border) !important;
}

/* ---------- Hero eyebrow label ---------- */
.tx-eyebrow {
  display: inline-block;
  font-size: var(--tx-fs-xs);
  font-weight: var(--tx-fw-bold);
  letter-spacing: .06em;
  text-transform: uppercase;
  color: var(--tx-accent);
}

/* ---------- Spec chips (product detail: "Intel Core i3 / 11th Gen" style boxes) ---------- */
.tx-spec-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: var(--tx-space-2);
}
.tx-spec-chip {
  display: flex;
  align-items: center;
  gap: var(--tx-space-2);
  border: 1px solid var(--tx-border);
  border-radius: var(--tx-radius-sm);
  padding: var(--tx-space-2) var(--tx-space-3);
  background: var(--tx-surface);
}
.tx-spec-chip__icon {
  width: 30px;
  height: 30px;
  flex-shrink: 0;
  border-radius: var(--tx-radius-sm);
  background: var(--tx-accent-2-soft);
  color: var(--tx-accent-2-hover);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: .85rem;
}
.tx-spec-chip__label {
  display: block;
  font-size: var(--tx-fs-sm);
  font-weight: var(--tx-fw-semibold);
  color: var(--tx-text);
  line-height: 1.25;
}
.tx-spec-chip__sublabel {
  display: block;
  font-size: var(--tx-fs-xs);
  color: var(--tx-text-muted);
  line-height: 1.25;
}

/* ---------- Warranty chips (icon alternates accent/accent-2) ---------- */
.tx-warranty-row {
  display: flex;
  flex-wrap: wrap;
  gap: var(--tx-space-3);
}
.tx-warranty-chip {
  display: flex;
  align-items: center;
  gap: var(--tx-space-2);
  flex: 1 1 180px;
}
.tx-warranty-chip__icon {
  width: 34px;
  height: 34px;
  flex-shrink: 0;
  border-radius: 50%;
  background: var(--tx-accent-soft);
  color: var(--tx-accent);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: .9rem;
}
.tx-warranty-chip:nth-child(even) .tx-warranty-chip__icon {
  background: var(--tx-accent-2-soft);
  color: var(--tx-accent-2-hover);
}
.tx-warranty-chip__label {
  display: block;
  font-size: var(--tx-fs-sm);
  font-weight: var(--tx-fw-semibold);
  color: var(--tx-text);
  line-height: 1.25;
}
.tx-warranty-chip__sublabel {
  display: block;
  font-size: var(--tx-fs-xs);
  color: var(--tx-text-muted);
}

/* ---------- In-stock row ---------- */
.tx-instock {
  display: flex;
  align-items: center;
  gap: 6px;
  color: var(--tx-success);
  font-weight: var(--tx-fw-semibold);
  font-size: var(--tx-fs-sm);
}

/* ---------- Homepage category tiles ---------- */
.tx-category-tile {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: var(--tx-space-2);
  text-align: center;
  background: var(--tx-surface);
  border: 1px solid var(--tx-border);
  border-radius: var(--tx-radius-md);
  padding: var(--tx-space-4) var(--tx-space-2);
  color: var(--tx-text);
  text-decoration: none;
  height: 100%;
  transition: border-color .2s ease, box-shadow .2s ease;
}
.tx-category-tile:hover {
  border-color: var(--tx-accent);
  box-shadow: var(--tx-shadow-sm);
  color: var(--tx-text);
}
.tx-category-tile__icon {
  width: 48px;
  height: 48px;
  border-radius: 50%;
  background: var(--tx-accent-2-soft);
  color: var(--tx-accent-2-hover);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.3rem;
}
.tx-category-tile:nth-child(odd) .tx-category-tile__icon {
  background: var(--tx-accent-soft);
  color: var(--tx-accent);
}
.tx-category-tile__label {
  font-size: var(--tx-fs-sm);
  font-weight: var(--tx-fw-semibold);
}
@media (max-width: 576px) {
  .tx-category-tile { padding: var(--tx-space-3) var(--tx-space-2); gap: var(--tx-space-1); }
  .tx-category-tile__icon { width: 36px; height: 36px; font-size: 1rem; }
  .tx-category-tile__label { font-size: var(--tx-fs-xs); }
}

/* ---------- Breadcrumb (product detail page, under the search bar) ---------- */
.tx-breadcrumb {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  font-size: var(--tx-fs-sm);
}
.tx-breadcrumb a {
  color: var(--tx-text-muted);
  text-decoration: none;
}
.tx-breadcrumb a:hover { color: var(--tx-accent); }
.tx-breadcrumb i { font-size: .65rem; color: var(--tx-text-muted); }
.tx-breadcrumb__current {
  color: var(--tx-text);
  font-weight: var(--tx-fw-semibold);
}
@media (max-width: 576px) {
  .tx-breadcrumb { font-size: var(--tx-fs-xs); }
}

/* ---------- Search bar (pill, icon-in-field) ---------- */
.tx-search-form .input-group {
  background: var(--tx-surface-2);
  border: 1px solid var(--tx-border);
  border-radius: var(--tx-radius-sm);
  box-shadow: none;
  padding: 3px 3px 3px 14px;
  align-items: center;
}
.tx-search-form .input-group .tx-search-icon {
  color: var(--tx-text-muted);
  margin-right: 8px;
  font-size: .9rem;
}
.tx-search-form .form-control {
  border: none;
  background: transparent;
  box-shadow: none !important;
  height: 38px;
  padding-left: 0;
  font-size: var(--tx-fs-sm);
}
.tx-search-form .btn,
.tx-search-form .btn-tx-primary {
  border-radius: var(--tx-radius-sm) !important;
  padding: 8px 18px !important;
  font-size: var(--tx-fs-sm) !important;
}

/* ---------- Product gallery: vertical thumbnail strip + main image + dot indicators,
   one layout at every width (replaces the old mobile-horizontal-strip /
   desktop-row-underneath split). ---------- */
.tx-gallery {
  display: flex;
  gap: var(--tx-space-3);
}
.tx-gallery-thumbs {
  display: flex;
  flex-direction: column;
  gap: var(--tx-space-2);
  flex: 0 0 64px;
  max-height: 420px;
  overflow-y: auto;
}
.tx-gallery-thumb {
  width: 64px;
  height: 64px;
  object-fit: cover;
  border-radius: var(--tx-radius-sm);
  border: 2px solid var(--tx-border);
  cursor: pointer;
  opacity: .75;
  transition: border-color .2s ease, opacity .2s ease;
}
.tx-gallery-thumb:hover { opacity: 1; }
.tx-gallery-thumb.active {
  border-color: var(--tx-accent);
  opacity: 1;
}
.tx-gallery-main {
  flex: 1 1 auto;
  min-width: 0;
}
.tx-gallery-main .carousel-item img {
  border-radius: var(--tx-radius-sm);
}
.tx-gallery-dots {
  position: static !important;
  margin: var(--tx-space-3) 0 0 !important;
}
.tx-gallery-dots [data-bs-target] {
  width: 8px !important;
  height: 8px !important;
  border-radius: 50% !important;
  background-color: var(--tx-border) !important;
  opacity: 1 !important;
  border: none !important;
}
.tx-gallery-dots [data-bs-target].active {
  background-color: var(--tx-accent) !important;
  width: 20px !important;
  border-radius: var(--tx-radius-pill) !important;
}
@media (max-width: 576px) {
  .tx-gallery-thumbs { flex: 0 0 52px; }
  .tx-gallery-thumb { width: 52px; height: 52px; }
}

/* ---------- Generic Bootstrap .card polish (contact page's remaining plain Bootstrap
   cards) — consistent radius/border/shadow instead of Bootstrap defaults ---------- */
.card {
  border-radius: var(--tx-radius-md);
  border-color: var(--tx-border);
}
.card.shadow-sm {
  box-shadow: var(--tx-shadow-sm) !important;
}
.map-responsive {
  border-radius: var(--tx-radius-sm);
  box-shadow: var(--tx-shadow-sm);
}

/* ---------- Mobile overrides (relocated from header.php's inline block) ---------- */
@media (max-width: 576px) {
  .product-title { font-size: var(--tx-fs-sm); }
  .product-price { font-size: var(--tx-fs-xs); }

  .pagination { flex-wrap: wrap; gap: 4px; justify-content: center; }
  .pagination .page-link { padding: 4px 8px; font-size: 12px; min-width: 32px; text-align: center; }
  .page-link.prev::after { content: "\00AB"; font-size: 14px; }
  .page-link.next::after { content: "\00BB"; font-size: 14px; }
  .page-link.prev, .page-link.next { font-size: 0; }

  #search-form .form-control { font-size: 13px; padding: 6px 8px; }
  #search-form .btn { font-size: 13px; padding: 6px 10px; }
  #search-form .input-group { flex-wrap: nowrap; }

  .filter-buttons { display: flex; overflow-x: auto; gap: 6px; padding-bottom: 5px; white-space: nowrap; }
  .filter-buttons::-webkit-scrollbar { display: none; }
  .btn-filter { font-size: 12px; padding: 7px 14px; border-radius: var(--tx-radius-sm); flex: 0 0 auto; }

  .dropbtn { font-size: 13px; padding: 9px 12px; min-width: 0; }
  .dropdown-content { min-width: 140px; }
  .dropdown-content a { font-size: 13px; padding: 12px 14px; }
  .desktop-space { display: none; }
}

/* ---------- Install-app banner (shop.php only — partials/install-banner.php) ---------- */
.tx-install-banner {
  display: flex;
  align-items: center;
  gap: var(--tx-space-3);
  background: var(--tx-surface);
  border: 1px solid var(--tx-border);
  border-radius: var(--tx-radius-md);
  box-shadow: var(--tx-shadow-sm);
  padding: var(--tx-space-3) var(--tx-space-4);
  margin-bottom: var(--tx-space-4);
}
.tx-install-banner[hidden] { display: none; }
.tx-install-banner__icon {
  width: 40px;
  height: 40px;
  flex: 0 0 auto;
  border-radius: var(--tx-radius-sm);
}
.tx-install-banner__text { flex: 1 1 auto; min-width: 0; }
.tx-install-banner__title {
  margin: 0;
  font-size: var(--tx-fs-sm);
  font-weight: var(--tx-fw-semibold);
  color: var(--tx-text);
}
.tx-install-banner__body {
  margin: 2px 0 0;
  font-size: var(--tx-fs-xs);
  color: var(--tx-text-muted);
}
.tx-install-banner__cta {
  flex: 0 0 auto;
  padding: 8px 16px;
  font-size: var(--tx-fs-sm);
  white-space: nowrap;
}
.tx-install-banner__dismiss {
  flex: 0 0 auto;
  background: none;
  border: none;
  color: var(--tx-text-muted);
  font-size: var(--tx-fs-base);
  padding: 4px;
  cursor: pointer;
}
@media (max-width: 576px) {
  .tx-install-banner { flex-wrap: wrap; }
  .tx-install-banner__text { order: 1; flex-basis: calc(100% - 56px); }
  .tx-install-banner__cta { order: 2; margin-left: auto; }
}
