@font-face {
  font-family: "Archivo Black";
  src: url("/night-hive/fonts/ArchivoBlack-Regular.ttf") format("truetype");
  font-display: swap;
  font-style: normal;
  font-weight: 400;
}

@font-face {
  font-family: "Archivo";
  src: url("/night-hive/fonts/Archivo-Regular.ttf") format("truetype");
  font-display: swap;
  font-style: normal;
  font-weight: 400;
}

@font-face {
  font-family: "Archivo";
  src: url("/night-hive/fonts/Archivo-Bold.ttf") format("truetype");
  font-display: swap;
  font-style: normal;
  font-weight: 700;
}

@font-face {
  font-family: "JetBrains Mono";
  src: url("/night-hive/fonts/JetBrainsMono-Regular.ttf") format("truetype");
  font-display: swap;
  font-style: normal;
  font-weight: 400;
}

@font-face {
  font-family: "JetBrains Mono";
  src: url("/night-hive/fonts/JetBrainsMono-Medium.ttf") format("truetype");
  font-display: swap;
  font-style: normal;
  font-weight: 500;
}

:root {
  --font-display: "Archivo Black", "Arial Black", sans-serif;
  --font-sans: "Archivo", Arial, sans-serif;
  --font-mono: "JetBrains Mono", ui-monospace, monospace;
  color-scheme: light;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  background: #f5f3ee;
  scroll-padding-top: 76px;
}

body {
  min-width: 320px;
  font-family: var(--font-sans);
  overflow-x: hidden;
  text-rendering: optimizeLegibility;
  -webkit-font-smoothing: antialiased;
}

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

button,
input,
select,
textarea {
  font: inherit;
}

a:focus-visible,
button:focus-visible,
summary:focus-visible,
input:focus-visible,
select:focus-visible,
textarea:focus-visible {
  outline: 3px solid #17150f;
  outline-offset: 4px;
}

main section[id] {
  scroll-margin-top: 76px;
}

main [data-lines] {
  max-width: 100%;
}

main [data-lines] [data-ln] {
  margin-top: -0.12em;
  margin-bottom: -0.1em !important;
  padding-top: 0.12em;
  padding-bottom: 0.12em !important;
}

.nh-home-hero__title {
  max-width: 100%;
}

.nh-home-hero__title .nh-home-hero__line {
  white-space: nowrap;
}

.nh-home-hero__title .nh-home-hero__pair {
  align-items: baseline;
  display: flex;
  gap: 0.14em;
  white-space: nowrap;
}

.nh-home-hero__title .nh-hero-production {
  font-size: 0.7em;
  letter-spacing: -0.045em;
}

.nh-skip {
  position: fixed;
  top: 10px;
  left: 10px;
  z-index: 1001;
  padding: 10px 14px;
  background: #17150f;
  color: #f5f3ee;
  font-family: var(--font-mono);
  font-size: 12px;
  min-height: 44px;
  transform: translateY(-160%);
}

header a:has(img[alt="HYVE Labs"]) {
  align-items: center;
  display: inline-flex;
  min-height: 44px;
}

.nh-skip:focus {
  transform: translateY(0);
}

.nh-signals-search {
  background: rgba(251, 250, 247, 0.9);
  border: 1px solid rgba(233, 162, 60, 0.3);
  border-top: 3px solid #de8e28;
  display: grid;
  gap: 18px;
  margin-top: 34px;
  padding: 24px 26px;
}

.nh-signals-search__copy {
  display: grid;
  gap: 7px;
}

.nh-signals-search__copy label {
  color: #17150f;
  font-family: var(--font-display);
  font-size: clamp(1.35rem, 2.4vw, 1.9rem);
  letter-spacing: -0.02em;
}

.nh-signals-search__copy p,
.nh-signals-search__status,
.nh-signals-search__empty p {
  color: #57534a;
  margin: 0;
}

.nh-signals-search__controls {
  display: grid;
  gap: 10px;
  grid-template-columns: minmax(0, 1fr) auto auto;
}

.nh-signals-search__controls input {
  background: #f5f3ee;
  border: 1px solid rgba(23, 21, 15, 0.24);
  color: #17150f;
  min-height: 52px;
  padding: 0 16px;
  width: 100%;
}

.nh-signals-search__controls input::placeholder {
  color: #8c8678;
}

