/* 0.4.0 shared presentation. All rules require the independently gated marker.
 * Preserve native menus, merchant images, data attributes and form handlers. */
body.tm-editorial-v1 { --ed-shadow: 0 12px 32px #1515150a; --ed-focus: #A45B00; }
body.tm-editorial-v1 :is(.site-body-container,.main-section,.sub-section,.entry,.vk_posts,.site-footer-content) { min-width: 0; }
body.tm-editorial-v1 :is(a,button,input,select,textarea,summary,[tabindex]):focus-visible { outline: 3px solid var(--ed-focus); outline-offset: 4px; }
body.tm-editorial-v1 :is(button,a):active { text-decoration-thickness: 3px; }
body.tm-editorial-v1 .tm-ed-skip { position: fixed; top: 8px; left: 8px; z-index: 100000; padding: 12px 20px; transform: translateY(-180%); background: #fff; color: #242424; border: 2px solid #874900; border-radius: 6px; }
body.tm-editorial-v1 .tm-ed-skip:focus { transform: none; }

/* Existing logo source is untouched; contrast comes from its white plate. */
body.tm-editorial-v1 #site-header { border-bottom: 1px solid #3D3D3D; }
body.tm-editorial-v1 #site-header-container { max-width: 1280px; }
body.tm-editorial-v1 #site-header .site-header-logo a { display: block; padding: 6px 10px; background: white; border-radius: 7px; }
body.tm-editorial-v1 #site-header .site-header-logo img { display: block; width: 195px; height: auto; object-fit: contain; }
body.tm-editorial-v1 #global-nav { border-top: 1px solid #414141; }
body.tm-editorial-v1 #global-nav .global-nav-list > li > a { padding: 13px 9px; font-size: 13px; font-weight: 700; }
body.tm-editorial-v1 #global-nav .sub-menu { border-radius: 0 0 8px 8px; box-shadow: 0 15px 30px #0003; }
body.tm-editorial-v1 #site-header .tm-brand-search { border-color: #777; max-width: 410px; }
body.tm-editorial-v1 #site-header :is(a,button,input):focus-visible { outline-color: #F2B547; }
body.tm-editorial-v1 #vk-mobile-nav { background: white !important; color: #242424; }
body.tm-editorial-v1 #vk-mobile-nav :is(a,li) { overflow-wrap: anywhere; }
body.tm-editorial-v1 #vk-mobile-nav a { border-bottom-color: var(--ed-line); font-size: 16px; }
body.tm-editorial-v1 #vk-mobile-nav :is(.current-menu-item,.current-menu-ancestor) > a { background: #FFF5E3; text-decoration: underline; text-decoration-thickness: 2px; text-underline-offset: 5px; }

/* A visible route back to the relevant guide above native lists and forms. */
body.tm-editorial-v1 .page-header { background: var(--ed-charcoal) !important; border: 0; padding-block: clamp(28px,4vw,56px); }
body.tm-editorial-v1 .page-header-title { color: white !important; font-size: clamp(27px,3vw,42px); line-height: 1.55; font-weight: 800; letter-spacing: -.035em; }
body.tm-editorial-v1 .breadcrumb { background: var(--ed-wash); color: #626262; font-size: 12px; line-height: 1.9; padding-block: 14px; }
body.tm-editorial-v1 .breadcrumb a { color: #874900; text-decoration: underline; text-underline-offset: 3px; }
body.tm-editorial-v1 .breadcrumb :is(ol,ul) { display: flex; flex-wrap: wrap; gap: 4px 8px; }
body.tm-editorial-v1 .entry-header { padding-bottom: 24px; margin-bottom: 24px; border-bottom: 1px solid var(--ed-line); }
body.tm-editorial-v1 .entry-title { color: var(--ed-ink) !important; font-size: clamp(27px,3vw,42px); line-height: 1.6; letter-spacing: -.035em; }
body.tm-editorial-v1 .entry-meta { font-size: 12px; line-height: 1.8; }
body.tm-editorial-v1:not(.home) .entry-body { border-radius: 12px; padding: clamp(20px,3vw,40px); box-shadow: var(--ed-shadow); }
body.tm-editorial-v1:not(.home) .entry-body :is(p,li,dd) { font-size: 17px; line-height: 1.95; }
body.tm-editorial-v1:not(.home) .entry-body :is(h2,h3,h4) { text-wrap: pretty; overflow-wrap: anywhere; }
body.tm-editorial-v1 .entry-body :is(figcaption,.tma-note,.tr-rkt__disc) { font-size: 13px !important; line-height: 1.8; }
body.tm-editorial-v1 .entry-body > blockquote { margin-block: 28px; padding: 18px 24px; border-left: 3px solid #E09915; background: #F5F5F4; }
body.tm-editorial-v1 .entry-body :is(.tma-rel,.tm-author) { border-radius: 10px; padding: 24px; }
body.tm-editorial-v1 .tm-brand-toc { border-left: 3px solid #E09915; border-radius: 8px; }
body.tm-editorial-v1 .entry-body :is(.vk_toc,.vk-toc,#toc_container,#ez-toc-container,.lwptoc) { background: #F5F5F4; border: 1px solid var(--ed-line); border-radius: 10px; }
body.tm-editorial-v1 .entry-body details:not(.tm-ed-legacy) { border: 1px solid var(--ed-line); border-radius: 9px; padding: 16px 20px; margin-block: 16px; background: white; }
body.tm-editorial-v1 .entry-body summary { cursor: pointer; min-height: 44px; line-height: 1.8; }
body.tm-editorial-v1 .entry-body details[open] > summary { margin-bottom: 16px; font-weight: 700; }
body.tm-editorial-v1 .tr-cmp { --n: #242424; --b: #874900; --ln: #DEDEDB; --sf: #F5F5F4; --mu: #626262; color: #242424; }
body.tm-editorial-v1 .tr-cmp .wrap { max-width: 100%; min-width: 0; overscroll-behavior-inline: contain; }
body.tm-editorial-v1 .tr-cmp .wrap thead th { background: #242424 !important; color: white !important; }
body.tm-editorial-v1 .tr-cmp a.go { color: #874900; text-decoration: underline; text-underline-offset: 4px; }
body.tm-editorial-v1 .tmc-card { background: white; border-color: #DEDEDB; box-shadow: var(--ed-shadow); border-top: 3px solid #E09915; }
body.tm-editorial-v1 :is(.tmc,.tma-about,.tma-page) a { color: #874900; text-decoration: underline; text-underline-offset: 4px; }
body.tm-editorial-v1 .tma-about th { background: #F5F5F4; color: #242424; }
body.tm-editorial-v1 .tma-about :is(th,td) { border-color: #DEDEDB; }

/* Same original cards, links and image URLs; no invented scores or snapshots. */
body.tm-editorial-v1 :is(.tmbb-card,.tr-card,.tr-pick,.tr-amz-card) { box-shadow: var(--ed-shadow); border-radius: 12px; padding: clamp(16px,2vw,24px); gap: 20px; }
body.tm-editorial-v1 :is(.tmbb-imgwrap,.tr-card__imgwrap,.tr-pick__imgwrap) { background: #fff !important; border: 1px solid #EAEAE7; border-radius: 8px; min-width: 0; }
body.tm-editorial-v1 :is(.tmbb-img,.tr-card__img,.tr-pick__img) { object-fit: contain; max-width: 100%; height: auto; }
body.tm-editorial-v1 :is(.tmbb-name,.tr-card__name,.tr-pick__name,.tr-amz-card__name-link) { font-weight: 800; letter-spacing: -.015em; text-wrap: pretty; }
body.tm-editorial-v1 :is(.tmbb-flag,.tr-card__rank,.tr-pick__ribbon) { border-radius: 4px; font-size: 12px; line-height: 1.6; }
body.tm-editorial-v1 :is(.tmbb-ctas,.tmt-ctas) { display: flex; flex-wrap: wrap; gap: 10px; }
body.tm-editorial-v1 :is(.tmbb-cta,.tmt-cta,.tr-btn--amazon,.tr-btn--rakuten) { min-height: 48px; border-radius: 7px; padding: 12px 18px; font-weight: 800; white-space: normal; }
body.tm-editorial-v1 :is(.tmbb-cta,.tmt-cta,.tr-btn--amazon,.tr-btn--rakuten):hover { box-shadow: inset 0 0 0 2px #151515; text-decoration: underline; text-underline-offset: 4px; }
body.tm-editorial-v1 .tm-ed-bestbuy { border-top: 3px solid #E09915; }
body.tm-editorial-v1 .tm-ed-bestbuy > summary { font-size: 18px; }
body.tm-editorial-v1 .tm-ed-bestbuy .tz-tablabels { gap: 8px; }
body.tm-editorial-v1 .tz-tablabels [aria-selected="true"] { background: #E09915 !important; color: #171717 !important; box-shadow: inset 0 -3px #151515; }

/* Contain tables within their own scroll regions, never hide page overflow. */
body.tm-editorial-v1 .tm-ed-table-wrap { max-width: 100%; min-width: 0; overflow-x: auto; overscroll-behavior-inline: contain; border: 1px solid var(--ed-line); border-radius: 8px; margin-block: 24px; }
body.tm-editorial-v1 .tm-ed-table-wrap > table { margin: 0; }
body.tm-editorial-v1 :is(.tm-ed-table-wrap,.tma-table-wrap,.tmbb-tblwrap,.wp-block-table) table { background: white; color: #242424; border-collapse: collapse; }
body.tm-editorial-v1 :is(.tm-ed-table-wrap,.tma-table-wrap,.tmbb-tblwrap,.wp-block-table) :is(th,td) { padding: 14px 16px; border-color: #DEDEDB; font-size: 14px; line-height: 1.8; }
body.tm-editorial-v1 :is(.tm-ed-table-wrap,.tma-table-wrap,.tmbb-tblwrap,.wp-block-table) thead th { background: #242424 !important; color: white !important; }
body.tm-editorial-v1 :is(.tm-ed-table-wrap,.tma-table-wrap,.tmbb-tblwrap,.wp-block-table) tbody tr:nth-child(even) > :is(th,td) { background: #F5F5F4; }
body.tm-editorial-v1 .tm-ed-scroll-hint { display: block; font-size: 12px; color: #626262; margin: 6px 0; }
body.tm-editorial-v1 .tm-ed-scroll-hint[hidden] { display: none; }

/* Native query, pagination and plugin-driven forms remain the functional owners. */
body.tm-editorial-v1 .vk_post { border: 1px solid var(--ed-line); border-radius: 10px; box-shadow: var(--ed-shadow); background: white; }
body.tm-editorial-v1 .vk_post_imgOuter { background: #F5F5F4; }
body.tm-editorial-v1 .vk_post_title a { color: #242424 !important; text-decoration: underline; text-underline-offset: 4px; }
body.tm-editorial-v1 .vk_post_title a:visited { color: #6A471E !important; }
body.tm-editorial-v1 .vk_post_date { color: #626262; font-size: 12px; }
body.tm-editorial-v1 .tm-ed-category-intro nav { margin-top: 18px; }
body.tm-editorial-v1 .pagination :is(a,span) { min-width: 44px; min-height: 44px; padding: 10px 14px; }
body.tm-editorial-v1 .pagination .current { color: #171717 !important; background: #E09915 !important; border: 1px solid #A66500; font-weight: 800; box-shadow: inset 0 -3px #151515; }
body.tm-editorial-v1 .pagination a { color: #874900; background: white; border: 1px solid #B6B6B0; text-decoration: underline; }
body.tm-editorial-v1 :is(.main-section,.sub-section) .search-form { display: flex; align-items: stretch; flex-wrap: wrap; gap: 10px; margin-block: 24px; }
body.tm-editorial-v1 :is(.main-section,.sub-section) .search-form label { flex: 1 1 200px; min-width: 0; margin: 0; }
body.tm-editorial-v1 .search-field { width: 100%; min-height: 48px; border: 1px solid #858580; border-radius: 7px; background: white; color: #242424; padding: 12px 16px; font-size: 16px; }
body.tm-editorial-v1 .tm-ed-search-help { margin-block: 24px; padding: 24px; background: white; border: 1px solid var(--ed-line); border-top: 3px solid #E09915; border-radius: 8px; }
body.tm-editorial-v1 .tm-ed-search-help nav { display: flex; flex-wrap: wrap; gap: 12px 24px; }
body.tm-editorial-v1 .tm-ed-search-help a { color: #874900; text-decoration: underline; padding-block: 8px; }
body.tm-editorial-v1 .wpcf7 { padding: clamp(4px,2vw,20px); }
body.tm-editorial-v1 .wpcf7 label { display: block; font-size: 15px; font-weight: 700; }
body.tm-editorial-v1 .wpcf7 :is(input:not([type=checkbox]):not([type=radio]):not([type=submit]):not([type=hidden]),select,textarea) { width: 100%; max-width: 100%; background: #fff; color: #242424; border: 1px solid #858580; border-radius: 7px; padding: 12px 14px; font-size: 16px; min-height: 48px; }
body.tm-editorial-v1 .wpcf7 textarea { min-height: 180px; resize: vertical; }
body.tm-editorial-v1 .wpcf7 :is(input[type=checkbox],input[type=radio]) { accent-color: #874900; }
body.tm-editorial-v1 .wpcf7-not-valid-tip { color: #9A241C; font-weight: 700; font-size: 14px; }
body.tm-editorial-v1 .wpcf7 [aria-invalid=true] { border: 2px solid #9A241C !important; }
body.tm-editorial-v1 .wpcf7-response-output { background: #F5F5F4; color: #242424; padding: 16px !important; border-radius: 8px; line-height: 1.8; }
body.tm-editorial-v1 :is(button:disabled,input[type=submit]:disabled,[aria-disabled=true]) { opacity: 1; background: #E6E6E3 !important; color: #626262 !important; border-color: #B4B4AF !important; cursor: not-allowed; box-shadow: none; }

/* Reuse the native footer's menus, disclosures, legal text and widgets in full. */
body.tm-editorial-v1 .site-footer { padding-top: 40px; }
body.tm-editorial-v1 .tm-ed-footer-brand { width: min(100% - 48px,1200px); margin: 0 auto 30px; padding-bottom: 28px; border-bottom: 1px solid #414141; display: flex; align-items: center; gap: 28px; }
body.tm-editorial-v1 .tm-ed-footer-brand > a { flex: 0 0 210px; padding: 8px 12px; background: white; border-radius: 7px; }
body.tm-editorial-v1 .tm-ed-footer-brand img { display: block; width: 100%; height: auto; content: normal !important; }
body.tm-editorial-v1 .tm-ed-footer-brand p { font-size: 16px; font-weight: 700; line-height: 1.9; margin: 0; }
body.tm-editorial-v1 .site-footer .footer-nav-list { justify-content: center; padding-block: 8px 24px; gap: 8px 24px; }
body.tm-editorial-v1 .site-footer .footer-nav-list a { font-size: 13px; min-height: 44px; }
body.tm-editorial-v1 .site-footer-content .row { display: flex; flex-wrap: wrap; }
body.tm-editorial-v1 .site-footer-content .row > :has(> #custom_html-2) { flex: 1 1 100%; max-width: 100%; }
body.tm-editorial-v1 .site-footer #custom_html-2 :is(div,p,span) { color: #D3D3CF !important; }
body.tm-editorial-v1 .site-footer #custom_html-2 a { color: #F2B547 !important; text-decoration: underline !important; text-underline-offset: 4px; }
body.tm-editorial-v1 .site-footer :is(a,button):focus-visible { outline-color: #F2B547; }
body.tm-editorial-v1 .site-footer-copyright { padding-block: 24px; font-size: 12px; }
body.tm-editorial-v1 .tm-brand-bottom-nav { border-top: 1px solid #B6B6B0; }
body.tm-editorial-v1 .tm-brand-bottom-nav [aria-current] { font-weight: 800; }

@media (max-width: 991px) {
  body.tm-editorial-v1 #site-header .site-header-logo a { display: inline-block; padding: 4px 8px; }
  body.tm-editorial-v1 #site-header .site-header-logo img { width: 160px; }
  body.tm-editorial-v1 #site-header .tm-brand-search { max-width: 100%; margin-top: 8px; }
  body.tm-editorial-v1 #site-header .tm-brand-search :is(input,button) { min-height: 42px; padding-block: 7px; }
}
@media (max-width: 767px) {
  body.tm-editorial-v1:not(.home) .entry-body { padding: 20px 14px; }
  body.tm-editorial-v1:not(.home) .entry-body :is(p,li,dd) { font-size: 16px; line-height: 1.95; }
  body.tm-editorial-v1 .entry-title { font-size: clamp(25px,6.9vw,30px); }
  body.tm-editorial-v1 :is(.tmbb-card,.tr-card,.tr-pick,.tr-amz-card) { padding: 16px; gap: 14px; }
  body.tm-editorial-v1 .tm-ed-footer-brand { flex-direction: column; align-items: flex-start; gap: 20px; }
  body.tm-editorial-v1 .tm-ed-footer-brand > a { flex: 0 0 auto; width: 195px; }
  body.tm-editorial-v1 .tm-ed-footer-brand p { font-size: 14px; }
  body.tm-editorial-v1 .site-footer .footer-nav-list { display: grid; grid-template-columns: repeat(2,minmax(0,1fr)); gap: 6px 18px; }
  body.tm-editorial-v1 .site-footer .footer-nav-list a { overflow-wrap: anywhere; }
  body.tm-editorial-v1 .tm-ed-search-help { padding: 20px; }
}
@media (prefers-reduced-motion: reduce) {
  body.tm-editorial-v1 * { scroll-behavior: auto !important; }
}

/* ===== 0.4.2 cascade reconciliation with the existing black×gold layer (tz-brand-css, wp-custom-css,
 * snippet 7 tm-color-unify). Those sheets print after this plugin and use !important with deep selectors,
 * so the editorial mode's white reading surfaces need an id-level specificity boost:
 * `:is(#tm-ed-hi, .tm-editorial-v1)` never needs an element with that id — :is() takes the specificity
 * of its most specific argument. Scope = reading surfaces only. Dark bands keep their own light-on-dark
 * text: site header/nav, footer, page-header band, hero (.tz-hero / .tm-ed-hero), BEST BUY why-box
 * (.tmbb-why), follow box (.veu_followSet), category CTA box (.tz-catcta), TOP disclosure (.tz-topdisc),
 * image term labels, share icons. No DOM, links, merchant output or measurement attributes change. ===== */

body.tm-editorial-v1:is(#tm-ed-hi,.tm-editorial-v1) { background: var(--ed-wash) !important; color: var(--ed-ink) !important; }

/* 1. Reading surfaces → paper. The article shell itself becomes transparent so the title sits on the wash. */
body.tm-editorial-v1:is(#tm-ed-hi,.tm-editorial-v1) :is(article.entry, article.post, .entry-full):where(:not(.tm-ed *)) { background: transparent !important; background-image: none !important; box-shadow: none !important; }
body.tm-editorial-v1:is(#tm-ed-hi,.tm-editorial-v1) :is(.entry-body, .article-body, .post-body, .entry-content.post_content, .vk_post, .vk_post.card, .card, .card-intext-inner, .related_posts .vk_post, .widget, .tr-card, .tr-pick, .tma-table td, .tma-concl, .tma-cta, .tma-mbox, .tma-review, .tma-rel, .tmg-badge, .tmg-fig, .tmh-trust2, .tm-author, .tm-related, .tm-faq, .tm-qa, .tm-owner-review, .vk_borderBox, .vk_alert, .vk_balloon_content, .wp-block-vk-blocks-border-box, .tmc-card, .tz-read, .tz-g, .tmt-pick, .tma-page, .tma-about):where(:not(.tm-ed *):not(.tz-catcta):not(.tmbb-why)) { background: var(--ed-paper) !important; background-image: none !important; color: var(--ed-ink) !important; border-color: var(--ed-line) !important; }
body.tm-editorial-v1:is(#tm-ed-hi,.tm-editorial-v1) :is(.tr-pick__comment, .tma-faq dt, .tma-table tr:nth-child(even) td, blockquote, .wp-block-quote, details, .vk_faq, .vk_faq_content, .swell-block-faq__item, .tm-brand-toc, .vk_toc, #toc_container, .tz-lvl--pro, .tz-lvl--beginner, .tma-mbox.is-merit, .tma-mbox.is-demerit):where(:not(.tm-ed *):not(.tm-ed-legacy)) { background: var(--ed-wash) !important; background-image: none !important; color: var(--ed-ink) !important; border-color: var(--ed-line) !important; }
body.tm-editorial-v1:is(#tm-ed-hi,.tm-editorial-v1) .tma-mbox.is-merit:where(:not(.tm-ed *)) { background: #FFF8E8 !important; }
body.tm-editorial-v1:is(#tm-ed-hi,.tm-editorial-v1) .tma-mbox.is-demerit:where(:not(.tm-ed *)) { background: #FFF1F1 !important; }
body.tm-editorial-v1:is(#tm-ed-hi,.tm-editorial-v1) .tm-author *:where(:not(.tm-ed *)) { background: transparent !important; }

/* 2. Content headings: drop the navy gradient the article module paints behind h2. */
body.tm-editorial-v1:is(#tm-ed-hi,.tm-editorial-v1) .entry-body :is(h2, h3, h4, h5, h6):where(:not(.tm-ed *):not(.tmbb-why *):not(.tz-catcta *)) { background-image: none !important; color: var(--ed-ink) !important; }
body.tm-editorial-v1:is(#tm-ed-hi,.tm-editorial-v1) .entry-body h2:where(:not(.tm-ed *):not(.tmbb-why *):not(.tz-catcta *)) { background-color: var(--ed-wash) !important; }

/* 3. Text on reading surfaces (dark modules excluded so they keep light-on-dark). */
body.tm-editorial-v1:is(#tm-ed-hi,.tm-editorial-v1) :is(.site-body, .entry-body, .vk_post, .widget, .tma, .tm-author, .tr-rkt, .tr-cmp, [id="tz404"], .tmc, .archive-header, .archive-description, .term-description, .tma-page, .tma-about, .tm-brand-toc) :is(p, li, dd, dt, td, figcaption, blockquote, summary, label, b, strong, em, span, div, table, h1, h2, h3, h4, h5, h6, time):where(:not(.tm-ed *):not(.tz-catcta *):not(.tmbb-why *):not(.veu_followSet *):not(.tz-eeat *):not(.card-intext *):not([style*="minmax"] *):not(.tz-topdisc):not(.tz-topdisc *):not(.tz-foot *):not([class*="tz-hero"] *):not(.tmt-hero *):not(.vk_post_imgOuter_singleTermLabel):not(.vk_post_imgOuter_singleTermLabel *):not(.sb_icon_inner *):not(.tz-amz):not(.tz-amz *):not(.tr-btn *):not(.tma-btn *):not(.b-r *):not(.b-a *):not([class*="btn"] *):not([class*="tmbb-cta"] *):not(#tm-scta *):not(.tr-card__rank):not(.tr-pick__ribbon):not(.tmbb-flag):not(thead *):not(th):not(th *)) { color: var(--ed-ink) !important; }
body.tm-editorial-v1:is(#tm-ed-hi,.tm-editorial-v1) :is(.archive-header-title, .archive-title, .entry-title, .vk_post_title, .vk_post_title a, .tr-card__name, .tr-pick__name, .tr-rkt__title, .widget-title, .widget h3, .widget h4, .vk_borderBox_title, .tr-card__price, .tr-pick__price, .tr-card__stars b, .tr-card__meta b, .tr-pick__comment b, .tma-rel b, .tmg h2, .tmh-trust2 .hd, .tma-mbox h4, summary, .vk_faq_title):where(:not(.tm-ed *):not(.tmbb-why *):not(.tz-catcta *):not(.card-intext *):not(.tz-eeat *):not([style*="minmax"] *)) { color: var(--ed-ink) !important; }
body.tm-editorial-v1:is(#tm-ed-hi,.tm-editorial-v1) :is(.entry-meta, .entry-meta a, .post-meta, .text-muted, small, .vk_post_excerpt, .postListText__excerpt, .vk_post_date, .media-date, .tr-rkt__disc, .tr-rkt__note, .tr-card__meta, .tr-card__stars, .tr-card__stars--none, .tr-cat-count, .tma-pr, .tma-note, .tma-review .ph, .tma-revimg, .tma-revimg figcaption, .tmg-lead, .tmg-note, .tmg-fig figcaption, .tmh-trust2 .sub, .tm-author .tm-author-note, .tm-author small, .tm-author .tm-author-stats span, .tm-author .tm-author-asof, [id="tz404"] .tz404-s label, .sb_count, .entry-body figcaption[style*="666"]):where(:not(.tm-ed *):not(.tmbb-why *):not(.tz-catcta *):not(.tz-foot *):not(.veu_followSet *):not(.card-intext *):not(.tz-eeat *)) { color: var(--ed-muted) !important; }
body.tm-editorial-v1:is(#tm-ed-hi,.tm-editorial-v1) .tma-mbox.is-demerit h4:where(:not(.tm-ed *)) { color: #B3261E !important; }

/* 4. Links on reading surfaces: brand link colour, underline (no colour-only cue). Buttons/CTAs untouched. */
body.tm-editorial-v1:is(#tm-ed-hi,.tm-editorial-v1) :is(.entry-body, .vk_post, .widget, .tma, .tm-author, .tr-cmp, [id="tz404"], .tmc, .tma-page, .tma-about, .archive-description, .term-description) a:where(:not(.tr-btn):not(.tma-btn):not(.b-r):not(.b-a):not([class*="btn"]):not([class*="tmbb-"]):not(.tmt-cta):not(.tz-rbtn):not(.tr-card__name):not(.tr-pick__name):not(.vk_post_title a):not(.tm-ed *):not(.tz-catcta *):not(.tmbb-why *):not(.veu_followSet *):not(.tz-topdisc *):not(.tz-foot *):not([class*="tz-hero"] *):not(.tmt-hero *):not(.vk_post_imgOuter_singleTermLabel):not(.vk_post_imgOuter_singleTermLabel *):not(.sb_icon_inner):not(.sb_icon_inner *):not(.tz-amz):not(#tm-scta *):not(.vk_post_taxonomy a):not(.post-categories a):not(.tag-links a):not(.entry-tags a)) { color: var(--ed-link) !important; text-decoration: underline; text-underline-offset: 3px; }
body.tm-editorial-v1:is(#tm-ed-hi,.tm-editorial-v1) :is(.tma-review .who, .tma-faq dt::before, .tma-faq dd::before, .tmh-trust2 .more, [id="tz404"] .tz404-h, .tr-cmp td.c, .tr-cmp .go, .vk_post_title_new):where(:not(.tm-ed *)) { color: var(--ed-link) !important; }
body.tm-editorial-v1:is(#tm-ed-hi,.tm-editorial-v1) :is(.vk_post_taxonomy a, .post-categories a, .tag-links a, .entry-tags a):where(:not(.tm-ed *)) { background: var(--ed-wash) !important; color: var(--ed-link) !important; border: 1px solid var(--ed-line) !important; }

/* 5. Tables on paper. */
body.tm-editorial-v1:is(#tm-ed-hi,.tm-editorial-v1) :is(table, .wp-block-table table):where(:not(.tm-ed *)) { background: var(--ed-paper) !important; color: var(--ed-ink) !important; border-color: var(--ed-line) !important; }
body.tm-editorial-v1:is(#tm-ed-hi,.tm-editorial-v1) :is(td, tbody th):where(:not(.tm-ed *):not(thead *)) { color: var(--ed-ink) !important; background: transparent !important; border-color: var(--ed-line) !important; }
body.tm-editorial-v1:is(#tm-ed-hi,.tm-editorial-v1) tbody tr:nth-child(even) td:where(:not(.tm-ed *)) { background: var(--ed-wash) !important; }
body.tm-editorial-v1:is(#tm-ed-hi,.tm-editorial-v1) :is(thead th, table th, .tma-table th, .tr-cmp .wrap thead th):where(:not(.tm-ed *)) { background: #242424 !important; color: #FFFFFF !important; border-color: #3D3D3D !important; }
body.tm-editorial-v1:is(#tm-ed-hi,.tm-editorial-v1) :is(thead th, table th, .tma-table th) *:where(:not(.tm-ed *)) { color: #FFFFFF !important; }

/* 6. Page-header band stays charcoal with white title; breadcrumb on wash. */
body.tm-editorial-v1:is(#tm-ed-hi,.tm-editorial-v1) .page-header { background: var(--ed-charcoal) !important; }
body.tm-editorial-v1:is(#tm-ed-hi,.tm-editorial-v1) .page-header :is(h1, .page-header-title, .page-header-title *) { color: #FFFFFF !important; }
body.tm-editorial-v1:is(#tm-ed-hi,.tm-editorial-v1) .breadcrumb { background: var(--ed-wash) !important; }
body.tm-editorial-v1:is(#tm-ed-hi,.tm-editorial-v1) :is(.breadcrumb, .breadcrumb *):where(:not(a)) { color: var(--ed-muted) !important; }
body.tm-editorial-v1:is(#tm-ed-hi,.tm-editorial-v1) .breadcrumb a, body.tm-editorial-v1:is(#tm-ed-hi,.tm-editorial-v1) .breadcrumb a * { color: var(--ed-link) !important; text-decoration: underline; text-underline-offset: 3px; }

/* 7. Forms inside reading surfaces (404 search, contact forms). Header search keeps its dark field. */
body.tm-editorial-v1:is(#tm-ed-hi,.tm-editorial-v1) :is(.entry-body, [id="tz404"], .site-body .wpcf7) :is(input:where(:not([type=submit]):not([type=button])), textarea, select):where(:not(.tm-ed *)) { background: var(--ed-paper) !important; color: var(--ed-ink) !important; border: 1px solid #626262 !important; }
body.tm-editorial-v1:is(#tm-ed-hi,.tm-editorial-v1) :is(.entry-body, [id="tz404"], .site-body .wpcf7) :is(input, textarea)::placeholder { color: var(--ed-muted) !important; }
body.tm-editorial-v1:is(#tm-ed-hi,.tm-editorial-v1) [id="tz404"] .tz404-s button, body.tm-editorial-v1:is(#tm-ed-hi,.tm-editorial-v1) .site-body .wpcf7 input[type=submit] { background: var(--ed-orange) !important; color: #171717 !important; border: 1px solid #A66500 !important; }

/* 7b. Entry footer term list and image-overlay cards (text over image keeps light text). */
body.tm-editorial-v1:is(#tm-ed-hi,.tm-editorial-v1) .entry-meta-data-list dt { background: #242424 !important; color: #FFFFFF !important; }
body.tm-editorial-v1:is(#tm-ed-hi,.tm-editorial-v1) .entry-meta-data-list a { color: var(--ed-link) !important; text-decoration: underline; text-underline-offset: 3px; }
body.tm-editorial-v1:is(#tm-ed-hi,.tm-editorial-v1) .card-intext .card-intext-inner :is(h5, .vk_post_title, .card-title, .card-date, .vk_post_date, .card-text, span, div) { color: #FFFFFF !important; }

/* 7c. BEST BUY cards (tm-bestbuy output) on paper: same DOM, light equivalents of the tmbb-css dark palette. */
body.tm-editorial-v1:is(#tm-ed-hi,.tm-editorial-v1) .tmbb-card { background: var(--ed-paper) !important; color: var(--ed-ink) !important; border: 1px solid var(--ed-line) !important; }
body.tm-editorial-v1:is(#tm-ed-hi,.tm-editorial-v1) :is(.tmbb-name, .tmbb-name a, .tmbb-score b, .tmbb-pros li, .tmbb-catch, .tmbb-catch *, .tmbb-trust, .tmbb-trust span, .tmbb-for) { color: var(--ed-ink) !important; }
body.tm-editorial-v1:is(#tm-ed-hi,.tm-editorial-v1) :is(.tmbb-score__label, .tmbb-score__max, .tmbb-for span, .tmbb-meta) { color: var(--ed-muted) !important; }
body.tm-editorial-v1:is(#tm-ed-hi,.tm-editorial-v1) :is(.tmbb-pros li::before, .tmbb-why li::before) { color: var(--ed-orange) !important; }
body.tm-editorial-v1:is(#tm-ed-hi,.tm-editorial-v1) :is(.tmbb-trust, .tmbb-for) { background: var(--ed-wash) !important; }
body.tm-editorial-v1:is(#tm-ed-hi,.tm-editorial-v1) .tmbb-catch { background: #FFF8E8 !important; }
body.tm-editorial-v1:is(#tm-ed-hi,.tm-editorial-v1) :is(.tmbb-flag__main, .tmbb-flag.is-s .tmbb-flag__main) { background: var(--ed-wash) !important; color: var(--ed-ink) !important; border: 1px solid var(--ed-line) !important; }
body.tm-editorial-v1:is(#tm-ed-hi,.tm-editorial-v1) .tmbb-flag__sub { background: var(--ed-orange) !important; color: #171717 !important; }
body.tm-editorial-v1:is(#tm-ed-hi,.tm-editorial-v1) .tmbb-cta--amazon { background: var(--ed-orange) !important; color: #171717 !important; border: 1px solid #A66500 !important; }
body.tm-editorial-v1:is(#tm-ed-hi,.tm-editorial-v1) .tmbb-cta--rakuten { background: var(--ed-paper) !important; color: var(--ed-ink) !important; border: 1px solid #242424 !important; }
body.tm-editorial-v1:is(#tm-ed-hi,.tm-editorial-v1) .tmbb-tbtn { background: var(--ed-orange) !important; color: #171717 !important; }

/* 8. Legacy TOP pieces that may remain inside the editorial HOME (ranking section) or on category pages. */
body.tm-editorial-v1:is(#tm-ed-hi,.tm-editorial-v1) .tz-read .lb { color: var(--ed-ink) !important; background: var(--ed-wash) !important; }
body.tm-editorial-v1:is(#tm-ed-hi,.tm-editorial-v1) .tz-topdisc { background: #151515 !important; color: #E7E5E0 !important; }
body.tm-editorial-v1:is(#tm-ed-hi,.tm-editorial-v1) .tz-foot .tz-fmsg { color: #E9E2D4 !important; }
body.tm-editorial-v1:is(#tm-ed-hi,.tm-editorial-v1) .tmbb-why :is(p, li, .tmbb-why__note) { color: #CFC8B4 !important; }
body.tm-editorial-v1:is(#tm-ed-hi,.tm-editorial-v1) .tmbb-why h3 { color: #E7C87C !important; }
body.tm-editorial-v1:is(#tm-ed-hi,.tm-editorial-v1) .veu_followSet :is(p, .followSet_title) { color: #F5F5F5 !important; }

/* 7d. Mobile TOP block (tm-mobile-top, SP only): same DOM, light equivalents of its dark chips/CTAs. */
body.tm-editorial-v1:is(#tm-ed-hi,.tm-editorial-v1) [id="tmt-sp"] { background: var(--ed-wash) !important; color: var(--ed-ink) !important; }
body.tm-editorial-v1:is(#tm-ed-hi,.tm-editorial-v1) [id="tmt-sp"] :is(.tmt-h, .tmt-nav-h, .tmt-name, .tmt-pick, .tmt-pick *):where(:not(a)) { color: var(--ed-ink) !important; }
body.tm-editorial-v1:is(#tm-ed-hi,.tm-editorial-v1) [id="tmt-sp"] :is(.tmt-note, .tmt-meta) { color: var(--ed-muted) !important; }
body.tm-editorial-v1:is(#tm-ed-hi,.tm-editorial-v1) [id="tmt-sp"] .tmt-note a { color: var(--ed-link) !important; }
body.tm-editorial-v1:is(#tm-ed-hi,.tm-editorial-v1) .tmt-chip { background: var(--ed-paper) !important; color: var(--ed-ink) !important; border: 1px solid var(--ed-line) !important; }
body.tm-editorial-v1:is(#tm-ed-hi,.tm-editorial-v1) :is(.tmt-chip:active, .tmt-chip[aria-selected="true"], .tmt-chip.is-on) { background: var(--ed-orange) !important; color: #171717 !important; }
body.tm-editorial-v1:is(#tm-ed-hi,.tm-editorial-v1) a.tmt-cta-r { background: var(--ed-paper) !important; color: var(--ed-ink) !important; border: 1px solid #242424 !important; }
body.tm-editorial-v1:is(#tm-ed-hi,.tm-editorial-v1) a.tmt-cta-a { background: var(--ed-orange) !important; color: #171717 !important; border: 1px solid #A66500 !important; }

/* 8a. Legacy TOP root (fallback when the HOME hash guard fails closed) reads as wash/ink like the rest of the mode. */
body.tm-editorial-v1:is(#tm-ed-hi,.tm-editorial-v1) .tz { background: var(--ed-wash) !important; color: var(--ed-ink) !important; }
body.tm-editorial-v1:is(#tm-ed-hi,.tm-editorial-v1) .tz > :is(p, div, a):where(:not([class*="tz-hero"]):not(.tz-eeat):not(.tmbb-why)) { color: var(--ed-ink) !important; }
body.tm-editorial-v1:is(#tm-ed-hi,.tm-editorial-v1) :is(.tz-eyebrow, .tz-g .tz-gcta) { color: var(--ed-link) !important; -webkit-text-fill-color: var(--ed-link) !important; }

/* 8b. Legacy TOP trust box keeps its light-on-dark text; the ranking block wrapper inside the editorial HOME stays transparent. */
body.tm-editorial-v1:is(#tm-ed-hi,.tm-editorial-v1) .tz-eeat :is(p, li, span, .tz-eeat-lead) { color: #CFC8B4 !important; }
body.tm-editorial-v1:is(#tm-ed-hi,.tm-editorial-v1) .tz-eeat :is(.tz-eeat-name, .tz-eeat-facts li) { color: #F3EFE6 !important; }
body.tm-editorial-v1:is(#tm-ed-hi,.tm-editorial-v1) .tz-eeat-head { color: #1A1408 !important; }
body.tm-editorial-v1:is(#tm-ed-hi,.tm-editorial-v1) .tm-ed-legacy-body .tz { background: transparent !important; color: var(--ed-ink) !important; padding: 0 !important; }
body.tm-editorial-v1:is(#tm-ed-hi,.tm-editorial-v1) .tm-ed-legacy-body .tz :is(.tz-h2, .tz-sub, p, li):where(:not(.tmbb-why *)) { color: var(--ed-ink) !important; }

/* ===== 9. The editorial template's own palette, re-asserted at the boosted specificity.
 * The template lives inside .entry-body, where the legacy sheet repaints every link gold and
 * every dt/dd ink with !important. These rules restate the template's intended colours so the
 * new HOME reads correctly; they change no markup, no href and no merchant output. ===== */

/* 9a. Dark hero: light text, orange eyebrow, amber figures. */
body.tm-editorial-v1:is(#tm-ed-hi,.tm-editorial-v1) .tm-ed-hero :is(p, span, small, strong, b, figcaption, dt, dd, li) { color: var(--ed-inverse) !important; }
body.tm-editorial-v1:is(#tm-ed-hi,.tm-editorial-v1) .tm-ed-hero :is(h1, h2, h3) { color: #FFFFFF !important; }
body.tm-editorial-v1:is(#tm-ed-hi,.tm-editorial-v1) .tm-ed-hero .tm-ed-eyebrow { color: #F2B547 !important; }
body.tm-editorial-v1:is(#tm-ed-hi,.tm-editorial-v1) .tm-ed-hero .tm-ed-eyebrow span { color: var(--ed-inverse) !important; }
body.tm-editorial-v1:is(#tm-ed-hi,.tm-editorial-v1) .tm-ed-hero-stats dd { color: #F2B547 !important; }
body.tm-editorial-v1:is(#tm-ed-hi,.tm-editorial-v1) .tm-ed-hero-stats dt { color: #CBC7C0 !important; }
body.tm-editorial-v1:is(#tm-ed-hi,.tm-editorial-v1) .tm-ed-hero-stats dd.tm-ed-stat-label { color: var(--ed-inverse) !important; }
body.tm-editorial-v1:is(#tm-ed-hi,.tm-editorial-v1) .tm-ed-hero-strip span { color: var(--ed-inverse) !important; }

/* 9b. Buttons keep dark text on orange; the hero's secondary link stays white. */
body.tm-editorial-v1:is(#tm-ed-hi,.tm-editorial-v1) .tm-ed .tm-ed-button { color: var(--ed-action-ink) !important; background: var(--ed-orange) !important; }
body.tm-editorial-v1:is(#tm-ed-hi,.tm-editorial-v1) .tm-ed .tm-ed-button :is(span, b) { color: var(--ed-action-ink) !important; }
body.tm-editorial-v1:is(#tm-ed-hi,.tm-editorial-v1) .tm-ed .tm-ed-inverse-link,
body.tm-editorial-v1:is(#tm-ed-hi,.tm-editorial-v1) .tm-ed .tm-ed-inverse-link :is(span, b) { color: #FFFFFF !important; }
body.tm-editorial-v1:is(#tm-ed-hi,.tm-editorial-v1) .tm-ed-hero-proof a { color: var(--ed-inverse) !important; text-decoration: underline; text-underline-offset: 4px; }

/* 9c. Every other link on the template's paper surfaces uses the brand link colour. */
body.tm-editorial-v1:is(#tm-ed-hi,.tm-editorial-v1) .tm-ed a:where(:not(.tm-ed-button):not(.tm-ed-inverse-link):not(.tm-ed-hero *):not(.tm-ed-hero-proof a):not([class*="tmbb-cta"]):not([class*="tmt-cta"]):not(.tmbb-name):not(.tmbb-tbtn):not(.tmt-name):not(.tr-btn):not(.tma-btn):not(.b-r):not(.b-a):not([class*="btn"])) { color: var(--ed-link) !important; }
body.tm-editorial-v1:is(#tm-ed-hi,.tm-editorial-v1) .tm-ed a:where(:not(.tm-ed-button):not(.tm-ed-inverse-link):not(.tm-ed-hero *)) :is(span, b, strong, h3, small) { color: inherit !important; }
body.tm-editorial-v1:is(#tm-ed-hi,.tm-editorial-v1) .tm-ed :is(.tm-ed-purpose-link, .tm-ed-story-read) { color: var(--ed-ink) !important; }
body.tm-editorial-v1:is(#tm-ed-hi,.tm-editorial-v1) .tm-ed .tm-ed-purpose-link :is(strong, span) { color: var(--ed-ink) !important; }
body.tm-editorial-v1:is(#tm-ed-hi,.tm-editorial-v1) .tm-ed .tm-ed-purpose-link small { color: var(--ed-muted) !important; }

/* 9d. Secondary type on the template's paper surfaces. */
body.tm-editorial-v1:is(#tm-ed-hi,.tm-editorial-v1) .tm-ed :is(small, time, .tm-ed-note, .tm-ed-guide-caution, .tm-ed-story-label):where(:not(.tm-ed-hero *)) { color: var(--ed-muted) !important; }
body.tm-editorial-v1:is(#tm-ed-hi,.tm-editorial-v1) .tm-ed :is(h2, h3, h4, p, li, dt, dd, span, b, strong):where(:not(.tm-ed-hero *):not(a *):not(.tmbb-why *):not(.tz-eeat *):not([class*="tmbb-cta"] *):not([class*="tmt-cta"] *):not(.tmbb-flag *):not(.tmbb-flag__sub)) { color: var(--ed-ink) !important; }
body.tm-editorial-v1:is(#tm-ed-hi,.tm-editorial-v1) .tm-ed .tm-ed-kicker { color: var(--ed-link) !important; }

/* 9e. BEST BUY price and star meta inside the template read on paper. */
body.tm-editorial-v1:is(#tm-ed-hi,.tm-editorial-v1) :is(.tmbb-price, .tmbb-price.is-big) { color: var(--ed-ink) !important; }
body.tm-editorial-v1:is(#tm-ed-hi,.tm-editorial-v1) :is(.tmbb-meta, .tmbb-meta__stars, .tmbb-src, .tmbb-asof) { color: var(--ed-muted) !important; }

/* 9f. Collapsible legacy blocks and the mobile pick names sit on paper too. */
body.tm-editorial-v1:is(#tm-ed-hi,.tm-editorial-v1) .tm-ed :is(.tm-ed-legacy, .tm-ed-legacy-body) { background: var(--ed-paper) !important; border-color: var(--ed-line) !important; }
body.tm-editorial-v1:is(#tm-ed-hi,.tm-editorial-v1) .tm-ed .tm-ed-legacy > summary { color: var(--ed-ink) !important; }
body.tm-editorial-v1:is(#tm-ed-hi,.tm-editorial-v1) .tm-ed .tm-ed-legacy > summary span { color: var(--ed-muted) !important; }
body.tm-editorial-v1:is(#tm-ed-hi,.tm-editorial-v1) a.tmt-name { color: var(--ed-ink) !important; }

/* ===== 10. Mobile purchase path. The hero carried ~190px of inherited heading margin and
 * padding, and the candidate's wrapped chip nav replaced the original single-row scroller,
 * pushing the first product link from 1.25 to 1.84 screens at 390px. These rules restore the
 * original compact geometry. Font sizes, the heading, the supplies photo and the copy are
 * unchanged; only margins, padding and the chip row's flow are adjusted. ===== */
@media (max-width: 768px) {
  body.tm-editorial-v1:is(#tm-ed-hi,.tm-editorial-v1) .tm-ed-hero-grid { padding-top: 12px !important; padding-bottom: 8px !important; gap: 10px !important; }
  body.tm-editorial-v1:is(#tm-ed-hi,.tm-editorial-v1) .tm-ed-hero h2 { margin-top: 4px !important; margin-bottom: 14px !important; padding-bottom: 0 !important; }
  body.tm-editorial-v1:is(#tm-ed-hi,.tm-editorial-v1) .tm-ed-hero .tm-ed-eyebrow { margin-bottom: 10px !important; }
  body.tm-editorial-v1:is(#tm-ed-hi,.tm-editorial-v1) .tm-ed-hero .tm-ed-lead { margin-bottom: 12px !important; }
  body.tm-editorial-v1:is(#tm-ed-hi,.tm-editorial-v1) .tm-ed-hero .tm-ed-actions { margin-top: 12px !important; }
  body.tm-editorial-v1:is(#tm-ed-hi,.tm-editorial-v1) .tm-ed-hero-stats { margin-top: 8px !important; padding-top: 8px !important; }
  body.tm-editorial-v1:is(#tm-ed-hi,.tm-editorial-v1) .tm-ed-hero-proof { margin-top: 4px !important; }

  /* The mobile block is injected outside .tz, so the original compact rules no longer reach it. */
  body.tm-editorial-v1:is(#tm-ed-hi,.tm-editorial-v1) .tmt-nav { padding: 12px 0 0 !important; border: 0 !important; border-radius: 0 !important; }
  body.tm-editorial-v1:is(#tm-ed-hi,.tm-editorial-v1) .tmt-chips { flex-wrap: nowrap !important; overflow-x: auto !important; gap: 8px !important; padding: 2px 2px 10px !important; }
  body.tm-editorial-v1:is(#tm-ed-hi,.tm-editorial-v1) .tmt-chip { flex: 0 0 auto !important; }
  body.tm-editorial-v1:is(#tm-ed-hi,.tm-editorial-v1) [id="tmt-sp"] .tmt-pick { padding: 14px 14px 12px !important; margin: 10px 0 0 !important; }
  body.tm-editorial-v1:is(#tm-ed-hi,.tm-editorial-v1) [id="tmt-sp"] a.tmt-cta-a { flex: 1.6 !important; }
  body.tm-editorial-v1:is(#tm-ed-hi,.tm-editorial-v1) [id="tmt-sp"] a.tmt-cta-r { flex: 1 !important; }
  body.tm-editorial-v1:is(#tm-ed-hi,.tm-editorial-v1) [id="tmt-sp"] .tmt-h { margin: 14px 0 4px !important; }
  body.tm-editorial-v1:is(#tm-ed-hi,.tm-editorial-v1) [id="tmt-sp"] { padding-top: 10px !important; }
}

