/* =====================================================================
 * RAGEX MASTER COLOR & TYPOGRAPHY SYSTEM — v6 "Option F" (Hybrid)
 * Authoritative design layer. Enqueued LAST so it wins source order.
 *
 *   Oswald   → display (UPPERCASE only)   var(--font-display)
 *   Inter    → body / prose               var(--font-body)
 *   JetBrains Mono → data, labels, code   var(--font-mono)
 *   Lora     → subtitles, quotes (italic) var(--font-serif)
 *
 * Tokens themselves live in style.css :root. This file applies the v6
 * RULES the tokens imply (typography discipline + category color system).
 * ===================================================================== */

/* V1.1.0 — Faux-bold kill switch.
   Oswald and Inter are loaded up to weight 700; ~110 legacy declarations
   across the CSS layers still request 800/900. Without this rule the
   browser paints a synthetic (smeared) bold from the 700 face. With
   synthesis disabled, 800/900 resolve to the TRUE 700 face — crisp,
   consistent letterforms across all browsers. Italic synthesis is left
   untouched (Lora ships a real italic face). */
html { font-synthesis-weight: none; }

/* ───────────────────────── Typography discipline ───────────────────── */

/* Body: Inter, never uppercase, 1.65 line-height default (v6 rule). Editorial
 * prose keeps its own larger size/line-height where the theme sets it (e.g. the
 * 17px article body) — these are defaults, not caps, so nothing shrinks. The
 * theme's reading column already sits at/above the 15px v6 floor. */
body{font-family:var(--font-body);line-height:1.65;}
body p,body li{line-height:1.65;}

/* Oswald is ALWAYS uppercase. Low-specificity safety net: any heading that
 * lacks an explicit transform still renders correct v6 display type.        */
h1,h2,h3,h4,h5,h6{
  font-family:var(--font-display);
  text-transform:uppercase;
  letter-spacing:0.01em;       /* positive only, headline range 0.01–0.05em */
  font-weight:700;
}
/* Never letter-space or uppercase Inter prose. */
.entry-content,.entry-content p,.post-content p{letter-spacing:normal;text-transform:none;}

/* Lora — italic only, reserved for subtitles / quotes / pull quotes. */
.article-header__subtitle,
.rx-404__subtitle,
.rx-contact__subtitle,
[class$="__subtitle"],
.article-subtitle,
.entry-subtitle,
.pullquote,
blockquote,
.entry-content blockquote,
.wp-block-quote{
  font-family:var(--font-serif);
  font-style:italic;
  text-transform:none;
  letter-spacing:normal;
}
/* Guard: Oswald headings inside a quote must NOT inherit Lora italics. */
blockquote h1,blockquote h2,blockquote h3,
.wp-block-quote h1,.wp-block-quote h2,.wp-block-quote h3{
  font-family:var(--font-display);
  font-style:normal;
}

/* JetBrains Mono color discipline:
 *   #CCA800 (Tactical Yellow) for DATA / technical readouts
 *   #C41800 (RAGE Red) for LABELS / eyebrows                              */
.trust-card__eyebrow,
[class*="eyebrow"],
[class*="kicker"]{
  font-family:var(--font-mono);
  color:var(--rage-red);
  letter-spacing:0.16em;          /* small-label Oswald/mono range 0.08–0.22em */
  text-transform:uppercase;
}
/* Intentional-use utilities (data vs label). */
.rx-data{font-family:var(--font-mono);color:var(--tactical-yellow);letter-spacing:0.04em;}
.rx-label{font-family:var(--font-mono);color:var(--rage-red);letter-spacing:0.16em;text-transform:uppercase;}

/* ───────────────────── Category color system (v6) ──────────────────────
 * Universal interactive pattern for every category chip / badge:
 *   Default : 10% bg · full-color border · full-color text
 *   Hover   : 20% bg
 *   Active  : 30% bg · #F0F0F0 text
 *   Focus   : 10% bg · 2px category outline
 * Reset the inherited solid fills / glows / animations from earlier layers. */
