/* ═══════════════════════════════════════════════════════════════
   IGNIFY:HR — shared site system
   Refined industrial brutalism. Brand colors only.
   Loaded by every page; page-specific styles stay inline per page.
   ═══════════════════════════════════════════════════════════════ */

/* ─── FONTS ─────────────────────────────────────────────────── */
@font-face { font-family: 'Cygre'; src: url('../brand_assets/Cygre-Thin.ttf') format('truetype'); font-weight: 100; font-display: swap; }
@font-face { font-family: 'Cygre'; src: url('../brand_assets/Cygre-Light.ttf') format('truetype'); font-weight: 300; font-display: swap; }
@font-face { font-family: 'Cygre'; src: url('../brand_assets/Cygre-Regular.ttf') format('truetype'); font-weight: 400; font-display: swap; }
@font-face { font-family: 'Cygre'; src: url('../brand_assets/Cygre-Medium.ttf') format('truetype'); font-weight: 500; font-display: swap; }
@font-face { font-family: 'Cygre'; src: url('../brand_assets/Cygre-SemiBold.ttf') format('truetype'); font-weight: 600; font-display: swap; }
@font-face { font-family: 'Cygre'; src: url('../brand_assets/Cygre-Bold.ttf') format('truetype'); font-weight: 700; font-display: swap; }
@font-face { font-family: 'Cygre'; src: url('../brand_assets/Cygre-ExtraBold.ttf') format('truetype'); font-weight: 800; font-display: swap; }
@font-face { font-family: 'Cygre'; src: url('../brand_assets/Cygre-Black.ttf') format('truetype'); font-weight: 900; font-display: swap; }

/* ─── TOKENS ────────────────────────────────────────────────── */
:root {
  /* brand */
  --pink: #ED62C7;
  --blue: #007DFF;
  --bg: #080808;
  --cream: #F3F1EC;
  --ink: #0F0E0C;

  /* text (contrast-lifted, dark surfaces) */
  --text-hi: rgba(255,255,255,0.92);
  --text:    rgba(255,255,255,0.74);
  --muted:   rgba(255,255,255,0.58);
  --label:   rgba(255,255,255,0.64);

  /* structure */
  --bw: 2px;
  --line:        rgba(255,255,255,0.14);
  --line-strong: rgba(255,255,255,0.30);
  --shadow-pink: 6px 6px 0 0 var(--pink);
  --shadow-blue: 6px 6px 0 0 var(--blue);

  /* type */
  --mono: ui-monospace, 'Cascadia Mono', 'SF Mono', Menlo, Consolas, monospace;

  /* legacy aliases still referenced by page CSS */
  --cream-muted: rgba(243,241,236,0.62);
  --ink-muted: rgba(15,14,12,0.62);

  /* spacing */
  --pad: clamp(24px, 4vw, 64px);
  --s1: 8px; --s2: 16px; --s3: 24px; --s4: 40px; --s5: 64px; --s6: 96px;
}

/* light-surface scope: flips text + line tokens to ink */
.section--cream,
.contact-section--cream,
.on-cream {
  --text-hi: rgba(15,14,12,0.95);
  --text:    rgba(15,14,12,0.78);
  --muted:   rgba(15,14,12,0.62);
  --label:   rgba(15,14,12,0.66);
  --line:        rgba(15,14,12,0.14);
  --line-strong: rgba(15,14,12,0.35);
}

/* ─── RESET / BASE ──────────────────────────────────────────── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; overflow-x: hidden; }

body {
  font-family: 'Cygre', sans-serif;
  background: var(--bg);
  color: #fff;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

[id] { scroll-margin-top: 80px; }

/* ─── FOCUS VISIBILITY (global) ─────────────────────────────── */
a:focus-visible,
button:focus-visible,
input:focus-visible,
textarea:focus-visible,
select:focus-visible,
[tabindex]:focus-visible {
  outline: 2px solid var(--pink);
  outline-offset: 3px;
}
.section--cream :focus-visible,
.contact-section--cream :focus-visible,
.on-cream :focus-visible {
  outline-color: var(--blue);
}

