/* =============================================================================
 * erp-tokens.css — ERP Peptide design system
 *
 * MEASURED over CDP (see RECON-FINDINGS §10 / source-cdp/tokens.json).
 *
 * ⚠️ The source defines ZERO :root custom properties — every value below was read
 *    off a real computed style, not invented. The vars here exist so OUR templates
 *    stay consistent; they are NOT a re-interpretation of the source. Where the
 *    source hard-codes a literal (e.g. #0a1a3b in a box-shadow rgba) the literal is
 *    kept literal so nothing silently drifts from the captures.
 *
 * Load order:  vendor-bootstrap.css -> erp-tokens.css -> erp-layout.css -> erp-home.css
 * =============================================================================*/

/* ---------------------------------------------------------------------------
 * 1. Fonts — self-hosted
 *
 *    Poppins: the source's own three TTFs, mapped to 400/600/700 exactly as the
 *    source maps them (note Poppins-SemiBold.ttf is declared as weight 700 there).
 *
 *    Playfair Display: ⚠️ correction to recon O3 — the source is NOT missing it.
 *    It loads at source via `@import url(fonts.googleapis.com/css2?family=
 *    Playfair+Display:wght@400;500;600;700;800&display=swap)` on line 1 of
 *    app.css, so the serif on h1–h6 renders there and is intentional, not a bug.
 *    We match that rendering but SELF-HOST it (brief decision 19): same family,
 *    no third-party request, no render-blocking @import. One variable woff2
 *    covers 400–900, which is a superset of the five weights the source asks for.
 * ------------------------------------------------------------------------- */
@font-face {
	font-family: "Poppins";
	font-style: normal;
	font-weight: 400;
	font-display: swap;
	src: url("../fonts/Poppins-Regular.ttf") format("truetype");
}
@font-face {
	font-family: "Poppins";
	font-style: normal;
	font-weight: 600;
	font-display: swap;
	src: url("../fonts/Poppins-Medium.ttf") format("truetype");
}
@font-face {
	font-family: "Poppins";
	font-style: normal;
	font-weight: 700;
	font-display: swap;
	src: url("../fonts/Poppins-SemiBold.ttf") format("truetype");
}

/* Variable woff2 — one file covers 400–900. */
@font-face {
	font-family: "Playfair Display";
	font-style: normal;
	font-weight: 400 900;
	font-display: swap;
	src: url("../fonts/PlayfairDisplay-latin.woff2") format("woff2");
	unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA,
		U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193,
		U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
	font-family: "Playfair Display";
	font-style: normal;
	font-weight: 400 900;
	font-display: swap;
	src: url("../fonts/PlayfairDisplay-latin-ext.woff2") format("woff2");
	unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF,
		U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020,
		U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}

/* ---------------------------------------------------------------------------
 * 2. Tokens
 * ------------------------------------------------------------------------- */