.nh-signals-search__controls button {
  background: #de8e28;
  border: 1px solid #de8e28;
  color: #17150f;
  cursor: pointer;
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.1em;
  min-height: 52px;
  padding: 0 17px;
  text-transform: uppercase;
}

.nh-signals-search__controls button[data-signals-search-clear] {
  background: transparent;
  border-color: rgba(23, 21, 15, 0.24);
}

.nh-signals-search__status {
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.08em;
  min-height: 20px;
}

.nh-signals-search__status strong {
  color: #9a5908;
}

.nh-signals-search__empty {
  border: 1px dashed rgba(176, 111, 29, 0.5);
  margin-top: 24px;
  padding: 28px;
  text-align: center;
}

.nh-signals-search__empty h3 {
  color: #17150f;
  font-family: var(--font-display);
  font-size: 1.5rem;
  font-weight: 400;
  margin: 0 0 8px;
}

[data-signal-card][hidden],
.nh-signals-search__empty[hidden] {
  display: none !important;
}

@media (max-width: 800px) {
  header > div {
    gap: 14px;
    padding: 12px 18px !important;
  }

  header img[alt="HYVE Labs"] {
    height: auto !important;
    max-width: 142px;
  }

  header nav[aria-label="Primary"] {
    align-items: stretch !important;
    background: rgba(245, 243, 238, 0.98);
    border-bottom: 1px solid rgba(233, 162, 60, 0.28);
    box-shadow: 0 18px 36px rgba(23, 21, 15, 0.08);
    display: none !important;
    flex-direction: column;
    gap: 0 !important;
    left: 0;
    padding: 10px 18px 18px;
    position: absolute;
    right: 0;
    top: 100%;
  }

  header nav[aria-label="Primary"][data-mobile-open="true"] {
    display: flex !important;
  }

  header nav[aria-label="Primary"] a {
    border-bottom: 1px solid rgba(233, 162, 60, 0.16);
    display: block !important;
    padding: 14px 4px !important;
    width: 100%;
  }

  header nav[aria-label="Primary"] a:last-child {
    margin-top: 10px;
    text-align: center;
  }

  .nh-menu-toggle {
    align-items: center;
    background: #17150f;
    border: 1px solid #17150f;
    color: #f5f3ee;
    cursor: pointer;
    display: inline-flex;
    font-family: var(--font-mono);
    font-size: 11px;
    gap: 9px;
    justify-content: center;
    letter-spacing: 0.12em;
    min-height: 44px;
    padding: 9px 12px;
    text-transform: uppercase;
  }

  .nh-menu-toggle__mark {
    display: grid;
    gap: 4px;
    width: 17px;
  }

  .nh-menu-toggle__mark span {
    background: currentColor;
    display: block;
    height: 1px;
    transition: transform 160ms ease, opacity 160ms ease;
  }

  .nh-menu-toggle[aria-expanded="true"] .nh-menu-toggle__mark span:first-child {
    transform: translateY(2.5px) rotate(45deg);
  }

  .nh-menu-toggle[aria-expanded="true"] .nh-menu-toggle__mark span:last-child {
    transform: translateY(-2.5px) rotate(-45deg);
  }

  main [style*="grid-template-columns"],
  footer [style*="grid-template-columns"] {
    grid-template-columns: minmax(0, 1fr) !important;
  }

  main [style*="display:flex"],
  footer [style*="display:flex"] {
    flex-wrap: wrap !important;
  }

  main section {
    min-height: auto !important;
  }

  main section > div {
    max-width: 100% !important;
  }

  h1,
  h2,
  h3,
  p,
  a,
  span {
    overflow-wrap: anywhere;
  }

  [data-night-hive-page="/"] h1 {
    font-size: clamp(2rem, 9.2vw, 2.6rem) !important;
    overflow-wrap: normal !important;
    word-break: normal;
  }

  [data-night-hive-page="/"] h1 .nh-home-hero__pair {
    display: block;
    white-space: normal;
  }

  [data-night-hive-page="/"] h1 .nh-hero-to,
  [data-night-hive-page="/"] h1 .nh-hero-production {
    display: block;
    white-space: nowrap;
  }

  [data-night-hive-page="/"] h1 .nh-hero-production {
    font-size: 0.72em;
    letter-spacing: -0.045em;
  }

  [data-night-hive-page="/"] [data-screen-label="Hero"] {
    min-height: calc(100svh - 60px) !important;
  }

  [data-night-hive-page="/"] [data-screen-label="Hero"] > div,
  [data-night-hive-page="/contact"] main > section > div {
    padding-left: 20px !important;
    padding-right: 20px !important;
  }

  [data-night-hive-page="/contact"] main h1 {
    font-size: clamp(3rem, 15vw, 4.25rem) !important;
  }

  [data-night-hive-page="/contact"] main form,
  [data-night-hive-page="/contact"] main aside {
    padding: 24px 20px !important;
  }

  [data-night-hive-page="/contact"] main aside a[href^="mailto:"] {
    display: block;
    font-size: clamp(0.76rem, 3.7vw, 0.95rem) !important;
    letter-spacing: -0.015em;
    overflow-wrap: normal;
    white-space: nowrap;
  }

  table {
    display: block;
    max-width: 100%;
    overflow-x: auto;
  }

  .nh-signals-search {
    padding: 20px;
  }

  .nh-signals-search__controls {
    grid-template-columns: minmax(0, 1fr) auto;
  }

  .nh-signals-search__controls button[data-signals-search-clear] {
    grid-column: 1 / -1;
  }
}

