:root {
  --brand-red: #ff0202;
  --brand-blue: #05059b;
  --navy: #05059b;
  --navy-mid: #03037a;
  --navy-light: #0a0abf;
  --blue: #1A6FC4;
  --blue-light: #2E88E5;
  --blue-pale: #EAF2FB;
  --accent: #00C2FF;
  --white: #FFFFFF;
  --off-white: #F7F9FC;
  --border: #DDE5EF;
  --text-main: #0B1F3A;
  --text-muted: #5A6E87;
  --text-light: #8DA0B8;
  --success-bg: #E8F7EE;
  --success-text: #1A6B3C;
  --warn-bg: #FFF4E0;
  --warn-text: #7A5000;
  --radius-sm: 6px;
  --radius-md: 10px;
  --radius-lg: 14px;
  --shadow-sm: 0 1px 4px rgba(11,31,58,0.07);
  --shadow-md: 0 4px 20px rgba(11,31,58,0.10);
  --shadow-lg: 0 8px 40px rgba(11,31,58,0.16);
  --font: 'DM Sans', sans-serif;
  --mono: 'DM Mono', monospace;
}

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

body {
  font-family: var(--font);
  background: var(--off-white);
  color: var(--text-main);
  min-height: 100vh;
  font-size: 15px;
  line-height: 1.6;
}

/* ── Header logos ── */
.header-logo-link { display: flex; align-items: center; flex-shrink: 0; }
.header-logo-img { display: block; object-fit: contain; }
.header-logo-invendis { height: 36px; }
.header-logo-silbo { height: 36px; }
.header-right {
  display: flex;
  align-items: center;
  gap: 20px;
  flex-shrink: 0;
}

/* ── Footer logos ── */
.footer-logos { display: flex; align-items: center; gap: 24px; flex-wrap: wrap; }
.footer-logo-img { display: block; object-fit: contain; filter: brightness(0) invert(1); opacity: 0.9; }
.footer-logo-invendis { height: 36px;}
.footer-logo-silbo { height: 36px;}

/* ── Header ── */
header {
  background: #ffffff;
  color: var(--brand-blue);
  padding: 0;
  position: sticky;
  top: 0;
  z-index: 100;
  box-shadow: 0 2px 12px rgba(0,0,0,0.10);
  border-bottom: 3px solid var(--brand-red);
}
.header-inner {
  max-width: 1280px;
  margin: 0 auto;
  padding: 0 32px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 62px;
  gap: 24px;
}
.logo {
  display: flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
  flex-shrink: 0;
}
.logo-mark {
  width: 34px;
  height: 34px;
  background: linear-gradient(135deg, var(--blue-light), var(--accent));
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 600;
  font-size: 14px;
  color: white;
  letter-spacing: -0.5px;
}
.logo-text { display: flex; flex-direction: column; line-height: 1.2; }
.logo-name { font-size: 15px; font-weight: 600; color: white; letter-spacing: 0.01em; }
.logo-tagline { font-size: 10px; color: rgba(255,255,255,0.5); letter-spacing: 0.06em; text-transform: uppercase; }
.header-contact {
  display: flex;
  align-items: center;
  gap: 20px;
  font-size: 12px;
  color: var(--brand-blue);
}
.header-contact a { color: var(--brand-blue); text-decoration: none; font-weight: 500; }
.header-contact a:hover { color: var(--brand-red); }
.header-nav { display: flex; gap: 8px; }
.header-nav a {
  font-size: 13px;
  color: rgba(255,255,255,0.75);
  text-decoration: none;
  padding: 6px 12px;
  border-radius: var(--radius-sm);
  transition: background 0.15s, color 0.15s;
}
.header-nav a:hover { background: rgba(255,255,255,0.1); color: white; }

/* ── Hero ── */
.hero {
  background: linear-gradient(135deg, var(--navy) 0%, var(--navy-light) 100%);
  color: white;
  padding: 48px 32px 36px;
  border-bottom: 1px solid rgba(255,255,255,0.08);
}
.hero-inner { max-width: 1280px; margin: 0 auto; }
.hero h1 { font-size: 28px; font-weight: 600; letter-spacing: -0.3px; margin-bottom: 6px; }
.hero p { color: rgba(255,255,255,0.6); font-size: 14px; }
.hero-stats {
  display: flex;
  gap: 28px;
  margin-top: 24px;
  flex-wrap: wrap;
}
.hero-stat { display: flex; flex-direction: column; gap: 2px; }
.hero-stat .num { font-size: 22px; font-weight: 600; color: var(--accent); font-family: var(--mono); }
.hero-stat .lbl { font-size: 11px; color: rgba(255,255,255,0.45); letter-spacing: 0.06em; text-transform: uppercase; }

