/* =========================================================
   North Harbor Technologies — Design System v2
   Plate framework. Cream + ink + fog. Helvetica Neue.
   ========================================================= */

:root {
  /* Surfaces — warm linen */
  --bg:           #EFEAE0;
  --bg-sunk:     #E7E2D6;     /* slightly deeper panel */
  --bg-deep:     #0F0F12;     /* inverted dark sections */

  /* Ink */
  --ink:          #0F0F12;
  --ink-soft:    rgba(15, 15, 18, 0.68);
  --ink-mute:    rgba(15, 15, 18, 0.45);
  --ink-dim:     rgba(15, 15, 18, 0.28);
  --ink-line:    rgba(15, 15, 18, 0.16);
  --ink-hair:    rgba(15, 15, 18, 0.10);

  /* Accent — fog */
  --accent:      #6E8696;
  --accent-soft: rgba(110, 134, 150, 0.12);
  --accent-line: rgba(110, 134, 150, 0.40);

  /* Inverse (for dark sections) */
  --paper-on-dark: #EFEAE0;
  --paper-dim:     rgba(239, 234, 224, 0.60);
  --paper-line:    rgba(239, 234, 224, 0.14);

  /* Type */
  --sans: "Helvetica Neue", "Hanken Grotesk", Helvetica, Arial, sans-serif;
  --mono: "JetBrains Mono", ui-monospace, "SF Mono", Menlo, monospace;

  --radius: 1px;
  --plate-radius: 2px;

  --container: 1240px;
  --gutter: 32px;
}

* { box-sizing: border-box; }
html, body { margin: 0; padding: 0; }

html {
  background: var(--bg);
  color: var(--ink);
  font-family: var(--sans);
  font-size: 16px;
  line-height: 1.5;
  letter-spacing: -0.005em;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

body { min-height: 100vh; }

::selection { background: var(--accent); color: var(--bg); }

a { color: inherit; text-decoration: none; }

img, svg { display: block; max-width: 100%; }

/* ---------- Layout ---------- */
.nh-container {
  max-width: var(--container);
  margin: 0 auto;
  padding: 0 var(--gutter);
}

.nh-rule {
  height: 1px;
  background: var(--ink-line);
  width: 100%;
}

/* ---------- Mono labels ---------- */
.nh-mono {
  font-family: var(--mono);
  font-size: 11px;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  font-weight: 400;
  color: var(--ink-mute);
}

.nh-mono--accent { color: var(--accent); }
.nh-mono--ink { color: var(--ink); }

/* ---------- Plate ---------- */
.nh-plate {
  display: inline-flex;
  align-items: center;
  gap: 16px;
  padding: 10px 14px;
  border: 1px solid var(--ink-line);
  border-radius: var(--plate-radius);
  background: transparent;
}

.nh-plate__serial {
  font-family: var(--mono);
  font-size: 10px;
  letter-spacing: 0.28em;
  text-transform: uppercase;
  color: var(--ink-mute);
  font-weight: 400;
}

/* ---------- Display type ---------- */
.nh-display {
  font-family: var(--sans);
  font-weight: 500;
  letter-spacing: -0.035em;
  line-height: 0.98;
  color: var(--ink);
  text-wrap: balance;
}

.nh-display em {
  font-style: normal;
  color: var(--accent);
}

.nh-lede {
  font-family: var(--sans);
  font-weight: 400;
  font-size: 22px;
  line-height: 1.45;
  letter-spacing: -0.015em;
  color: var(--ink-soft);
  text-wrap: pretty;
}

/* ---------- Buttons ---------- */
.nh-btn {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 14px 18px;
  font-family: var(--sans);
  font-size: 13px;
  font-weight: 500;
  letter-spacing: -0.005em;
  border-radius: var(--plate-radius);
  border: 1px solid transparent;
  cursor: pointer;
  background: transparent;
  color: inherit;
  transition: background 200ms ease, border-color 200ms ease, color 200ms ease;
}
.nh-btn--ink {
  background: var(--ink);
  color: var(--bg);
  border-color: var(--ink);
}
.nh-btn--ink:hover { background: var(--accent); border-color: var(--accent); color: var(--bg); }

.nh-btn--ghost {
  border-color: var(--ink-line);
  color: var(--ink);
}
.nh-btn--ghost:hover { border-color: var(--ink); }

.nh-btn--inverse {
  background: var(--paper-on-dark);
  color: var(--bg-deep);
  border-color: var(--paper-on-dark);
}
.nh-btn--inverse:hover { background: var(--accent); border-color: var(--accent); color: var(--bg-deep); }

.nh-btn .nh-arrow {
  display: inline-block;
  transition: transform 220ms ease;
}
.nh-btn:hover .nh-arrow { transform: translateX(3px); }

/* ---------- Header ---------- */
.nh-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: color-mix(in oklab, var(--bg) 88%, transparent);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border-bottom: 1px solid var(--ink-hair);
}
.nh-header__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 80px;
}

.nh-wordmark {
  display: inline-flex;
  align-items: center;
  gap: 14px;
  color: var(--ink);
}
.nh-wordmark--plate {
  gap: 14px;
  padding: 9px 14px;
  border: 1px solid var(--ink-line);
  border-radius: var(--plate-radius);
  transition: border-color 200ms ease;
}
.nh-wordmark--plate:hover { border-color: var(--ink-soft); }
.nh-wordmark__name {
  font-size: 15px;
  font-weight: 500;
  letter-spacing: -0.02em;
}
.nh-wordmark__sub {
  font-family: var(--mono);
  font-size: 10px;
  letter-spacing: 0.24em;
  text-transform: uppercase;
  color: var(--ink-mute);
  margin-left: 8px;
}