@media (min-width: 801px) {
  .nh-menu-toggle {
    display: none;
  }

  [data-night-hive-page="/"] .nh-home-hero__title {
    font-size: clamp(4rem, min(10.5vw, 14svh), 10rem) !important;
  }
}

@media (min-width: 801px) and (max-height: 800px) {
  [data-night-hive-page="/"] .nh-home-hero {
    padding-bottom: 34px !important;
    padding-top: 90px !important;
  }

  [data-night-hive-page="/"] .nh-home-hero__hud {
    margin-bottom: 2.5vh !important;
  }

  [data-night-hive-page="/"] .nh-home-hero__footer {
    margin-top: 3vh !important;
  }
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto !important;
  }

  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    scroll-behavior: auto !important;
    transition-duration: 0.01ms !important;
  }
}

/* Readable display type: Night Hive text is always filled, never outline-only. */
body[data-night-hive-page] [style*="-webkit-text-stroke"] {
  color: #9a5908 !important;
  -webkit-text-stroke: 0 transparent !important;
  text-shadow: none !important;
}

body[data-night-hive-page] [style*="color:#8C8678"],
body[data-night-hive-page] [style*="color: #8C8678"] {
  color: #625d53 !important;
}

body[data-night-hive-page] [style^="color:#DE8E28"],
body[data-night-hive-page] [style*=";color:#DE8E28"] {
  color: #9a5908 !important;
}

/* Signal articles are mobile-first; larger layouts are additive below. */
.nh-article {
  color: #57534a;
}

.nh-article__shell {
  margin-inline: auto;
  max-width: 1180px;
  padding-inline: 20px;
  width: 100%;
}

.nh-kicker {
  color: #9a5908;
  font-family: var(--font-mono);
  font-size: 0.7rem;
  letter-spacing: 0.14em;
  line-height: 1.5;
  margin: 0 0 14px;
  text-transform: uppercase;
}

.nh-article__hero {
  background: rgba(245, 243, 238, 0.4);
  border-bottom: 1px solid rgba(233, 162, 60, 0.22);
  padding-block: 34px 46px;
}

.nh-article__breadcrumbs {
  align-items: center;
  color: #625d53;
  display: flex;
  font-family: var(--font-mono);
  font-size: 0.67rem;
  gap: 9px;
  letter-spacing: 0.08em;
  margin-bottom: 38px;
  overflow-x: auto;
  padding-block: 3px;
  scrollbar-width: none;
  text-transform: uppercase;
  white-space: nowrap;
}

.nh-article__breadcrumbs a {
  color: #57534a;
  min-height: 44px;
  min-width: 44px;
  display: inline-flex;
  align-items: center;
}

.nh-article__hero-grid {
  display: grid;
  gap: 32px;
}

.nh-article__hero h1 {
  color: #17150f;
  font-family: var(--font-display);
  font-size: clamp(2.25rem, 11.5vw, 4.9rem);
  font-weight: 400;
  letter-spacing: -0.045em;
  line-height: 0.99;
  margin: 0;
  overflow-wrap: break-word;
}