/* ─── SKIP LINK ─────────────────────────────────────────────── */
.skip-link {
  position: fixed;
  top: 8px; left: 8px;
  z-index: 1000;
  padding: 12px 20px;
  font-family: var(--mono);
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: #000;
  background: var(--pink);
  border: var(--bw) solid #000;
  text-decoration: none;
  transform: translateY(-200%);
}
.skip-link:focus-visible {
  transform: translateY(0);
  outline: 2px solid #fff;
  outline-offset: 2px;
}

/* ─── MONO TECHNICAL CHROME ─────────────────────────────────── */
.mono-label {
  font-family: var(--mono);
  font-size: 11px;
  font-weight: 500;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--label);
}
.mono-chip {
  display: inline-block;
  font-family: var(--mono);
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--label);
  border: var(--bw) solid var(--line-strong);
  padding: 6px 10px;
  line-height: 1;
}

/* ─── NAV ───────────────────────────────────────────────────── */
.main-nav {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 100;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 var(--pad);
  height: 64px;
  background: rgba(8,8,8,0.88);
  backdrop-filter: blur(12px);
  border-bottom: var(--bw) solid var(--line-strong);
}

.logo {
  display: flex;
  align-items: center;
  text-decoration: none;
  flex-shrink: 0;
  padding: 8px 0;
}
.logo img { height: 22px; width: auto; display: block; }

.nav-links {
  display: flex;
  gap: 8px;
  list-style: none;
  margin-left: auto;
  margin-right: 28px;
}
.nav-links a {
  display: inline-block;
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--muted);
  text-decoration: none;
  padding: 14px 12px;
  transition: color 0.15s ease, background-color 0.15s ease;
  position: relative;
}
.nav-links a:hover { color: #fff; }
.nav-links a[aria-current="page"] {
  color: var(--pink);
}
.nav-links a[aria-current="page"]::after {
  content: '';
  position: absolute;
  left: 12px; right: 12px; bottom: 8px;
  height: 2px;
  background: var(--pink);
}

/* pink-highlighted nav item (QiHR Simulation) */
.nav-sim-link { color: var(--pink) !important; }
.nav-sim-link::before {
  content: '[';
  font-family: var(--mono);
  margin-right: 6px;
  color: var(--pink);
}
.nav-sim-link::after {
  content: ']' !important;
  font-family: var(--mono);
  margin-left: 6px;
  position: static !important;
  background: none !important;
  height: auto !important;
  color: var(--pink);
}

/* ─── INDUSTRIAL BUTTONS ────────────────────────────────────── */
/* base spec shared by all CTA classes */
.nav-cta,
.btn-fill,
.mobile-cta-link,
.btn-pink,
.btn-dl,
.sidebar-cta,
.article-closing-cta {
  font-family: 'Cygre', sans-serif;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--text-hi);
  background: var(--bg);
  border: var(--bw) solid var(--line-strong);
  padding: 12px 24px;
  min-height: 44px;
  cursor: pointer;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  position: relative;
  transition: background-color 0.18s ease, color 0.18s ease,
              border-color 0.18s ease, transform 0.18s ease,
              box-shadow 0.18s ease;
}
.nav-cta:hover,
.btn-fill:hover,
.mobile-cta-link:hover,
.btn-pink:hover,
.btn-dl:hover,
.sidebar-cta:hover,
.article-closing-cta:hover {
  background: var(--pink);
  border-color: var(--pink);
  color: #000;
  transform: translate(-3px, -3px);
  box-shadow: var(--shadow-pink);
}
.nav-cta:active,
.btn-fill:active,
.mobile-cta-link:active,
.btn-pink:active,
.btn-dl:active,
.sidebar-cta:active,
.article-closing-cta:active {
  transform: translate(0, 0);
  box-shadow: none;
}

/* blue secondary variant */
.btn-blue-hover:hover {
  background: var(--blue) !important;
  border-color: var(--blue) !important;
  color: #fff !important;
  box-shadow: var(--shadow-blue) !important;
}