.nh-nav {
  display: flex;
  align-items: center;
  gap: 36px;
  font-size: 13px;
  font-weight: 400;
  color: var(--ink-soft);
}
.nh-nav a {
  position: relative;
  padding: 4px 0;
  transition: color 160ms ease;
}
.nh-nav a:hover { color: var(--ink); }
.nh-nav a[data-active="true"] { color: var(--ink); }
.nh-nav a[data-active="true"]::after {
  content: "";
  position: absolute;
  left: 0; right: 0; bottom: -3px;
  height: 1px;
  background: var(--accent);
}

.nh-nav a.nh-nav__cta {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 9px 14px;
  border: 1px solid var(--ink);
  border-radius: var(--plate-radius);
  background: var(--ink);
  color: var(--bg);
  transition: background 160ms ease, border-color 160ms ease, color 160ms ease;
}
.nh-nav a.nh-nav__cta:hover { background: var(--accent); border-color: var(--accent); color: var(--bg); }

/* ---------- Section ---------- */
.nh-sect {
  padding: 140px 0;
  position: relative;
}
.nh-sect--dark {
  background: var(--bg-deep);
  color: var(--paper-on-dark);
}
.nh-sect--dark .nh-mono { color: var(--paper-dim); }
.nh-sect--dark .nh-mono--ink { color: var(--paper-on-dark); }
.nh-sect--dark .nh-rule { background: var(--paper-line); }

.nh-sect__head {
  display: grid;
  grid-template-columns: 200px 1fr;
  gap: 64px;
  margin-bottom: 96px;
  align-items: start;
}
.nh-sect__index {
  display: flex; flex-direction: column; gap: 16px;
}
.nh-sect__title {
  font-family: var(--sans);
  font-weight: 500;
  font-size: clamp(40px, 5.2vw, 80px);
  line-height: 1;
  letter-spacing: -0.04em;
  margin: 0;
  color: inherit;
  max-width: 14ch;
  text-wrap: balance;
}
.nh-sect__title em { font-style: normal; color: var(--accent); }

/* ---------- Footer ---------- */
.nh-footer {
  border-top: 1px solid var(--ink-line);
  padding: 80px 0 40px;
  margin-top: 0;
  font-size: 13px;
  color: var(--ink-soft);
}
.nh-footer__grid {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1fr;
  gap: 56px;
  margin-bottom: 80px;
}
.nh-footer h6 {
  font-family: var(--mono);
  font-size: 10px;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--ink-mute);
  font-weight: 400;
  margin: 0 0 20px;
}
.nh-footer ul {
  list-style: none; padding: 0; margin: 0;
  display: flex; flex-direction: column; gap: 12px;
}
.nh-footer a { transition: color 160ms ease; }
.nh-footer a:hover { color: var(--ink); }
.nh-footer__bottom {
  display: flex;
  justify-content: space-between;
  padding-top: 28px;
  border-top: 1px solid var(--ink-hair);
  font-family: var(--mono);
  font-size: 10px;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--ink-mute);
}

/* ---------- Cards / surfaces ---------- */
.nh-card {
  border: 1px solid var(--ink-line);
  border-radius: var(--plate-radius);
  background: transparent;
  transition: border-color 200ms ease;
}
.nh-card:hover { border-color: var(--ink-soft); }

/* ---------- Forms ---------- */
.nh-field {
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.nh-field label {
  font-family: var(--mono);
  font-size: 10px;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--ink-mute);
  font-weight: 400;
}
.nh-field input,
.nh-field textarea,
.nh-field select {
  background: transparent;
  border: none;
  border-bottom: 1px solid var(--ink-line);
  padding: 12px 0;
  color: var(--ink);
  font-family: var(--sans);
  font-size: 17px;
  letter-spacing: -0.01em;
  outline: none;
  transition: border-color 160ms ease;
}
.nh-field input::placeholder,
.nh-field textarea::placeholder { color: var(--ink-dim); }
.nh-field input:focus,
.nh-field textarea:focus,
.nh-field select:focus { border-bottom-color: var(--ink); }
.nh-field textarea { resize: vertical; min-height: 110px; }

/* ---------- Tag (small pill) ---------- */
.nh-tag {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 5px 10px;
  border: 1px solid var(--ink-line);
  border-radius: 999px;
  font-family: var(--mono);
  font-size: 10px;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--ink-soft);
}
.nh-tag__dot {
  width: 5px; height: 5px; border-radius: 50%;
  background: var(--accent);
}

/* ---------- Reveal ---------- */
.nh-reveal {
  opacity: 0;
  transform: translateY(12px);
  transition: opacity 800ms ease, transform 800ms cubic-bezier(.2,.7,.2,1);
}
.nh-reveal.is-in {
  opacity: 1;
  transform: none;
}

@media (max-width: 960px) {
  .nh-sect { padding: 96px 0; }
  .nh-sect__head { grid-template-columns: 1fr; gap: 24px; margin-bottom: 56px; }
  .nh-footer__grid { grid-template-columns: 1fr 1fr; gap: 40px; }
  .nh-nav { display: none; }
}
@media (max-width: 560px) {
  .nh-footer__grid { grid-template-columns: 1fr; }
  .nh-footer__bottom { flex-direction: column; gap: 12px; }
  .nh-wordmark__sub { display: none; }
}