.nh-article__dek {
  color: #57534a;
  font-size: clamp(1.05rem, 4.7vw, 1.3rem);
  line-height: 1.58;
  margin: 24px 0 0;
  max-width: 62ch;
}

.nh-article__meta {
  align-items: flex-start;
  border-top: 1px solid rgba(233, 162, 60, 0.24);
  color: #716b5f;
  display: flex;
  flex-direction: column;
  font-family: var(--font-mono);
  font-size: 0.68rem;
  gap: 8px;
  letter-spacing: 0.08em;
  margin-top: 26px;
  padding-top: 18px;
  text-transform: uppercase;
}

.nh-article__visual {
  align-self: center;
  background: rgba(251, 250, 247, 0.8);
  border: 1px solid rgba(233, 162, 60, 0.24);
  margin: 0;
  overflow: hidden;
}

.nh-article__visual img {
  aspect-ratio: 16 / 9;
  display: block;
  height: auto;
  object-fit: cover;
  width: 100%;
}

.nh-article__body {
  display: grid;
  gap: 36px;
  padding-block: 48px 64px;
}

.nh-article__toc {
  border: 1px solid rgba(233, 162, 60, 0.24);
  border-top: 3px solid #de8e28;
  padding: 20px;
}

.nh-article__toc ol {
  display: grid;
  gap: 12px;
  list-style-position: inside;
  margin: 0;
  padding: 0;
}

.nh-article__toc li,
.nh-article__toc a {
  color: #57534a;
  font-size: 0.9rem;
  line-height: 1.45;
}

.nh-article__toc a {
  align-items: center;
  display: flex;
  min-height: 44px;
  text-decoration: underline;
  text-decoration-color: rgba(222, 142, 40, 0.5);
  text-underline-offset: 4px;
}

.nh-article__content {
  color: #464137;
  font-size: 1.04rem;
  line-height: 1.78;
  min-width: 0;
}

.nh-article__content > :first-child {
  margin-top: 0;
}

.nh-article__content h2,
.nh-article__content h3,
.nh-article__content h4 {
  color: #17150f;
  font-family: var(--font-display);
  font-weight: 400;
  letter-spacing: -0.025em;
  line-height: 1.12;
  scroll-margin-top: 92px;
}

.nh-article__content h2 {
  font-size: clamp(1.75rem, 8vw, 2.8rem);
  margin: 2.15em 0 0.7em;
}

.nh-article__content h3 {
  font-size: clamp(1.28rem, 5.5vw, 1.8rem);
  margin: 1.8em 0 0.55em;
}

.nh-article__content p,
.nh-article__content ul,
.nh-article__content ol {
  margin: 0 0 1.35em;
}

.nh-article__content li + li {
  margin-top: 0.55em;
}

.nh-article__content a {
  color: #9a5e16;
  font-weight: 700;
  text-decoration: underline;
  text-decoration-thickness: 1px;
  text-underline-offset: 3px;
}

.nh-article__content blockquote {
  border-left: 4px solid #de8e28;
  color: #17150f;
  margin: 1.8em 0;
  padding: 5px 0 5px 20px;
}

.nh-article__content pre,
.nh-article__content table {
  max-width: 100%;
  overflow-x: auto;
}

.nh-article__content img {
  height: auto;
  margin-block: 18px;
  width: 100%;
}

.nh-article__faq {
  background: rgba(234, 229, 218, 0.58);
  margin-top: 54px;
  padding: 24px 20px;
}

.nh-article__faq > h2,
.nh-article__next h2,
.nh-article__related h2 {
  font-size: clamp(1.65rem, 7vw, 2.45rem);
  margin: 0 0 20px;
}

.nh-article__faq details {
  border-top: 1px solid rgba(176, 111, 29, 0.25);
}

.nh-article__faq summary {
  color: #17150f;
  cursor: pointer;
  font-family: var(--font-display);
  font-size: 1rem;
  line-height: 1.4;
  min-height: 52px;
  padding: 15px 0;
}

.nh-article__faq details div {
  padding-bottom: 4px;
}

.nh-article__next {
  background: #17150f;
  color: #c9c3b4;
  display: grid;
  gap: 24px;
  margin-top: 54px;
  padding: 26px 22px;
}

.nh-article__next h2 {
  color: #f5f3ee;
}

.nh-article__next p {
  margin: 0;
}

.nh-article__next .nh-kicker {
  color: #e9a23c;
}