:root {
	/* -- palette (measured) -- */
	--erp-navy: #0a1a3b;          /* .btn-primary bg, .price-new, .faq-question, support pill */
	--erp-navy-deep: #061635;     /* notice-bar gradient stop 1 */
	--erp-navy-mid: #102b5c;      /* notice-bar gradient stop 3 */
	--erp-navy-card: #0b1f3f;     /* .section-card--dark */
	--erp-navy-foot: #08152e;     /* footer-bottom */
	--erp-slate: #233044;         /* body text, .nav-link, .product-name */
	--erp-dark: #212529;          /* bootstrap dark — .btn-outline-dark text */
	--erp-gold: #f6db7b;          /* banner dot + links, hero eyebrow pills, JOIN NOW */
	--erp-gold-soft: #fff2b8;     /* banner link hover */
	--erp-gold-ink: #7a5a00;      /* assurance tag text on gold tint */
	--erp-white: #fff;
	--erp-panel: #f9fbff;         /* .faq-item bg */
	--erp-page: #e9f1fb;          /* body.page-factory bg */
	--erp-tile: #f5f5f5;          /* product card image well */
	--erp-muted: #536171;
	--erp-muted-2: #5c6168;
	--erp-muted-3: #667085;
	--erp-muted-4: #5e6c7b;
	--erp-body-copy: #4a5a6d;     /* .factory-page p */

	/* -- hairlines / tints -- */
	--erp-line: rgba(10, 26, 59, 0.08);
	--erp-line-2: rgba(10, 26, 59, 0.12);
	--erp-line-3: rgba(10, 26, 59, 0.18);
	--erp-line-light: rgba(255, 255, 255, 0.14);
	/* ⚠️ The SOLID gold is #F6DB7B = rgb(246,219,123), but every TINT on the
	   source is authored as hsla(47,87%,72%,x), which resolves to
	   rgb(246,219,121) — one unit of blue apart. Measured over CDP. Keep the
	   hsla() form so the tints stay byte-identical to the captures. */
	--erp-gold-12: hsla(47, 87%, 72%, 0.12);
	--erp-gold-18: hsla(47, 87%, 72%, 0.18);
	--erp-gold-22: rgba(246, 219, 123, 0.22); /* banner border — authored as rgba at source */
	--erp-gold-28: hsla(47, 87%, 72%, 0.28);
	--erp-gold-32: hsla(47, 87%, 72%, 0.32);

	/* -- shadows (measured) -- */
	--erp-shadow-card: 0 14px 26px rgba(10, 26, 59, 0.08);   /* .product-wrap */
	--erp-shadow-card-hover: 0 18px 32px rgba(10, 26, 59, 0.12);
	--erp-shadow-pill: 0 12px 30px rgba(10, 26, 59, 0.12);   /* .header-pill */
	--erp-shadow-section: 0 18px 40px rgba(10, 26, 59, 0.08);/* .section-card / .faq-shell */
	--erp-shadow-banner: 0 8px 20px rgba(10, 26, 59, 0.16);
	--erp-shadow-footer: 0 18px 30px rgba(10, 26, 59, 0.15);
	--erp-shadow-panel: 0 20px 48px rgba(10, 26, 59, 0.18);  /* live-support panel */

	/* -- radii (measured) -- */
	--erp-r-pill: 999px;    /* header pill, outline buttons, banner dot, JOIN NOW */
	--erp-r-section: 26px;  /* .section-card */
	--erp-r-shell: 24px;    /* .faq-shell */
	--erp-r-card: 18px;     /* product card, faq item, support panel */
	--erp-r-tile: 14px;     /* card image well, support rows */
	--erp-r-btn: 8px;       /* .btn-primary */
	--erp-r-footer: 36px;   /* footer shell */

	/* -- type -- */
	--erp-font-body: "Poppins", "Helvetica", "Arial", sans-serif;
	--erp-font-display: "Playfair Display", Georgia, "Times New Roman", serif;
	--erp-font-system: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto,
		"Helvetica Neue", Arial, sans-serif;

	/* -- layout -- */
	--erp-container: 1320px;
	--erp-container-pad: 24px;       /* .container */
	--erp-container-pad-fluid: 50px; /* .container-fluid */

	/* -- the notice-bar height contract. The header + hero offsets read this;
	     erp-app.js re-measures the real bar and rewrites it on load/resize, exactly
	     as the source's inline script does. Keep this relationship intact. -- */
	--site-banner-height: 38px;
}

@media (max-width: 768px) {
	:root {
		--site-banner-height: 34px;
	}
}

/* ---------------------------------------------------------------------------
 * 3. Base
 * ------------------------------------------------------------------------- */
body {
	-webkit-font-smoothing: antialiased;
	-webkit-text-size-adjust: none;
	background-color: #fff;
	color: var(--erp-slate);
	font-family: var(--erp-font-body);
	font-style: normal;
	overflow-x: hidden;
}

/* The source pins BOTH container widths at 1320 and only the padding differs.
 *
 * ⚠️ `!important` on the fluid rule is NOT decoration — the source has it too, and
 * without it the vendored Bootstrap's `.container-fluid:not(.w-100.px-0){max-width:1920px}`
 * wins on specificity (0,3,0 vs 0,1,1) and EVERY `-fluid` page runs full-bleed.
 * Found by P3's CDP box diff at integration; it affected P8's pages as well. */
body .container,
body .container-fluid {
	margin-left: auto;
	margin-right: auto;
	max-width: var(--erp-container);
	width: 100%;
}

body .container-fluid {
	max-width: var(--erp-container) !important;
}

/* The unsized `.btn-outline-dark` pill below must NOT swallow `.btn-sm`, or the
 * archive "View Category" pill renders 41×143 against the source's 26×100 —
 * 14px taller, which shifts every grid row beneath it. */
