/* ==========================================================================
   BITNACION DESIGN SYSTEM — Reverse-engineered from hugeinc.com
   ========================================================================== */

:root {
  /* Brand & Accent Colors (Bitnacion Red adapted from Huge Magenta) */
  --color-brand-accent: #e82a2a;
  --color-brand-accent-hover: #c91e1e;
  --color-brand-accent-light: #fff0f0;
  --color-brand-accent-100: #ffd6d6;
  --color-brand-accent-900: #750000;

  /* Neutrals */
  --color-neutral-0: #ffffff;
  --color-neutral-25: #faf8f4;
  --color-neutral-50: #f7f4ee;
  --color-neutral-75: #f0ebe2;
  --color-neutral-100: #ede8e0;
  --color-neutral-200: #e1ddd7;
  --color-neutral-300: #d5d2cf;
  --color-neutral-400: #a5a19d;
  --color-neutral-500: #76726e;
  --color-neutral-600: #55514d;
  --color-neutral-700: #433f3c;
  --color-neutral-800: #292624;
  --color-neutral-900: #1a1816;
  --color-neutral-950: #0d0b0a;
  --color-neutral-1000: #000000;

  /* Theme Defaults (Light) */
  --theme-bg: #ffffff;
  --theme-text-primary: #0d0b0a;
  --theme-text-secondary: #76726e;
  --theme-border-subtle: rgba(0, 0, 0, 0.14);
  --theme-border-strong: rgba(0, 0, 0, 0.7);
  --theme-pill-bg: rgba(0, 0, 0, 0.05);

  /* Typography */
  --font-display: 'Plus Jakarta Sans', 'Inter', ui-sans-serif, system-ui, -apple-system, sans-serif;
  --font-body: 'Plus Jakarta Sans', 'Inter', ui-sans-serif, system-ui, -apple-system, sans-serif;
  --font-mono: 'JetBrains Mono', ui-monospace, SFMono-Regular, Menlo, monospace;

  /* Fluid Type Scale (exact hugeinc.com proportions) */
  --text-display-2xl: clamp(4.25rem, 2.2rem + 9.5vw, 13.5rem);
  --text-display-xl: clamp(3.5rem, 1.8rem + 7.5vw, 10.5rem);
  --text-display-l: clamp(3rem, 1.5rem + 6vw, 8.5rem);
  --text-h1: clamp(2.5rem, 1.4rem + 4.2vw, 5.75rem);
  --text-h2: clamp(2.125rem, 1.2rem + 3.2vw, 4.5rem);
  --text-h3: clamp(1.75rem, 1.1rem + 2.2vw, 3.25rem);
  --text-h4: clamp(1.375rem, 1rem + 1.4vw, 2.375rem);
  --text-h5: clamp(1.25rem, 1rem + 0.8vw, 1.875rem);
  --text-h6: clamp(1.125rem, 0.95rem + 0.5vw, 1.5rem);
  --text-body-xl: clamp(1.375rem, 1.05rem + 1.2vw, 2.25rem);
  --text-body-large: clamp(1.125rem, 1rem + 0.45vw, 1.5rem);
  --text-body: clamp(1rem, 0.95rem + 0.25vw, 1.1875rem);
  --text-body-small: 0.875rem;
  --text-body-tiny: 0.75rem;
  --text-nav-link: 0.96875rem;

  /* Layout & Spacing */
  --header-height: 4.5rem;
  --page-margin: clamp(1.25rem, 0.5rem + 2.6vw, 3.75rem);
  --section-gap-xl: clamp(5rem, 3rem + 6vw, 10rem);
  --section-gap-lg: clamp(3.5rem, 2rem + 4vw, 7rem);
  --section-gap-md: clamp(2.5rem, 1.5rem + 2.5vw, 4.5rem);

  /* Huge Easing Curves */
  --ease-osmo: cubic-bezier(0.625, 0.05, 0, 1);
  --ease-ui-out: cubic-bezier(0.23, 1, 0.32, 1);
  --ease-ui-in-out: cubic-bezier(0.77, 0, 0.175, 1);
}

@media (min-width: 64rem) {
  :root {
    --header-height: 5.75rem;
  }
}

[data-theme="dark"] {
  --theme-bg: #0d0b0a;
  --theme-text-primary: #ffffff;
  --theme-text-secondary: #a5a19d;
  --theme-border-subtle: rgba(255, 255, 255, 0.18);
  --theme-border-strong: rgba(255, 255, 255, 0.7);
  --theme-pill-bg: rgba(255, 255, 255, 0.08);
}

[data-theme="cream"] {
  --theme-bg: #f7f4ee;
  --theme-text-primary: #0d0b0a;
  --theme-text-secondary: #55514d;
  --theme-border-subtle: rgba(0, 0, 0, 0.12);
}

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