.nh-article__actions {
  align-items: stretch;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.nh-article__actions a,
.nh-article__cta a {
  align-items: center;
  border: 1px solid rgba(233, 162, 60, 0.55);
  color: #f5f3ee;
  display: inline-flex;
  font-family: var(--font-mono);
  font-size: 0.72rem;
  justify-content: center;
  letter-spacing: 0.1em;
  min-height: 48px;
  padding: 13px 16px;
  text-align: center;
  text-transform: uppercase;
}

.nh-article__actions .nh-article__primary,
.nh-article__cta a {
  background: #de8e28;
  color: #17150f;
}

.nh-article__related {
  border-top: 1px solid rgba(233, 162, 60, 0.25);
  padding-block: 48px 64px;
}

.nh-article__section-head {
  align-items: flex-start;
  display: flex;
  flex-direction: column;
  gap: 2px;
  margin-bottom: 24px;
}

.nh-article__section-head > a {
  color: #57534a;
  font-family: var(--font-mono);
  font-size: 0.7rem;
  letter-spacing: 0.08em;
  min-height: 44px;
  padding-block: 12px;
  text-transform: uppercase;
}

.nh-article__related-grid {
  display: grid;
  gap: 16px;
}

.nh-article__cta {
  background: #ede8de;
  border-block: 1px solid rgba(233, 162, 60, 0.25);
  padding-block: 56px;
}

.nh-article__cta h2 {
  color: #17150f;
  font-family: var(--font-display);
  font-size: clamp(2.35rem, 12vw, 5.8rem);
  font-weight: 400;
  letter-spacing: -0.045em;
  line-height: 0.98;
  margin: 0 0 22px;
}

.nh-article__cta h2 span {
  color: #9a5908;
}

.nh-article__cta p:not(.nh-kicker) {
  font-size: 1.06rem;
  line-height: 1.6;
  margin: 0 0 24px;
  max-width: 52ch;
}

.nh-article__footer {
  background: #f5f3ee;
  padding-block: 24px;
}

.nh-article__footer > div {
  align-items: flex-start;
  display: flex;
  flex-direction: column;
  gap: 18px;
}

.nh-article__footer img {
  display: block;
  width: 142px;
}

.nh-article__footer > div > a {
  align-items: center;
  display: inline-flex;
  min-height: 44px;
}

.nh-article__footer p {
  color: #625d53;
  font-family: var(--font-mono);
  font-size: 0.67rem;
  letter-spacing: 0.08em;
  margin: 0;
  text-transform: uppercase;
}

.nh-article__footer nav {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 18px;
}

.nh-article__footer nav a {
  color: #57534a;
  font-family: var(--font-mono);
  font-size: 0.68rem;
  letter-spacing: 0.08em;
  min-height: 44px;
  min-width: 44px;
  padding-block: 12px;
  text-transform: uppercase;
}

@media (hover: none), (pointer: coarse) {
  .nh-cursor {
    display: none !important;
  }
}

@media (min-width: 900px) {
  .nh-article__shell {
    padding-inline: 5vw;
  }

  .nh-article__hero {
    padding-block: 54px 72px;
  }

  .nh-article__hero-grid {
    align-items: center;
    grid-template-columns: minmax(0, 1.35fr) minmax(280px, 0.65fr);
    gap: 60px;
  }

  .nh-article__meta {
    align-items: center;
    flex-direction: row;
    flex-wrap: wrap;
    gap: 10px 22px;
  }

  .nh-article__body {
    align-items: start;
    grid-template-columns: 220px minmax(0, 760px);
    justify-content: center;
    gap: 68px;
    padding-block: 78px 96px;
  }

  .nh-article__toc {
    position: sticky;
    top: 98px;
  }

  .nh-article__content {
    font-size: 1.1rem;
  }

  .nh-article__faq {
    padding: 34px;
  }

  .nh-article__next {
    align-items: end;
    grid-template-columns: minmax(0, 1fr) minmax(260px, 0.65fr);
    padding: 38px;
  }

  .nh-article__section-head {
    align-items: center;
    flex-direction: row;
    justify-content: space-between;
  }

  .nh-article__related-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .nh-article__cta {
    padding-block: 88px;
  }

  .nh-article__footer > div {
    align-items: center;
    flex-direction: row;
    justify-content: space-between;
  }
}
