/* ============================================================
   styles-v3.css — V3 supplemental (extends V1 styles.css)
   Adds: subnav, series strip, mat tabs, overview grid, CTA bar
   V1 styles.css handles: header, finder, table, breadcrumb
   ============================================================ */

/* ── Site header tweaks ────────────────────────────────── */
.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(255,255,255,.97);
  border-top: 4px solid var(--deep);
  border-bottom: 1px solid var(--line);
  backdrop-filter: blur(12px);
}

.header-main {
  display: grid;
  grid-template-columns: auto 1fr auto auto;
  align-items: center;
  gap: 14px;
  min-height: 64px;
  padding: 0 24px;
}

.brand img { display: block; }

.global-search {
  display: grid;
  grid-template-columns: 1fr auto;
  height: 40px;
  border: 2px solid var(--blue);
  border-radius: 4px;
  overflow: hidden;
  min-width: 0;
}
.global-search input  { border: 0; padding: 0 14px; outline: 0; font: inherit; font-size: 14px; width: 100%; }
.global-search button { padding: 0 18px; background: var(--blue); color: #fff; border: 0; font: inherit; font-size: 13px; font-weight: 800; cursor: pointer; white-space: nowrap; }
.global-search button:hover { background: #0d47a1; }

.header-actions { display: flex; align-items: center; gap: 8px; }
.header-actions a { display: inline-flex; align-items: center; min-height: 34px; padding: 0 12px; border: 1px solid var(--line); border-radius: 4px; color: #26313f; background: #fbfbfc; font-size: 13px; font-weight: 800; white-space: nowrap; }
.btn-line  { color: #00653b !important; border-color: #bbf7d0 !important; background: #f0fdf4 !important; }
.btn-shopee { color: var(--orange-dark) !important; border-color: #ffd0b5 !important; background: #fff8f0 !important; }

.hamburger-button { display: none; flex-direction: column; gap: 5px; padding: 8px; border: 0; background: 0; cursor: pointer; }
.hamburger-button span { display: block; width: 22px; height: 2px; background: var(--text); border-radius: 2px; }

/* ── Nav-links active state ─────────────────────────────── */
.nav-links a.active {
  background: var(--deep) !important;
  color: #fff !important;
  border-color: var(--deep) !important;
}
.nav-links a:not(.active):hover {
  background: var(--soft);
  border-color: #c0c7d0;
}

/* ── Nav drawer styles (mobile only — hidden on desktop via separate rule) ── */
.nav-drawer-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px 20px;
  border-bottom: 1px solid #f0f2f5;
  background: var(--deep);
  flex-shrink: 0;
}
.nav-drawer-head .brand img { filter: brightness(0) invert(1); }
.nav-drawer-close {
  background: 0;
  border: 0;
  color: #fff;
  font-size: 22px;
  line-height: 1;
  cursor: pointer;
  padding: 4px 8px;
}
.nav-drawer a {
  display: flex;
  align-items: center;
  min-height: 52px;
  padding: 0 24px;
  border: 0;
  border-bottom: 1px solid #f0f2f5;
  border-radius: 0 !important;
  font-size: 15px;
  font-weight: 700;
  color: #1a2332;
  text-decoration: none;
  background: #fff;
  transition: background .12s;
}
.nav-drawer a:hover   { background: #f5f7fa; }
.nav-drawer a.active  {
  background: #eff6ff !important;
  color: var(--deep) !important;
  border-left: 4px solid var(--deep) !important;
  font-weight: 900;
}

/* ── Subnav (product type tabs, white bar) ─────────────── */
.v3-subnav {
  display: flex;
  align-items: center;
  gap: 6px;
  min-height: 46px;
  padding: 0 24px;
  background: #fff;
  border-bottom: 1px solid var(--line);
  overflow-x: auto;
  scrollbar-width: none;
}
.v3-subnav::-webkit-scrollbar { display: none; }

.v3-subnav-item {
  display: inline-flex;
  align-items: center;
  min-height: 30px;
  padding: 0 14px;
  border: 1px solid var(--line);
  border-radius: 4px;
  background: #fff;
  font-family: "Montserrat", "Noto Sans Thai", system-ui, sans-serif;
  font-size: 12px;
  font-weight: 800;
  color: #26313f;
  white-space: nowrap;
  text-decoration: none;
  flex-shrink: 0;
  transition: background .15s, border-color .15s;
}
.v3-subnav-item:hover  { background: var(--soft); border-color: #c5cbd5; }
.v3-subnav-item.active { color: #fff; border-color: var(--deep); background: var(--deep); }

/* ── Series strip ──────────────────────────────────────── */
.v3-series-strip {
  display: flex;
  gap: 10px;
  align-items: center;
  padding: 12px 24px;
  background: #fff;
  border-bottom: 2px solid var(--orange);
  overflow-x: auto;
  scrollbar-width: none;
}
.v3-series-strip::-webkit-scrollbar { display: none; }

.v3-series-card {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
  flex-shrink: 0;
  width: 84px;
  padding: 8px 6px 10px;
  border: 1.5px solid #e0e3e8;
  border-radius: 10px;
  background: #fff;
  text-decoration: none;
  color: inherit;
  font-size: 10px;
  font-weight: 900;
  font-family: "Montserrat", system-ui, sans-serif;
  color: var(--deep);
  transition: border-color .15s, box-shadow .15s;
}
.v3-series-card:hover  { border-color: #9bafc4; box-shadow: 0 4px 12px rgba(7,29,60,.08); }
.v3-series-card.active { border-color: var(--orange); background: #fff5ed; color: var(--orange-dark); }
.v3-series-card img    { width: 56px; height: 56px; object-fit: contain; border-radius: 6px; background: #f6f7f9; }

/* ── Material tabs ─────────────────────────────────────── */
.v3-mat-tabs {
  display: flex;
  background: #fff;
  border-bottom: 1px solid var(--line);
}
.v3-mat-tab {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 44px;
  padding: 0 16px;
  font-size: 14px;
  font-weight: 700;
  color: var(--muted);
  border-bottom: 3px solid transparent;
  text-decoration: none;
  transition: color .15s;
}
.v3-mat-tab:hover:not(.active)  { background: var(--soft); }
.v3-mat-tab.active              { color: var(--deep); border-bottom-color: var(--deep); }
/* Per-material active colors */
.v3-mat-tab[data-mat="NBR"].active   { color: #1e40af; border-bottom-color: #1e40af; background: #eff6ff; }
.v3-mat-tab[data-mat="Viton"].active { color: #b45309; border-bottom-color: var(--orange); background: #fff8f0; }
.v3-mat-badge   { font-size: 11px; padding: 2px 8px; border-radius: 10px; font-weight: 700; }
.v3-nbr-badge   { background: #dbeafe; color: #1e40af; }
.v3-vit-badge   { background: #fff5ed; color: var(--orange-dark); }

/* ── Mobile table → card layout (search.php) ─────────────── */
@media (max-width: 700px) {
  .native-product-table thead { display: none; }
  .native-product-table tbody tr {
    display: block;
    border: 1px solid #e4e7ec;
    border-radius: 10px;
    margin-bottom: 12px;
    background: #fff;
    box-shadow: 0 1px 4px rgba(0,0,0,.05);
    overflow: hidden;
  }
  .native-product-table td {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
    padding: 9px 14px;
    border-bottom: 1px solid #f3f4f6;
    font-size: 13px;
  }
  .native-product-table td:last-child { border-bottom: 0; }
  .native-product-table td.td-no { display: none; }
  .native-product-table td::before {
    content: attr(data-label);
    font-size: 11px;
    font-weight: 800;
    color: #6b7280;
    text-transform: uppercase;
    letter-spacing: .05em;
    white-space: nowrap;
    font-family: "Montserrat", system-ui, sans-serif;
    flex-shrink: 0;
  }
  .native-product-table td.td-sku { font-weight: 700; font-size: 14px; color: #111; background: #fafafa; }
  .native-product-table td.td-sku::before { content: none; }
}

/* ── Overview page ─────────────────────────────────────── */
.v3-overview-hero {
  padding: 32px 28px 28px;
  background: #fff;
  border-bottom: 1px solid var(--line);
}
.v3-overview-hero .eyebrow {
  display: block;
  margin-bottom: 8px;
  color: var(--orange);
  font-size: 12px;
  font-weight: 900;
  text-transform: uppercase;
  letter-spacing: .05em;
  font-family: "Montserrat", system-ui, sans-serif;
}
.v3-overview-hero h1 { margin: 0 0 10px; color: #050a0f; font-size: clamp(24px,3.5vw,40px); font-weight: 900; line-height: 1.15; }
.v3-overview-hero > p { margin: 0; color: #344052; font-size: 15px; font-weight: 600; line-height: 1.75; max-width: 640px; }

.v3-overview-grid-wrap { padding: 24px 28px 40px; background: var(--soft); }
.v3-overview-head { display: flex; align-items: baseline; gap: 10px; margin-bottom: 18px; }
.v3-overview-head h2  { margin: 0; font-size: 18px; font-weight: 900; color: #05070a; }
.v3-overview-head span { font-size: 13px; color: var(--muted); font-weight: 700; }

/* ── Model grid cards (reference style) ─────────────────── */
.v3-model-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  gap: 16px;
}

.v3-model-card {
  display: flex;
  flex-direction: column;
  border: 1.5px solid #e0e3e8;
  border-radius: 8px;
  overflow: hidden;
  background: #fff;
  text-decoration: none;
  color: inherit;
  box-shadow: 0 1px 4px rgba(0,0,0,.06);
  transition: border-color .18s, box-shadow .18s, transform .18s;
}
.v3-model-card:hover {
  border-color: var(--orange);
  box-shadow: 0 6px 24px rgba(7,29,60,.12);
  transform: translateY(-2px);
}

/* Top header — colored bg per category */
.v3-model-card-head {
  padding: 12px 14px 10px;
  background: #fff;
  border-bottom: 1px solid #f0f2f5;
}
/* Oil Seal — น้ำเงิน */
.v3-cat-oil-seal  { background: #1e3a8a; border-bottom-color: #1e3a8a; }
/* Hydraulic Seal (rod/piston/wiper) — ส้ม */
.v3-cat-rod-seal,
.v3-cat-piston-seal,
.v3-cat-wiper-seal { background: #c2410c; border-bottom-color: #c2410c; }
/* O-Ring — ดำ */
.v3-cat-o-ring    { background: #111827; border-bottom-color: #111827; }
/* V-Ring — เขียว */
.v3-cat-v-ring    { background: #14532d; border-bottom-color: #14532d; }

/* White text when colored header */
.v3-cat-oil-seal .v3-model-card-label,
.v3-cat-rod-seal .v3-model-card-label,
.v3-cat-piston-seal .v3-model-card-label,
.v3-cat-wiper-seal .v3-model-card-label,
.v3-cat-o-ring .v3-model-card-label,
.v3-cat-v-ring .v3-model-card-label { color: #fff; }

.v3-cat-oil-seal .v3-model-card-sub,
.v3-cat-rod-seal .v3-model-card-sub,
.v3-cat-piston-seal .v3-model-card-sub,
.v3-cat-wiper-seal .v3-model-card-sub,
.v3-cat-o-ring .v3-model-card-sub,
.v3-cat-v-ring .v3-model-card-sub { color: rgba(255,255,255,.65); }

.v3-model-card-label {
  display: block;
  font-family: "Montserrat", system-ui, sans-serif;
  font-size: 16px;
  font-weight: 900;
  color: #c0392b;
  line-height: 1.1;
  margin-bottom: 4px;
}
.v3-model-card-sub {
  display: block;
  font-size: 11px;
  color: #6b7280;
  font-weight: 600;
  line-height: 1.3;
}

/* Image area */
.v3-model-card-img {
  flex: 1;
  min-height: 160px;
  background: #ffffff;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 16px;
  overflow: hidden;
}
.v3-model-card-img img {
  max-width: 100%;
  max-height: 160px;
  object-fit: contain;
  transition: transform .25s;
}
.v3-model-card:hover .v3-model-card-img img { transform: scale(1.06); }

/* Specs table — matching reference row layout */
.v3-model-card-specs {
  border-top: 1px solid #f0f2f5;
  padding: 0;
}
.v3-spec-row {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 6px;
  padding: 7px 14px;
  border-bottom: 1px solid #f4f5f7;
  font-size: 12px;
}
.v3-spec-row:last-child { border-bottom: 0; }
.v3-spec-row > span   { color: #6b7280; font-weight: 500; white-space: nowrap; }
.v3-spec-row > strong { color: #111827; font-weight: 800; text-align: right; font-family: "Montserrat", system-ui, sans-serif; font-size: 11.5px; }

/* Material badge on card label — NBR blue, Viton orange */
.v3-model-card-label .badge-nbr   { display:inline-block; margin-left:6px; font-size:10px; padding:1px 7px; border-radius:999px; background:#dbeafe; color:#1e40af; font-weight:800; vertical-align:middle; }
.v3-model-card-label .badge-viton { display:inline-block; margin-left:6px; font-size:10px; padding:1px 7px; border-radius:999px; background:#fff5ed; color:var(--orange-dark); font-weight:800; vertical-align:middle; }

/* ── detail-page-bar: always show on detail page ────────── */
.model-page-active .detail-page-bar { display: flex !important; }

/* ── Full-width search bar ──────────────────────────────── */
.v3-search-wrap {
  padding: 20px 28px 4px;
  background: #05070a;           /* เข้มเหมือน .finder section */
}

.v3-search-bar {
  display: flex;
  align-items: center;
  gap: 0;
  height: 56px;
  background: #fff;
  border: 2.5px solid #fff;
  border-radius: 10px;
  overflow: hidden;
  box-shadow: 0 4px 24px rgba(0,0,0,.35);
  transition: border-color .18s, box-shadow .18s;
}
.v3-search-bar:focus-within {
  border-color: var(--orange);
  box-shadow: 0 4px 28px rgba(234,88,12,.30);
}

.v3-search-icon {
  flex-shrink: 0;
  width: 52px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 22px;
  color: #9ca3af;
  background: #fff;
  height: 100%;
  pointer-events: none;
  user-select: none;
}

.v3-search-bar input {
  flex: 1;
  min-width: 0;
  height: 100%;
  border: 0;
  outline: 0;
  background: #fff;
  font: inherit;
  font-size: 17px;
  font-weight: 600;
  color: #111827;
  padding: 0 8px;
}
.v3-search-bar input::placeholder {
  color: #9ca3af;
  font-weight: 500;
}

.v3-search-bar button {
  flex-shrink: 0;
  height: 100%;
  padding: 0 32px;
  background: var(--orange);
  color: #fff;
  border: 0;
  font: inherit;
  font-size: 15px;
  font-weight: 900;
  font-family: "Montserrat", system-ui, sans-serif;
  cursor: pointer;
  white-space: nowrap;
  transition: background .15s;
  letter-spacing: .02em;
}
.v3-search-bar button:hover { background: var(--orange-dark); }

/* Chips row */
.v3-search-chips {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
  padding: 10px 0 16px;
}
.v3-search-chips > span {
  font-size: 12px;
  color: rgba(255,255,255,.55);
  font-weight: 700;
}
.v3-search-chips button {
  padding: 4px 14px;
  border: 1.5px solid rgba(255,255,255,.2);
  border-radius: 999px;
  background: rgba(255,255,255,.07);
  color: #e2e8f0;
  font: inherit;
  font-size: 12px;
  font-weight: 800;
  cursor: pointer;
  transition: background .15s, border-color .15s;
  font-family: "Montserrat", system-ui, sans-serif;
}
.v3-search-chips button:hover {
  background: rgba(255,255,255,.16);
  border-color: rgba(255,255,255,.45);
}
.v3-search-chips button.active {
  background: var(--orange);
  border-color: var(--orange);
  color: #fff;
}

@media (max-width: 768px) {
  .v3-search-wrap { padding: 14px 14px 2px; }
  .v3-search-bar { height: 50px; border-radius: 8px; }
  .v3-search-icon { width: 40px; font-size: 18px; }
  .v3-search-bar input { font-size: 15px; }
  .v3-search-bar button { padding: 0 18px; font-size: 14px; }
  .v3-search-chips { padding: 8px 0 12px; gap: 6px; }
}

/* ── Finder result area additions ─────────────────────── */
.v3-pagination {
  display: flex;
  align-items: center;
  gap: 4px;
  padding: 12px 16px;
  background: #f5f6f8;
  border-top: 1px solid #e7e9ed;
  border-radius: 0 0 8px 8px;
  flex-wrap: wrap;
}
.v3-pagination .pg-btn {
  min-width: 32px; height: 32px; padding: 0 8px;
  border: 1px solid #dde2ea; border-radius: 4px;
  background: #fff; color: #374151;
  font-size: 13px; font-weight: 800;
  cursor: pointer; display: inline-flex; align-items: center; justify-content: center;
}
.v3-pagination .pg-btn:hover  { background: #e5e8ec; }
.v3-pagination .pg-btn.on     { background: var(--deep); color: #fff; border-color: var(--deep); }
.v3-pagination .pg-info       { font-size: 12px; color: var(--muted); margin-left: auto; font-weight: 700; }

/* ── CTA bar ───────────────────────────────────────────── */
.v3-cta-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
  padding: 20px 28px;
  background: var(--deep);
  color: #fff;
}
.v3-cta-bar strong { display: block; font-size: 14px; font-weight: 900; }
.v3-cta-bar span   { display: block; font-size: 12px; color: #a8c4e0; margin-top: 3px; }
.v3-cta-btn {
  display: inline-flex; align-items: center; gap: 6px;
  padding: 10px 22px; border-radius: 999px;
  background: var(--orange); color: #fff;
  font-size: 13px; font-weight: 800;
  text-decoration: none; white-space: nowrap;
  transition: background .15s;
}
.v3-cta-btn:hover { background: var(--orange-dark); }

/* ── Social channels bar ───────────────────────────────── */
.home-social-bar {
  padding: 28px 28px 32px;
  background: #fff;
  border-bottom: 2px solid #f0f2f5;
}
.home-social-label {
  font-size: 11px;
  font-weight: 900;
  text-transform: uppercase;
  letter-spacing: .08em;
  color: var(--muted);
  margin-bottom: 14px;
  font-family: "Montserrat", system-ui, sans-serif;
}
.home-social-channels {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 14px;
}

.home-social-card {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 16px 18px;
  border-radius: 14px;
  text-decoration: none;
  color: inherit;
  border: 2px solid transparent;
  transition: transform .18s, box-shadow .18s, border-color .18s;
  position: relative;
  overflow: hidden;
}
.home-social-card::before {
  content: '';
  position: absolute;
  inset: 0;
  opacity: .07;
  transition: opacity .18s;
}
.home-social-card:hover { transform: translateY(-3px); box-shadow: 0 10px 28px rgba(0,0,0,.10); }
.home-social-card:hover::before { opacity: .13; }

/* LINE */
.home-social-line { background: #f0fff5; border-color: #b7ebc8; }
.home-social-line::before { background: #06C755; }
.home-social-line:hover { border-color: #06C755; }

/* Shopee */
.home-social-shopee { background: #fff5f3; border-color: #fcc8bc; }
.home-social-shopee::before { background: #EE4D2D; }
.home-social-shopee:hover { border-color: #EE4D2D; }

/* Facebook */
.home-social-facebook { background: #f0f4ff; border-color: #bfd0fb; }
.home-social-facebook::before { background: #1877F2; }
.home-social-facebook:hover { border-color: #1877F2; }

.home-social-icon {
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 52px;
  height: 52px;
  border-radius: 12px;
  background: #fff;
  box-shadow: 0 2px 8px rgba(0,0,0,.08);
  position: relative;
  z-index: 1;
}
.home-social-info {
  flex: 1;
  min-width: 0;
  position: relative;
  z-index: 1;
}
.home-social-info strong {
  display: block;
  font-family: "Montserrat", system-ui, sans-serif;
  font-size: 15px;
  font-weight: 900;
  color: #050a0f;
  line-height: 1.2;
}
.home-social-info span {
  display: block;
  font-size: 13px;
  font-weight: 700;
  color: #374151;
  margin-top: 2px;
}
.home-social-info em {
  display: block;
  font-size: 11.5px;
  font-weight: 500;
  color: var(--muted);
  margin-top: 3px;
  font-style: normal;
}
.home-social-arrow {
  font-size: 18px;
  color: #9ca3af;
  flex-shrink: 0;
  position: relative;
  z-index: 1;
  transition: transform .18s, color .18s;
}
.home-social-card:hover .home-social-arrow { transform: translateX(4px); color: #374151; }

@media (max-width: 768px) {
  .home-social-bar { padding: 20px 16px 24px; }
  .home-social-channels { grid-template-columns: 1fr; gap: 10px; }
  .home-social-card { padding: 14px 16px; }
  .home-social-icon { width: 44px; height: 44px; }
  .home-social-info strong { font-size: 14px; }
}

/* ── Hero banner ────────────────────────────────────────── */
.home-hero-banner {
  display: block;
  line-height: 0;
  background: #0b1625;
}
.home-hero-banner a {
  display: block;
  line-height: 0;
}
.home-hero-banner img {
  display: block;
  width: 100%;
  height: auto;
  max-height: 520px;
  object-fit: cover;
  object-position: center top;
}
@media (max-width: 600px) {
  .home-hero-banner img { max-height: 220px; object-position: left top; }
}

/* ── Home catalog sections ──────────────────────────────── */
.home-catalog-head { padding: 32px 28px 0; }
.home-catalog-head h2 { margin: 0 0 4px; font-size: 22px; font-weight: 900; color: #050a0f; }
.home-catalog-head p  { margin: 0; font-size: 14px; color: var(--muted); font-weight: 600; }

/* Category jump tabs */
.home-cat-tabs {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  padding: 16px 28px 0;
}
.home-cat-tab {
  display: inline-flex;
  align-items: center;
  min-height: 32px;
  padding: 0 16px;
  border: 1.5px solid var(--line);
  border-radius: 999px;
  font-size: 13px;
  font-weight: 800;
  color: #374151;
  text-decoration: none;
  background: #fff;
  font-family: "Montserrat", system-ui, sans-serif;
  transition: background .15s, border-color .15s, color .15s;
}
.home-cat-tab:hover { background: var(--deep); color: #fff; border-color: var(--deep); }

/* Category section */
.home-cat-section {
  padding: 32px 28px 0;
  border-top: 2px solid #f0f2f5;
  margin-top: 32px;
}
.home-cat-section:first-of-type { border-top: 0; margin-top: 0; }

.home-cat-header {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 8px;
}
.home-cat-title-wrap { display: flex; align-items: baseline; gap: 10px; flex-wrap: wrap; }
.home-cat-title {
  margin: 0;
  font-family: "Montserrat", system-ui, sans-serif;
  font-size: 20px;
  font-weight: 900;
  color: #050a0f;
  border-left: 4px solid #c0392b;
  padding-left: 12px;
}
.home-cat-th { font-size: 13px; color: var(--muted); font-weight: 700; }
.home-cat-all-link {
  flex-shrink: 0;
  font-size: 13px;
  font-weight: 800;
  color: var(--orange-dark);
  text-decoration: none;
  white-space: nowrap;
  font-family: "Montserrat", system-ui, sans-serif;
}
.home-cat-all-link:hover { text-decoration: underline; }

.home-cat-desc {
  margin: 0 0 18px;
  font-size: 13.5px;
  color: #4b5563;
  font-weight: 500;
  line-height: 1.65;
  max-width: 720px;
}

/* "View all" card */
.v3-model-card-more {
  border-style: dashed !important;
  border-color: #c8cdd5 !important;
  background: #f8f9fb !important;
  align-items: center;
  justify-content: center;
  min-height: 200px;
}
.v3-model-card-more:hover {
  border-color: var(--orange) !important;
  background: #fff5ed !important;
}
.v3-more-inner {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
  text-align: center;
  padding: 20px;
}
.v3-more-icon {
  font-size: 28px;
  color: var(--orange);
  line-height: 1;
}
.v3-more-inner strong {
  font-family: "Montserrat", system-ui, sans-serif;
  font-size: 14px;
  font-weight: 900;
  color: var(--deep);
}
.v3-more-inner > span {
  font-size: 12px;
  color: var(--muted);
  font-weight: 600;
}

/* Footer */
.home-footer {
  margin-top: 40px;
  padding: 24px 28px;
  background: #0d1117;
  color: #8b9ab0;
  font-size: 13px;
  text-align: center;
}
.home-footer-links {
  margin: 0 0 10px;
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 6px 20px;
}
.home-footer-links a { color: #a8c4e0; font-weight: 700; text-decoration: none; }
.home-footer-links a:hover { color: #fff; }
.home-footer-about {
  color: rgba(255,255,255,0.45);
  font-size: 11px;
  line-height: 1.65;
  max-width: 720px;
  margin: 0 auto 10px;
  padding: 0 12px;
  text-align: center;
}
.home-footer-about strong { color: rgba(255,255,255,0.7); }
.home-footer-copy { margin: 0; }
.home-footer-views { margin: 6px 0 0; font-size: 11px; color: #6a8099; }

/* ── Shopee badge on product cards ─────────────────────── */
.v3-model-card-img { position: relative; }
.v3-shopee-badge {
  position: absolute;
  top: 6px;
  right: 6px;
  background: #EE4D2D;
  color: #fff;
  font-size: 10px;
  font-weight: 700;
  line-height: 1;
  padding: 3px 7px;
  border-radius: 4px;
  letter-spacing: 0.4px;
  text-transform: uppercase;
  z-index: 2;
  pointer-events: none;
  font-family: "Montserrat", system-ui, sans-serif;
}

/* ── Shoppe btn ────────────────────────────────────────── */
.shopee-btn {
  display: inline-flex; align-items: center; gap: 5px;
  padding: 5px 14px; border-radius: 999px;
  background: var(--orange); color: #fff; border: none;
  font-size: 12px; font-weight: 800; cursor: pointer;
  text-decoration: none; white-space: nowrap;
  transition: background .15s;
}
.shopee-btn:hover { background: var(--orange-dark); }
.no-link { color: #adb5bd; font-size: 12px; }

/* ── Pills ─────────────────────────────────────────────── */
.pill          { display: inline-block; font-size: 11px; padding: 3px 10px; border-radius: 999px; font-weight: 800; }
.pill-nbr      { background: #dbeafe; color: #1e40af; }
.pill-viton    { background: #fff5ed; color: var(--orange-dark); }
.pill-stock    { background: #dcfce7; color: #15803d; }
.pill-low      { background: #fef3c7; color: #92400e; }
.pill-vlow     { background: #fee2e2; color: #b91c1c; }
.pill-nostock  { background: var(--soft); color: var(--muted); }

/* ── Filter row (search.php) ───────────────────────────── */
.v3-filter-row {
  display: flex;
  align-items: flex-end;
  gap: 10px;
  flex-wrap: wrap;
  padding: 12px 28px 16px;
  background: #05070a;
  border-top: 1px solid rgba(255,255,255,.08);
}
.v3-filter-group {
  display: flex;
  flex-direction: column;
  gap: 4px;
}
.v3-filter-group label {
  font-size: 11px;
  font-weight: 800;
  color: rgba(255,255,255,.5);
  text-transform: uppercase;
  letter-spacing: .06em;
  font-family: "Montserrat", system-ui, sans-serif;
}
.v3-filter-group select {
  height: 38px;
  padding: 0 10px;
  border: 1.5px solid rgba(255,255,255,.18);
  border-radius: 6px;
  background: rgba(255,255,255,.08);
  color: #e2e8f0;
  font: inherit;
  font-size: 13px;
  font-weight: 700;
  cursor: pointer;
  min-width: 140px;
}
.v3-filter-group select:focus { outline: 0; border-color: var(--orange); }
.v3-filter-group select option { background: #0d1117; color: #e2e8f0; }
.v3-clear-btn {
  height: 38px;
  padding: 0 18px;
  border: 1.5px solid rgba(255,255,255,.18);
  border-radius: 6px;
  background: transparent;
  color: rgba(255,255,255,.7);
  font: inherit;
  font-size: 13px;
  font-weight: 800;
  cursor: pointer;
  align-self: flex-end;
  font-family: "Montserrat", system-ui, sans-serif;
}
.v3-clear-btn:hover { background: rgba(255,255,255,.1); color: #fff; }

.search-meta {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 12px 16px 8px;
  font-size: 13px;
  font-weight: 700;
  color: var(--muted);
}

/* ── Zoom overlay ──────────────────────────────────────── */
#zoomOverlay { align-items: center; justify-content: center; }

/* ── Drawer hidden on desktop ───────────────────────────── */
.nav-overlay,
.nav-drawer { display: none; }
/* Mobile: hide inline nav-links, show hamburger instead */
@media (max-width: 900px) {
  .site-header > .nav-links { display: none !important; }
  .nav-overlay { display: block; position: fixed; inset: 0; z-index: 8999; background: rgba(0,0,0,.5); }
  body:not(.nav-open) .nav-overlay { display: none; }
  .nav-drawer {
    display: flex;
    flex-direction: column;
    position: fixed;
    top: 0; left: 0;
    width: min(300px, 86vw);
    height: 100dvh;
    overflow-y: auto;
    background: #fff;
    z-index: 9001;
    box-shadow: 4px 0 32px rgba(0,0,0,.25);
    transform: translateX(-100%);
    transition: transform .25s cubic-bezier(.4,0,.2,1);
  }
  body.nav-open .nav-drawer {
    transform: translateX(0);
  }
}

/* ── Responsive ────────────────────────────────────────── */
@media (max-width: 900px) {
  .header-main { grid-template-columns: auto 1fr auto; gap: 8px; padding: 0 14px; min-height: 52px; }
  .header-actions { display: none; }
  .hamburger-button { display: flex; }
  .global-search { height: 36px; }
  .global-search input { font-size: 13px; padding: 0 10px; }
  .global-search button { padding: 0 12px; font-size: 12px; }
}

@media (max-width: 768px) {

  .v3-subnav     { padding: 0 12px; min-height: 38px; }
  .v3-subnav-item { font-size: 11px; padding: 0 10px; min-height: 26px; }
  .v3-series-strip { padding: 8px 12px; }
  .v3-series-card  { width: 70px; }
  .v3-series-card img { width: 48px; height: 48px; }

  .v3-overview-hero { padding: 20px 16px; }
  .v3-overview-grid-wrap { padding: 16px 16px 28px; }
  .v3-model-grid { grid-template-columns: repeat(auto-fill, minmax(155px, 1fr)); gap: 10px; }
  .v3-model-card-img { min-height: 120px; padding: 12px; }
  .v3-model-card-img img { max-height: 120px; }

  .v3-cta-bar { padding: 16px; flex-direction: column; text-align: center; }
  .v3-cta-btn { justify-content: center; width: 100%; }

  .v3-pagination { padding: 10px 12px; gap: 3px; }
  .v3-pagination .pg-btn { min-width: 28px; height: 28px; font-size: 12px; }

  .v3-filter-row { padding: 10px 14px 12px; gap: 8px; }
  .v3-filter-group select { min-width: 120px; font-size: 12px; }
}

/* ============================================================
   Article pages (article/index.php + article/view.php)
   ============================================================ */

/* ── Hero ────────────────────────────────────────────────── */
.art-hero {
  background: linear-gradient(135deg, #071d3c 0%, #0d2d5e 60%, #1a3a6b 100%);
  padding: 48px 28px 44px;
  position: relative;
  overflow: hidden;
}
.art-hero::after {
  content: '';
  position: absolute;
  right: -60px; top: -60px;
  width: 340px; height: 340px;
  border-radius: 50%;
  background: rgba(255,255,255,.04);
}
.art-hero-inner { max-width: 720px; position: relative; z-index: 1; }
.art-hero .eyebrow {
  font-size: 11px; font-weight: 900; letter-spacing: .1em;
  color: var(--orange); text-transform: uppercase; margin: 0 0 10px;
  font-family: "Montserrat", system-ui, sans-serif;
}
.art-hero h1 {
  font-size: clamp(22px, 4vw, 34px); font-weight: 900;
  color: #fff; margin: 0 0 12px; line-height: 1.2;
}
.art-hero p { color: rgba(255,255,255,.7); font-size: 15px; margin: 0; }

/* ── Filter bar ──────────────────────────────────────────── */
.art-filter-bar {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  padding: 16px 28px;
  background: #fff;
  border-bottom: 1px solid #ebedf0;
}
.art-filter-tab {
  display: inline-flex;
  align-items: center;
  min-height: 32px;
  padding: 0 16px;
  border: 1.5px solid var(--line);
  border-radius: 999px;
  font-size: 13px;
  font-weight: 800;
  color: #374151;
  text-decoration: none;
  background: #fff;
  font-family: "Montserrat", system-ui, sans-serif;
  transition: all .15s;
}
.art-filter-tab:hover { background: #f3f4f6; border-color: #9ca3af; }
.art-filter-tab.active { background: var(--deep); color: #fff; border-color: var(--deep); }

/* ── Article grid (listing) ──────────────────────────────── */
.art-grid-wrap {
  max-width: 1200px;
  margin: 0 auto;
  padding: 32px 28px 48px;
}
.art-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
  gap: 24px;
}
.art-card {
  display: flex;
  flex-direction: column;
  border: 1px solid #e4e7ec;
  border-radius: 12px;
  overflow: hidden;
  background: #fff;
  text-decoration: none;
  color: inherit;
  box-shadow: 0 1px 4px rgba(0,0,0,.05);
  transition: box-shadow .2s, transform .2s;
}
.art-card:hover {
  box-shadow: 0 8px 28px rgba(7,29,60,.12);
  transform: translateY(-3px);
}
.art-card-img {
  aspect-ratio: 16/9;
  overflow: hidden;
  background: #f3f4f6;
}
.art-card-img img {
  width: 100%; height: 100%;
  object-fit: cover;
  transition: transform .3s;
}
.art-card:hover .art-card-img img { transform: scale(1.04); }
.art-card-body {
  display: flex;
  flex-direction: column;
  flex: 1;
  padding: 18px 20px 20px;
}
.art-card-meta {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 10px;
}
.art-cat {
  display: inline-block;
  font-size: 11px; font-weight: 900;
  padding: 3px 10px;
  border-radius: 999px;
  background: #dbeafe; color: #1e40af;
  font-family: "Montserrat", system-ui, sans-serif;
  text-transform: uppercase; letter-spacing: .05em;
}
.art-date { font-size: 12px; color: var(--muted); font-weight: 600; }
.art-card-title {
  margin: 0 0 8px;
  font-size: 16px; font-weight: 900;
  color: #111827; line-height: 1.4;
}
.art-card-excerpt {
  margin: 0 0 14px;
  font-size: 13.5px; color: #4b5563;
  line-height: 1.65; flex: 1;
}
.art-read-more {
  font-size: 13px; font-weight: 800;
  color: var(--orange-dark);
  font-family: "Montserrat", system-ui, sans-serif;
}

/* ── Article view layout ─────────────────────────────────── */
.art-breadcrumb {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 10px 28px;
  font-size: 13px; color: var(--muted); font-weight: 600;
  background: #f9fafb;
  border-bottom: 1px solid #ebedf0;
}
.art-breadcrumb a { color: var(--deep); text-decoration: none; }
.art-breadcrumb a:hover { text-decoration: underline; }

.art-layout {
  display: grid;
  grid-template-columns: 1fr 320px;
  gap: 32px;
  max-width: 1100px;
  margin: 0 auto;
  padding: 36px 28px 56px;
  align-items: start;
}

/* Main article */
.art-article-head { margin-bottom: 24px; }
.art-article-meta {
  display: flex; align-items: center; gap: 10px; margin-bottom: 14px;
}
.art-article-meta time { font-size: 13px; color: var(--muted); font-weight: 600; }
.art-main h1 {
  font-size: clamp(20px, 3.5vw, 30px); font-weight: 900;
  color: #050a0f; margin: 0 0 14px; line-height: 1.35;
}
.art-article-lead {
  font-size: 16px; color: #374151; line-height: 1.7; margin: 0;
  border-left: 4px solid var(--orange); padding-left: 16px;
  background: #fff8f0; padding: 14px 16px; border-radius: 0 8px 8px 0;
}
.art-cover {
  border-radius: 10px; overflow: hidden;
  margin-bottom: 28px; line-height: 0;
  box-shadow: 0 2px 16px rgba(0,0,0,.10);
}
.art-cover img { width: 100%; height: auto; max-height: 420px; object-fit: cover; }

/* Article body typography */
.art-content { line-height: 1.8; color: #1f2937; font-size: 15.5px; }
.art-content h2 {
  font-size: 20px; font-weight: 900; color: var(--deep);
  margin: 32px 0 12px; padding-bottom: 8px;
  border-bottom: 2px solid #e5e7eb;
}
.art-content h3 {
  font-size: 16px; font-weight: 900; color: #1f2937; margin: 22px 0 8px;
}
.art-content p  { margin: 0 0 16px; }
.art-content ul,
.art-content ol { padding-left: 22px; margin: 0 0 16px; }
.art-content li { margin-bottom: 6px; }
.art-content strong { color: #050a0f; }

/* Prev / Next */
.art-prev-next {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
  margin-top: 40px;
  padding-top: 24px;
  border-top: 2px solid #f0f2f5;
}
.art-prev, .art-next {
  display: flex; flex-direction: column; gap: 4px;
  padding: 14px 16px; border: 1.5px solid #e4e7ec;
  border-radius: 8px; text-decoration: none; color: inherit;
  background: #fff; transition: border-color .15s, background .15s;
}
.art-prev:hover, .art-next:hover { border-color: var(--orange); background: #fff8f0; }
.art-next { text-align: right; }
.pn-label { font-size: 11px; font-weight: 900; color: var(--muted); text-transform: uppercase; letter-spacing: .05em; font-family: "Montserrat", system-ui, sans-serif; }
.pn-title { font-size: 13.5px; font-weight: 700; color: #1a2332; line-height: 1.4; }

/* Sidebar */
.art-sidebar { display: flex; flex-direction: column; gap: 20px; position: sticky; top: 80px; }

.art-sidebar-cta {
  background: var(--deep); color: #fff;
  border-radius: 12px; padding: 24px 20px;
  display: flex; flex-direction: column; gap: 8px; text-align: center;
}
.art-sidebar-cta-icon { font-size: 28px; }
.art-sidebar-cta strong { font-size: 15px; font-weight: 900; display: block; }
.art-sidebar-cta p { margin: 0; font-size: 13px; color: rgba(255,255,255,.7); }
.art-cta-btn {
  display: block; padding: 11px 0; border-radius: 8px;
  font-size: 14px; font-weight: 900; text-decoration: none; text-align: center;
  font-family: "Montserrat", system-ui, sans-serif;
  transition: opacity .15s;
}
.art-cta-btn:hover { opacity: .88; }
.art-cta-line   { background: #06C755; color: #fff; }
.art-cta-shopee { background: var(--orange); color: #fff; margin-top: 4px; }

.art-sidebar-related {
  background: #fff; border: 1px solid #e4e7ec;
  border-radius: 12px; padding: 20px; display: flex; flex-direction: column; gap: 12px;
}
.art-sidebar-related h3 {
  font-size: 13px; font-weight: 900; color: var(--muted);
  text-transform: uppercase; letter-spacing: .06em; margin: 0;
  font-family: "Montserrat", system-ui, sans-serif;
}
.art-related-item {
  display: flex; gap: 10px; align-items: center;
  text-decoration: none; color: #1a2332;
  font-size: 13.5px; font-weight: 600; line-height: 1.45;
}
.art-related-item img { width: 56px; height: 40px; object-fit: cover; border-radius: 6px; flex-shrink: 0; }
.art-related-item:hover { color: var(--orange-dark); }

.art-sidebar-search {
  background: #f9fafb; border: 1px solid #e4e7ec;
  border-radius: 12px; padding: 20px;
}
.art-sidebar-search h3 {
  font-size: 13px; font-weight: 900; color: var(--muted);
  text-transform: uppercase; letter-spacing: .06em; margin: 0 0 12px;
  font-family: "Montserrat", system-ui, sans-serif;
}
.art-sidebar-search form { display: flex; gap: 0; border-radius: 6px; overflow: hidden; border: 2px solid var(--deep); }
.art-sidebar-search input { flex: 1; padding: 8px 10px; border: 0; font: inherit; font-size: 13px; outline: 0; min-width: 0; }
.art-sidebar-search button { padding: 0 14px; background: var(--deep); color: #fff; border: 0; font: inherit; font-size: 12px; font-weight: 900; cursor: pointer; white-space: nowrap; }

/* ── Article responsive ──────────────────────────────────── */
@media (max-width: 900px) {
  .art-layout { grid-template-columns: 1fr; padding: 20px 16px 40px; }
  .art-sidebar { position: static; }
  .art-grid-wrap { padding: 20px 16px 36px; }
  .art-grid { grid-template-columns: 1fr; gap: 16px; }
  .art-filter-bar { padding: 12px 16px; }
  .art-hero { padding: 28px 16px 24px; }
  .art-breadcrumb { padding: 8px 16px; }
  .art-prev-next { grid-template-columns: 1fr; }
}

/* ── Series datasheet links ────────────────────────────────── */
.series-datasheet-links {
  margin-top: 16px;
  padding: 14px 16px;
  background: #f0f7ff;
  border: 1.5px solid #bfd9f7;
  border-radius: 8px;
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.series-datasheet-links strong {
  display: block;
  font-size: 11px;
  font-weight: 900;
  color: var(--muted);
  text-transform: uppercase;
  letter-spacing: .06em;
  font-family: "Montserrat", system-ui, sans-serif;
  margin-bottom: 2px;
}
.series-datasheet-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 9px 14px;
  background: var(--deep);
  color: #fff;
  border-radius: 6px;
  font-size: 12.5px;
  font-weight: 700;
  text-decoration: none;
  font-family: "Montserrat", system-ui, sans-serif;
  transition: opacity .15s;
}
.series-datasheet-btn:hover { opacity: .85; }

/* ── Back to Top button ─────────────────────────────────────── */
#backToTop {
  position: fixed;
  bottom: 24px;
  right: 20px;
  z-index: 990;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: var(--deep);
  color: #fff;
  border: none;
  font-size: 22px;
  font-weight: 900;
  line-height: 1;
  cursor: pointer;
  box-shadow: 0 4px 18px rgba(0,0,0,.28);
  opacity: 0;
  pointer-events: none;
  transition: opacity .25s, transform .2s, background .15s;
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: "Montserrat", system-ui, sans-serif;
}
#backToTop.visible     { opacity: 1; pointer-events: auto; }
#backToTop:hover       { transform: translateY(-3px); background: #0d2d5e; }

/* ── Live viewers badge ──────────────────────────────────────── */
.live-viewers-badge {
  position: fixed;
  bottom: 80px;
  right: 16px;
  z-index: 989;
  display: flex;
  align-items: center;
  gap: 7px;
  padding: 7px 14px 7px 10px;
  background: rgba(255,255,255,.97);
  border: 1.5px solid #dde4ee;
  border-radius: 999px;
  font-size: 12.5px;
  font-weight: 700;
  color: #1a2332;
  box-shadow: 0 4px 18px rgba(0,0,0,.13);
  backdrop-filter: blur(8px);
  font-family: "Montserrat", system-ui, sans-serif;
  user-select: none;
  pointer-events: none;
}
.live-viewers-badge strong { color: #15803d; }

.live-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #22c55e;
  flex-shrink: 0;
  animation: livePulse 2s ease-in-out infinite;
}
@keyframes livePulse {
  0%,100% { box-shadow: 0 0 0 2px rgba(34,197,94,.3); }
  50%     { box-shadow: 0 0 0 6px rgba(34,197,94,.0); }
}

/* Mobile adjustments */
@media (max-width: 600px) {
  #backToTop             { bottom: 16px; right: 14px; width: 40px; height: 40px; font-size: 19px; }
  .live-viewers-badge    { bottom: 66px; right: 10px; font-size: 11.5px; padding: 6px 12px 6px 8px; }
}