.btn-outline-dark.btn-sm {
	font-size: 0.8rem;
	font-weight: 400;
	padding: 0.25rem 0.5rem;
}

/* ---------------------------------------------------------------------------
 * Heading scale — the source's own, verbatim (app.css, immediately after the
 * Poppins @font-face block). Bootstrap's responsive `h2{font-size:calc(...)}`
 * is overridden by it, so this scale is what actually renders. Every later
 * phase inherits it; do not re-derive per template.
 * ------------------------------------------------------------------------- */
h1, h2, h3, h4, h5, h6 {
	color: #282828;
	font-family: var(--erp-font-display);
	font-weight: 700;
}

h1 { font-size: 3.5rem; }
h2 { font-size: 2.25rem; }
h3 { font-size: 1.75rem; }
h4 { font-size: 1.5rem; }
h5 { font-size: 1.25rem; }
h6 { font-size: 1rem; }

@media (max-width: 992px) {
	h1 { font-size: 3rem; }
	h2 { font-size: 2rem; }
	h3 { font-size: 1.5rem; }
	h4 { font-size: 1.25rem; }
	h5 { font-size: 1.125rem; }
}

b, strong {
	color: #282828;
	font-weight: 700;
}

/* Every non-front template clears the fixed header. The front page's hero sits
   under it deliberately (source: body.page-home has no padding-top). */
body:not(.erp-front) {
	padding-top: 90px;
}

@media (max-width: 768px) {
	body:not(.erp-front) {
		padding-top: 80px;
	}
}

a {
	text-decoration: none;
}

/* ---------------------------------------------------------------------------
 * 4. Button primitives (measured off .btn-primary / .btn-outline-dark)
 * ------------------------------------------------------------------------- */
.btn-primary {
	--bs-btn-color: #fff;
	--bs-btn-bg: var(--erp-navy);
	--bs-btn-border-color: var(--erp-navy);
	--bs-btn-hover-color: #fff;
	--bs-btn-hover-bg: #091632;
	--bs-btn-hover-border-color: #08152f;
	--bs-btn-active-color: #fff;
	--bs-btn-active-bg: #08152f;
	--bs-btn-active-border-color: #08142c;
	--bs-btn-disabled-color: #fff;
	--bs-btn-disabled-bg: var(--erp-navy);
	--bs-btn-disabled-border-color: var(--erp-navy);
	border-radius: var(--erp-r-btn);
	color: #fff !important;
}

.btn-outline-dark {
	border-radius: var(--erp-r-pill);
	border: 1px solid var(--erp-line-3);
	font-size: 0.92rem;
	font-weight: 600;
	padding: 0.55rem 1rem;
}

/* ---------------------------------------------------------------------------
 * 5. Badge / pill primitives
 * ------------------------------------------------------------------------- */
.erp-pill-gold {
	align-items: center;
	background: var(--erp-gold-18);
	border: 1px solid var(--erp-gold-32);
	border-radius: var(--erp-r-pill);
	color: var(--erp-gold);
	display: inline-flex;
	font-size: 0.75rem;
	font-weight: 600;
	letter-spacing: 0.08em;
	padding: 5px 10px;
	text-transform: uppercase;
}

.erp-tag-gold {
	align-items: center;
	background: var(--erp-gold-28);
	border-radius: var(--erp-r-pill);
	color: var(--erp-gold-ink);
	display: inline-flex;
	font-size: 0.75rem;
	font-weight: 700;
	justify-content: center;
	letter-spacing: 0.08em;
	padding: 6px 12px;
	text-transform: uppercase;
}

/* ---------------------------------------------------------------------------
 * 6. Card primitives
 * ------------------------------------------------------------------------- */
.section-card {
	background: #fff;
	border-radius: var(--erp-r-section);
	box-shadow: var(--erp-shadow-section);
	padding: 36px 40px;
}

.section-card--feature {
	background: linear-gradient(180deg, #fff, #f7fbff);
	border: 1px solid var(--erp-line);
}

.section-card--dark {
	background: var(--erp-navy-card);
	color: #fff;
}

.section-card--dark h2,
.section-card--dark p {
	color: #fff;
}

.section-header {
	margin-bottom: 16px;
}

.section-header.text-center {
	text-align: center;
}

@media (max-width: 768px) {
	.section-card {
		padding: 28px 24px;
	}
}