/* nav CTA: tighter shift so it doesn't collide inside the 64px bar */
.nav-cta { padding: 10px 20px; min-height: 40px; }
.nav-cta:hover { transform: translate(-2px, -2px); box-shadow: 4px 4px 0 0 var(--pink); }

/* filled primary on light surfaces */
.contact-section--cream .btn-fill,
.on-cream .btn-fill {
  background: var(--ink);
  color: var(--cream);
  border-color: var(--ink);
}
.contact-section--cream .btn-fill:hover,
.on-cream .btn-fill:hover {
  background: var(--pink);
  border-color: var(--ink);
  color: #000;
}

/* ─── MOBILE NAV ────────────────────────────────────────────── */
.nav-burger {
  display: none;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  gap: 5px;
  width: 44px; height: 44px;
  background: none;
  border: var(--bw) solid var(--line-strong);
  cursor: pointer;
  padding: 0;
  flex-shrink: 0;
  transition: border-color 0.15s ease;
}
.nav-burger:hover { border-color: var(--pink); }
.nav-burger span {
  display: block;
  width: 18px; height: 2px;
  background: rgba(255,255,255,0.85);
  transition: transform 0.25s ease, opacity 0.2s ease, width 0.25s ease;
}
.nav-burger.open span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.nav-burger.open span:nth-child(2) { opacity: 0; width: 0; }
.nav-burger.open span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

.mobile-menu {
  display: none;
  position: fixed;
  top: 64px; left: 0; right: 0;
  background: rgba(8,8,8,0.97);
  backdrop-filter: blur(16px);
  border-bottom: var(--bw) solid var(--line-strong);
  z-index: 99;
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.35s cubic-bezier(0.4, 0, 0.2, 1);
}
.mobile-menu.open { max-height: 480px; }
.mobile-menu-inner {
  padding: 8px var(--pad) 28px;
  display: flex;
  flex-direction: column;
}
.mobile-menu ul { list-style: none; border-top: 1px solid var(--line); }
.mobile-menu ul li { border-bottom: 1px solid var(--line); }
.mobile-menu ul li a {
  display: block;
  padding: 16px 0;
  font-size: 13px;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--muted);
  text-decoration: none;
  transition: color 0.15s ease;
}
.mobile-menu ul li a:hover { color: #fff; }
.mobile-menu ul li a[aria-current="page"] { color: var(--pink); }
.mobile-cta-link { margin-top: 24px; }

@media (max-width: 900px) {
  .nav-links { display: none; }
  .nav-cta { display: none; }
  .nav-burger { display: flex; }
  .mobile-menu { display: block; }
}

/* ─── SECTION SYSTEM ────────────────────────────────────────── */
.section {
  padding: 120px var(--pad);
  border-top: var(--bw) solid var(--line-strong);
  position: relative;
}
/* corner registration ticks */
.section::before,
.section::after {
  font-family: var(--mono);
  font-size: 14px;
  font-weight: 500;
  color: var(--line-strong);
  position: absolute;
  top: 10px;
  line-height: 1;
  pointer-events: none;
}
.section::before { content: '+'; left: 10px; }
.section::after  { content: '+'; right: 10px; }

.section-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  margin-bottom: 80px;
  gap: 24px;
}

.section-num {
  font-family: var(--mono);
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--label);
  border: var(--bw) solid var(--line-strong);
  padding: 8px 12px;
  line-height: 1;
  white-space: nowrap;
}

.section-title {
  font-size: clamp(48px, 6vw, 96px);
  font-weight: 900;
  letter-spacing: -0.03em;
  line-height: 0.92;
  text-transform: uppercase;
}
.section-title em { font-style: normal; color: var(--pink); }

.section--cream {
  background: var(--cream);
  border-top: var(--bw) solid var(--ink);
  color: var(--ink);
}
.section--cream .section-title { color: var(--ink); }
.section--cream .section-title em { color: var(--pink); }

@media (max-width: 900px) {
  .section { padding: 80px var(--pad); }
  .section-head {
    flex-direction: column;
    align-items: flex-start;
    gap: 16px;
    margin-bottom: 48px;
  }
}

