/* ===================================================================
   V3 catalogue structure (EKK-style interaction, XH-CHIP visual style)
   Header · mega menu · contact bar · tables · DigiKey-style product page
   =================================================================== */

/* ---------- header ---------- */
.v3-header { position: sticky; top: 0; z-index: 50; background: var(--white); box-shadow: 0 1px 0 var(--line); }
.v3-header .site-header__inner { display: none; }
.v3-topbar { background: var(--navy); color: rgba(255,255,255,.78); font-size: 12.5px; }
.v3-topbar__inner { display: flex; align-items: center; justify-content: space-between; gap: 16px; min-height: 34px; }
.v3-topbar__claim { display: flex; align-items: center; gap: 8px; margin: 0; }
.v3-topbar__links { display: flex; align-items: center; gap: 18px; }
.v3-topbar__links a { color: rgba(255,255,255,.82); }
.v3-topbar__links a:hover { color: #fff; }
.v3-mainbar { display: flex; align-items: center; gap: 24px; min-height: 74px; }
.v3-mainbar .brand__logo { width: 190px; height: auto; }
.v3-search { position: relative; flex: 1 1 auto; max-width: 640px; margin: 0; display: flex; }
.v3-search input { flex: 1; height: 46px; padding: 0 14px 0 42px; border: 2px solid var(--brand); border-right: 0; border-radius: 12px 0 0 12px; font-size: 15px; background: var(--white); color: var(--ink); }
.v3-search input:focus { outline: none; box-shadow: 0 0 0 3px rgba(11, 95, 224, .15); }
.v3-search .header-search__icon { left: 14px; }
.v3-search__btn { height: 46px; padding: 0 22px; border: 0; border-radius: 0 12px 12px 0; background: var(--brand); color: #fff; font: inherit; font-weight: 600; font-size: 15px; cursor: pointer; }
.v3-search__btn:hover { background: #0950c0; }
.v3-search .search-suggest { top: calc(100% + 6px); min-width: 100%; }
.v3-actions { display: flex; align-items: center; gap: 12px; margin-left: auto; }
.v3-cart { position: relative; display: inline-flex; align-items: center; gap: 6px; padding: 8px 10px; border-radius: 10px; color: var(--ink); font-weight: 600; font-size: 14px; }
.v3-cart:hover { background: var(--bg-tint); }
.v3-cart svg { width: 24px; height: 24px; }
.v3-cart__count { position: absolute; top: 2px; left: 24px; min-width: 18px; height: 18px; padding: 0 5px; border-radius: 9px; background: #e5482d; color: #fff; font-size: 11px; line-height: 18px; text-align: center; }
.v3-navrow { background: var(--brand); }
.v3-navrow__inner { display: flex; align-items: center; gap: 4px; min-height: 46px; }
.v3-navrow .primary-nav__link { color: rgba(255,255,255,.9); padding: 0 14px; height: 46px; display: inline-flex; align-items: center; font-weight: 600; font-size: 14.5px; border-radius: 0; }
.v3-navrow .primary-nav__link:hover, .v3-navrow .primary-nav__link.is-active { color: #fff; background: rgba(255,255,255,.12); }
.v3-navrow .primary-nav__link::after { display: none; }
.lang-switch { position: relative; }
.lang-switch__btn { display: inline-flex; align-items: center; gap: 6px; padding: 4px 8px; border: 1px solid rgba(255,255,255,.25); border-radius: 8px; background: transparent; color: #fff; font: inherit; font-size: 12.5px; cursor: pointer; }
.lang-switch__btn svg { width: 14px; height: 14px; }
.lang-switch__menu { position: absolute; right: 0; top: calc(100% + 6px); z-index: 70; min-width: 170px; margin: 0; padding: 6px; list-style: none; background: var(--white); border: 1px solid var(--line); border-radius: 12px; box-shadow: 0 20px 50px -24px rgba(5,28,64,.45); }
.lang-switch__menu a { display: block; padding: 7px 10px; border-radius: 8px; color: var(--ink); font-size: 13.5px; }
.lang-switch__menu a:hover, .lang-switch__menu a.is-active { background: var(--bg-tint); color: var(--brand); }

/* ---------- mega menu ---------- */
.mega { position: relative; margin-right: 8px; }
.mega__btn { display: inline-flex; align-items: center; gap: 10px; height: 46px; min-width: 230px; padding: 0 18px; border: 0; background: #0848ad; color: #fff; font: inherit; font-weight: 700; font-size: 14.5px; cursor: pointer; }
.mega__btn svg { width: 16px; height: 16px; }
.mega__panel { position: absolute; left: 0; top: 100%; z-index: 60; display: flex; flex-direction: column; width: min(1100px, calc(100vw - 48px)); max-height: 72vh; background: var(--white); border: 1px solid var(--line); border-top: 0; border-radius: 0 0 14px 14px; box-shadow: 0 30px 70px -30px rgba(5,28,64,.5); }
.mega__tops { position: relative; display: block; width: 260px; margin: 0; padding: 8px 0; list-style: none; border-right: 1px solid var(--line); overflow: visible; flex: 1; }
.mega__top > a { display: flex; align-items: center; justify-content: space-between; gap: 8px; padding: 9px 18px; color: var(--ink); font-size: 14px; font-weight: 500; }
.mega__top > a small { color: var(--ink-muted); font-size: 12px; }
.mega__top.is-active > a, .mega__top > a:hover { background: var(--bg-tint); color: var(--brand); }
.mega__sub { display: none; position: absolute; left: 260px; top: 0; width: calc(min(1100px, 100vw - 48px) - 262px); min-height: 100%; max-height: 72vh; overflow: auto; padding: 18px 24px; background: var(--white); column-count: 3; column-gap: 24px; }
.mega__top.is-active .mega__sub { display: block; }
.mega__group { break-inside: avoid; margin-bottom: 16px; }
.mega__mid { display: block; margin-bottom: 6px; color: var(--ink); font-weight: 700; font-size: 14px; }
.mega__leaf { display: block; padding: 3px 0; color: var(--ink-soft); font-size: 13px; }
.mega__leaf:hover, .mega__mid:hover { color: var(--brand); }
.mega__leaf small { color: var(--ink-muted); }
.mega__empty { color: var(--ink-muted); font-size: 13px; }
.mega__all { display: block; padding: 10px 18px; border-top: 1px solid var(--line); color: var(--brand); font-weight: 600; font-size: 13.5px; width: 260px; }

/* ---------- contact bar ---------- */
.contact-bar { position: fixed; right: 0; top: 50%; z-index: 45; display: flex; flex-direction: column; transform: translateY(-50%); }
.contact-bar__item { position: relative; display: grid; place-items: center; width: 52px; height: 52px; margin-bottom: 1px; border: 0; background: var(--brand); color: #fff; cursor: pointer; }
.contact-bar__item:first-child { border-top-left-radius: 10px; }
.contact-bar__item:last-child { border-bottom-left-radius: 10px; }
.contact-bar__item svg { width: 24px; height: 24px; }
.contact-bar__item:hover, .contact-bar__item:focus-visible { background: #0848ad; }
.contact-bar__item--wa:hover { background: #1fa855; }
.contact-bar__item--wechat:hover { background: #07b53b; }
.contact-bar__tip { position: absolute; right: calc(100% + 8px); top: 50%; display: none; min-width: 150px; padding: 10px 12px; border-radius: 10px; background: var(--white); color: var(--ink); font-size: 12.5px; line-height: 1.5; text-align: left; white-space: nowrap; box-shadow: 0 16px 40px -18px rgba(5,28,64,.5); transform: translateY(-50%); }
.contact-bar__tip img { display: block; margin-top: 8px; border-radius: 6px; }
.contact-bar__item:hover .contact-bar__tip, .contact-bar__item:focus-visible .contact-bar__tip, .contact-bar__item:focus-within .contact-bar__tip { display: block; }
.contact-bar__tip b { font-weight: 700; }
.contact-bar__top { background: #3d4a5c; }

/* ---------- page frame ---------- */
.v3-page { padding: 22px 0 64px; background: var(--bg); }
.v3-crumbs { display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: 14px; color: var(--ink-muted); font-size: 13px; }
.v3-crumbs a { color: var(--ink-soft); }
.v3-crumbs a:hover { color: var(--brand); }
.v3-title { margin: 0 0 6px; font-size: clamp(24px, 3vw, 32px); letter-spacing: -.02em; }
.v3-lead { margin: 0 0 18px; color: var(--ink-soft); max-width: 900px; }
.v3-box { background: var(--white); border: 1px solid var(--line); border-radius: var(--radius-sm); }
.v3-box + .v3-box { margin-top: 16px; }
.v3-box__head { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 14px 18px; border-bottom: 1px solid var(--line); }
.v3-box__head h2, .v3-box__head h3 { margin: 0; font-size: 17px; }
.v3-box__body { padding: 16px 18px; }

/* subcategory chips (EKK "classification") */
.v3-subcats { display: grid; grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); gap: 6px 18px; }
.v3-subcats a { color: var(--ink-soft); font-size: 13.5px; padding: 4px 0; }
.v3-subcats a:hover { color: var(--brand); }
.v3-subcats a small { color: var(--ink-muted); }

/* ---------- catalogue layout ---------- */
.v3-catalog { display: grid; grid-template-columns: 250px minmax(0, 1fr); gap: 18px; align-items: start; }
.v3-filters { position: sticky; top: 170px; max-height: calc(100vh - 190px); overflow: auto; }
.v3-filter { padding: 12px 16px; border-bottom: 1px solid var(--line); }
.v3-filter:last-child { border-bottom: 0; }
.v3-filter h4 { margin: 0 0 8px; font-size: 13px; text-transform: uppercase; letter-spacing: .06em; color: var(--ink-muted); }
.v3-filter a { display: flex; justify-content: space-between; gap: 8px; padding: 4px 6px; margin: 0 -6px; border-radius: 6px; color: var(--ink); font-size: 13.5px; }
.v3-filter a:hover { background: var(--bg-tint); }
.v3-filter a.is-active { background: var(--brand); color: #fff; }
.v3-filter a small { color: inherit; opacity: .65; }
.v3-filter details summary { cursor: pointer; font-size: 13px; color: var(--brand); margin-top: 4px; }
.v3-toolbar { display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap; padding: 12px 16px; border-bottom: 1px solid var(--line); background: var(--bg-tint); border-radius: var(--radius-sm) var(--radius-sm) 0 0; font-size: 13.5px; }
.v3-toolbar__chips { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; }
.v3-chip { display: inline-flex; align-items: center; gap: 6px; padding: 3px 10px; border-radius: 999px; background: var(--brand); color: #fff; font-size: 12.5px; }
.v3-chip a { color: #fff; font-weight: 700; }
.v3-toolbar select { height: 32px; border: 1px solid var(--line-strong); border-radius: 8px; padding: 0 8px; font: inherit; font-size: 13px; background: var(--white); }

/* ---------- parts table ---------- */
.parts-table { width: 100%; border-collapse: collapse; font-size: 13.5px; }
.parts-table th { position: sticky; top: 0; padding: 10px 12px; background: #f2f5fa; color: var(--ink-soft); font-size: 12px; font-weight: 700; text-align: left; text-transform: uppercase; letter-spacing: .04em; border-bottom: 1px solid var(--line); white-space: nowrap; }
.parts-table td { padding: 10px 12px; border-bottom: 1px solid var(--line); vertical-align: middle; }
.parts-table tbody tr:hover { background: #fafcff; }
.parts-table__img { width: 56px; }
.parts-table__img img, .parts-table__img span { display: grid; place-items: center; width: 48px; height: 48px; border-radius: 8px; object-fit: contain; background: #f4f6fa; color: var(--ink-muted); font-size: 11px; font-weight: 700; }
.parts-table__part a { color: var(--brand); font-family: var(--font-mono); font-weight: 700; font-size: 13.5px; text-decoration: underline; text-decoration-color: rgba(11,95,224,.25); text-underline-offset: 3px; }
.parts-table__desc { color: var(--ink-soft); max-width: 340px; }
.parts-table__qty { font-family: var(--font-mono); font-weight: 700; color: #d9480f; font-size: 14px; }
.parts-table__ds a { display: inline-grid; place-items: center; width: 30px; height: 30px; border-radius: 50%; background: #e5482d; color: #fff; font-size: 9.5px; font-weight: 800; }
.parts-table__ds span { color: var(--ink-muted); }
.btn-quote { display: inline-flex; align-items: center; justify-content: center; gap: 6px; height: 32px; padding: 0 12px; border: 0; border-radius: 8px; background: #f76707; color: #fff; font: inherit; font-size: 12.5px; font-weight: 700; white-space: nowrap; cursor: pointer; }
.btn-quote:hover { background: #e8590c; }
.btn-quote.is-added { background: var(--stock-in); }
.v3-pager { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 12px 16px; font-size: 13px; color: var(--ink-soft); }
.v3-pager__links { display: flex; gap: 4px; flex-wrap: wrap; }
.v3-pager__links a, .v3-pager__links span { display: inline-grid; place-items: center; min-width: 34px; height: 34px; padding: 0 8px; border: 1px solid var(--line); border-radius: 8px; color: var(--ink); background: var(--white); }
.v3-pager__links .is-current { background: var(--brand); color: #fff; border-color: var(--brand); }

@media (max-width: 1100px) {
  .v3-catalog { grid-template-columns: 1fr; }
  .v3-filters { position: static; max-height: none; }
  .v3-filters .v3-filter { display: inline-block; vertical-align: top; width: 49%; border-bottom: 0; }
  .mega__btn { min-width: 0; }
  .v3-topbar__claim { display: none; }
}
@media (max-width: 860px) {
  .v3-navrow, .v3-cart__label, .v3-actions .btn--nav { display: none; }
  .v3-mainbar { min-height: 64px; gap: 12px; flex-wrap: wrap; padding-bottom: 10px; }
  .v3-mainbar .brand__logo { width: 140px; }
  .v3-search { order: 3; flex-basis: 100%; max-width: none; }
  .v3-search input { height: 42px; font-size: 16px; }
  .v3-search__btn { height: 42px; padding: 0 14px; }
  .v3-topbar__links a { display: none; }
  .contact-bar { top: auto; bottom: 84px; transform: none; }
  .contact-bar__item { width: 44px; height: 44px; }
  .contact-bar__item:not(.contact-bar__item--wa):not(.contact-bar__item--wechat):not(.contact-bar__top) { display: none; }
  .v3-filters .v3-filter { width: 100%; }
  .parts-table thead { display: none; }
  .parts-table, .parts-table tbody, .parts-table tr, .parts-table td { display: block; width: 100%; }
  .parts-table tr { display: grid; grid-template-columns: 56px 1fr auto; gap: 4px 10px; padding: 12px; border-bottom: 1px solid var(--line); }
  .parts-table td { padding: 0; border: 0; }
  .parts-table__img { grid-row: span 3; }
  .parts-table__desc, .parts-table__pkg, .parts-table__ds, .parts-table__mfr { grid-column: 2 / 4; font-size: 12.5px; }
  .parts-table__pkg:empty, .parts-table__price:empty { display: none; }
  .parts-table__act { grid-column: 3; grid-row: 1; }
}

/* ---------- product page (DigiKey-style) ---------- */
.pd-grid { display: grid; grid-template-columns: minmax(0, 1fr) 360px; gap: 20px; align-items: start; }
.pd-head { display: grid; grid-template-columns: 220px minmax(0, 1fr); gap: 22px; padding: 20px; }
.pd-image { position: relative; display: grid; place-items: center; aspect-ratio: 1; border: 1px solid var(--line); border-radius: 12px; background: #f6f8fb; overflow: hidden; }
.pd-image img { width: 100%; height: 100%; object-fit: contain; }
.pd-image__note { margin-top: 6px; color: var(--ink-muted); font-size: 11.5px; line-height: 1.4; }
.pd-mpn { margin: 2px 0 4px; font-family: var(--font-mono); font-size: clamp(22px, 2.6vw, 30px); letter-spacing: -.01em; word-break: break-all; }
.pd-sub { margin: 0 0 14px; color: var(--ink-soft); font-size: 15px; }
.pd-facts { display: grid; grid-template-columns: 160px minmax(0, 1fr); gap: 0; margin: 0; font-size: 13.5px; border-top: 1px solid var(--line); }
.pd-facts dt, .pd-facts dd { margin: 0; padding: 8px 0; border-bottom: 1px solid var(--line); }
.pd-facts dt { color: var(--ink-muted); }
.pd-facts dd a { color: var(--brand); }
.pd-side { position: sticky; top: 170px; }
.pd-tabs { display: flex; gap: 2px; padding: 0 12px; border-bottom: 1px solid var(--line); overflow-x: auto; }
.pd-tabs button { padding: 13px 14px; border: 0; border-bottom: 3px solid transparent; background: none; color: var(--ink-soft); font: inherit; font-weight: 600; font-size: 14px; white-space: nowrap; cursor: pointer; }
.pd-tabs button[aria-selected="true"] { color: var(--brand); border-bottom-color: var(--brand); }
.pd-panel { padding: 16px 20px 20px; }
.pd-panel[hidden] { display: none; }
.spec-grid { width: 100%; border-collapse: collapse; font-size: 13.5px; }
.spec-grid th, .spec-grid td { padding: 9px 12px; border-bottom: 1px solid var(--line); text-align: left; vertical-align: top; }
.spec-grid thead th { background: #f2f5fa; color: var(--ink-soft); font-size: 12px; text-transform: uppercase; letter-spacing: .04em; }
.spec-grid tbody th { width: 38%; color: var(--ink-soft); font-weight: 500; background: #fbfcfe; }
.spec-grid td small { color: var(--ink-muted); }
.spec-grid .spec-src a { color: var(--ink-muted); font-size: 12px; }
.spec-compiling { display: flex; gap: 12px; align-items: flex-start; padding: 14px 16px; border-radius: 10px; background: #fff8e6; color: #7a5300; font-size: 13.5px; }
.pd-docs { margin: 0; padding: 0; list-style: none; }
.pd-docs li { display: flex; align-items: center; gap: 10px; padding: 10px 0; border-bottom: 1px solid var(--line); font-size: 14px; }
.pd-docs li a { color: var(--brand); }
.pd-related { margin-top: 18px; }
.pd-desc { font-size: 14.5px; line-height: 1.75; color: var(--ink); }
.pd-desc p { margin: 0 0 10px; }
.machine-note { margin-bottom: 14px; padding: 8px 12px; border-radius: 8px; background: var(--bg-tint); color: var(--ink-soft); font-size: 12.5px; }
@media (max-width: 1100px) {
  .pd-grid { grid-template-columns: 1fr; }
  .pd-side { position: static; }
}
@media (max-width: 640px) {
  .pd-head { grid-template-columns: 1fr; }
  .pd-image { max-width: 260px; }
  .pd-facts { grid-template-columns: 120px minmax(0, 1fr); }
}

/* ---------- home ---------- */
.v3-hero { position: relative; padding: 46px 0 40px; background: radial-gradient(1200px 400px at 70% -10%, rgba(47,150,255,.25), transparent), var(--navy); color: #fff; overflow: hidden; }
.v3-hero__grid { display: grid; grid-template-columns: minmax(0, 1.3fr) minmax(0, 1fr); gap: 32px; align-items: center; }
.v3-hero h1 { margin: 0 0 12px; font-size: clamp(30px, 4.4vw, 52px); line-height: 1.05; letter-spacing: -.035em; }
.v3-hero h1 span { color: var(--brand-cyan); }
.v3-hero p { margin: 0 0 22px; color: rgba(255,255,255,.75); font-size: 16px; max-width: 620px; }
.v3-hero .hero-search { margin-top: 0; max-width: 640px; }
.v3-entries { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
.v3-entry { display: flex; flex-direction: column; gap: 6px; padding: 18px; border: 1px solid rgba(255,255,255,.14); border-radius: 14px; background: rgba(255,255,255,.06); color: #fff; transition: background .2s, transform .2s; }
.v3-entry:hover { background: rgba(255,255,255,.12); transform: translateY(-2px); }
.v3-entry strong { font-size: 16px; }
.v3-entry span { color: rgba(255,255,255,.7); font-size: 13px; }
.v3-entry i { font-style: normal; font-size: 22px; }
.v3-stats { display: grid; grid-template-columns: repeat(var(--cols, 4), minmax(0, 1fr)); gap: 0; margin-top: 30px; border-top: 1px solid rgba(255,255,255,.14); }
.v3-stats div { padding: 18px 12px 0; }
.v3-stats strong { display: block; font-size: clamp(22px, 2.6vw, 30px); letter-spacing: -.02em; }
.v3-stats span { color: rgba(255,255,255,.66); font-size: 13px; }
.v3-section { padding: 34px 0 6px; }
.v3-section__head { display: flex; align-items: flex-end; justify-content: space-between; gap: 12px; margin-bottom: 14px; }
.v3-section__head h2 { margin: 0; font-size: 22px; letter-spacing: -.02em; }
.v3-section__head a { color: var(--brand); font-weight: 600; font-size: 14px; }
.v3-tabs { display: flex; gap: 6px; margin-bottom: 12px; flex-wrap: wrap; }
.v3-tabs button { padding: 8px 14px; border: 1px solid var(--line); border-radius: 999px; background: var(--white); color: var(--ink-soft); font: inherit; font-weight: 600; font-size: 13.5px; cursor: pointer; }
.v3-tabs button[aria-selected="true"] { background: var(--brand); border-color: var(--brand); color: #fff; }
.v3-mini-grid { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 10px; }
.v3-mini { display: flex; flex-direction: column; gap: 4px; padding: 14px; border: 1px solid var(--line); border-radius: 12px; background: var(--white); min-width: 0; }
.v3-mini:hover { border-color: var(--brand-bright); box-shadow: var(--shadow-soft); }
.v3-mini strong { font-family: var(--font-mono); font-size: 13.5px; color: var(--ink); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.v3-mini span { color: var(--ink-soft); font-size: 12.5px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.v3-mini > strong, .v3-mini > span:not(.v3-mini__img):not(.stock-badge) { min-width: 0; max-width: 100%; align-self: stretch; text-align: center; }
.v3-mini > span:not(.v3-mini__img):not(.stock-badge) { white-space: normal; overflow-wrap: anywhere; display: -webkit-box; -webkit-box-orient: vertical; -webkit-line-clamp: 2; line-clamp: 2; }
.v3-mini > .stock-badge { min-width: 0; max-width: 100%; white-space: normal; overflow-wrap: anywhere; }
.v3-mini .stock-badge { align-self: center; margin-top: auto; text-align: center; flex-shrink: 0; }
.v3-cat-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 12px; }
.v3-cat { padding: 16px; border: 1px solid var(--line); border-radius: 12px; background: var(--white); }
.v3-cat h3 { margin: 0 0 8px; font-size: 15px; }
.v3-cat h3 a { color: var(--ink); }
.v3-cat a.v3-cat__sub { display: block; padding: 2px 0; color: var(--ink-soft); font-size: 13px; }
.v3-cat a:hover { color: var(--brand); }
.v3-brand-wall { display: flex; flex-wrap: wrap; gap: 10px; }
.v3-brand-wall a { display: inline-flex; align-items: center; gap: 8px; padding: 12px 18px; border: 1px solid var(--line); border-radius: 12px; background: var(--white); color: var(--ink); font-weight: 700; letter-spacing: -.01em; }
.v3-brand-wall a small { color: var(--ink-muted); font-weight: 500; }
.v3-brand-wall a:hover { border-color: var(--brand); color: var(--brand); }
.v3-az { display: flex; flex-wrap: wrap; gap: 6px; }
.v3-az a, .v3-az span { display: grid; place-items: center; width: 36px; height: 36px; border: 1px solid var(--line); border-radius: 8px; background: var(--white); color: var(--ink); font-weight: 700; font-size: 14px; }
.v3-az span { color: var(--ink-muted); opacity: .5; }
.v3-az a:hover, .v3-az a.is-active { background: var(--brand); border-color: var(--brand); color: #fff; }
.v3-parts-list { columns: 4 220px; column-gap: 24px; margin: 0; padding: 0; list-style: none; }
.v3-parts-list li { padding: 4px 0; break-inside: avoid; font-size: 13.5px; }
.v3-parts-list a { font-family: var(--font-mono); color: var(--brand); }
@media (max-width: 1100px) { .v3-mini-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); } .v3-hero__grid { grid-template-columns: 1fr; } }
@media (max-width: 640px) { .v3-mini-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } .v3-stats { grid-template-columns: repeat(2, minmax(0, 1fr)); } .v3-entries { grid-template-columns: 1fr 1fr; } }

/* ---------- BOM ---------- */
.bom-input textarea { width: 100%; min-height: 180px; padding: 12px; border: 1px solid var(--line-strong); border-radius: 10px; font-family: var(--font-mono); font-size: 14px; }
.bom-actions { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; margin-top: 10px; }
.bom-summary { display: flex; flex-wrap: wrap; gap: 10px; margin: 14px 0; }
.bom-summary span { padding: 6px 12px; border-radius: 999px; font-weight: 600; font-size: 13px; }
.bom-table input { width: 100px; height: 32px; padding: 0 8px; border: 1px solid var(--line-strong); border-radius: 6px; font: inherit; }
.bom-contact { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 10px; }
.bom-contact input, .bom-contact textarea { width: 100%; height: 42px; padding: 8px 12px; border: 1px solid var(--line-strong); border-radius: 8px; font: inherit; font-size: 15px; }
.bom-contact textarea { grid-column: 1 / -1; height: 80px; }
@media (max-width: 760px) { .bom-contact { grid-template-columns: 1fr; } }

/* RTL (Arabic) */
[dir="rtl"] .contact-bar { right: auto; left: 0; }
[dir="rtl"] .contact-bar__item:first-child { border-radius: 0 10px 0 0; }
[dir="rtl"] .contact-bar__tip { right: auto; left: calc(100% + 8px); }
[dir="rtl"] .mega__sub { left: auto; right: 260px; }
[dir="rtl"] .v3-search input { border-radius: 0 12px 12px 0; border-right: 2px solid var(--brand); border-left: 0; padding: 0 42px 0 14px; }
[dir="rtl"] .v3-search__btn { border-radius: 12px 0 0 12px; }

/* ===== V3.2 home (DigiKey-style left category rail) ===== */
.home-top { padding: 18px 0 8px; background: var(--bg); }
.home-top__grid { display: grid; grid-template-columns: 300px minmax(0, 1fr); gap: 16px; align-items: stretch; }
.cat-rail { position: relative; z-index: 20; padding: 14px 0 10px; border-radius: 14px; background: #f3f4f6; }
.cat-rail__title { display: inline-flex; gap: 6px; padding: 0 18px 8px; color: var(--ink); font-weight: 800; font-size: 17px; }
.cat-rail ul { margin: 0; padding: 0; list-style: none; }
.cat-rail__row { padding: 7px 18px; font-size: 14px; line-height: 1.45; color: var(--ink-soft); }
.cat-rail__row a { color: var(--ink); }
.cat-rail__row a:hover { color: var(--brand); }
.cat-rail__row:hover, .cat-rail__row:focus-within { background: var(--white); }
.cat-rail__fly { display: none; position: absolute; left: 100%; top: 0; width: min(760px, calc(100vw - 360px)); min-height: 100%; padding: 18px 22px; border: 1px solid var(--line); border-radius: 0 14px 14px 0; background: var(--white); box-shadow: 0 30px 60px -30px rgba(5,28,64,.4); grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px 22px; align-content: start; }
.cat-rail__row:hover .cat-rail__fly, .cat-rail__row:focus-within .cat-rail__fly { display: grid; }
.cat-rail__col a { display: block; padding: 3px 0; font-size: 13px; color: var(--ink-soft); }
.cat-rail__col a small { color: var(--ink-muted); }
.cat-rail__col .cat-rail__head { margin-bottom: 4px; font-size: 14px; font-weight: 700; color: var(--ink); }
.home-top__main { display: flex; flex-direction: column; gap: 14px; min-width: 0; }
.home-hero { padding: 26px 28px; border-radius: 14px; background: radial-gradient(900px 300px at 85% -20%, rgba(47,150,255,.28), transparent), var(--navy); color: #fff; }
.home-hero__eyebrow { display: flex; align-items: center; gap: 8px; margin: 0 0 8px; color: rgba(255,255,255,.75); font-size: 13px; }
.home-hero h1 { margin: 0 0 16px; font-size: clamp(22px, 2.6vw, 32px); line-height: 1.15; letter-spacing: -.02em; }
.home-hero__search { display: flex; max-width: 720px; }
.home-hero__search input { flex: 1; min-width: 0; height: 50px; padding: 0 16px; border: 0; border-radius: 10px 0 0 10px; font: inherit; font-size: 16px; }
.home-hero__search button { padding: 0 26px; border: 0; border-radius: 0 10px 10px 0; background: #f76707; color: #fff; font: inherit; font-weight: 700; font-size: 15px; cursor: pointer; }
.home-hero__search button:hover { background: #e8590c; }
.home-hero__hint { margin: 10px 0 0; color: rgba(255,255,255,.7); font-size: 13px; }
.home-hero__hint a { color: #fff; text-decoration: underline; text-underline-offset: 3px; }
.home-entries { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 10px; }
.home-entries a { display: flex; flex-direction: column; gap: 3px; padding: 14px 16px; border: 1px solid var(--line); border-radius: 12px; background: var(--white); }
.home-entries a:hover { border-color: var(--brand); box-shadow: var(--shadow-soft); }
.home-entries strong { color: var(--ink); font-size: 15px; }
.home-entries span { color: var(--ink-muted); font-size: 12.5px; }
.home-stats { display: grid; grid-template-columns: repeat(var(--cols, 4), minmax(0, 1fr)); border: 1px solid var(--line); border-radius: 12px; background: var(--white); }
.home-stats div { padding: 14px 16px; border-left: 1px solid var(--line); }
.home-stats div:first-child { border-left: 0; }
.home-stats strong { display: block; color: var(--brand); font-size: 22px; letter-spacing: -.02em; }
.home-stats span { color: var(--ink-soft); font-size: 12.5px; }
.trust-strip { padding: 10px 0; }
.trust-strip__inner { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 10px; }
.trust-strip__inner > div { display: flex; gap: 10px; align-items: flex-start; padding: 12px 14px; border-radius: 12px; background: var(--bg-tint); font-size: 12.5px; color: var(--ink-soft); }
.trust-strip__inner b { display: grid; place-items: center; flex: none; width: 22px; height: 22px; border-radius: 50%; background: var(--stock-in); color: #fff; font-size: 12px; }
.trust-strip__inner strong { display: block; color: var(--ink); font-size: 13.5px; }
.v3-mini { display: grid; grid-template-columns: 56px minmax(0, 1fr); grid-template-rows: auto auto auto auto; column-gap: 10px; align-items: center; }
.v3-mini__img { grid-row: 1 / span 4; display: grid; place-items: center; width: 56px; height: 56px; border-radius: 8px; background: #f4f6fa; overflow: hidden; }
.v3-mini__img img { width: 100%; height: 100%; object-fit: contain; }
.v3-mini__img i { font-style: normal; font-weight: 800; font-size: 12px; color: var(--ink-muted); }
.v3-mini > strong, .v3-mini > span, .v3-mini > .stock-badge { grid-column: 2; }
@media (max-width: 1100px) {
  .home-top__grid { grid-template-columns: 1fr; }
  .cat-rail { order: 2; }
  .cat-rail ul { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .cat-rail__fly { display: none !important; }
  .home-entries, .trust-strip__inner { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 560px) { .cat-rail ul { grid-template-columns: 1fr; } .home-stats { grid-template-columns: repeat(2, minmax(0, 1fr)); } .home-stats div:nth-child(3) { border-left: 0; } }

/* ===== V3.2 image sizes: chips need small, crisp images ===== */
.pd-head { grid-template-columns: 180px minmax(0, 1fr); }
.pd-image { max-width: 180px; }
.pd-image img { padding: 10px; }
.product-card__media { aspect-ratio: 4 / 3; max-height: 180px; }
.product-card__media img { object-fit: contain; padding: 18px; background: #f6f8fb; }

/* ===== V3.2 blog: dense list, small images ===== */
.blog-layout { display: grid; grid-template-columns: minmax(0, 1fr) 300px; gap: 16px; align-items: start; }
.blog-side { display: grid; gap: 16px; position: sticky; top: 170px; }
.post-row { display: grid; grid-template-columns: 120px minmax(0, 1fr); gap: 16px; padding: 16px 18px; border-bottom: 1px solid var(--line); }
.post-row__thumb { display: grid; place-items: center; width: 120px; height: 80px; border-radius: 8px; overflow: hidden; background: #eef2f7; color: var(--ink-muted); font-weight: 800; }
.post-row__thumb img { width: 100%; height: 100%; object-fit: cover; }
.post-row__meta { margin: 0 0 4px; color: var(--ink-muted); font-size: 12.5px; }
.post-row h3 { margin: 0 0 6px; font-size: 17px; line-height: 1.35; }
.post-row h3 a { color: var(--ink); }
.post-row h3 a:hover { color: var(--brand); }
.post-row__excerpt { margin: 0; color: var(--ink-soft); font-size: 14px; line-height: 1.6; }
.post-row__parts { display: flex; flex-wrap: wrap; gap: 6px; margin: 8px 0 0; }
.post-row__parts a { padding: 2px 8px; border-radius: 6px; background: var(--bg-tint); color: var(--brand); font-size: 12px; }
.side-parts { margin: 0; padding: 4px 0; list-style: none; }
.side-parts li { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 0 8px; padding: 8px 16px; border-bottom: 1px solid var(--line); font-size: 13px; }
.side-parts li:last-child { border-bottom: 0; }
.side-parts a { color: var(--brand); font-weight: 700; overflow: hidden; text-overflow: ellipsis; }
.side-parts span { grid-column: 1; color: var(--ink-muted); font-size: 12px; }
.side-parts b { grid-column: 2; grid-row: 1 / span 2; align-self: center; color: var(--stock-in); font-family: var(--font-mono); font-size: 12.5px; }
.article-cover--slim { margin-top: 18px; height: 180px; border-radius: 12px; overflow: hidden; }
.article-cover--slim img { width: 100%; height: 100%; object-fit: cover; }
.article-cover:not(.article-cover--slim) { display: none; }
.article-grid { display: block; border: 1px solid var(--line); border-radius: var(--radius-sm); background: var(--white); }
@media (max-width: 1000px) { .blog-layout { grid-template-columns: 1fr; } .blog-side { position: static; } }
@media (max-width: 560px) { .post-row { grid-template-columns: 80px minmax(0, 1fr); gap: 12px; } .post-row__thumb { width: 80px; height: 56px; } }

/* ===== V3.2 live chat ===== */
.chatw { position: fixed; right: 18px; bottom: 18px; z-index: 80; font-size: 14px; }
.chatw__bubble { display: inline-flex; align-items: center; gap: 8px; height: 50px; padding: 0 18px 0 14px; border: 0; border-radius: 25px; background: #f76707; color: #fff; font: inherit; font-weight: 700; box-shadow: 0 14px 30px -12px rgba(247,103,7,.7); cursor: pointer; }
.chatw__bubble svg { width: 24px; height: 24px; }
.chatw.is-open .chatw__bubble { display: none; }
.chatw__panel { display: flex; flex-direction: column; width: 360px; height: min(560px, calc(100vh - 40px)); border: 1px solid var(--line); border-radius: 16px; background: var(--white); box-shadow: 0 30px 70px -20px rgba(5,28,64,.45); overflow: hidden; }
.chatw__panel[hidden] { display: none; }
.chatw__head { display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 12px 14px; background: var(--brand); color: #fff; }
.chatw__head small { display: block; opacity: .8; font-size: 12px; }
.chatw__close { border: 0; background: transparent; color: #fff; font-size: 24px; cursor: pointer; line-height: 1; }
.chatw__log { flex: 1; overflow-y: auto; padding: 12px; background: #f6f8fb; }
.chatw__msg { margin-bottom: 10px; max-width: 86%; }
.chatw__msg span { display: block; margin-bottom: 2px; color: var(--ink-muted); font-size: 11px; }
.chatw__msg p { margin: 0; padding: 8px 11px; border-radius: 12px; background: var(--white); border: 1px solid var(--line); line-height: 1.5; word-break: break-word; }
.chatw__msg p a { color: var(--brand); }
.chatw__msg--visitor { margin-left: auto; text-align: right; }
.chatw__msg--visitor p { background: var(--brand); border-color: var(--brand); color: #fff; text-align: left; }
.chatw__msg--staff p { background: var(--stock-in-bg); border-color: #b9e4cb; }
.chatw__typing i { display: inline-block; width: 6px; height: 6px; margin: 0 2px; border-radius: 50%; background: var(--ink-muted); animation: chatdot 1s infinite alternate; }
.chatw__typing i:nth-child(2) { animation-delay: .2s; } .chatw__typing i:nth-child(3) { animation-delay: .4s; }
@keyframes chatdot { to { opacity: .2; } }
.chatw__chips { display: flex; flex-wrap: wrap; gap: 6px; padding: 8px 12px 0; }
.chatw__chips button { padding: 5px 10px; border: 1px solid var(--line-strong); border-radius: 999px; background: var(--white); color: var(--ink-soft); font: inherit; font-size: 12.5px; cursor: pointer; }
.chatw__chips button:hover { border-color: var(--brand); color: var(--brand); }
.chatw__contact { display: grid; gap: 6px; padding: 10px 12px; border-top: 1px solid var(--line); background: #fff8e6; }
.chatw__contact[hidden] { display: none; }
.chatw__contact p { margin: 0; font-size: 12.5px; color: var(--ink-soft); }
.chatw__contact input { height: 36px; padding: 0 10px; border: 1px solid var(--line-strong); border-radius: 8px; font: inherit; font-size: 14px; }
.chatw__form { display: flex; gap: 8px; padding: 10px 12px; border-top: 1px solid var(--line); }
.chatw__form textarea { flex: 1; min-height: 40px; max-height: 110px; padding: 9px 11px; border: 1px solid var(--line-strong); border-radius: 10px; font: inherit; font-size: 14px; resize: none; }
.chatw__form button { width: 42px; border: 0; border-radius: 10px; background: var(--brand); color: #fff; cursor: pointer; }
.chatw__form button svg { width: 20px; height: 20px; }
.chatw__leave { margin: 0 12px 10px; padding: 6px; border: 0; background: none; color: var(--brand); font: inherit; font-size: 12.5px; font-weight: 600; cursor: pointer; }
.stock-badge--ask { border: 0; cursor: pointer; font: inherit; font-size: 11.5px; font-weight: 600; }
.stock-badge--ask:hover { filter: brightness(.95); text-decoration: underline; }
.contact-bar { bottom: auto; }
@media (max-width: 560px) { .chatw { right: 10px; bottom: 74px; } .chatw__panel { width: calc(100vw - 20px); height: calc(100vh - 100px); } .chatw__bubble span { display: none; } .chatw__bubble { padding: 0 13px; } }
[dir="rtl"] .chatw { right: auto; left: 18px; }

/* V3.3 unified category rail / menu */
.cat-rail__row { padding: 6px 18px; }
.cat-rail__n { color: var(--ink-muted); font-size: 11.5px; }
.cat-rail__fly, .mega__sub { column-count: 3; }
.cat-rail__fly { display: none; grid-template-columns: none; column-gap: 22px; }
.cat-rail__row:hover .cat-rail__fly, .cat-rail__row:focus-within .cat-rail__fly { display: block; }
.cat-rail__col { break-inside: avoid; margin-bottom: 12px; }
.cat-rail__col a.is-empty, .mega__leaf.is-empty { color: var(--ink-muted); opacity: .75; }
.cat-rail__all { display: block; margin-top: 6px; padding: 8px 18px 0; color: var(--brand); font-weight: 600; font-size: 13.5px; border-top: 1px solid var(--line); }
.cat-rail { max-height: none; }

/* V3.3 home product cards: image-led, no wasted space */
.v3-mini { display: flex; flex-direction: column; gap: 4px; padding: 10px 10px 12px; }
.v3-mini__img { width: 100%; height: 140px; margin-bottom: 6px; border-radius: 10px; background: #f4f6fa; grid-row: auto; }
.v3-mini__img img { width: 100%; height: 100%; object-fit: contain; padding: 6px; }
.v3-mini__img i { font-size: 18px; }
.v3-mini > strong { font-size: 14px; }
.v3-mini > span { font-size: 12.5px; }
.v3-mini .stock-badge { margin-top: auto; align-self: center; text-align: center; flex-shrink: 0; }
@media (max-width: 640px) { .v3-mini__img { height: 110px; } }

/* V3.3 category filter (top of list sidebar) */
.v3-catfilter { border-bottom: 1px solid var(--line); }
.v3-catfilter > summary { display: flex; flex-direction: column; gap: 2px; padding: 12px 16px; background: var(--brand); color: #fff; cursor: pointer; list-style: none; border-radius: var(--radius-sm) var(--radius-sm) 0 0; }
.v3-catfilter > summary::-webkit-details-marker { display: none; }
.v3-catfilter > summary span { font-weight: 800; font-size: 14.5px; }
.v3-catfilter > summary span::after { content: ' ▾'; }
.v3-catfilter[open] > summary span::after { content: ' ▴'; }
.v3-catfilter > summary b { font-weight: 500; font-size: 12.5px; opacity: .85; }
.v3-catfilter__body { padding: 8px 10px 12px; max-height: 60vh; overflow: auto; }
.v3-catfilter__body a { display: flex; justify-content: space-between; gap: 6px; padding: 4px 6px; border-radius: 6px; color: var(--ink); font-size: 13px; }
.v3-catfilter__body a:hover { background: var(--bg-tint); }
.v3-catfilter__body a.is-active { background: var(--brand); color: #fff; }
.v3-catfilter__body small { color: var(--ink-muted); font-size: 11.5px; }
.v3-catfilter__top > summary { display: flex; align-items: center; justify-content: space-between; gap: 6px; padding: 2px 0; cursor: pointer; font-weight: 700; }
.v3-catfilter__top > summary a { flex: 1; font-weight: 700; }
.v3-catfilter__mid { padding-left: 16px !important; font-weight: 600; }
.v3-catfilter__leaf { padding-left: 28px !important; color: var(--ink-soft) !important; }
.v3-catfilter__all { font-weight: 700; }
.v3-catfilter__note { margin: 8px 6px 0; color: var(--ink-muted); font-size: 12px; }
.v3-catfilter__more { color: var(--brand) !important; font-weight: 600; }
.v3-filters { padding-top: 0; }

/* ===== V3.3 buyer community ===== */
.cm-head { display: flex; align-items: flex-end; justify-content: space-between; gap: 16px; flex-wrap: wrap; }
.cm-userbar { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; font-size: 13.5px; }
.cm-userbar form { display: inline; }
.cm-link { border: 0; background: none; color: var(--brand); cursor: pointer; font: inherit; }
.cm-newbtn { padding: 8px 16px; }
.cm-tabs { display: flex; align-items: center; gap: 4px; flex-wrap: wrap; padding: 10px 14px; border-bottom: 1px solid var(--line); background: var(--bg-tint); border-radius: var(--radius-sm) var(--radius-sm) 0 0; }
.cm-tabs a { padding: 6px 12px; border-radius: 999px; color: var(--ink-soft); font-weight: 600; font-size: 13.5px; }
.cm-tabs a.is-active { background: var(--brand); color: #fff; }
.cm-tabs__sort { margin-left: auto; font-size: 13px; }
.cm-tabs__sort a { padding: 4px 6px; background: none !important; }
.cm-tabs__sort a.is-active { color: var(--brand) !important; }
.cm-row { display: grid; grid-template-columns: 64px minmax(0, 1fr) 90px; gap: 14px; align-items: center; padding: 14px 16px; border-bottom: 1px solid var(--line); }
.cm-row__stat { display: grid; place-items: center; padding: 6px 0; border-radius: 8px; background: var(--bg-tint); }
.cm-row__stat b { color: var(--brand); font-size: 18px; }
.cm-row__stat span { color: var(--ink-muted); font-size: 11px; }
.cm-row h3 { margin: 0 0 4px; font-size: 16px; line-height: 1.35; }
.cm-row h3 a { color: var(--ink); }
.cm-row h3 a:hover { color: var(--brand); }
.cm-row p { margin: 0; color: var(--ink-soft); font-size: 13.5px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.cm-row__meta { margin-top: 4px !important; color: var(--ink-muted) !important; font-size: 12px !important; }
.cm-board { display: inline-block; padding: 1px 8px; border-radius: 6px; background: var(--stock-src-bg); color: var(--stock-src); font-size: 11.5px; margin-right: 4px; }
.cm-pin { display: inline-block; margin-right: 6px; padding: 0 6px; border-radius: 4px; background: #e5482d; color: #fff; font-size: 11px; vertical-align: 2px; }
.cm-row__likes { display: grid; justify-items: end; gap: 4px; }
.cm-row__likes small { color: var(--ink-muted); font-size: 11.5px; }
.cm-like { display: inline-flex; align-items: center; gap: 4px; padding: 5px 10px; border: 1px solid var(--line-strong); border-radius: 999px; background: var(--white); color: var(--ink-soft); font: inherit; font-size: 13px; cursor: pointer; }
.cm-like:hover, .cm-like.is-liked { border-color: #f76707; color: #f76707; }
.cm-stats { display: grid; grid-template-columns: repeat(3, 1fr); text-align: center; }
.cm-stats b { display: block; color: var(--brand); font-size: 20px; }
.cm-stats span { color: var(--ink-muted); font-size: 12px; }
.cm-hotlist { margin: 0; padding: 4px 0; list-style: none; }
.cm-hotlist li { padding: 8px 16px; border-bottom: 1px solid var(--line); font-size: 13px; }
.cm-hotlist li:last-child { border-bottom: 0; }
.cm-hotlist a { color: var(--ink); display: block; }
.cm-hotlist small { color: var(--ink-muted); font-size: 11.5px; }
.cm-post { margin-bottom: 10px; }
.cm-post__head { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; padding: 10px 16px; border-bottom: 1px solid var(--line); background: #fbfcfe; font-size: 13px; color: var(--ink-muted); border-radius: var(--radius-sm) var(--radius-sm) 0 0; }
.cm-post__head strong { color: var(--ink); font-size: 14px; }
.cm-op { padding: 1px 6px; border-radius: 4px; background: var(--brand); color: #fff; font-size: 11px; }
.cm-post__body { padding: 14px 16px; font-size: 14.5px; line-height: 1.75; color: var(--ink); word-break: break-word; }
.cm-post__body a { color: var(--brand); }
.cm-part { font-family: var(--font-mono); font-weight: 700; }
.cm-imgs { display: flex; flex-wrap: wrap; gap: 8px; padding: 0 16px 12px; }
.cm-imgs img { width: 200px; height: 150px; object-fit: cover; border-radius: 8px; border: 1px solid var(--line); }
.cm-post__foot { padding: 8px 16px 12px; }
.cm-form { display: grid; gap: 12px; }
.cm-form label { display: grid; gap: 4px; font-size: 13px; font-weight: 600; color: var(--ink-soft); }
.cm-form input, .cm-form select, .cm-form textarea { padding: 9px 12px; border: 1px solid var(--line-strong); border-radius: 8px; font: inherit; font-size: 15px; font-weight: 400; color: var(--ink); background: var(--white); }
.cm-form textarea { min-height: 110px; resize: vertical; }
.cm-error { padding: 10px 12px; border-radius: 8px; background: #fdecea; color: #b42318; font-size: 13.5px; }
@media (max-width: 640px) { .cm-row { grid-template-columns: 52px minmax(0, 1fr); } .cm-row__likes { grid-column: 2; justify-items: start; grid-auto-flow: column; } .cm-imgs img { width: 46%; height: 110px; } }

/* home: scrolling hot posts (the empty area under the stats) */
.cm-ticker { display: grid; grid-template-columns: 170px minmax(0, 1fr) auto; align-items: center; gap: 14px; padding: 12px 16px; border: 1px solid var(--line); border-radius: 12px; background: var(--white); }
.cm-ticker__label { display: grid; gap: 2px; }
.cm-ticker__label strong { color: var(--ink); font-size: 15px; }
.cm-ticker__label span { color: var(--ink-muted); font-size: 12px; }
.cm-ticker__window { height: 132px; overflow: hidden; position: relative; }
.cm-ticker__window::after { content: ''; position: absolute; left: 0; right: 0; bottom: 0; height: 26px; background: linear-gradient(transparent, var(--white)); pointer-events: none; }
.cm-ticker ul { margin: 0; padding: 0; list-style: none; }
.cm-ticker li { display: grid; grid-template-columns: auto minmax(0, 1fr) auto; gap: 10px; align-items: center; height: 44px; border-bottom: 1px dashed var(--line); font-size: 13.5px; }
.cm-ticker li .cm-board { margin: 0; }
.cm-ticker li a { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; color: var(--ink); }
.cm-ticker li a:hover { color: var(--brand); }
.cm-ticker li small { color: #f76707; font-weight: 700; white-space: nowrap; }
.cm-ticker__go { display: grid; gap: 6px; }
@media (max-width: 760px) { .cm-ticker { grid-template-columns: 1fr; } }
.cm-sample { display: inline-block; margin-left: 6px; padding: 0 6px; border-radius: 4px; background: #fff3cd; color: #8a6d00; font-size: 11px; font-weight: 600; }

/* V3.4 availability + hint tooltip */
.v3-avail a.is-active .stock-dot { box-shadow: 0 0 0 2px #fff; }
.hint { position: relative; display: inline-grid; place-items: center; width: 16px; height: 16px; margin-left: 4px; border-radius: 50%; background: var(--ink-muted); color: #fff; font-size: 11px; font-weight: 800; cursor: help; vertical-align: 1px; }
.hint::after { content: attr(data-tip); position: absolute; left: 50%; bottom: calc(100% + 8px); z-index: 30; width: max-content; max-width: 220px; padding: 7px 10px; border-radius: 8px; background: var(--navy); color: #fff; font-size: 12px; font-weight: 500; line-height: 1.45; white-space: normal; transform: translateX(-50%); opacity: 0; pointer-events: none; transition: opacity .15s; }
.hint:hover::after, .hint:focus::after { opacity: 1; }
.v3-catfilter__body a.is-empty { color: var(--ink-muted); }
.v3-catfilter { border-top: 1px solid var(--line); }
.v3-catfilter > summary { border-radius: 0; }

/* V3.4 content-sized category popups (menu + home rail) */
.mega__panel { display: flex; width: auto; max-height: none; flex-direction: row; align-items: flex-start; }
.mega__tops { flex: none; width: 260px; max-height: 72vh; overflow-y: auto; border-right: 1px solid var(--line); }
.mega__top > a { padding: 7px 18px; }
.mega__subs { position: relative; }
.mega__sub { position: static; display: block; width: max-content; max-width: min(820px, calc(100vw - 340px)); min-height: 0; max-height: 72vh; overflow-y: auto; padding: 16px 22px; column-gap: 26px; }
.mega__sub[hidden] { display: none; }
.mega__sub.cols-1 { column-count: 1; min-width: 240px; }
.mega__sub.cols-2 { column-count: 2; min-width: 460px; }
.mega__sub.cols-3 { column-count: 3; min-width: 640px; }
.mega__top.is-active .mega__sub { display: block; }
.mega__tops .mega__all { width: auto; border-top: 1px solid var(--line); }
.mega__panel { position: absolute; }
.cat-rail__fly { width: max-content; max-width: min(820px, calc(100vw - 360px)); min-height: 0; height: auto; padding: 16px 22px; }
.cat-rail__fly.cols-1 { column-count: 1; min-width: 240px; }
.cat-rail__fly.cols-2 { column-count: 2; min-width: 460px; }
.cat-rail__fly.cols-3 { column-count: 3; min-width: 640px; }
.cat-rail__row { position: static; }
.cat-rail__row:hover .cat-rail__fly { top: 0; }
.cat-rail__more { display: block; width: calc(100% - 36px); margin: 4px 18px 0; padding: 7px 0; border: 1px dashed var(--line-strong); border-radius: 8px; background: var(--white); color: var(--brand); font: inherit; font-size: 13px; font-weight: 600; cursor: pointer; }
.cat-rail__more[hidden] { display: none; }
.cat-rail__row[hidden] { display: none; }
.home-top__grid { align-items: start; }

/* V3.4 translation toggle */
.tr-toggle { display: inline-flex; align-items: center; gap: 4px; margin: 0 16px 10px; padding: 3px 10px; border: 1px solid var(--line-strong); border-radius: 999px; background: var(--white); color: var(--ink-soft); font: inherit; font-size: 12px; cursor: pointer; }
.tr-toggle:hover { border-color: var(--brand); color: var(--brand); }
.article-hero .tr-toggle, .pd-desc + .tr-toggle, .prose + .tr-toggle { margin-left: 0; }

/* V3.5 product-page category filter: hover flyout like the home rail */
.v3-filters { position: static; max-height: none; overflow: visible; }
.mega--side { position: relative; margin: 0; border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.mega--side__btn { display: flex; width: 100%; min-width: 0; height: auto; flex-direction: column; align-items: flex-start; gap: 2px; padding: 12px 16px; background: var(--brand); text-align: left; }
.mega--side__btn span { font-weight: 800; font-size: 14.5px; }
.mega--side__btn i { font-style: normal; margin-left: 4px; }
.mega--side__btn b { font-weight: 500; font-size: 12.5px; opacity: .85; }
.mega--side .mega__panel { left: 100%; top: 0; z-index: 70; border: 1px solid var(--line); border-radius: 0 14px 14px 14px; }
.mega--side .mega__sub { max-width: min(820px, calc(100vw - 640px)); }
.mega--side a.is-current { color: var(--brand); font-weight: 700; }
.mega--side .mega__top > a.is-empty { color: var(--ink-muted); }
@media (max-width: 1100px) { .mega--side .mega__panel { left: 0; top: 100%; } .mega--side .mega__sub { max-width: calc(100vw - 320px); } }

/* V3.5 tooltip opens to the right of the "?" */
.hint::after { left: calc(100% + 8px); bottom: auto; top: 50%; transform: translateY(-50%); }
[dir="rtl"] .hint::after { left: auto; right: calc(100% + 8px); }

/* V3.5 article page: compact title band (about one-third of the old height) */
.article-hero { padding: 22px 0 26px; }
.article-hero h1 { margin-top: 8px; font-size: clamp(1.5rem, 2.3vw, 2rem); line-height: 1.22; letter-spacing: -0.02em; max-width: 1000px; }
.article-hero__excerpt { margin-top: 10px; max-width: 900px; font-size: .95rem; line-height: 1.6; }
.article-hero__meta { margin-top: 12px; }
.article-hero .article-cover, .article-cover { margin-top: 18px; }
@media (max-width: 760px) { .article-hero { padding: 18px 0 20px; } .article-hero h1 { font-size: 1.35rem; } }

/* V3.5 About page: button text matches the other light buttons */
.about-contact__details .btn { color: var(--btn-fg); border-bottom: 0; }
.about-contact__details .btn:hover { color: var(--btn-fg); }

/* V3.5 one translate button per post */
.tr-toggle[data-tr-btn] { margin: 0 0 0 12px; vertical-align: middle; white-space: nowrap; }
.tr-toggle[hidden] { display: none; }
.cm-head .tr-toggle { margin: 6px 0 0 12px; }
.article-hero .tr-toggle { margin-left: 4px; background: rgba(255,255,255,.08); color: #cfe0f5; border-color: rgba(180,213,255,.3); }
.pd-sub + .tr-toggle { margin: 6px 0 0; }

/* V3.5 nav: current page = deep navy + orange underline (option B) */
.v3-navrow .primary-nav__link.is-active { background: #062f6e; box-shadow: inset 0 -4px 0 #ff7a1a; color: #fff; }
.v3-navrow .primary-nav__link:hover:not(.is-active) { background: rgba(255,255,255,.12); }
