/* ============================================================
   NGM — Design Tokens · v2
   NEX GEN Media LLC
   Colors match the official brand guideline; italics on "forward"
   ============================================================ */

:root {
  /* Brand — from Official Brand Guideline */
  --midnight-command: #161654;   /* Trust · Stability · Authority */
  --flame-forward:   #FF6C19;    /* Energy · Motion · Creativity */
  --signal-slate:    #8282A3;    /* Balance · Tech · Support */
  --frost-white:     #FFFFFF;    /* Clarity · Simplicity */
  --true-black:      #000000;    /* Strength · Contrast · Execution */

  /* Legacy aliases (so existing markup keeps working during rebuild) */
  --navy: var(--midnight-command);
  --navy-deep: #0d0d38;
  --navy-ink: #05052a;
  --coral: var(--flame-forward);
  --coral-soft: #FF8C4A;
  --coral-glow: #FFA470;
  --lilac: var(--signal-slate);
  --lilac-cool: var(--signal-slate);
  --white: var(--frost-white);
  --paper: #f6f4ef;
  --paper-warm: #efe9dd;
  --ink: #05052a;
  --ink-soft: rgba(5,5,42,0.72);
  --ink-mute: rgba(5,5,42,0.56);
  --line: rgba(5,5,42,0.12);
  --line-strong: rgba(5,5,42,0.22);
  --line-inv: rgba(255,255,255,0.14);
  --line-inv-strong: rgba(255,255,255,0.28);

  /* Gradients — restrained; brand rules discourage excessive gradients */
  --grad-flame: linear-gradient(90deg, #FF6C19 0%, #FF8C4A 100%);
  --grad-coral: var(--grad-flame); /* legacy alias */
  --grad-coral-vert: linear-gradient(180deg, #FF8C4A 0%, #FF6C19 100%);
  --grad-navy: linear-gradient(180deg, #161654 0%, #05052a 100%);
  --grad-navy-radial: radial-gradient(ellipse at top, #1e1e6b 0%, #161654 40%, #05052a 100%);

  /* Type — Archivo is the closest free web substitute for Cy Grotesk Wide.
     Cy Grotesk Wide is the official typeface; Archivo maintains the wide-grotesk feel
     for web where the licensed font isn't available. */
  --font-display: 'Archivo', 'Space Grotesk', system-ui, sans-serif;
  --font-heading: 'Archivo', 'Space Grotesk', system-ui, sans-serif;
  --font-body: 'Archivo', 'Space Grotesk', system-ui, sans-serif;
  --font-mono: 'JetBrains Mono', 'IBM Plex Mono', ui-monospace, monospace;
  --font-italic: 'Instrument Serif', 'Archivo', Georgia, serif;

  /* Motion — restrained, purposeful */
  --ease-out-expo: cubic-bezier(0.16, 1, 0.3, 1);
  --ease-in-out-quart: cubic-bezier(0.76, 0, 0.24, 1);
  --ease-spring: cubic-bezier(0.34, 1.56, 0.64, 1);

  /* Spacing rhythm */
  --pad-page: clamp(20px, 4vw, 64px);
  --pad-section: clamp(64px, 10vw, 140px);
}

* { box-sizing: border-box; }
html, body { margin: 0; padding: 0; }
body {
  font-family: var(--font-body);
  color: var(--ink);
  background: var(--frost-white);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  overflow-x: hidden;
  font-weight: 400;
}

a { color: inherit; text-decoration: none; }
img { display: block; max-width: 100%; }

::selection { background: var(--flame-forward); color: var(--frost-white); }

/* ============================================================
   TYPE SYSTEM — Cy Grotesk Wide feel (Archivo stack, wider tracking)
   ============================================================ */

.eyebrow {
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.24em;
  text-transform: uppercase;
  font-weight: 500;
  color: var(--flame-forward);
  display: inline-flex;
  align-items: center;
  gap: 10px;
}
.eyebrow::before {
  content: "";
  width: 24px; height: 1px;
  background: currentColor;
  display: inline-block;
}

/* Display type — bold, wide, uppercase */
.display-xl {
  font-family: var(--font-display);
  font-weight: 800;
  font-size: clamp(60px, 12vw, 200px);
  line-height: 0.88;
  letter-spacing: -0.02em;
  text-transform: uppercase;
  margin: 0;
  font-stretch: expanded;
}
.display-lg {
  font-family: var(--font-display);
  font-weight: 800;
  font-size: clamp(48px, 8vw, 120px);
  line-height: 0.9;
  letter-spacing: -0.015em;
  text-transform: uppercase;
  margin: 0;
  font-stretch: expanded;
}
.display-md {
  font-family: var(--font-display);
  font-weight: 800;
  font-size: clamp(36px, 5vw, 68px);
  line-height: 0.98;
  letter-spacing: -0.01em;
  text-transform: uppercase;
  margin: 0;
  font-stretch: expanded;
}
.heading-lg {
  font-family: var(--font-heading);
  font-size: clamp(26px, 3.2vw, 42px);
  line-height: 1.08;
  letter-spacing: -0.01em;
  font-weight: 700;
  margin: 0;
}
.heading-md {
  font-family: var(--font-heading);
  font-size: clamp(18px, 2vw, 24px);
  line-height: 1.2;
  letter-spacing: -0.005em;
  font-weight: 700;
  margin: 0;
}
/* Italic accent — always used on 'forward' in tagline per brand rules */
.italic-accent,
em.fwd {
  font-family: var(--font-italic);
  font-style: italic;
  font-weight: 400;
}
.body-lg {
  font-size: clamp(16px, 1.25vw, 19px);
  line-height: 1.55;
  color: var(--ink-soft);
  font-weight: 400;
  text-wrap: pretty;
}
.body-md {
  font-size: 15px;
  line-height: 1.6;
  color: var(--ink-soft);
  text-wrap: pretty;
}
.body-sm {
  font-size: 13px;
  line-height: 1.55;
  color: var(--ink-mute);
}
.mono-tag {
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  font-weight: 500;
}

/* Text on dark surfaces */
.on-dark { color: var(--frost-white); }
.on-dark .body-lg,
.on-dark .body-md,
.on-dark .body-sm { color: rgba(255,255,255,0.72); }
.on-dark .mono-tag { color: rgba(255,255,255,0.6); }

/* ============================================================
   BUTTONS — restrained, brand-clean
   ============================================================ */

.btn {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  padding: 15px 24px;
  font-family: var(--font-heading);
  font-weight: 700;
  font-size: 13px;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  border-radius: 2px;
  border: 1px solid transparent;
  cursor: pointer;
  transition: background .25s ease, color .25s ease, border-color .25s ease, transform .25s ease;
  white-space: nowrap;
  position: relative;
}
.btn:hover { transform: translateY(-1px); }
.btn:active { transform: translateY(0); }

.btn-primary {
  background: var(--flame-forward);
  color: var(--frost-white);
}
.btn-primary:hover {
  background: #E85E10;
}
.btn-ghost {
  background: transparent;
  color: var(--frost-white);
  border-color: rgba(255,255,255,0.35);
}
.btn-ghost:hover {
  background: rgba(255,255,255,0.06);
  border-color: rgba(255,255,255,0.8);
}
.btn-outline-dark {
  background: transparent;
  color: var(--midnight-command);
  border-color: var(--midnight-command);
}
.btn-outline-dark:hover {
  background: var(--midnight-command);
  color: var(--frost-white);
}
.btn .arrow {
  display: inline-flex;
  width: 16px; height: 16px;
  align-items: center; justify-content: center;
  transition: transform .25s ease;
  font-size: 16px;
  line-height: 1;
}
.btn:hover .arrow { transform: translateX(3px); }

/* ============================================================
   NAV BAR — logo TOP-LEFT per brand rules
   ============================================================ */

.ngm-nav {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 100;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 20px var(--pad-page);
  transition: background .3s ease, border .3s ease;
  border-bottom: 1px solid transparent;
}
.ngm-nav.is-scrolled {
  background: rgba(5,5,42,0.85);
  backdrop-filter: blur(16px) saturate(1.3);
  -webkit-backdrop-filter: blur(16px) saturate(1.3);
  border-bottom-color: var(--line-inv);
}
.ngm-nav.on-light.is-scrolled {
  background: rgba(255,255,255,0.92);
  border-bottom-color: var(--line);
}
.ngm-nav__logo {
  display: flex;
  align-items: center;
  gap: 12px;
  height: 40px;
}
.ngm-nav__logo img { height: 40px; width: auto; }

.ngm-nav__links {
  display: flex;
  gap: 2px;
  align-items: center;
}
.ngm-nav__link {
  padding: 10px 14px;
  font-family: var(--font-heading);
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: rgba(255,255,255,0.72);
  transition: color .2s;
  position: relative;
}
.ngm-nav.on-light .ngm-nav__link { color: var(--ink-soft); }
.ngm-nav__link:hover { color: var(--frost-white); }
.ngm-nav.on-light .ngm-nav__link:hover { color: var(--midnight-command); }
.ngm-nav__link.is-active { color: var(--flame-forward); }
.ngm-nav__link.is-active::after {
  content: "";
  position: absolute;
  bottom: 4px; left: 14px; right: 14px;
  height: 1px;
  background: var(--flame-forward);
}
.ngm-nav__cta {
  margin-left: 12px;
  padding: 10px 18px;
  font-size: 11px;
}

@media (max-width: 900px) {
  .ngm-nav__links { display: none; }
}

/* ============================================================
   FOOTER
   ============================================================ */

.ngm-footer {
  background: var(--midnight-command);
  color: var(--frost-white);
  padding: 100px var(--pad-page) 40px;
  position: relative;
  overflow: hidden;
}
.ngm-footer__big {
  font-family: var(--font-display);
  font-weight: 800;
  font-size: clamp(60px, 14vw, 200px);
  line-height: 0.85;
  letter-spacing: -0.02em;
  color: transparent;
  -webkit-text-stroke: 1px rgba(255,255,255,0.2);
  margin: 0;
  text-transform: uppercase;
  pointer-events: none;
  user-select: none;
}
.ngm-footer__big em {
  -webkit-text-stroke: 0;
  color: var(--flame-forward);
  font-family: var(--font-italic);
  font-style: italic;
  font-weight: 400;
}
.ngm-footer__grid {
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr 1fr;
  gap: 40px;
  margin-top: 60px;
  padding-top: 60px;
  border-top: 1px solid var(--line-inv);
}
.ngm-footer__col h4 {
  font-family: var(--font-mono);
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.24em;
  color: var(--flame-forward);
  margin: 0 0 20px;
  font-weight: 500;
}
.ngm-footer__col a {
  display: block;
  padding: 6px 0;
  color: rgba(255,255,255,0.72);
  font-size: 14px;
  transition: color .2s;
}
.ngm-footer__col a:hover { color: var(--flame-forward); }
.ngm-footer__col p {
  color: rgba(255,255,255,0.72);
  font-size: 14px;
  line-height: 1.6;
  margin: 0 0 12px;
}
.ngm-footer__meta {
  margin-top: 60px;
  padding-top: 30px;
  border-top: 1px solid var(--line-inv);
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: rgba(255,255,255,0.48);
  gap: 20px;
  flex-wrap: wrap;
}
@media (max-width: 900px) {
  .ngm-footer__grid { grid-template-columns: 1fr 1fr; }
}

/* ============================================================
   PLACEHOLDER MEDIA BLOCKS — restrained
   ============================================================ */

.media-placeholder {
  position: relative;
  overflow: hidden;
  background: var(--midnight-command);
  border-radius: 2px;
}
.media-placeholder::before {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(135deg, transparent 50%, rgba(255,108,25,0.15) 100%);
}
.media-placeholder::after {
  content: attr(data-label);
  position: absolute;
  bottom: 16px;
  left: 16px;
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: rgba(255,255,255,0.75);
}
.media-placeholder--light {
  background: #efe9dd;
}
.media-placeholder--light::before {
  background: linear-gradient(135deg, transparent 60%, rgba(255,108,25,0.15) 100%);
}
.media-placeholder--light::after {
  color: var(--midnight-command);
}
.media-placeholder--flame {
  background: var(--flame-forward);
}
.media-placeholder--flame::before { display: none; }
.media-placeholder--flame::after {
  color: var(--midnight-command);
}

/* ============================================================
   REVEAL / MOTION — subtle only
   ============================================================ */

.reveal {
  opacity: 0;
  transform: translateY(20px);
  transition: opacity .8s var(--ease-out-expo), transform .8s var(--ease-out-expo);
}
.reveal.is-in {
  opacity: 1;
  transform: translateY(0);
}
.reveal-delay-1 { transition-delay: 0.08s; }
.reveal-delay-2 { transition-delay: 0.16s; }
.reveal-delay-3 { transition-delay: 0.24s; }
.reveal-delay-4 { transition-delay: 0.32s; }
.reveal-delay-5 { transition-delay: 0.4s; }

/* Kinetic word split (used only on hero) */
.kinetic-word { display: inline-block; overflow: hidden; }
.kinetic-word .char {
  display: inline-block;
  transform: translateY(105%);
  transition: transform .8s var(--ease-out-expo);
}
.kinetic-word.is-in .char { transform: translateY(0); }

/* Section spacing */
.section { padding: var(--pad-section) var(--pad-page); }
.section-dark { background: #05052a; color: var(--frost-white); }
.section-navy { background: var(--midnight-command); color: var(--frost-white); }
.section-paper { background: #f6f4ef; }
.section-white { background: var(--frost-white); }
.section-slate { background: var(--signal-slate); color: var(--midnight-command); }

/* Grid helpers */
.grid { display: grid; gap: 20px; }
.grid-2 { grid-template-columns: repeat(2, 1fr); }
.grid-3 { grid-template-columns: repeat(3, 1fr); }
.grid-4 { grid-template-columns: repeat(4, 1fr); }
.grid-5 { grid-template-columns: repeat(5, 1fr); }
@media (max-width: 900px) {
  .grid-3, .grid-4, .grid-5 { grid-template-columns: repeat(2, 1fr); }
  .grid-2 { grid-template-columns: 1fr; }
}
@media (max-width: 600px) {
  .grid-3, .grid-4, .grid-5 { grid-template-columns: 1fr; }
}

/* Rule */
.rule { height: 1px; background: var(--line); border: 0; margin: 0; }
.rule.on-dark { background: var(--line-inv); }

/* Scrollbar */
::-webkit-scrollbar { width: 10px; height: 10px; }
::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-thumb { background: rgba(22,22,84,0.25); border-radius: 10px; }
::-webkit-scrollbar-thumb:hover { background: rgba(22,22,84,0.5); }