/* ─── FOOTER ────────────────────────────────────────────────── */
.site-footer {
  border-top: var(--bw) solid var(--line-strong);
  position: relative;
}
.site-footer::before {
  content: '+';
  font-family: var(--mono);
  font-size: 14px;
  color: var(--line-strong);
  position: absolute;
  top: 10px; left: 10px;
  line-height: 1;
  pointer-events: none;
}
.footer-grid {
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr;
}
.footer-col {
  padding: 40px var(--s4);
  border-left: 1px solid var(--line);
  display: flex;
  flex-direction: column;
  gap: 16px;
  align-items: flex-start;
}
.footer-col:first-child { border-left: none; padding-left: var(--pad); }
.footer-col:last-child { padding-right: var(--pad); }

.footer-col-label {
  font-family: var(--mono);
  font-size: 10px;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--label);
  margin-bottom: 4px;
}

.footer-logo {
  display: flex;
  align-items: center;
  text-decoration: none;
}
.footer-logo .logo-text,
.footer-logo .logo-hr {
  font-size: 17px;
  font-weight: 900;
  letter-spacing: -0.02em;
  color: #fff;
  line-height: 1;
}
.footer-logo .logo-colon {
  display: inline-flex;
  flex-direction: column;
  gap: 3px;
  margin: 0 2px;
  vertical-align: middle;
  position: relative;
  top: -1px;
}
.footer-logo .logo-colon span {
  display: block;
  width: 4px; height: 4px;
  background: var(--pink);
}

.footer-copy,
.footer-company { font-size: 12px; color: var(--muted); line-height: 1.7; }
.footer-made { font-size: 11px; color: var(--muted); letter-spacing: 0.06em; }
.footer-made span { color: var(--pink); }

.footer-nav { display: flex; flex-direction: column; gap: 4px; }
.footer-nav a {
  font-size: 12px;
  color: var(--muted);
  text-decoration: none;
  letter-spacing: 0.04em;
  padding: 6px 0;
  transition: color 0.15s ease;
}
.footer-nav a:hover { color: var(--pink); }

.footer-social { display: flex; gap: 12px; align-items: center; margin-top: auto; }
.footer-social a {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 44px; height: 44px;
  border: var(--bw) solid var(--line-strong);
  color: var(--muted);
  transition: color 0.15s ease, border-color 0.15s ease, background-color 0.15s ease;
}
.footer-social a:hover {
  color: #000;
  background: var(--pink);
  border-color: var(--pink);
}
.footer-social svg { width: 18px; height: 18px; }

@media (max-width: 900px) {
  .footer-grid { grid-template-columns: 1fr; }
  .footer-col {
    border-left: none;
    border-top: 1px solid var(--line);
    padding: 28px var(--pad);
  }
  .footer-col:first-child { border-top: none; }
}

/* ─── FORMS (shared spec) ───────────────────────────────────── */
.form-field {
  display: flex;
  flex-direction: column;
  border: var(--bw) solid var(--line);
  margin: calc(var(--bw) * -1) 0 0 calc(var(--bw) * -1);
  padding: 18px 22px;
  position: relative;
  background: transparent;
}
.form-field:focus-within {
  border-color: var(--pink);
  z-index: 1;
}
.form-field.field-full { grid-column: 1 / -1; }

.form-label {
  font-family: var(--mono);
  font-size: 10px;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--label);
  margin-bottom: 10px;
  display: block;
}
.form-label::before {
  content: attr(data-index) ' — ';
  color: var(--pink);
}
.form-label:not([data-index])::before { content: none; }

.form-input,
.form-textarea {
  font-family: 'Cygre', sans-serif;
  font-size: 15px;
  font-weight: 400;
  color: #fff;
  background: transparent;
  border: none;
  outline: none;
  width: 100%;
  line-height: 1.4;
}
.form-input:focus-visible,
.form-textarea:focus-visible { outline: none; } /* focus shown on .form-field border */
.form-input::placeholder,
.form-textarea::placeholder { color: rgba(255,255,255,0.28); }

.form-textarea { resize: none; min-height: 120px; }

/* ─── REDUCED MOTION ────────────────────────────────────────── */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}
