/* nsn-page.css: the NSN page by visitor intent (phase 1). Scoped to .nsn-v2 so nothing else on the site changes.
   Colors and buttons come from nsn-dialog.css (--nl-* tokens, .nl-btn). Markup: Pages\NSN\NSN.cshtml, _NSN_HeroPartial,
   _NSN_IntentBarPartial, _NSN_CardHeadPartial. Behavior: wwwroot\js\nsn-page.js.

   How intents work: <div class="nsn-v2" data-intent="buy|sell|make|maintain|ship|all|staff">. Every card carries its
   position for each intent as custom properties (--o-buy ...) and the intents where it is in the top three (data-top).
   The rules below order the cards, open the top three and close the rest; "all" opens everything. A visitor's own
   show / hide on a card adds .is-open / .is-closed, which wins until the intent changes. */

.nsn-v2 {
    --nsn-bg: #f3f5f8;
    --nsn-card: #fff;
    --nsn-line: var(--nl-line, #d8dee6);
    --nsn-line-soft: #edf0f4;
    --nsn-ink: var(--nl-ink, #10233a);
    --nsn-muted: var(--nl-muted, #51627a);
    --nsn-text: #3b4656;
    --nsn-navy: var(--nl-navy, #0b2545);
    --nsn-blue: var(--nl-blue, #13487a);
    --nsn-gold: var(--nl-gold, #ffc233);
    --nsn-mono: "Roboto Mono", ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
    color: var(--nsn-ink);
    font-family: var(--nl-font, Roboto, "Helvetica Neue", Arial, sans-serif);
    font-size: 15px;
    line-height: 1.5;
    display: flex;
    flex-direction: column;
    gap: 16px;
    margin-bottom: 24px;
}

.nsn-v2 a { color: var(--nsn-blue); }
.nsn-v2 a:hover { color: var(--nsn-navy); }

/* ---------- Breadcrumb ---------- */
.nsn-crumbs { display: flex; flex-wrap: wrap; gap: 4px 8px; font-size: 13px; color: var(--nsn-muted); margin-top: 4px; }
.nsn-crumbs a { color: var(--nsn-muted); text-decoration: none; }
.nsn-crumbs a:hover { color: var(--nsn-blue); text-decoration: underline; }
.nsn-crumbs [aria-current] { color: var(--nsn-ink); font-weight: 500; }

/* ---------- Hero ---------- */
.nsn-hero {
    background: var(--nsn-card);
    border: 1px solid var(--nsn-line);
    border-radius: 14px;
    padding: 24px;
    display: grid;
    grid-template-columns: minmax(200px, 260px) minmax(0, 1fr) minmax(260px, 320px);
    grid-template-areas: "photo main buy";
    gap: 24px;
    align-items: start;
}
.nsn-hero__main { grid-area: main; min-width: 0; display: flex; flex-direction: column; gap: 10px; }
.nsn-hero__photo { grid-area: photo; min-width: 0; text-align: center; }
.nsn-buy { grid-area: buy; }

.nsn-hero__chips, .nsn-hero__keys { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; }
.nsn-chip { display: inline-flex; align-items: center; gap: 4px; font-size: 13px; line-height: 1.4; background: #f1f3f6; color: var(--nsn-text); border-radius: 6px; padding: 3px 8px; text-decoration: none; }
.nsn-chip--mono { font-family: var(--nsn-mono); background: #e8eef6; color: var(--nsn-blue); }
.nsn-chip--ok { background: #e7f3ea; color: #1d5b2d; }
.nsn-chip--bad { background: #fdecea; color: #8a1c12; font-weight: 500; }
.nsn-v2 a.nsn-chip--staff { background: #fff4d6; color: #6b4b00; }

.nsn-hero__title { margin: 0; display: flex; flex-direction: column; gap: 2px; }
.nsn-hero__nsn { font-family: var(--nsn-mono); font-size: 32px; font-weight: 600; letter-spacing: .3px; color: var(--nsn-navy); line-height: 1.15; }
.nsn-hero__name { font-size: 21px; font-weight: 500; color: var(--nsn-ink); line-height: 1.3; }
.nsn-hero__aka { margin: 0; font-size: 13px; color: var(--nsn-muted); overflow-wrap: anywhere; display: -webkit-box; -webkit-box-orient: vertical; -webkit-line-clamp: 2; line-clamp: 2; overflow: hidden; }
.nsn-hero__desc { margin: 0; color: var(--nsn-text); max-width: 68ch; }
.nsn-hero__notice { margin: 0; padding: 8px 12px; border-radius: 8px; background: #fdecea; color: #8a1c12; font-weight: 500; }
.nsn-hero__notice a { color: #8a1c12; }
/* Sourcing / family / supplier / demand lines (their own partials, each behind its ShowOnPages switch): left-aligned in the hero. */
.nsn-hero__signals:empty, .nsn-hero__signals:not(:has(*)) { display: none; }
.nsn-hero__signals .text-center { text-align: left !important; }
.nsn-hero__signals > :last-child, .nsn-hero__signals > div > :last-child { margin-bottom: 0; }
.nsn-key { display: inline-flex; font-size: 13px; border: 1px solid var(--nsn-line); border-radius: 999px; padding: 3px 10px; color: var(--nsn-text); background: #fff; text-decoration: none; }
.nsn-v2 a.nsn-key:hover { border-color: var(--nsn-blue); color: var(--nsn-blue); }
.nsn-key--warn { border-color: #f0d9a8; background: #fff7e6; }
.nsn-hero__meta { display: flex; flex-wrap: wrap; gap: 6px 20px; margin: 4px 0 0; font-size: 13px; }
.nsn-hero__meta > div { display: flex; gap: 6px; align-items: baseline; }
.nsn-hero__meta dt { font-weight: 400; color: var(--nsn-muted); }
.nsn-hero__meta dd { margin: 0; font-weight: 500; color: var(--nsn-ink); }
.nsn-stars { color: #d49a00; letter-spacing: 1px; }
.nsn-hero__barcode { display: block; margin: 8px auto 0; max-width: 100%; height: auto; opacity: .9; }

/* The existing gallery partial inside the hero */
.nsn-hero__photo section > .col { padding: 0 !important; }
.nsn-hero__photo .figure { margin: 0 !important; }
.nsn-hero__photo .figure-img { max-height: 260px; width: auto; border-radius: 10px; }
.nsn-hero__photo .figure-caption { font-size: 12px; color: var(--nsn-muted) !important; font-style: normal !important; text-align: center !important; }
.nsn-hero__photo .nav-pills { margin: 6px 0 0 !important; gap: 4px; }
.nsn-hero__photo .row { margin: 0; }

/* Price and actions */
.nsn-buy { background: #f7f9fc; border: 1px solid var(--nsn-line); border-radius: 12px; padding: 18px; display: flex; flex-direction: column; gap: 10px; }
.nsn-buy__label { font-size: 13px; color: var(--nsn-muted); }
.nsn-buy__price { display: flex; align-items: baseline; gap: 8px; flex-wrap: wrap; }
.nsn-buy__price > :first-child { font-size: 28px; font-weight: 700; color: var(--nsn-navy); }
.nsn-buy__price > span + span { color: var(--nsn-text); }
.nsn-buy__note { font-size: 12px; color: var(--nsn-muted); margin-top: -6px; }
.nsn-buy__facts { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 4px; font-size: 14px; color: var(--nsn-text); }
.nsn-buy__facts i { color: var(--nsn-blue); margin-right: 4px; }
.nsn-v2 .nsn-buy .nl-btn { text-decoration: none; }
.nsn-v2 .nsn-buy__quote { min-height: 48px; font-size: 16px; }
.nsn-buy__more { font-size: 13px; text-align: center; }

.nsn-lock { display: flex; gap: 8px; align-items: flex-start; padding: 10px 12px; border-radius: 10px; background: #f7f9fc; border: 1px dashed #b9c7d8; font-size: 14px; color: var(--nsn-text) !important; text-decoration: none; }
.nsn-lock i { color: var(--nsn-blue); margin-top: 2px; }
.nsn-lock:hover { border-color: var(--nsn-blue); }
.nsn-lock--line { margin: 0 0 14px; }

/* ---------- Banners (compact, below the hero) ---------- */
.nsn-banners { display: flex; flex-direction: column; gap: 8px; }
.nsn-banners:empty { display: none; }
.nsn-banner { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 8px 16px; padding: 8px 14px; border-radius: 10px; font-size: 14px; }
.nsn-banner--dark { background: #3e3f3a; color: #fff; }
.nsn-banner__actions { display: inline-flex; gap: 8px; }
.nsn-btn-sm { min-height: 34px !important; padding: 4px 14px !important; font-size: 14px !important; }
.nsn-banners > .row { margin: 0 !important; padding: 6px 10px !important; border-width: 1px !important; border-radius: 10px !important; font-size: 14px; }
.nsn-banners > .row .btn { padding: 4px 14px; font-size: 14px; }
.nsn-v2 .nsn-banners .btn-primary, .nsn-v2 .nsn-banners .btn-primary:hover { color: #fff !important; }
.nsn-banners > .row p { font-size: 14px; }

.nsn-v2 .nsn-btn-ghost { display: inline-flex; align-items: center; justify-content: center; min-height: 44px; padding: 0 18px; border-radius: 10px; border: 1px solid #8fb0d6; color: #fff; text-decoration: none; white-space: nowrap; background: transparent; }
.nsn-v2 .nsn-btn-ghost:hover { border-color: #fff; color: #fff; }
.nsn-v2 .nsn-btn-solid { display: inline-flex; align-items: center; justify-content: center; align-self: flex-start; min-height: 44px; padding: 0 18px; border-radius: 10px; background: var(--nsn-blue); color: #fff; text-decoration: none; font-weight: 500; }
.nsn-v2 .nsn-btn-solid:hover { background: var(--nsn-navy); color: #fff; }
.nsn-v2 .nsn-btn-outline { display: inline-flex; align-items: center; gap: 6px; min-height: 40px; padding: 0 14px; border-radius: 8px; border: 1px solid var(--nsn-blue); color: var(--nsn-blue); text-decoration: none; background: #fff; }

/* ---------- Intent bar ---------- */
.nsn-intent { background: var(--nsn-navy); color: #fff; border-radius: 14px; padding: 16px 20px; display: flex; flex-direction: column; gap: 14px; }
.nsn-intent__row { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; }
.nsn-intent__lead { font-weight: 500; margin-right: 6px; }
.nsn-intent__pill { min-height: 40px; padding: 0 16px; border-radius: 999px; border: 1px solid #5a7aa3; background: transparent; color: #fff; font: inherit; font-size: 14px; cursor: pointer; white-space: nowrap; }
.nsn-intent__pill:hover { border-color: #fff; }
.nsn-intent__pill:focus-visible { outline: 3px solid var(--nsn-gold); outline-offset: 2px; }
.nsn-intent__pill--staff { border-style: dashed; }
.nsn-intent__panel { display: none; flex-direction: column; gap: 12px; }
.nsn-intent__tiles { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 10px; }
.nsn-tile { background: var(--nsn-blue); border-radius: 10px; padding: 10px 14px; display: flex; flex-direction: column; gap: 1px; min-width: 0; }
.nsn-tile__label { font-size: 12px; color: #cfdcec; text-transform: uppercase; letter-spacing: .5px; }
.nsn-tile__value { font-size: 18px; font-weight: 700; color: #fff !important; text-decoration: none; overflow-wrap: anywhere; }
.nsn-tile__note { font-size: 13px; color: #dbe6f3; overflow-wrap: anywhere; }
.nsn-tile--locked .nsn-tile__value { color: var(--nsn-gold) !important; }
.nsn-intent__ctas { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; }
.nsn-v2 .nsn-intent__cta { text-decoration: none; }
.nsn-intent__hint { font-size: 13px; color: #cfdcec; }

/* The chosen intent: its pill and its panel. The default ("all") is set in the HTML, the inline script changes it before paint. */
.nsn-v2[data-intent="buy"] [data-intent-pick="buy"],
.nsn-v2[data-intent="sell"] [data-intent-pick="sell"],
.nsn-v2[data-intent="make"] [data-intent-pick="make"],
.nsn-v2[data-intent="maintain"] [data-intent-pick="maintain"],
.nsn-v2[data-intent="ship"] [data-intent-pick="ship"],
.nsn-v2[data-intent="all"] [data-intent-pick="all"],
.nsn-v2[data-intent="staff"] [data-intent-pick="staff"] { background: var(--nsn-gold); border-color: var(--nsn-gold); color: var(--nsn-navy); font-weight: 700; }

.nsn-v2[data-intent="buy"] [data-intent-panel="buy"],
.nsn-v2[data-intent="sell"] [data-intent-panel="sell"],
.nsn-v2[data-intent="make"] [data-intent-panel="make"],
.nsn-v2[data-intent="maintain"] [data-intent-panel="maintain"],
.nsn-v2[data-intent="ship"] [data-intent-panel="ship"],
.nsn-v2[data-intent="all"] [data-intent-panel="all"],
.nsn-v2[data-intent="staff"] [data-intent-panel="staff"] { display: flex; }

/* ---------- Layout: "On this page" + cards ---------- */
.nsn-layout { display: grid; grid-template-columns: 220px minmax(0, 1fr); gap: 20px; align-items: start; }
.nsn-toc { position: sticky; top: 12px; background: #fff; border: 1px solid var(--nsn-line); border-radius: 12px; padding: 12px; max-height: calc(100vh - 24px); overflow: auto; }
.nsn-toc__title { font-size: 12px; color: var(--nsn-muted); text-transform: uppercase; letter-spacing: .6px; padding: 2px 8px 6px; }
.nsn-toc__list { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 2px; }
.nsn-toc__list a { display: block; padding: 6px 8px; border-radius: 8px; text-decoration: none; font-size: 14px; color: var(--nsn-blue); }
.nsn-toc__list a:hover { background: #f1f4f8; }

.nsn-cards { display: flex; flex-direction: column; gap: 14px; min-width: 0; }

/* Order of cards and table of contents for each intent */
.nsn-v2[data-intent="buy"] :is(.nsn-cards, .nsn-toc__list) > * { order: var(--o-buy, 500); }
.nsn-v2[data-intent="sell"] :is(.nsn-cards, .nsn-toc__list) > * { order: var(--o-sell, 500); }
.nsn-v2[data-intent="make"] :is(.nsn-cards, .nsn-toc__list) > * { order: var(--o-make, 500); }
.nsn-v2[data-intent="maintain"] :is(.nsn-cards, .nsn-toc__list) > * { order: var(--o-maintain, 500); }
.nsn-v2[data-intent="ship"] :is(.nsn-cards, .nsn-toc__list) > * { order: var(--o-ship, 500); }
.nsn-v2[data-intent="all"] :is(.nsn-cards, .nsn-toc__list) > * { order: var(--o-all, 500); }
.nsn-v2[data-intent="staff"] :is(.nsn-cards, .nsn-toc__list) > * { order: var(--o-staff, 500); }

/* Top three of the chosen intent: highlighted in the list, marked "Key for you" */
.nsn-card__key { display: none; font-size: 12px; background: #fff3cf; color: #6b4b00; border-radius: 6px; padding: 2px 8px; white-space: nowrap; }
.nsn-v2[data-intent="buy"] [data-top~="buy"] .nsn-card__key,
.nsn-v2[data-intent="sell"] [data-top~="sell"] .nsn-card__key,
.nsn-v2[data-intent="make"] [data-top~="make"] .nsn-card__key,
.nsn-v2[data-intent="maintain"] [data-top~="maintain"] .nsn-card__key,
.nsn-v2[data-intent="ship"] [data-top~="ship"] .nsn-card__key,
.nsn-v2[data-intent="staff"] [data-top~="staff"] .nsn-card__key { display: inline-block; }
.nsn-v2[data-intent="buy"] li[data-top~="buy"] a,
.nsn-v2[data-intent="sell"] li[data-top~="sell"] a,
.nsn-v2[data-intent="make"] li[data-top~="make"] a,
.nsn-v2[data-intent="maintain"] li[data-top~="maintain"] a,
.nsn-v2[data-intent="ship"] li[data-top~="ship"] a,
.nsn-v2[data-intent="staff"] li[data-top~="staff"] a { background: #e8eef6; color: var(--nsn-navy); font-weight: 500; }

/* Open / closed: "all" opens every card; other intents open their top three. A visitor's own choice wins. */
.nsn-v2:not([data-intent="all"]) .nsn-card > .nsn-card__body { display: none; }
.nsn-v2[data-intent="buy"] .nsn-card[data-top~="buy"] > .nsn-card__body,
.nsn-v2[data-intent="sell"] .nsn-card[data-top~="sell"] > .nsn-card__body,
.nsn-v2[data-intent="make"] .nsn-card[data-top~="make"] > .nsn-card__body,
.nsn-v2[data-intent="maintain"] .nsn-card[data-top~="maintain"] > .nsn-card__body,
.nsn-v2[data-intent="ship"] .nsn-card[data-top~="ship"] > .nsn-card__body,
.nsn-v2[data-intent="staff"] .nsn-card[data-top~="staff"] > .nsn-card__body,
.nsn-v2 .nsn-card.is-open > .nsn-card__body { display: block; }
.nsn-v2 .nsn-card.is-closed > .nsn-card__body { display: none; }

/* ---------- Cards ---------- */
.nsn-card { background: var(--nsn-card); border: 1px solid var(--nsn-line); border-radius: 12px; min-width: 0; scroll-margin-top: 12px; }
.nsn-card__head { display: flex; align-items: center; gap: 12px; padding: 14px 18px; }
.nsn-card__titles { flex: 1; min-width: 0; }
.nsn-card__title { margin: 0; font-size: 17px; font-weight: 700; color: var(--nsn-navy); line-height: 1.3; }
.nsn-card__summary { margin: 0; font-size: 13px; color: var(--nsn-muted); }
.nsn-card__toggle { display: inline-flex; align-items: center; gap: 6px; min-height: 36px; padding: 0 12px; border-radius: 8px; border: 1px solid var(--nsn-line); background: #f7f9fc; color: var(--nsn-blue); font: inherit; font-size: 14px; cursor: pointer; white-space: nowrap; }
.nsn-card__toggle:hover { border-color: var(--nsn-blue); }
.nsn-card__toggle:focus-visible { outline: 3px solid var(--nsn-blue); outline-offset: 2px; }
.nsn-card__toggle[aria-expanded="false"] i { transform: rotate(180deg); }
.nsn-card__body { border-top: 1px solid var(--nsn-line-soft); padding: 16px 18px 18px; min-width: 0; overflow-wrap: break-word; }
.nsn-subhead { font-size: 15px; font-weight: 700; color: var(--nsn-navy); margin: 0 0 8px; }
.nsn-muted { color: var(--nsn-muted); }
.nsn-prose { margin: 0; color: var(--nsn-text); }

/* The existing section partials inside a card: their old "Title > NSN" bars are replaced by the card heading,
   the magenta corner ribbons by one lock line, and borders and colors calmed down. Content and gating are unchanged. */
.nsn-card__body div.row.bg-light.border-primary:has(> h2 > img[src*="nsn-lookup-icon"]),
.nsn-card__body div.row.bg-light.border-primary:has(> h3 > img[src*="nsn-lookup-icon"]),
.nsn-v2 .ribbon-corner { display: none !important; }
.nsn-card__body .row { margin-left: 0; margin-right: 0; }
.nsn-card__body .border-primary { border-color: var(--nsn-line) !important; }
.nsn-card__body .border-2 { border-width: 1px !important; }
.nsn-card__body .border-3 { border-width: 1px !important; }
.nsn-card__body .text-primary { color: var(--nsn-ink) !important; }
.nsn-card__body .link-primary { color: var(--nsn-blue) !important; }
.nsn-card__body .bg-light { background-color: #f7f9fc !important; }
.nsn-card__body .card { border-radius: 10px; }
.nsn-card__body > :last-child { margin-bottom: 0 !important; }
.nsn-card__body .col { min-width: 0; }
.nsn-card__body dl.row > * { overflow-wrap: break-word; }
.nsn-card__body .card-header { background: #f7f9fc; }

.nsn-allrows { margin: 12px 0 16px; }
.nsn-allrows > summary { cursor: pointer; color: var(--nsn-blue); font-weight: 500; min-height: 36px; display: flex; align-items: center; }

.nsn-table { width: 100%; border-collapse: collapse; font-size: 14px; }
.nsn-table th { text-align: left; font-size: 12px; font-weight: 500; text-transform: uppercase; letter-spacing: .4px; color: var(--nsn-muted); padding: 6px 8px; border-bottom: 1px solid var(--nsn-line); }
.nsn-table td { padding: 8px; border-bottom: 1px solid var(--nsn-line-soft); vertical-align: top; }
.nsn-prices { overflow-x: auto; }

/* Story */
.nsn-story { list-style: none; margin: 0; padding: 0; }
.nsn-story__item { display: grid; grid-template-columns: 112px minmax(0, 1fr); gap: 14px; padding: 0 0 14px 0; position: relative; }
.nsn-story__item::before { content: ""; position: absolute; left: 118px; top: 8px; width: 9px; height: 9px; border-radius: 50%; background: var(--nsn-blue); }
.nsn-story__item::after { content: ""; position: absolute; left: 122px; top: 20px; bottom: 0; width: 1px; background: var(--nsn-line); }
.nsn-story__item:last-child::after { display: none; }
.nsn-story__when { font-family: var(--nsn-mono); font-size: 13px; color: var(--nsn-muted); padding-top: 2px; }
.nsn-story__what { padding-left: 22px; display: flex; flex-direction: column; }
.nsn-story__what span { font-size: 13px; color: var(--nsn-muted); }
.nsn-story__item--marker::before { background: var(--nsn-gold); box-shadow: 0 0 0 3px #fff3cf; }
.nsn-story__item--marker strong { color: #6b4b00; }

/* Sell or make */
.nsn-sellmake { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px; }
.nsn-sellmake__card { border: 1px solid var(--nsn-line); border-radius: 12px; padding: 16px; display: flex; flex-direction: column; gap: 6px; }
.nsn-sellmake__card p { margin: 0 0 6px; font-size: 14px; color: var(--nsn-text); }
.nsn-makers { margin-bottom: 16px; }
.nsn-makers__list { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 6px; }
.nsn-makers__list li { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; }

/* Similar items */
.nsn-similar { display: grid; grid-template-columns: repeat(auto-fill, minmax(112px, 1fr)); gap: 12px; }
.nsn-similar a { display: flex; flex-direction: column; align-items: center; gap: 4px; text-decoration: none; font-size: 12px; }
.nsn-similar img { width: 100px; height: 100px; object-fit: contain; border-radius: 8px; }

/* Staff */
.nsn-staff__links { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 10px; }
.nsn-staff__note { padding: 10px 12px; border-radius: 10px; background: #fff7e6; border: 1px solid #f0d9a8; font-size: 14px; }
.nsn-staff__inspect { display: grid; grid-template-columns: max-content minmax(0, 1fr); gap: 4px 16px; font-size: 14px; margin: 0; }
.nsn-staff__inspect dd { margin: 0; overflow-wrap: anywhere; }

/* Ads and the sales strip sit between the cards (their order is set inline) */
.nsn-ad, .nsn-more { min-width: 0; }
.nsn-ad:empty { display: none; }

/* ---------- Tablet ---------- */
@media (max-width: 1199.98px) {
    .nsn-hero { grid-template-columns: minmax(180px, 220px) minmax(0, 1fr); grid-template-areas: "photo main" "photo buy"; }
}

@media (max-width: 991.98px) {
    .nsn-layout { grid-template-columns: minmax(0, 1fr); }
    .nsn-toc { display: none; }
    .nsn-intent__tiles { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

/* ---------- Phone: NSN, name, price and Request a quote in the first screen ---------- */
@media (max-width: 767.98px) {
    .nsn-v2 { gap: 12px; font-size: 15px; }
    .nsn-crumbs { font-size: 12px; }
    .nsn-hero { display: flex; flex-direction: column; align-items: stretch; gap: 12px; padding: 14px; border-radius: 12px; }
    .nsn-hero__main { display: contents; }
    .nsn-hero__chips { order: 1; }
    .nsn-hero__title { order: 2; }
    .nsn-buy { order: 3; padding: 14px; gap: 8px; }
    .nsn-hero__photo { order: 4; }
    .nsn-hero__aka, .nsn-hero__notice, .nsn-hero__signals, .nsn-hero__competition, .nsn-hero__desc, .nsn-hero__keys, #nl-affiliate-strip, .nsn-hero__meta { order: 5; }
    .nsn-name-edit { order: 2; }
    .nsn-hero__nsn { font-size: 24px; }
    .nsn-hero__name { font-size: 18px; }
    .nsn-buy__price > :first-child { font-size: 24px; }
    .nsn-hero__photo .figure-img { max-height: 170px; }
    /* Long INC descriptions: four lines on a phone, tap to read the rest (the full text is always in the HTML). */
    .nsn-hero__desc { display: -webkit-box; -webkit-box-orient: vertical; -webkit-line-clamp: 4; line-clamp: 4; overflow: hidden; cursor: pointer; }
    .nsn-hero__desc.is-open { display: block; -webkit-line-clamp: unset; line-clamp: none; }
    .nsn-hero__barcode { display: none; }
    .nsn-intent { padding: 12px; border-radius: 12px; }
    .nsn-intent__row { flex-wrap: nowrap; overflow-x: auto; padding-bottom: 4px; scrollbar-width: thin; }
    .nsn-intent__lead { flex: 0 0 auto; }
    .nsn-intent__pill { flex: 0 0 auto; }
    .nsn-tile__value { font-size: 16px; }
    .nsn-card__head { padding: 12px 14px; }
    .nsn-card__body { padding: 12px 14px 14px; }
    .nsn-card__key { display: none !important; }
    .nsn-sellmake { grid-template-columns: minmax(0, 1fr); }
    .nsn-story__item { grid-template-columns: 92px minmax(0, 1fr); gap: 10px; }
    .nsn-story__item::before { left: 96px; }
    .nsn-story__item::after { left: 100px; }
    .nsn-story__what { padding-left: 18px; }
    .nsn-banner { font-size: 13px; }
}

/* Print: every section open */
@media print {
    .nsn-v2 .nsn-card > .nsn-card__body { display: block !important; }
    .nsn-card__toggle, .nsn-intent, .nsn-toc, .nsn-ad, .nsn-more { display: none !important; }
}

/* Marketplace "Need help?" quote box: narrow label column, wide form */
@media (min-width: 576px) {
    .nsn-card__body .card:has(#marketplacehelp) .row.align-items-center > .col-sm:first-child { flex: 0 0 32%; max-width: 32%; }
}

/* Phone marketplace rows: buttons and condition chips never wrap letter by letter; long part numbers and NIIN.FSC
   strings break inside their own column instead of running into the next one. */
.nsn-card__body .btn, .nsn-card__body .rounded-pill { white-space: nowrap; overflow-wrap: normal; }
@media (max-width: 767.98px) {
    .nsn-card__body .col-1:has(> .btn), .nsn-card__body .col-1:has(> .rounded-pill) { flex: 0 0 auto; width: auto; }
    .nsn-card__body .btn.rounded-pill { padding: 2px 8px; font-size: 12px; }
    #Marketplace .row > [class*="col"] { min-width: 0; overflow-wrap: anywhere; }
    #Marketplace .row > [class*="col"]:has(> .btn) { overflow-wrap: normal; }
}
.nsn-table--dense td, .nsn-table--dense th { padding: 4px 8px; font-size: 13px; }