html {
  scroll-behavior: smooth;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
}

body {
  margin: 0;
  font-family: var(--font-body);
  font-size: var(--text-body);
  line-height: 1.5;
  color: var(--theme-text-primary);
  background-color: var(--theme-bg);
  overflow-x: hidden;
}

::selection {
  background-color: var(--color-brand-accent);
  color: #ffffff;
}

/* Typography Utility Classes matching hugeinc.com */
.text-display-2xl {
  font-family: var(--font-display);
  font-size: var(--text-display-2xl);
  line-height: 0.88;
  letter-spacing: -0.05em;
  font-weight: 700;
}

.text-display-xl {
  font-family: var(--font-display);
  font-size: var(--text-display-xl);
  line-height: 0.88;
  letter-spacing: -0.05em;
  font-weight: 700;
}

.text-display-l {
  font-family: var(--font-display);
  font-size: var(--text-display-l);
  line-height: 0.92;
  letter-spacing: -0.045em;
  font-weight: 700;
}

.text-h1 {
  font-family: var(--font-display);
  font-size: var(--text-h1);
  line-height: 0.98;
  letter-spacing: -0.045em;
  font-weight: 600;
}

.text-h2 {
  font-family: var(--font-display);
  font-size: var(--text-h2);
  line-height: 1.04;
  letter-spacing: -0.04em;
  font-weight: 600;
}

.text-h3 {
  font-family: var(--font-display);
  font-size: var(--text-h3);
  line-height: 1.1;
  letter-spacing: -0.035em;
  font-weight: 600;
}

.text-h4 {
  font-family: var(--font-display);
  font-size: var(--text-h4);
  line-height: 1.15;
  letter-spacing: -0.03em;
  font-weight: 600;
}

.text-h5 {
  font-family: var(--font-display);
  font-size: var(--text-h5);
  line-height: 1.2;
  letter-spacing: -0.025em;
  font-weight: 600;
}

.text-body-xl {
  font-size: var(--text-body-xl);
  line-height: 1.32;
  letter-spacing: -0.025em;
}

.text-body-large {
  font-size: var(--text-body-large);
  line-height: 1.42;
  letter-spacing: -0.015em;
}

.text-nav-link {
  font-size: var(--text-nav-link);
  line-height: 1;
  letter-spacing: -0.025em;
}

.font-mono-tech {
  font-family: var(--font-mono);
}

/* Page Container */
.page-container {
  padding-left: var(--page-margin);
  padding-right: var(--page-margin);
  width: 100%;
  max-width: 112.5rem;
  margin-left: auto;
  margin-right: auto;
}

/* Huge-style Pill CTA Button */
.btn-pill {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  border-radius: 999px;
  font-weight: 600;
  font-size: 0.9375rem;
  letter-spacing: -0.02em;
  padding: 0.72rem 1.35rem;
  transition: background-color 0.22s var(--ease-ui-out), color 0.22s var(--ease-ui-out), transform 0.16s var(--ease-ui-out), border-color 0.22s var(--ease-ui-out);
  cursor: pointer;
  white-space: nowrap;
}

.btn-pill:active {
  transform: scale(0.97);
}

.btn-pill-dark {
  background-color: #0d0b0a;
  color: #ffffff;
  border: 1.5px solid #0d0b0a;
}

.btn-pill-dark:hover {
  background-color: var(--color-brand-accent);
  border-color: var(--color-brand-accent);
  color: #ffffff;
}

.btn-pill-outline {
  background-color: transparent;
  color: var(--theme-text-primary);
  border: 1.5px solid var(--theme-border-strong);
}

.btn-pill-outline:hover {
  background-color: var(--theme-text-primary);
  color: var(--theme-bg);
}

/* Nav link animated underline / lift */
.nav-link-item {
  position: relative;
  display: inline-flex;
  align-items: center;
  padding: 0.4rem 0;
  transition: color 0.2s var(--ease-ui-out), opacity 0.2s var(--ease-ui-out);
}

.nav-link-item:hover {
  color: var(--color-brand-accent);
}

/* B&W High Contrast Editorial Portrait Filter */
.portrait-bw {
  filter: grayscale(100%) contrast(1.18) brightness(0.98);
  transition: filter 0.45s var(--ease-osmo), transform 0.55s var(--ease-osmo);
}

.group:hover .portrait-bw {
  filter: grayscale(0%) contrast(1.05) brightness(1);
  transform: scale(1.03);
}

/* Solution Card Hover */
.solution-card {
  transition: border-color 0.3s var(--ease-ui-out), transform 0.35s var(--ease-osmo), background-color 0.3s var(--ease-ui-out);
}

.solution-card:hover {
  border-color: var(--color-brand-accent);
}
