/*
Theme Name: The Best Vitamin — Intelligence
Theme URI: https://thebestvitamin.shop
Author: The Best Vitamin editorial team
Description: Premium independent vitamin product research and buying guide publication.
Version: 1.0.0
License: GNU General Public License v2 or later
Text Domain: tbv
*/

/* ------------------------------------------------------------------
   1. Design tokens
   ------------------------------------------------------------------ */
@font-face {
	font-family: 'Fraunces';
	src: url('assets/fonts/fraunces-latin.woff2') format('woff2');
	font-style: normal;
	font-weight: 400 700;
	font-display: swap;
}
@font-face {
	font-family: 'Inter';
	src: url('assets/fonts/inter-latin.woff2') format('woff2');
	font-style: normal;
	font-weight: 400 700;
	font-display: swap;
}

:root {
	--forest: #183d32;
	--forest-deep: #112c24;
	--forest-soft: #2c5a4b;
	--sage: #78917c;
	--ivory: #f7f6f0;
	--ivory-deep: #efeee5;
	--white: #ffffff;
	--charcoal: #252b28;
	--ink-muted: #5d6862;
	--gold: #b69a62;
	--gold-soft: #d9c9a5;
	--border: #e5e6de;
	--border-dark: #d2d6cb;
	--font-display: 'Fraunces', 'Iowan Old Style', Georgia, serif;
	--font-ui: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Helvetica, Arial, sans-serif;
	--shadow-soft: 0 12px 30px rgba(24, 61, 50, .06);
	--shadow-lift: 0 18px 44px rgba(24, 61, 50, .11);
	--radius: 4px;
	--radius-lg: 8px;
	--container: 1240px;
	--space-section: clamp(64px, 7vw, 112px);
	font-synthesis: none;
}

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

html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }

body {
	margin: 0;
	background: var(--ivory);
	color: var(--charcoal);
	font-family: var(--font-ui);
	font-size: 16px;
	line-height: 1.65;
	-webkit-font-smoothing: antialiased;
}

body.tbv-nav-open { overflow: hidden; }

img { max-width: 100%; height: auto; display: block; }
a { color: var(--forest); text-decoration-thickness: 1px; text-underline-offset: 3px; }
a:hover { color: var(--forest-soft); }
button, input, select, textarea { font: inherit; color: inherit; }
h1, h2, h3, h4 { font-family: var(--font-display); font-weight: 500; line-height: 1.14; letter-spacing: -.018em; margin: 0 0 .5em; color: var(--forest-deep); }
h1 { font-size: clamp(2.35rem, 4.4vw, 4rem); }
h2 { font-size: clamp(1.75rem, 2.8vw, 2.55rem); }
h3 { font-size: clamp(1.15rem, 1.6vw, 1.4rem); }
h4 { font-size: 1.05rem; }
p { margin: 0 0 1.1em; }
ul, ol { padding-left: 1.25em; margin: 0 0 1.2em; }
li { margin-bottom: .4em; }
:focus-visible { outline: 3px solid var(--gold); outline-offset: 3px; border-radius: 2px; }
::selection { background: var(--gold-soft); color: var(--forest-deep); }