.cat-badge{
  border:1px solid transparent;
  background:transparent;
  box-shadow:none;
  animation:none;
  transition:background-color .18s ease,color .18s ease,border-color .18s ease,outline-color .18s ease;
}

/* alerts / breaking → Breaking Red */
.cat-badge--alerts,.cat-badge--alert,.cat-badge--breaking{color:var(--cat-alerts-text);background:var(--cat-alerts-bg);border-color:var(--cat-alerts);}
.cat-badge--alerts:hover,.cat-badge--alert:hover,.cat-badge--breaking:hover{background:var(--cat-alerts-bg-hover);}
.cat-badge--alerts:active,.cat-badge--alert:active,.cat-badge--breaking:active{background:rgba(240,32,0,0.30);color:#F0F0F0;}
.cat-badge--alerts:focus-visible,.cat-badge--alert:focus-visible,.cat-badge--breaking:focus-visible{outline:2px solid var(--cat-alerts);outline-offset:2px;}

/* global → Teal-blue */
.cat-badge--global{color:var(--cat-global-text);background:var(--cat-global-bg);border-color:var(--cat-global);}
.cat-badge--global:hover{background:var(--cat-global-bg-hover);}
.cat-badge--global:active{background:rgba(27,107,138,0.30);color:#F0F0F0;}
.cat-badge--global:focus-visible{outline:2px solid var(--cat-global);outline-offset:2px;}

/* war → Burnt orange */
.cat-badge--war{color:var(--cat-war-text);background:var(--cat-war-bg);border-color:var(--cat-war);}
.cat-badge--war:hover{background:var(--cat-war-bg-hover);}
.cat-badge--war:active{background:rgba(184,92,0,0.30);color:#F0F0F0;}
.cat-badge--war:focus-visible{outline:2px solid var(--cat-war);outline-offset:2px;}

/* defense → Deep cyan */
.cat-badge--defense{color:var(--cat-defense-text);background:var(--cat-defense-bg);border-color:var(--cat-defense);}
.cat-badge--defense:hover{background:var(--cat-defense-bg-hover);}
.cat-badge--defense:active{background:rgba(0,105,148,0.30);color:#F0F0F0;}
.cat-badge--defense:focus-visible{outline:2px solid var(--cat-defense);outline-offset:2px;}

/* military → Field green */
.cat-badge--military{color:var(--cat-military-text);background:var(--cat-military-bg);border-color:var(--cat-military);}
.cat-badge--military:hover{background:var(--cat-military-bg-hover);}
.cat-badge--military:active{background:rgba(74,122,58,0.30);color:#F0F0F0;}
.cat-badge--military:focus-visible{outline:2px solid var(--cat-military);outline-offset:2px;}

/* intelligence / intel → RAGE Red (brand primary) */
.cat-badge--intelligence,.cat-badge--intel{color:var(--cat-intelligence-text);background:var(--cat-intelligence-bg);border-color:var(--cat-intelligence);}
.cat-badge--intelligence:hover,.cat-badge--intel:hover{background:var(--cat-intelligence-bg-hover);}
.cat-badge--intelligence:active,.cat-badge--intel:active{background:rgba(196,24,0,0.30);color:#F0F0F0;}
.cat-badge--intelligence:focus-visible,.cat-badge--intel:focus-visible{outline:2px solid var(--cat-intelligence);outline-offset:2px;}

/* nuclear → Isotope Gold */
.cat-badge--nuclear{color:var(--cat-nuclear-text);background:var(--cat-nuclear-bg);border-color:var(--cat-nuclear);}
.cat-badge--nuclear:hover{background:var(--cat-nuclear-bg-hover);}
.cat-badge--nuclear:active{background:rgba(184,168,0,0.30);color:#F0F0F0;}
.cat-badge--nuclear:focus-visible{outline:2px solid var(--cat-nuclear);outline-offset:2px;}

/* reports / report → Phosphor Green */
.cat-badge--reports,.cat-badge--report{color:var(--cat-reports-text);background:var(--cat-reports-bg);border-color:var(--cat-reports);}
.cat-badge--reports:hover,.cat-badge--report:hover{background:var(--cat-reports-bg-hover);}
.cat-badge--reports:active,.cat-badge--report:active{background:rgba(122,184,0,0.30);color:#F0F0F0;}
.cat-badge--reports:focus-visible,.cat-badge--report:focus-visible{outline:2px solid var(--cat-reports);outline-offset:2px;}

/* technology → Cyber teal */
.cat-badge--technology{color:var(--cat-technology-text);background:var(--cat-technology-bg);border-color:var(--cat-technology);}
.cat-badge--technology:hover{background:var(--cat-technology-bg-hover);}
.cat-badge--technology:active{background:rgba(0,122,122,0.30);color:#F0F0F0;}
.cat-badge--technology:focus-visible{outline:2px solid var(--cat-technology);outline-offset:2px;}

/* analysis (editorial, not a content category) → Intel Blue tint */
.cat-badge--analysis{color:var(--intel-blue-light);background:rgba(30,80,128,0.12);border-color:var(--intel-blue);}
.cat-badge--analysis:hover{background:rgba(30,80,128,0.22);}
.cat-badge--analysis:focus-visible{outline:2px solid var(--intel-blue);outline-offset:2px;}

/* exclusive flag → Tactical Yellow tint */
.cat-badge--exclusive{color:var(--tactical-yellow);background:rgba(204,168,0,0.12);border-color:var(--tactical-yellow);}
.cat-badge--exclusive:hover{background:rgba(204,168,0,0.22);}
.cat-badge--exclusive:focus-visible{outline:2px solid var(--tactical-yellow);outline-offset:2px;}

/* Subtle "live" pulse kept only for genuinely breaking flags. */
@media (prefers-reduced-motion:no-preference){
  .cat-badge--breaking{animation:rx-v6-breaking 2.6s ease-in-out infinite;}
  @keyframes rx-v6-breaking{0%,100%{border-color:var(--cat-alerts);}50%{border-color:rgba(240,32,0,0.45);}}
}

/* Category left-border accent utility — full-opacity color, never a fill. */
.cat-accent-rule{border-left:3px solid var(--cat-accent,var(--rage-red));}

/* Links / focus: keep brand-consistent focus ring (WCAG AA). */
a:focus-visible,button:focus-visible,[tabindex]:focus-visible{
  outline:2px solid var(--tactical-yellow);
  outline-offset:2px;
}

/* In-prose links: #3A6AAA fails AA (~3.2:1) for small body text. Brighten to an
 * AA-safe blue (>=4.5:1 on #0C0C0C/#1A1A1A) and underline so colour is not the
 * sole at-rest cue (WCAG 1.4.1 + 1.4.3). Scoped to editorial prose only. */
.article-body a,.entry-content a,.rx-article .article-body a,.author-box__all-posts,a.more-link{
  color:#6A92D0;
  text-decoration:underline;
  text-decoration-thickness:1px;
  text-underline-offset:2px;
}
.article-body a:hover,.entry-content a:hover,.rx-article .article-body a:hover{
  color:#88AEE6;
}

/* ───────── Oswald positive-tracking enforcement (v6) ─────────
 * v4 tuned NEGATIVE tracking for Inter 900 ("Inter 900 needs tight tracking").
 * Oswald letter-spacing is ALWAYS positive (0.01–0.05em at headline sizes).
 * Override every display/title surface still carrying old negative values. */
.hero-main__title,.hero-side__title,.hero-intel__title,.page-hero__title,
.cat-feat__title,.cat-section-featured__title,
.archive-header__title,.cat-header__title,
.rx-article__title,.single-article__title,.article-header__title,.entry-title,
.article-card__title,.rx-article-card__title,.article-card__title a,
.alert-panel__item-title a,
.rx-404__code{ letter-spacing:0.02em !important; }
.article-body h2,.rx-article .article-body h2,
.article-body h3,.rx-article .article-body h3{ letter-spacing:0.015em !important; }
.theme-toggle__btn[data-mode="auto"]{ letter-spacing:0.04em !important; }