/* ── Main layout ── */
.main { max-width: 1280px; margin: 0 auto; padding: 28px 32px 60px; }

/* ── Filter bar ── */
.filter-bar {
  background: white;
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 18px 20px;
  margin-bottom: 22px;
  box-shadow: var(--shadow-sm);
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  align-items: center;
}
.search-wrap {
  position: relative;
  flex: 1;
  min-width: 220px;
}
.search-wrap svg {
  position: absolute;
  left: 12px;
  top: 50%;
  transform: translateY(-50%);
  color: var(--text-light);
  width: 16px;
  height: 16px;
}
.search-wrap input {
  width: 100%;
  height: 38px;
  padding: 0 12px 0 38px;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  font-family: var(--font);
  font-size: 14px;
  color: var(--text-main);
  background: var(--off-white);
  outline: none;
  transition: border-color 0.15s, box-shadow 0.15s;
}
.search-wrap input:focus { border-color: var(--blue); box-shadow: 0 0 0 3px rgba(26,111,196,0.12); background: white; }
.search-wrap input::placeholder { color: var(--text-light); }

select {
  height: 38px;
  padding: 0 32px 0 12px;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  font-family: var(--font);
  font-size: 13px;
  color: var(--text-main);
  background: var(--off-white) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12'%3E%3Cpath fill='%235A6E87' d='M6 8L1 3h10z'/%3E%3C/svg%3E") no-repeat right 10px center;
  appearance: none;
  cursor: pointer;
  outline: none;
  transition: border-color 0.15s;
}
select:focus { border-color: var(--blue); background-color: white; }
select.active-filter { border-color: var(--blue); background-color: var(--blue-pale); color: var(--navy); font-weight: 500; }

.filter-divider { width: 1px; height: 24px; background: var(--border); flex-shrink: 0; }

.view-toggle {
  display: flex;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  overflow: hidden;
  flex-shrink: 0;
}
.view-toggle button {
  width: 36px;
  height: 38px;
  border: none;
  background: white;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text-light);
  transition: background 0.15s, color 0.15s;
}
.view-toggle button.active { background: var(--navy); color: white; }
.view-toggle button:first-child { border-right: 1px solid var(--border); }

/* ── Results bar ── */
.results-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 16px;
  gap: 12px;
  flex-wrap: wrap;
}
.results-count { font-size: 13px; color: var(--text-muted); }
.results-count strong { color: var(--text-main); font-weight: 600; }
.clear-filters {
  font-size: 13px;
  color: var(--blue);
  background: none;
  border: none;
  cursor: pointer;
  text-decoration: underline;
  font-family: var(--font);
}
.clear-filters:hover { color: var(--navy); }

/* ── Category tabs ── */
.cat-tabs {
  display: flex;
  gap: 6px;
  flex-wrap: wrap;
  margin-bottom: 20px;
}
.cat-tab {
  padding: 6px 14px;
  border-radius: 20px;
  font-size: 13px;
  font-weight: 500;
  border: 1px solid var(--border);
  background: white;
  cursor: pointer;
  transition: all 0.15s;
  color: var(--text-muted);
  display: flex;
  align-items: center;
  gap: 6px;
}
.cat-tab:hover { border-color: var(--blue); color: var(--blue); }
.cat-tab.active { background: var(--navy); border-color: var(--navy); color: white; }
.cat-tab .count {
  font-size: 11px;
  background: rgba(255,255,255,0.2);
  padding: 1px 6px;
  border-radius: 10px;
  font-family: var(--mono);
}
.cat-tab:not(.active) .count { background: var(--off-white); color: var(--text-light); }