.tbv-container { width: min(calc(100% - 48px), var(--container)); margin-inline: auto; }
.tbv-visually-hidden { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0,0,0,0); white-space: nowrap; border: 0; }
.tbv-skip-link { position: absolute; left: 16px; top: -60px; z-index: 200; background: var(--forest); color: #fff; padding: 10px 16px; border-radius: 3px; transition: top .2s ease; }
.tbv-skip-link:focus { top: 12px; color: #fff; }

/* ------------------------------------------------------------------
   2. Header
   ------------------------------------------------------------------ */
.tbv-topbar { background: var(--forest-deep); color: #dfe8e1; font-size: .72rem; letter-spacing: .08em; text-transform: uppercase; }
.tbv-topbar__inner { display: flex; justify-content: space-between; gap: 16px; padding: 8px 0; }
.tbv-topbar__right { color: var(--gold-soft); }

.tbv-site-header { position: sticky; top: 0; z-index: 100; background: rgba(247,246,240,.96); backdrop-filter: blur(12px); border-bottom: 1px solid var(--border); }
.tbv-header__inner { min-height: 82px; display: flex; align-items: center; gap: 30px; }
.tbv-brand { display: flex; align-items: center; gap: 12px; text-decoration: none; flex: 0 0 auto; }
.tbv-brand img { width: 42px; height: 42px; }
.tbv-brand__text { display: flex; flex-direction: column; line-height: 1.1; }
.tbv-brand__text strong { font-family: var(--font-display); font-size: 1.28rem; color: var(--forest-deep); letter-spacing: -.02em; }
.tbv-brand__text small { font-size: .62rem; letter-spacing: .19em; text-transform: uppercase; color: var(--sage); margin-top: 4px; }

.tbv-primary-nav { margin-left: auto; }
.tbv-menu { display: flex; align-items: center; gap: clamp(14px, 1.6vw, 26px); list-style: none; margin: 0; padding: 0; }
.tbv-menu > li { margin: 0; }
.tbv-menu a { color: var(--forest-deep); text-decoration: none; font-size: .86rem; font-weight: 600; letter-spacing: .01em; padding: 8px 0; border-bottom: 2px solid transparent; }
.tbv-menu a:hover, .tbv-menu .current_page_item > a, .tbv-menu .current-menu-item > a { color: var(--forest); border-bottom-color: var(--gold); }

.tbv-header__actions { display: flex; align-items: center; gap: 12px; }
.tbv-icon-button { background: transparent; border: 1px solid var(--border-dark); border-radius: 50%; width: 38px; height: 38px; display: grid; place-items: center; cursor: pointer; }
.tbv-icon-button svg { width: 18px; height: 18px; fill: none; stroke: var(--forest); stroke-width: 1.7; }
.tbv-icon-button:hover { border-color: var(--forest); }

.tbv-button { display: inline-flex; align-items: center; justify-content: center; gap: 8px; background: var(--forest); color: #fff; border: 1px solid var(--forest); border-radius: var(--radius); padding: 13px 22px; font-size: .86rem; font-weight: 600; text-decoration: none; cursor: pointer; transition: background .18s ease, transform .18s ease, box-shadow .18s ease; }
.tbv-button:hover { background: var(--forest-soft); border-color: var(--forest-soft); color: #fff; transform: translateY(-1px); box-shadow: var(--shadow-soft); }
.tbv-button--small { padding: 9px 15px; font-size: .8rem; }
.tbv-button--outline { background: transparent; color: var(--forest); border-color: var(--forest); }
.tbv-button--outline:hover { background: var(--forest); color: #fff; }
.tbv-button--light { background: #fff; color: var(--forest); border-color: #fff; }
.tbv-button--light:hover { background: var(--gold-soft); border-color: var(--gold-soft); color: var(--forest-deep); }
.tbv-button--block { width: 100%; }
.tbv-button--amazon { margin-top: 10px; font-size: .8rem; }
.tbv-cta-group { display: flex; flex-direction: column; gap: 10px; margin-top: 22px; }
.tbv-cta-group--header { max-width: 340px; }
.tbv-cta-group--footer { margin: 44px 0 0; padding: 24px; background: var(--white); border: 1px solid var(--border); border-radius: var(--radius); }
.tbv-cta-group .tbv-compare-link { align-self: center; }
.tbv-text-link { font-size: .86rem; font-weight: 600; color: var(--forest); text-decoration: none; border-bottom: 1px solid var(--gold); padding-bottom: 2px; }
.tbv-text-link:hover { color: var(--forest-soft); border-bottom-color: var(--forest-soft); }

.tbv-nav-toggle { display: none; flex-direction: column; gap: 5px; width: 42px; height: 42px; border: 1px solid var(--border-dark); background: transparent; border-radius: var(--radius); align-items: center; justify-content: center; cursor: pointer; }
.tbv-nav-toggle span { width: 19px; height: 1.5px; background: var(--forest); display: block; }
.tbv-mobile-nav { display: none; border-top: 1px solid var(--border); background: var(--ivory); }
.tbv-search-panel { display: none; border-top: 1px solid var(--border); background: var(--white); padding: 20px 0; box-shadow: var(--shadow-soft); }
.tbv-search-panel.is-open { display: block; }
.tbv-search-panel form { display: flex; gap: 10px; }
.tbv-search-panel input { flex: 1; padding: 13px 16px; border: 1px solid var(--border-dark); border-radius: var(--radius); background: var(--ivory); }

/* ------------------------------------------------------------------
   3. Hero and trust strip
   ------------------------------------------------------------------ */
.tbv-hero { padding: clamp(56px, 7vw, 104px) 0 clamp(48px, 6vw, 88px); background: linear-gradient(180deg, var(--ivory) 0%, #f4f3ea 100%); border-bottom: 1px solid var(--border); }
.tbv-hero__grid { display: grid; grid-template-columns: minmax(0, 1.02fr) minmax(0, .98fr); gap: clamp(36px, 6vw, 88px); align-items: center; }
.tbv-eyebrow { font-size: .7rem; letter-spacing: .19em; text-transform: uppercase; color: var(--sage); font-weight: 700; margin-bottom: 18px; display: flex; align-items: center; gap: 12px; }
.tbv-eyebrow::before { content: ''; width: 28px; height: 1px; background: var(--gold); flex: none; }
.tbv-hero h1 { margin-bottom: 22px; font-size: clamp(2.5rem, 4.7vw, 4.35rem); }
.tbv-hero h1 em { font-style: italic; color: var(--forest-soft); font-weight: 400; }
.tbv-hero__deck { font-size: clamp(1.02rem, 1.35vw, 1.2rem); color: var(--ink-muted); max-width: 51ch; line-height: 1.72; }
.tbv-hero__actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 32px; }
.tbv-hero__note { font-size: .75rem; color: var(--sage); margin-top: 26px; letter-spacing: .02em; }
.tbv-hero__visual { position: relative; }
.tbv-hero__visual img { width: 100%; aspect-ratio: 16 / 9; object-fit: cover; border-radius: var(--radius-lg); border: 1px solid var(--border-dark); box-shadow: var(--shadow-lift); }
.tbv-hero__visual::after { content: ''; position: absolute; inset: 18px -18px -18px 18px; border: 1px solid var(--gold-soft); border-radius: var(--radius-lg); z-index: -1; }
.tbv-hero__caption { display: block; font-size: .7rem; color: var(--sage); margin-top: 16px; }
.tbv-hero__type { aspect-ratio: 16 / 9; border-radius: var(--radius-lg); background: var(--forest); color: #fff; display: flex; flex-direction: column; justify-content: center; padding: clamp(28px, 4vw, 64px); box-shadow: var(--shadow-lift); }
.tbv-hero__type span { font-family: var(--font-display); font-size: clamp(2rem, 3.6vw, 3.6rem); line-height: 1.05; color: #fff; }
.tbv-hero__type span:nth-child(2) { color: var(--gold-soft); font-style: italic; }
.tbv-hero__type small { text-transform: uppercase; letter-spacing: .2em; font-size: .68rem; color: #c4d3c9; margin-top: 22px; }

.tbv-trust-strip { background: var(--forest); color: #e8efe9; padding: 30px 0; }
.tbv-trust-strip__grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 34px; }
.tbv-trust-strip h2 { color: #fff; font-family: var(--font-ui); font-size: .83rem; text-transform: uppercase; letter-spacing: .13em; margin-bottom: 6px; }
.tbv-trust-strip p { font-size: .82rem; color: #c7d5cc; margin: 0; line-height: 1.5; }
.tbv-trust-strip__grid > div { border-left: 1px solid rgba(255,255,255,.16); padding-left: 22px; }
.tbv-trust-strip__grid > div:first-child { border-left: 0; padding-left: 0; }

/* ------------------------------------------------------------------
   4. Sections and shared components
   ------------------------------------------------------------------ */
.tbv-section { padding: var(--space-section) 0; }
.tbv-section--white { background: var(--white); }
.tbv-section--forest { background: var(--forest); color: #e7eee8; }
.tbv-section--forest h2, .tbv-section--forest h3 { color: #fff; }
.tbv-section--forest .tbv-eyebrow { color: var(--gold-soft); }
.tbv-section--forest p { color: #cbd8cf; }
.tbv-section__head { display: flex; align-items: end; justify-content: space-between; gap: 40px; margin-bottom: 42px; }
.tbv-section__head h2 { margin-bottom: 0; }
.tbv-section__head > p { max-width: 46ch; color: var(--ink-muted); margin: 0; font-size: .95rem; }
.tbv-section--forest .tbv-section__head > p { color: #cbd8cf; }
.tbv-section__foot { margin-top: 32px; margin-bottom: 0; }
.tbv-subhead { display: flex; justify-content: space-between; align-items: baseline; gap: 20px; margin: 56px 0 24px; border-bottom: 1px solid var(--border); padding-bottom: 14px; }
.tbv-subhead h2 { font-size: 1.6rem; margin: 0; }
.tbv-notice { background: var(--ivory-deep); border: 1px solid var(--border); border-left: 3px solid var(--gold); border-radius: var(--radius); padding: 18px 22px; color: var(--ink-muted); font-size: .92rem; }
.tbv-notice p:last-child { margin-bottom: 0; }
.tbv-source-hint { font-size: .78rem; color: var(--sage); line-height: 1.55; }
.tbv-meta-line { font-size: .8rem; color: var(--ink-muted); }
.tbv-badge-row { display: flex; align-items: center; gap: 14px; flex-wrap: wrap; }

.tbv-status { display: inline-block; font-size: .68rem; letter-spacing: .08em; text-transform: uppercase; font-weight: 700; padding: 5px 10px; border-radius: 2px; border: 1px solid currentColor; color: var(--forest-soft); }
.tbv-status--verified, .tbv-status--third-party-verified { color: #2f6b4f; background: #eaf3ec; border-color: #bcd8c5; }
.tbv-status--manufacturer-reported { color: #8a6a2f; background: #faf3e4; border-color: #e6d6ad; }
.tbv-status--unverified, .tbv-status--not-disclosed, .tbv-status--not-available, .tbv-status--outdated, .tbv-status--not-recorded { color: #7b665f; background: #f4efeb; border-color: #e0d5ce; }

/* Directory */
.tbv-directory { display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px; }
.tbv-directory__item { position: relative; display: flex; flex-direction: column; min-height: 158px; padding: 26px 24px; background: var(--white); border: 1px solid var(--border); border-radius: var(--radius); text-decoration: none; transition: border-color .18s ease, transform .18s ease, box-shadow .18s ease; overflow: hidden; }
.tbv-directory__media { display: block; width: calc(100% + 48px); margin: -26px -24px 18px; aspect-ratio: 4 / 3; overflow: hidden; background: var(--ivory-deep); }
.tbv-directory__media img { width: 100%; height: 100%; object-fit: cover; display: block; }
.tbv-directory__item:hover { border-color: var(--sage); transform: translateY(-3px); box-shadow: var(--shadow-soft); }
.tbv-directory__name { font-family: var(--font-display); font-size: 1.35rem; color: var(--forest-deep); margin-bottom: 10px; }
.tbv-directory__desc { font-size: .82rem; color: var(--ink-muted); line-height: 1.5; max-width: 28ch; }
.tbv-directory__arrow { position: absolute; top: 20px; right: 20px; color: var(--gold); font-size: 1rem; }

/* Editorial guide features */
.tbv-guide-feature-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; }
.tbv-guide-feature { display: flex; flex-direction: column; border: 1px solid var(--border); border-radius: var(--radius); background: var(--ivory); overflow: hidden; }
.tbv-guide-feature > :not(.tbv-guide-feature__media) { margin-left: 28px; margin-right: 28px; }
.tbv-guide-feature > p:last-child { margin-bottom: 28px; }
.tbv-guide-feature__media { display: block; aspect-ratio: 16 / 9; overflow: hidden; margin-bottom: 22px; background: var(--ivory-deep); }
.tbv-guide-feature__media img { width: 100%; height: 100%; object-fit: cover; display: block; }
.tbv-guide-feature h3 { font-size: 1.28rem; margin-bottom: 10px; }
.tbv-guide-feature h3 a { text-decoration: none; color: var(--forest-deep); }
.tbv-guide-feature h3 a:hover { color: var(--forest-soft); }
.tbv-guide-feature p:not(.tbv-card-brand) { font-size: .88rem; color: var(--ink-muted); flex: 1; }
.tbv-card-brand { font-size: .67rem; text-transform: uppercase; letter-spacing: .14em; color: var(--sage); font-weight: 700; margin-bottom: 12px; }

/* Editorial cards and grids */
.tbv-editorial-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 22px; }
.tbv-editorial-card { background: var(--white); border: 1px solid var(--border); border-radius: var(--radius); overflow: hidden; display: flex; flex-direction: column; transition: box-shadow .2s ease, transform .2s ease; }
.tbv-editorial-card:hover { box-shadow: var(--shadow-soft); transform: translateY(-2px); }
.tbv-editorial-card__media { overflow: hidden; aspect-ratio: 16 / 9; background: var(--ivory-deep); }
.tbv-editorial-card__media img { width: 100%; height: 100%; object-fit: cover; transition: transform .4s ease; }
.tbv-editorial-card:hover .tbv-editorial-card__media img { transform: scale(1.03); }
.tbv-editorial-card__body { padding: 24px; display: flex; flex-direction: column; flex: 1; }
.tbv-editorial-card__body h3 a { text-decoration: none; color: var(--forest-deep); }
.tbv-editorial-card__body p:last-of-type { font-size: .88rem; color: var(--ink-muted); flex: 1; }
.tbv-card-date { font-size: .74rem; color: var(--sage); margin: 0; }

/* Comparison intro */
.tbv-compare-intro { display: grid; grid-template-columns: 1fr 1fr; gap: 48px; align-items: center; }
.tbv-dimension-list { list-style: none; padding: 0; margin: 0; display: grid; grid-template-columns: 1fr 1fr; gap: 0 28px; }
.tbv-dimension-list li { border-bottom: 1px solid var(--border); padding: 13px 0 13px 26px; position: relative; font-size: .92rem; margin: 0; }
.tbv-dimension-list li::before { content: ''; position: absolute; left: 0; top: 21px; width: 9px; height: 9px; border: 1px solid var(--gold); transform: rotate(45deg); }
.tbv-compare-intro__action { background: var(--forest); color: #d7e2d9; padding: 38px; border-radius: var(--radius-lg); }
.tbv-compare-intro__action h3 { color: #fff; }
.tbv-compare-intro__action p { font-size: .9rem; color: #cbd8cf; }
.tbv-compare-intro__action .tbv-button { background: var(--gold); border-color: var(--gold); color: var(--forest-deep); }
.tbv-compare-intro__action .tbv-button:hover { background: var(--gold-soft); border-color: var(--gold-soft); }

/* Split section */
.tbv-split { display: grid; grid-template-columns: minmax(0, 1.05fr) minmax(0, .95fr); gap: clamp(40px, 6vw, 90px); align-items: center; }
.tbv-split h2 { font-size: clamp(1.8rem, 2.8vw, 2.7rem); }
.tbv-split__list { list-style: none; padding: 0; margin: 0; }
.tbv-split__list li { border-top: 1px solid rgba(255,255,255,.16); padding: 18px 0; display: flex; flex-direction: column; gap: 4px; margin: 0; }
.tbv-split__list strong { font-family: var(--font-display); font-size: 1.15rem; color: #fff; font-weight: 500; }
.tbv-split__list span { font-size: .88rem; color: #cbd8cf; }

/* Method grid */
.tbv-method-grid { display: grid; grid-template-columns: repeat(5, 1fr); gap: 16px; }
.tbv-method-grid article { padding: 26px 20px; background: var(--white); border: 1px solid var(--border); border-top: 2px solid var(--gold); border-radius: var(--radius); }
.tbv-method-num { font-family: var(--font-display); font-size: 1.7rem; color: var(--gold); display: block; margin-bottom: 16px; }
.tbv-method-grid h3 { font-size: 1.05rem; }
.tbv-method-grid p { font-size: .83rem; color: var(--ink-muted); margin: 0; }

/* Trust section */
.tbv-trust-section { background: var(--ivory-deep); border-top: 1px solid var(--border); }
.tbv-trust-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 60px; align-items: start; }
.tbv-trust-grid > div p { color: var(--ink-muted); max-width: 46ch; }
.tbv-trust-grid ul { list-style: none; padding: 0; margin: 0; }
.tbv-trust-grid li { border-bottom: 1px solid var(--border-dark); margin: 0; }
.tbv-trust-grid a { display: flex; justify-content: space-between; padding: 15px 0; text-decoration: none; font-weight: 600; font-size: .92rem; }
.tbv-trust-grid a span { color: var(--gold); }

/* ------------------------------------------------------------------
   5. Product cards and archives
   ------------------------------------------------------------------ */
.tbv-product-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 22px; }
.tbv-product-card { background: var(--white); border: 1px solid var(--border); border-radius: var(--radius); overflow: hidden; display: flex; flex-direction: column; transition: box-shadow .2s ease, transform .2s ease; }
.tbv-product-card:hover { box-shadow: var(--shadow-soft); transform: translateY(-2px); }
.tbv-product-card__media { aspect-ratio: 4 / 2.6; background: var(--ivory-deep); overflow: hidden; display: grid; place-items: center; }
.tbv-product-card__media img { width: 100%; height: 100%; object-fit: cover; }
.tbv-product-card__media--type { text-decoration: none; color: var(--sage); }
.tbv-product-card__media--type span { font-family: var(--font-display); font-size: 1.4rem; color: var(--sage); text-decoration: none; }
.tbv-product-card__body { padding: 22px 22px 18px; display: flex; flex-direction: column; flex: 1; }
.tbv-product-card__body h3 { font-size: 1.2rem; margin-bottom: 12px; }
.tbv-product-card__body h3 a { text-decoration: none; color: var(--forest-deep); }
.tbv-card-specs { margin: 0 0 18px; }
.tbv-card-specs > div { display: flex; justify-content: space-between; gap: 12px; padding: 7px 0; border-top: 1px solid var(--border); font-size: .8rem; }
.tbv-card-specs dt { color: var(--ink-muted); }
.tbv-card-specs dd { margin: 0; font-weight: 600; text-align: right; font-variant-numeric: tabular-nums; }
.tbv-card-price { font-weight: 700; font-variant-numeric: tabular-nums; margin-bottom: 14px; }
.tbv-card-price span { font-weight: 400; font-size: .72rem; color: var(--sage); }
.tbv-card-price--muted { font-weight: 400; color: var(--sage); font-size: .82rem; }
.tbv-card-footer { margin-top: auto; border-top: 1px solid var(--border); padding-top: 14px; display: flex; align-items: center; justify-content: space-between; gap: 10px; flex-wrap: wrap; }
.tbv-card-compare { font-size: .74rem; font-weight: 600; color: var(--sage); text-decoration: none; border-bottom: 1px solid var(--border-dark); }
.tbv-card-compare:hover { color: var(--forest); border-bottom-color: var(--gold); }
.tbv-card-retailer { font-size: .74rem; font-weight: 700; color: var(--forest); text-decoration: none; }
.tbv-card-retailer:hover { color: var(--forest-soft); text-decoration: underline; }

.tbv-page-header { padding: 34px 0 38px; border-bottom: 1px solid var(--border); margin-bottom: 38px; }
.tbv-page-header h1 { margin-bottom: 14px; }
.tbv-page-header__deck { max-width: 66ch; color: var(--ink-muted); font-size: 1.02rem; margin: 0; }
.tbv-breadcrumbs { padding: 24px 0 0; }
.tbv-breadcrumbs ol { list-style: none; display: flex; flex-wrap: wrap; gap: 8px; padding: 0; margin: 0; font-size: .74rem; color: var(--ink-muted); }
.tbv-breadcrumbs li + li::before { content: '/'; margin-right: 8px; color: var(--gold); }
.tbv-breadcrumbs a { text-decoration: none; color: var(--ink-muted); }
.tbv-breadcrumbs a:hover { color: var(--forest); }
.tbv-catalog-filters { display: grid; grid-template-columns: 1.4fr 1fr 1fr 1fr 1fr auto; gap: 12px; align-items: end; background: var(--white); border: 1px solid var(--border); border-radius: var(--radius); padding: 18px; margin-bottom: 28px; }
.tbv-catalog-filters label { display: flex; flex-direction: column; gap: 6px; font-size: .74rem; font-weight: 600; color: var(--forest); }
.tbv-catalog-filters input, .tbv-catalog-filters select { width: 100%; padding: 9px 10px; border: 1px solid var(--border-dark); border-radius: 3px; background: var(--ivory); font-size: .85rem; }
.tbv-filter-bar { margin-bottom: 30px; }
.tbv-filter-links { display: flex; flex-wrap: wrap; gap: 8px; }
.tbv-filter-links a { padding: 7px 14px; border: 1px solid var(--border); border-radius: 100px; font-size: .8rem; text-decoration: none; background: var(--white); }
.tbv-filter-links a:hover, .tbv-filter-links a.is-active { background: var(--forest); border-color: var(--forest); color: #fff; }

/* ------------------------------------------------------------------
   6. Article layout
   ------------------------------------------------------------------ */
.tbv-article__header { max-width: 900px; padding: 34px 0 40px; border-bottom: 1px solid var(--border); margin-bottom: 38px; }
.tbv-article__header h1 { margin-bottom: 18px; }
.tbv-deck { font-size: clamp(1.05rem, 1.4vw, 1.25rem); color: var(--ink-muted); max-width: 70ch; }
.tbv-article__meta { display: flex; gap: 26px; flex-wrap: wrap; font-size: .78rem; color: var(--sage); margin-top: 22px; }
.tbv-article__meta strong { color: var(--forest); font-weight: 600; }
.tbv-article__layout { display: grid; grid-template-columns: minmax(0, 1fr) 300px; gap: clamp(36px, 5vw, 74px); align-items: start; }
.tbv-prose { font-size: 1rem; line-height: 1.78; }
.tbv-prose h2 { margin-top: 1.8em; font-size: 1.85rem; }
.tbv-prose h3 { margin-top: 1.6em; font-size: 1.3rem; }
.tbv-prose table { width: 100%; border-collapse: collapse; font-size: .88rem; margin: 1.5em 0; }
.tbv-prose th, .tbv-prose td { border: 1px solid var(--border); padding: 10px 12px; text-align: left; vertical-align: top; }
.tbv-prose thead th { background: var(--ivory-deep); font-family: var(--font-ui); font-size: .74rem; text-transform: uppercase; letter-spacing: .08em; }
.tbv-prose blockquote { border-left: 3px solid var(--gold); margin: 1.6em 0; padding: 6px 0 6px 22px; color: var(--forest-soft); font-family: var(--font-display); font-size: 1.15rem; }
.tbv-prose img { border-radius: var(--radius); margin: 1.5em 0; }
.tbv-prose a { text-decoration-color: var(--gold); }
.tbv-takeaways { background: var(--white); border: 1px solid var(--border); border-left: 3px solid var(--gold); border-radius: var(--radius); padding: 24px 28px; margin-bottom: 34px; }
.tbv-takeaways h2 { font-size: 1.25rem; }
.tbv-takeaways ul { margin-bottom: 0; font-size: .92rem; }
.tbv-aside-card { background: var(--white); border: 1px solid var(--border); border-radius: var(--radius); padding: 24px; margin-bottom: 18px; }
.tbv-aside-card h2 { font-size: 1.15rem; margin-bottom: 14px; }
.tbv-aside-card--quiet { background: transparent; }
.tbv-aside-links { list-style: none; padding: 0; margin: 0; font-size: .86rem; }
.tbv-aside-links li { border-bottom: 1px solid var(--border); padding: 8px 0; margin: 0; }
.tbv-aside-links a { text-decoration: none; }
.tbv-aside-price { font-family: var(--font-display); font-size: 1.9rem; color: var(--forest-deep); margin-bottom: 2px; font-variant-numeric: tabular-nums; }
.tbv-aside-sub { font-size: .82rem; color: var(--ink-muted); }
.tbv-disclosure { font-size: .78rem; line-height: 1.6; color: var(--ink-muted); background: var(--ivory-deep); border: 1px solid var(--border); border-radius: var(--radius); padding: 18px; }
.tbv-disclosure a { color: var(--forest); }
.tbv-disclosure--inline { margin-top: 34px; }
.tbv-sources { margin-top: 44px; }
.tbv-sources h2 { font-size: 1.35rem; }
.tbv-sources ol { font-size: .84rem; color: var(--ink-muted); }
.tbv-sources a { word-break: break-word; }
.tbv-source-arrow { color: var(--gold); margin-left: 4px; }
.tbv-related { margin-top: 70px; }
.tbv-reference-facts { margin-top: 40px; }
.tbv-reference-facts h2 { font-size: 1.35rem; }
.tbv-reference-facts dl { border-top: 1px solid var(--border); }
.tbv-reference-facts dl > div { border-bottom: 1px solid var(--border); padding: 16px 0; display: grid; grid-template-columns: 220px 1fr; gap: 20px; }
.tbv-reference-facts dt { font-weight: 700; font-size: .85rem; color: var(--forest); }
.tbv-reference-facts dd { margin: 0; font-size: .9rem; color: var(--ink-muted); }

/* ------------------------------------------------------------------
   7. Product detail
   ------------------------------------------------------------------ */
.tbv-product-detail__header { display: grid; grid-template-columns: minmax(0, 1.05fr) minmax(0, .95fr); gap: clamp(30px, 5vw, 70px); align-items: center; padding: 34px 0 46px; border-bottom: 1px solid var(--border); }
.tbv-product-detail__header h1 { margin-bottom: 14px; }
.tbv-product-detail__media img { border-radius: var(--radius-lg); border: 1px solid var(--border); box-shadow: var(--shadow-soft); }
.tbv-image-credit { font-size: .7rem; color: var(--sage); margin-top: 10px; }
.tbv-product-placeholder { aspect-ratio: 4 / 2.8; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 10px; background: var(--ivory-deep); border: 1px dashed var(--border-dark); border-radius: var(--radius-lg); text-align: center; padding: 24px; }
.tbv-product-placeholder span { font-family: var(--font-display); font-size: 1.3rem; color: var(--forest-soft); }
.tbv-product-placeholder small { font-size: .75rem; color: var(--sage); max-width: 34ch; }
.tbv-product-layout { display: grid; grid-template-columns: minmax(0, 1fr) 300px; gap: clamp(36px, 5vw, 72px); align-items: start; padding-top: 44px; }
.tbv-content-block { margin-bottom: 44px; }
.tbv-content-block > h2 { font-size: 1.5rem; margin-bottom: 14px; }
.tbv-spec-table { border-top: 1px solid var(--border); margin: 0; }
.tbv-spec-table > div { display: grid; grid-template-columns: 200px 1fr; gap: 16px; padding: 12px 0; border-bottom: 1px solid var(--border); font-size: .88rem; }
.tbv-spec-table dt { color: var(--ink-muted); }
.tbv-spec-table dd { margin: 0; font-weight: 600; }
.tbv-spec-table--stacked > div { grid-template-columns: 180px 1fr; }
.tbv-two-col { display: grid; grid-template-columns: 1fr 1fr; gap: 26px; }
.tbv-two-col h3 { font-size: 1.05rem; }
.tbv-two-col ul { font-size: .88rem; color: var(--ink-muted); }

/* Tables */
.tbv-table-wrap { overflow-x: auto; border: 1px solid var(--border); border-radius: var(--radius); background: var(--white); -webkit-overflow-scrolling: touch; }
.tbv-table-wrap table { width: 100%; border-collapse: collapse; font-size: .86rem; }
.tbv-table-wrap caption { text-align: left; padding: 14px 16px; font-size: .78rem; color: var(--ink-muted); border-bottom: 1px solid var(--border); background: var(--ivory); }
.tbv-table-wrap th, .tbv-table-wrap td { padding: 12px 14px; border-bottom: 1px solid var(--border); text-align: left; vertical-align: top; }
.tbv-table-wrap thead th { background: var(--ivory-deep); font-size: .78rem; text-transform: uppercase; letter-spacing: .06em; color: var(--forest); min-width: 150px; }
.tbv-table-wrap tbody th { background: var(--white); font-weight: 600; color: var(--forest); min-width: 170px; }
.tbv-table-wrap tbody tr:last-child th, .tbv-table-wrap tbody tr:last-child td { border-bottom: 0; }
.tbv-facts-table th:first-child, .tbv-facts-table td { font-variant-numeric: tabular-nums; }
.tbv-compare-table td { color: var(--ink-muted); }

/* Comparison browser */
.tbv-browser-controls { display: flex; gap: 18px; flex-wrap: wrap; margin-bottom: 22px; }
.tbv-browser-controls label { display: flex; flex-direction: column; gap: 6px; font-size: .78rem; font-weight: 600; color: var(--forest); min-width: 220px; }
.tbv-browser-controls select, .tbv-browser-controls input { padding: 10px 12px; border: 1px solid var(--border-dark); border-radius: var(--radius); background: var(--white); font-size: .88rem; }
.tbv-browser-hint { font-size: .82rem; color: var(--sage); }
.tbv-browser-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; margin-bottom: 28px; }
.tbv-browser-item { display: flex; gap: 12px; align-items: flex-start; padding: 16px; border: 1px solid var(--border); border-radius: var(--radius); background: var(--white); cursor: pointer; }
.tbv-browser-item:hover { border-color: var(--sage); }
.tbv-browser-item input { margin-top: 5px; accent-color: var(--forest); }
.tbv-browser-item strong { display: block; font-size: .88rem; color: var(--forest-deep); }
.tbv-browser-item small { display: block; font-size: .72rem; color: var(--sage); margin-top: 3px; }
.tbv-compare-results:empty { display: none; }
.tbv-selected-chips { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 16px; }
.tbv-chip { display: inline-flex; align-items: center; gap: 6px; background: var(--ivory-deep); border: 1px solid var(--border-dark); border-radius: 100px; padding: 5px 12px; font-size: .76rem; color: var(--forest); cursor: pointer; }
.tbv-chip:hover { border-color: var(--forest); }

/* 404 */
.tbv-404 { padding: 100px 0 120px; max-width: 760px; }
.tbv-404 h1 { margin-bottom: 18px; }
.tbv-404__links { display: flex; flex-wrap: wrap; gap: 10px; margin: 30px 0 44px; }
.tbv-404__search { border-top: 1px solid var(--border); padding-top: 28px; display: flex; flex-direction: column; gap: 10px; max-width: 520px; }
.tbv-404__search label { font-weight: 600; font-size: .86rem; }
.tbv-404__search input { padding: 12px; border: 1px solid var(--border-dark); border-radius: var(--radius); }
.tbv-404__search button { align-self: flex-start; }

/* Pagination */
.tbv-pagination { display: flex; gap: 8px; list-style: none; padding: 0; margin: 44px 0 0; }
.tbv-pagination .page-numbers { padding: 8px 13px; border: 1px solid var(--border); border-radius: var(--radius); text-decoration: none; font-size: .84rem; background: var(--white); }
.tbv-pagination .current { background: var(--forest); color: #fff; border-color: var(--forest); }

/* ------------------------------------------------------------------
   8. Footer
   ------------------------------------------------------------------ */
.tbv-site-footer { background: var(--forest-deep); color: #ced9d0; padding: 72px 0 28px; }
.tbv-footer__top { display: grid; grid-template-columns: 1.5fr repeat(3, 1fr); gap: 44px; padding-bottom: 46px; border-bottom: 1px solid rgba(255,255,255,.12); }
.tbv-footer__brand img { width: 44px; height: 44px; margin-bottom: 18px; }
.tbv-footer__brand h2 { color: #fff; font-size: 1.5rem; }
.tbv-footer__brand p { font-size: .85rem; color: #b8c8bd; max-width: 40ch; }
.tbv-footer__promise { color: var(--gold-soft) !important; font-style: italic; }
.tbv-footer__col h3 { color: #fff; font-family: var(--font-ui); font-size: .76rem; letter-spacing: .15em; text-transform: uppercase; margin-bottom: 18px; }
.tbv-footer__col ul { list-style: none; padding: 0; margin: 0; }
.tbv-footer__col li { margin-bottom: 10px; }
.tbv-footer__col a { color: #b8c8bd; text-decoration: none; font-size: .85rem; }
.tbv-footer__col a:hover { color: #fff; text-decoration: underline; }
.tbv-footer__disclosure { padding: 30px 0; border-bottom: 1px solid rgba(255,255,255,.12); }
.tbv-footer__disclosure p { font-size: .74rem; color: #aebfb3; max-width: 92ch; margin-bottom: 10px; }
.tbv-footer__disclosure strong { color: #e3ece5; }
.tbv-footer__disclosure a { color: var(--gold-soft); }
.tbv-footer__bottom { display: flex; justify-content: space-between; gap: 20px; padding-top: 24px; font-size: .74rem; color: #94a99b; }
.tbv-footer__bottom p { margin: 0; }
.tbv-footer__bottom a { color: #94a99b; }

/* ------------------------------------------------------------------
   9. Editorial imagery — reusable, predictable media containers
   ------------------------------------------------------------------ */
/* Base: every image is fluid, dimensioned and never escapes its container. */
.tbv-figure { margin: 30px 0 34px; min-width: 0; }
.tbv-figure__image {
	display: block;
	width: 100%;
	max-width: 100%;
	height: auto;
	border: 1px solid var(--border);
	border-radius: var(--radius);
	background: var(--white);
}
.tbv-figure figcaption { display: flex; flex-direction: column; gap: 4px; margin-top: 12px; font-size: .8rem; line-height: 1.55; color: var(--ink-muted); }
.tbv-figure__caption { color: var(--charcoal); }
.tbv-figure__credit { color: var(--sage); font-size: .74rem; }
.tbv-figure__credit a { color: var(--forest); }
.tbv-figure--wide { margin: 38px 0 44px; max-width: 100%; }
.tbv-hero__visual .tbv-figure { margin: 0; }

/* Editorial photography: 16:9, cropped consistently. */
.tbv-media--editorial { aspect-ratio: 16 / 9; overflow: hidden; }
.tbv-media--editorial img { width: 100%; height: 100%; object-fit: cover; }

/* Product packaging and labels: contained, never cropped. */
.tbv-media--product { aspect-ratio: 1 / 1; overflow: hidden; display: grid; place-items: center; }
.tbv-media--product img { width: 100%; height: 100%; object-fit: contain; }

/* Category thumbnails: 4:3, cropped consistently. */
.tbv-media--thumbnail { aspect-ratio: 4 / 3; overflow: hidden; }
.tbv-media--thumbnail img { width: 100%; height: 100%; object-fit: cover; }

/* Scientific diagrams: intrinsic proportions, no cropping. */
.tbv-media--diagram img { width: 100%; height: auto; object-fit: contain; }

.tbv-image-strip { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 20px; margin-top: 44px; }
.tbv-image-strip .tbv-figure { margin: 0; min-width: 0; }
.tbv-image-strip .tbv-figure__image { aspect-ratio: 4 / 3; object-fit: cover; }
.tbv-image-strip figcaption { font-size: .78rem; }
.tbv-image-pair { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 24px; align-items: start; margin-top: 38px; }
.tbv-image-pair .tbv-figure { margin: 0; min-width: 0; }
.tbv-image-pair .tbv-figure__image { aspect-ratio: 4 / 3; object-fit: cover; }
.tbv-image-pair .tbv-figure--contain .tbv-figure__image { object-fit: contain; background: var(--white); padding: 14px; }
.tbv-image-pair figcaption { font-size: .78rem; }

/* ------------------------------------------------------------------
   10. Responsive
   ------------------------------------------------------------------ */
@media (max-width: 1180px) {
	.tbv-menu { gap: 14px; }
	.tbv-menu a { font-size: .8rem; }
	.tbv-header__inner { gap: 18px; }
	.tbv-method-grid { grid-template-columns: repeat(3, 1fr); }
}

@media (max-width: 1024px) {
	.tbv-primary-nav { display: none; }
	.tbv-header__actions > .tbv-button { display: none; }
	.tbv-nav-toggle { display: flex; }
	.tbv-mobile-nav.is-open { display: block; padding: 12px 0 24px; }
	.tbv-mobile-menu { list-style: none; padding: 0; margin: 0 0 18px; }
	.tbv-mobile-menu li { margin: 0; border-bottom: 1px solid var(--border); }
	.tbv-mobile-menu a { display: block; padding: 14px 0; text-decoration: none; font-weight: 600; font-variant-numeric: tabular-nums; }
	.tbv-hero__grid { gap: 34px; }
	.tbv-directory { grid-template-columns: repeat(3, 1fr); }
	.tbv-guide-feature-grid, .tbv-editorial-grid, .tbv-product-grid, .tbv-browser-grid { grid-template-columns: repeat(2, 1fr); }
	.tbv-split, .tbv-compare-intro, .tbv-trust-grid { grid-template-columns: 1fr; gap: 34px; }
	.tbv-compare-intro { gap: 26px; }
	.tbv-article__layout, .tbv-product-layout { grid-template-columns: minmax(0, 1fr) 260px; gap: 34px; }
	.tbv-footer__top { grid-template-columns: 1.2fr repeat(3, 1fr); gap: 28px; }
}

@media (max-width: 768px) {
	.tbv-container { width: min(calc(100% - 32px), var(--container)); }
	.tbv-topbar__right { display: none; }
	.tbv-header__inner { min-height: 70px; }
	.tbv-header__actions .tbv-button { display: none; }
	.tbv-hero__grid { grid-template-columns: 1fr; }
	.tbv-hero__visual { order: -1; }
	.tbv-hero__visual::after { inset: 10px -10px -10px 10px; }
	.tbv-trust-strip__grid { grid-template-columns: repeat(2, 1fr); gap: 22px; }
	.tbv-trust-strip__grid > div:nth-child(3) { border-left: 0; padding-left: 0; }
	.tbv-section__head { flex-direction: column; align-items: flex-start; gap: 14px; margin-bottom: 30px; }
	.tbv-directory { grid-template-columns: repeat(2, 1fr); }
	.tbv-method-grid { grid-template-columns: repeat(2, 1fr); }
	.tbv-article__layout, .tbv-product-layout { grid-template-columns: 1fr; }
	.tbv-article__aside, .tbv-product-layout__aside { display: grid; grid-template-columns: repeat(2, 1fr); gap: 14px; }
	.tbv-product-detail__header { grid-template-columns: 1fr; }
	.tbv-product-detail__media { order: -1; }
	.tbv-reference-facts dl > div { grid-template-columns: 1fr; gap: 6px; }
	.tbv-spec-table > div, .tbv-spec-table--stacked > div { grid-template-columns: 150px 1fr; }
	.tbv-footer__top { grid-template-columns: 1fr 1fr; }
}

@media (max-width: 560px) {
	body { font-size: 15px; }
	.tbv-hero { padding-top: 44px; }
	.tbv-hero__actions { flex-direction: column; align-items: stretch; }
	.tbv-hero__actions .tbv-button { width: 100%; }
	.tbv-directory, .tbv-guide-feature-grid, .tbv-editorial-grid, .tbv-product-grid, .tbv-browser-grid, .tbv-method-grid, .tbv-two-col, .tbv-dimension-list, .tbv-trust-strip__grid, .tbv-article__aside, .tbv-product-layout__aside { grid-template-columns: 1fr; }
	.tbv-trust-strip__grid > div { border-left: 0; padding-left: 0; }
	.tbv-subhead { flex-direction: column; align-items: flex-start; gap: 6px; }
	.tbv-browser-controls { flex-direction: column; }
	.tbv-browser-controls label { min-width: 0; width: 100%; }
	.tbv-table-wrap th, .tbv-table-wrap td { min-width: 140px; }
	.tbv-spec-table > div, .tbv-spec-table--stacked > div { grid-template-columns: 1fr; gap: 3px; }
	.tbv-footer__top { grid-template-columns: 1fr; }
	.tbv-footer__bottom { flex-direction: column; }
	.tbv-search-panel form { flex-direction: column; }
	.tbv-search-panel .tbv-button { width: 100%; }
}

@media (max-width: 1024px) {
	.tbv-catalog-filters { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}

@media (max-width: 768px) {
	.tbv-catalog-filters { grid-template-columns: repeat(2, minmax(0, 1fr)); }
	.tbv-image-strip { grid-template-columns: 1fr; gap: 26px; }
	.tbv-image-pair { grid-template-columns: 1fr; gap: 26px; }
	.tbv-figure { margin: 24px 0 28px; }
	.tbv-figure figcaption { font-size: .76rem; }
	/* Text-heavy diagrams scroll inside their figure; the page must not expand. */
	.tbv-article__layout, .tbv-product-layout { grid-template-columns: minmax(0, 1fr); }
	.tbv-article__body, .tbv-content-block, .tbv-prose, .tbv-figure { min-width: 0; max-width: 100%; }
	.tbv-figure:has(img[src$=".svg"]) { overflow-x: auto; -webkit-overflow-scrolling: touch; }
	.tbv-figure img[src$=".svg"] { min-width: 640px; }
}

@media (prefers-reduced-motion: reduce) {
	*, *::before, *::after { animation-duration: .01ms !important; transition-duration: .01ms !important; scroll-behavior: auto !important; }
}
