/*
 * fonts-global.css
 * Site-wide typography refresh for the vintage/retro/digital/analog brand.
 * Loaded on every page (not just the homepage).
 *
 * Stack:
 *   - VT323      - display/headings (iconic CRT terminal pixel font)
 *   - Space Mono - body + metadata (retro-futurist monospace, readable at text sizes)
 *
 * Parent + child themes hardcode Playfair Display / Open Sans in many rules;
 * we override them here at the end of the cascade, with specificity where
 * needed to beat the parent theme's inline font-family declarations.
 */

/* Google Fonts import. If OMGF is active on prod, it will self-host these. */
@import url('https://fonts.googleapis.com/css2?family=Abril+Fatface&family=Oswald:wght@400;500;600;700&family=Cutive+Mono&family=VT323&family=Space+Mono:ital,wght@0,400;0,700;1,400;1,700&display=swap');

/* Global font tokens - heavy vintage direction.
   Hero / headlines = Abril Fatface (vintage magazine display serif).
   Nameplate labels = Oswald (condensed industrial - rack-unit faceplates).
   Readout          = VT323 (mechanical tape counter / LED glyph feel).
   Body             = Cutive Mono (warm typewriter) + Space Mono fallback. */
:root {
	--ad-font-hero:      'Abril Fatface', 'Georgia', serif;
	--ad-font-nameplate: 'Oswald', 'Arial Narrow', sans-serif;
	--ad-font-display:   'Abril Fatface', 'Georgia', serif;
	--ad-font-readout:   'VT323', 'Courier New', monospace;
	--ad-font-body:      'Cutive Mono', 'Space Mono', 'Courier New', monospace;
	--ad-font-mono:      'Cutive Mono', 'Space Mono', 'Courier New', monospace;
}

/* Base body text */
body,
#primary,
#primary select,
#primary input,
#primary textarea,
#site-footer,
#site-footer select,
#site-footer input,
#site-footer textarea {
	font-family: var(--ad-font-body);
	letter-spacing: 0.005em;
}

/* All headings site-wide get the pixel display face */
h1, h2, h3, h4, h5, h6,
.site-branding h1,
.site-branding a,
.site-description,
.entry-title,
.post-title,
.post-title a,
.widget-title,
.widget-title h2,
.graceful-widget h2,
.graceful-widget h3,
.graceful-widget h4,
#primary h1,
#primary h2,
#primary h3,
#primary h4,
#primary h5,
#primary h6,
#primary .post-title,
#primary .entry-title,
#primary h1 a,
#site-footer h1,
#site-footer h2,
#site-footer h3,
#site-footer h4,
#site-footer h5,
#site-footer h6 {
	font-family: var(--ad-font-display);
	letter-spacing: 0.01em;
	font-weight: 400;
}

/* VT323 is a pixel font without bold weight - scale up instead */
h1 { font-size: clamp(2rem, 5vw, 3.4rem); line-height: 1.05; }
h2 { font-size: clamp(1.6rem, 3.2vw, 2.4rem); line-height: 1.1; }
h3 { font-size: clamp(1.4rem, 2.4vw, 1.9rem); line-height: 1.15; }
h4 { font-size: clamp(1.2rem, 1.8vw, 1.5rem); line-height: 1.2; }

/* Nav + meta labels */
#main-navigation a,
#main-navigation i,
#main-navigation #s,
#site-menu a,
.site-menu a,
.post-date,
.post-comments,
.post-author,
.post-meta,
.entry-meta,
.related-post-date,
.comment-meta a,
.post-tags a,
.tagcloud a,
.post-categories,
button,
input,
select,
textarea,
.wp-block-button__link,
.button,
.ad-rate-limit-notice {
	font-family: var(--ad-font-body);
}

/* Anything that was previously forcibly set to Playfair Display or Open Sans
   is normalized here. Using high specificity to beat inline theme CSS. */
body p,
body li,
body blockquote,
body figcaption,
body cite,
body em,
body strong,
body span,
body a,
body label,
body dt,
body dd,
body th,
body td {
	font-family: inherit;
}

/* Code / pre / preformatted content stays mono (already is) */
code, kbd, samp, pre, tt, var {
	font-family: var(--ad-font-mono);
}