/* ── Grid view ── */
.grid-view {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(210px, 1fr));
  gap: 14px;
}
.card {
  background: white;
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 18px;
  cursor: default;
  transition: box-shadow 0.18s, border-color 0.18s, transform 0.15s;
  display: flex;
  flex-direction: column;
  gap: 8px;
  position: relative;
}
.card:hover { box-shadow: var(--shadow-md); border-color: #B8CCE4; transform: translateY(-1px); }
.card.compare-selected { border: 2px solid var(--blue); box-shadow: 0 0 0 3px rgba(26,111,196,0.12); }

.card-cat-badge { align-self: flex-start; }
.badge {
  display: inline-block;
  font-size: 10px;
  font-weight: 600;
  padding: 3px 8px;
  border-radius: 4px;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}
.b-router { background: #EAF2FB; color: #1260A8; }
.b-gateway { background: #E4F5EE; color: #0F6040; }
.b-switch { background: #FFF3E0; color: #8B5200; }
.b-energy { background: #F9EAF3; color: #7B2563; }
.b-other { background: #EEF0F3; color: #3A4D63; }

.card-thumb-wrap {
  margin: -18px -18px 4px -18px;
  border-radius: var(--radius-lg) var(--radius-lg) 0 0;
  overflow: hidden;
  background: #f5f7fa;
  height: 130px;
  display: flex;
  align-items: center;
  justify-content: center;
}
.card-thumb {
  max-height: 114px;
  max-width: calc(100% - 16px);
  object-fit: contain;
  display: block;
}
.card-name { font-size: 15px; font-weight: 600; color: var(--text-main); line-height: 1.3; }
.card-desc { font-size: 12px; color: var(--text-muted); line-height: 1.5; flex: 1; }
.card-specs {
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
  margin-top: 4px;
}
.spec-pill {
  font-size: 11px;
  padding: 2px 8px;
  border-radius: 4px;
  border: 1px solid var(--border);
  color: var(--text-muted);
  background: var(--off-white);
}
.spec-pill.highlight { background: var(--success-bg); color: var(--success-text); border-color: #B4DFC5; }
.spec-pill.warn { background: var(--warn-bg); color: var(--warn-text); border-color: #F0D090; }

.card-use-cases { display: flex; flex-wrap: wrap; gap: 4px; margin: 6px 0 2px; }
.use-case-chip-sm { font-size: 10px; font-weight: 500; padding: 2px 7px; border-radius: 20px; background: #EAF2FB; color: #1A6FC4; border: 1px solid #C4DCF5; white-space: nowrap; }

.card-footer {
  margin-top: 6px;
  padding-top: 10px;
  border-top: 1px solid var(--border);
  display: flex;
  align-items: center;
  gap: 8px;
}
.compare-check {
  display: flex;
  align-items: center;
  gap: 5px;
  font-size: 12px;
  color: var(--text-muted);
  cursor: pointer;
  user-select: none;
}
.compare-check input[type=checkbox] { width: 14px; height: 14px; accent-color: var(--blue); cursor: pointer; }
.details-link {
  margin-left: auto;
  font-size: 12px;
  color: var(--blue);
  font-weight: 500;
  cursor: pointer;
}
.details-link:hover { text-decoration: underline; }

/* ── List view ── */
.list-view { display: flex; flex-direction: column; gap: 6px; }
.list-head {
  display: grid;
  grid-template-columns: 48px 160px 1fr 80px 80px 68px 68px 80px;
  gap: 10px;
  padding: 8px 16px;
  font-size: 11px;
  font-weight: 600;
  color: var(--text-light);
  letter-spacing: 0.06em;
  text-transform: uppercase;
  border-bottom: 1px solid var(--border);
  margin-bottom: 4px;
}
.list-row {
  background: white;
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  padding: 12px 16px;
  display: grid;
  grid-template-columns: 48px 160px 1fr 80px 80px 68px 68px 80px;
  gap: 10px;
  align-items: center;
  cursor: pointer;
  transition: box-shadow 0.15s, border-color 0.15s;
}
.list-row:hover { box-shadow: var(--shadow-sm); border-color: #B8CCE4; }
.list-row.compare-selected { border: 2px solid var(--blue); }
.list-thumb {
  width: 40px;
  height: 40px;
  object-fit: contain;
  border-radius: var(--radius-sm);
  background: #f5f7fa;
  display: block;
}
.list-name { font-size: 13px; font-weight: 600; }
.list-cat { margin-top: 3px; }
.list-desc { font-size: 12px; color: var(--text-muted); line-height: 1.4; }
.list-cell { font-size: 12px; text-align: center; }
.yes-pill { background: var(--success-bg); color: var(--success-text); border: 1px solid #B4DFC5; font-size: 11px; font-weight: 600; padding: 2px 7px; border-radius: 4px; }
.no-pill { color: var(--text-light); font-size: 12px; }

/* ── Empty state ── */
.empty-state {
  text-align: center;
  padding: 64px 24px;
  color: var(--text-muted);
}
.empty-state svg { width: 40px; height: 40px; color: var(--text-light); margin-bottom: 14px; }
.empty-state h3 { font-size: 16px; font-weight: 600; color: var(--text-main); margin-bottom: 6px; }
.empty-state p { font-size: 14px; }

/* ── Compare bar ── */
.compare-tray {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  background: var(--navy);
  color: white;
  padding: 14px 32px;
  display: flex;
  align-items: center;
  gap: 16px;
  z-index: 90;
  box-shadow: 0 -4px 20px rgba(0,0,0,0.2);
  transform: translateY(100%);
  transition: transform 0.25s ease;
  flex-wrap: wrap;
}
.compare-tray.visible { transform: translateY(0); }
.compare-tray-chips { display: flex; gap: 8px; flex: 1; flex-wrap: wrap; }
.compare-chip {
  background: rgba(255,255,255,0.12);
  border: 1px solid rgba(255,255,255,0.2);
  border-radius: 6px;
  padding: 4px 10px;
  font-size: 13px;
  display: flex;
  align-items: center;
  gap: 6px;
}
.compare-chip button {
  background: none;
  border: none;
  color: rgba(255,255,255,0.6);
  cursor: pointer;
  font-size: 16px;
  line-height: 1;
  padding: 0;
}
.compare-chip button:hover { color: white; }
.compare-tray-label { font-size: 13px; color: rgba(255,255,255,0.6); }
.btn-compare {
  background: var(--blue-light);
  color: white;
  border: none;
  border-radius: var(--radius-sm);
  padding: 9px 20px;
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  font-family: var(--font);
  transition: background 0.15s;
  flex-shrink: 0;
}
.btn-compare:hover { background: var(--blue); }
.btn-clear-compare {
  background: none;
  border: 1px solid rgba(255,255,255,0.25);
  color: rgba(255,255,255,0.75);
  border-radius: var(--radius-sm);
  padding: 8px 16px;
  font-size: 13px;
  cursor: pointer;
  font-family: var(--font);
  flex-shrink: 0;
}
.btn-clear-compare:hover { background: rgba(255,255,255,0.08); }

/* ── Modal ── */
.modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(11,31,58,0.45);
  z-index: 300;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
  animation: fadeIn 0.15s ease;
}
@keyframes fadeIn { from { opacity: 0; } to { opacity: 1; } }
.modal {
  background: white;
  border-radius: var(--radius-lg);
  width: 100%;
  max-width: min(860px, 96vw);
  max-height: 88vh;
  overflow-y: auto;
  box-shadow: var(--shadow-lg);
  animation: slideUp 0.18s ease;
}
@keyframes slideUp { from { transform: translateY(14px); opacity: 0; } to { transform: translateY(0); opacity: 1; } }
.modal-header {
  padding: 16px 24px 18px;
  border-bottom: 1px solid var(--border);
}
.modal-close-bar {
  position: sticky;
  top: 0;
  z-index: 10;
  height: 0;
  overflow: visible;
  display: flex;
  justify-content: flex-end;
  pointer-events: none;
}
.modal-close {
  pointer-events: all;
  position: relative;
  top: 12px;
  margin-right: 14px;
  width: 30px;
  height: 30px;
  border: none;
  background: var(--off-white);
  border-radius: 50%;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 18px;
  color: var(--text-muted);
  line-height: 1;
  transition: background 0.15s;
  box-shadow: 0 1px 4px rgba(11,31,58,0.12);
}
.modal-close:hover { background: var(--border); color: var(--text-main); }
.modal-title { font-size: 20px; font-weight: 700; margin-top: 8px; letter-spacing: -0.2px; }
.modal-desc { font-size: 13px; color: var(--text-muted); margin-top: 6px; line-height: 1.5; }
.product-image-wrap {
  position: relative;
  background: #f5f7fa;
  border-bottom: 1px solid var(--border);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px 60px;
  min-height: 180px;
}
.carousel-img {
  max-height: 260px;
  max-width: 100%;
  object-fit: contain;
  display: block;
}
.carousel-btn {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  background: rgba(255,255,255,0.92);
  border: 1px solid var(--border);
  border-radius: 50%;
  width: 36px;
  height: 36px;
  font-size: 22px;
  cursor: pointer;
  color: var(--navy);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0;
  transition: background 0.15s, border-color 0.15s, color 0.15s;
  box-shadow: 0 1px 4px rgba(11,31,58,0.1);
}
.carousel-btn:hover { background: #fff; border-color: var(--blue); color: var(--blue); }
.carousel-prev { left: 12px; }
.carousel-next { right: 12px; }
.carousel-counter {
  position: absolute;
  bottom: 8px;
  right: 12px;
  font-size: 11px;
  color: var(--text-light);
  background: rgba(255,255,255,0.85);
  border-radius: 4px;
  padding: 2px 6px;
  font-family: var(--mono);
}
.modal-body { padding: 20px 24px; }
.spec-section { margin-bottom: 20px; }
.spec-section-title {
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--text-light);
  margin-bottom: 10px;
  padding-bottom: 6px;
  border-bottom: 1px solid var(--border);
}
.spec-row {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  padding: 8px 0;
  border-bottom: 1px solid #F0F4F9;
  gap: 16px;
  font-size: 13px;
}
.spec-row:last-child { border-bottom: none; }
.spec-key { color: var(--text-muted); flex-shrink: 0; width: 140px; }
.spec-val { font-weight: 500; text-align: right; }
.modal-use-cases { padding: 14px 24px 12px; border-bottom: 1px solid var(--border); background: #FAFCFF; }
.modal-use-cases-label { font-size: 11px; font-weight: 700; letter-spacing: 0.06em; text-transform: uppercase; color: var(--text-muted); margin-bottom: 8px; }
.modal-use-cases-chips { display: flex; flex-wrap: wrap; gap: 6px; }
.use-case-chip { font-size: 12px; font-weight: 500; padding: 4px 10px; border-radius: 20px; background: #EAF2FB; color: #1A6FC4; border: 1px solid #C4DCF5; }

.modal-actions {
  padding: 16px 24px 22px;
  border-top: 1px solid var(--border);
  display: flex;
  gap: 10px;
  align-items: center;
}
.btn-enquire {
  flex: 1;
  background: var(--blue);
  color: white;
  border: none;
  border-radius: var(--radius-sm);
  padding: 10px 20px;
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  font-family: var(--font);
  transition: background 0.15s;
  text-align: center;
  text-decoration: none;
  display: inline-block;
}
.btn-enquire:hover { background: var(--navy); }
.btn-add-compare {
  background: none;
  border: 1px solid var(--border);
  color: var(--text-muted);
  border-radius: var(--radius-sm);
  padding: 9px 16px;
  font-size: 13px;
  font-weight: 500;
  cursor: pointer;
  font-family: var(--font);
  transition: all 0.15s;
}
.btn-add-compare:hover { border-color: var(--blue); color: var(--blue); }

/* ── Datasheet buttons (used in variants table and product-level section) ── */
.ds-btn {
  display: inline-block;
  font-size: 11px;
  font-weight: 600;
  font-family: inherit;
  padding: 3px 9px;
  border-radius: var(--radius-sm);
  text-decoration: none;
  border: 1px solid transparent;
  transition: all 0.15s;
  white-space: nowrap;
  line-height: 1.4;
  cursor: pointer;
  -webkit-appearance: none;
  appearance: none;
}
.ds-view { background: var(--white); color: var(--blue); border-color: var(--blue); }
.ds-view:hover { background: var(--blue); color: var(--white); }
.ds-download {
  background: var(--blue);
  color: var(--white);
  border-color: var(--blue);
  font-size: 13px;
  padding: 2px 8px;
}
.ds-download:hover { background: var(--navy); border-color: var(--navy); }
.ds-contact { background: var(--white); color: var(--blue); border-color: var(--blue); }
.ds-contact:hover { background: var(--blue); color: var(--white); }

/* Variants table — Data Sheet column */
.col-datasheet { text-align: center; white-space: nowrap; width: 1%; }
.cell-datasheet { text-align: center; white-space: nowrap; }
.cell-datasheet .ds-btn + .ds-btn { margin-left: 4px; }

/* ── Product-level datasheet section (no per-variant sheets) ── */
.datasheet-section { border-top: 1px solid var(--border); margin-top: 0; }
.datasheet-item {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 8px 10px;
  border-radius: var(--radius-sm);
  background: var(--off-white);
  border: 1px solid var(--border);
}
.datasheet-icon { width: 18px; height: 18px; flex-shrink: 0; color: #e63946; }
.datasheet-label {
  flex: 1;
  font-size: 13px;
  font-weight: 500;
  color: var(--text-main);
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.datasheet-btns { display: flex; gap: 6px; flex-shrink: 0; }
.datasheet-btns .ds-btn { font-size: 12px; padding: 4px 12px; }

/* ── Compare modal ── */
.compare-modal { max-width: 900px; }
.compare-table { width: 100%; border-collapse: collapse; font-size: 13px; }
.compare-table th {
  text-align: left;
  padding: 12px 16px;
  font-weight: 600;
  border-bottom: 2px solid var(--border);
  background: var(--off-white);
  font-size: 13px;
  white-space: nowrap;
}
.compare-table th:first-child { width: 140px; color: var(--text-muted); font-weight: 500; }
.compare-table td {
  padding: 10px 16px;
  border-bottom: 1px solid var(--border);
  vertical-align: top;
}
.compare-table td:first-child { color: var(--text-muted); font-size: 12px; background: var(--off-white); }
.compare-table tr.diff-row td:not(:first-child) { background: #FEFDF0; font-weight: 500; }
.compare-table tr:last-child td { border-bottom: none; }

/* ── Variants table ── */
.variants-section { margin-top: 4px; }
.variants-note {
  font-size: 11.5px;
  color: var(--text-muted);
  background: var(--off-white);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 8px 12px;
  margin-bottom: 12px;
  line-height: 1.6;
  font-family: var(--mono);
}
.variants-table-wrap { overflow-x: auto; border-radius: var(--radius-sm); border: 1px solid var(--border); }
.variants-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 13px;
}
.variants-table thead tr {
  background: var(--navy-mid);
  color: white;
}
.variants-table th {
  padding: 7px 10px;
  text-align: center;
  font-weight: 600;
  font-size: 11.5px;
  letter-spacing: 0.04em;
  white-space: nowrap;
}
.variants-table td {
  padding: 6px 10px;
  border-bottom: 1px solid var(--border);
  vertical-align: middle;
  text-align: center;
  font-size: 13px;
}
.variants-table tbody tr:last-child td { border-bottom: none; }
.variants-table tbody tr:nth-child(even) { background: var(--off-white); }
.variants-table tbody tr:hover { background: var(--blue-pale); }
.cell-yes {
  text-align: center;
  color: var(--success-text);
  font-weight: 700;
  font-size: 15px;
}
.cell-no {
  text-align: center;
  color: var(--text-light);
  font-size: 15px;
}
.cell-partno {
  text-align: center;
  font-family: var(--mono);
  font-weight: 600;
  font-size: 12px;
  color: var(--navy-mid);
  letter-spacing: 0.03em;
}

/* ── Pagination ── */
#pagination { margin-top: 28px; }
.pagination {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 4px;
  flex-wrap: wrap;
}
.pg-btn {
  min-width: 36px;
  height: 36px;
  padding: 0 6px;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  background: white;
  color: var(--text-main);
  font-family: var(--font);
  font-size: 13px;
  font-weight: 500;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background 0.15s, border-color 0.15s, color 0.15s;
}
.pg-btn:hover:not(:disabled) { border-color: var(--blue); color: var(--blue); background: var(--blue-pale); }
.pg-btn.active { background: var(--navy); border-color: var(--navy); color: white; }
.pg-btn:disabled { opacity: 0.35; cursor: default; }
.pg-ellipsis { min-width: 36px; text-align: center; font-size: 13px; color: var(--text-light); }

/* ── Footer ── */
footer {
  background: var(--brand-blue);
  color: rgba(255,255,255,0.75);
  padding: 0 32px 36px;
  margin-top: 40px;
  border-top: 4px solid var(--brand-red);
}
.footer-inner {
  max-width: 1280px;
  margin: 0 auto;
  padding-top: 36px;
  display: flex;
  flex-wrap: wrap;
  gap: 32px;
  justify-content: space-between;
  align-items: flex-start;
}
.footer-brand .logo-name { font-size: 16px; color: white; }
.footer-brand p { font-size: 13px; color: rgba(255,255,255,0.55); margin-top: 6px; max-width: 280px; line-height: 1.5; }
.footer-contact h4 { font-size: 13px; font-weight: 600; color: var(--brand-red); margin-bottom: 10px; text-transform: uppercase; letter-spacing: 0.06em; }
.footer-contact p { font-size: 13px; margin-bottom: 5px; }
.footer-contact a { color: rgba(255,255,255,0.75); text-decoration: none; }
.footer-contact a:hover { color: #ffffff; }
.footer-bottom {
  max-width: 1280px;
  margin: 24px auto 0;
  padding-top: 18px;
  border-top: 1px solid rgba(255,255,255,0.15);
  font-size: 12px;
  color: rgba(255,255,255,0.45);
}

/* ── Responsive ── */

/* Wide tablets (≤ 900px) */
@media (max-width: 900px) {
  .compare-modal { max-width: calc(100vw - 40px); }
}

/* Tablets and large phones (≤ 768px) */
@media (max-width: 768px) {
  /* Header */
  .header-contact { display: none; }
  .header-inner { padding: 0 16px; }

  /* Hero */
  .hero { padding: 24px 16px 20px; }
  .hero h1 { font-size: 20px; }
  .hero-stats { gap: 14px; margin-top: 16px; }

  /* Main */
  .main { padding: 16px 16px 80px; }

  /* Filter bar */
  .filter-bar { padding: 12px; gap: 8px; }
  .search-wrap { min-width: 0; width: 100%; flex: none; }
  .filter-divider { display: none; }

  /* Category tabs — horizontal scroll instead of wrapping */
  .cat-tabs {
    flex-wrap: nowrap;
    overflow-x: auto;
    padding-bottom: 4px;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
  }
  .cat-tabs::-webkit-scrollbar { display: none; }
  .cat-tab { flex-shrink: 0; }

  /* Grid */
  .grid-view { grid-template-columns: repeat(auto-fill, minmax(155px, 1fr)); gap: 10px; }

  /* List view */
  .list-head { display: none; }
  .list-row { grid-template-columns: 1fr; gap: 6px; }
  .list-row .list-cell { text-align: left; }

  /* Compare tray */
  .compare-tray { padding: 10px 16px; gap: 8px; }

  /* Footer */
  footer { padding: 24px 16px 20px; }
  .footer-inner { gap: 20px; }

  /* Modal — bottom sheet */
  .modal-overlay { padding: 0; align-items: flex-end; }
  .modal {
    max-width: 100%;
    max-height: 95vh;
    border-radius: var(--radius-lg) var(--radius-lg) 0 0;
  }
  .modal-header { padding: 12px 16px 14px; }
  .modal-title { font-size: 17px; }
  .modal-close { width: 38px; height: 38px; }
  .modal-use-cases { padding: 12px 16px 10px; }
  .product-image-wrap { padding: 16px 20px; min-height: 130px; }
  .carousel-img { max-height: 180px; }
  .carousel-btn { width: 40px; height: 40px; }
  .modal-body { padding: 16px; }
  .spec-key { width: 110px; }
  .modal-actions { flex-direction: column; padding: 14px 16px 18px; gap: 8px; }
  .btn-enquire { width: 100%; }
  .btn-add-compare { width: 100%; text-align: center; }
  .datasheet-item { flex-wrap: wrap; }
  .datasheet-btns { margin-top: 4px; }
}

/* Small phones (≤ 480px) */
@media (max-width: 480px) {
  /* Filter bar — full vertical stack */
  .filter-bar { flex-direction: column; align-items: stretch; }
  select { width: 100%; }
  .view-toggle { align-self: flex-start; }

  /* Grid — fixed 2 columns */
  .grid-view { grid-template-columns: repeat(2, 1fr); gap: 8px; }
  .card { padding: 12px; gap: 6px; }
  .card-thumb-wrap { height: 110px; margin: -12px -12px 4px -12px; }
  .card-name { font-size: 14px; }

  /* Hero */
  .hero h1 { font-size: 17px; }
  .hero-stat .num { font-size: 18px; }

  /* Modal spec labels */
  .spec-key { width: 95px; font-size: 12px; }

  /* Compare tray — stack vertically */
  .compare-tray { flex-direction: column; align-items: stretch; gap: 8px; }
  .btn-compare { width: 100%; }
  .btn-clear-compare { width: 100%; text-align: center; }
}
