/* ================================================
   OPENENVELOPE — BASE STYLES
   ================================================ */
@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700;800;900&family=Orbitron:wght@400;500&display=swap');

/* Body */
body {
  font-family: 'Inter', system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  background-color: var(--bg-primary);
  color: var(--text-primary);
  line-height: 1.6;
}

/* Grid overlay */
body::before {
  content: '';
  position: fixed;
  inset: 0;
  background-image:
    linear-gradient(rgba(255,255,255,0.015) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255,255,255,0.015) 1px, transparent 1px);
  background-size: 72px 72px;
  pointer-events: none;
  z-index: 0;
}

/* Ambient glow */
.glow-orb {
  position: fixed;
  border-radius: 50%;
  pointer-events: none;
  filter: blur(110px);
  z-index: 0;
}
.glow-orb-1 {
  width: 800px; height: 800px;
  background: radial-gradient(circle, rgba(124,58,237,0.07) 0%, transparent 70%);
  top: -15%; right: -12%;
  animation: orbDrift 20s ease-in-out infinite alternate;
}
.glow-orb-2 {
  width: 600px; height: 600px;
  background: radial-gradient(circle, rgba(37,99,235,0.06) 0%, transparent 70%);
  bottom: 5%; left: -10%;
  animation: orbDrift 26s ease-in-out infinite alternate-reverse;
}
@keyframes orbDrift {
  0%   { transform: translate(0,0) scale(1); }
  100% { transform: translate(30px,-22px) scale(1.07); }
}

/* Scrollbar */
::-webkit-scrollbar       { width: 6px; }
::-webkit-scrollbar-track { background: var(--bg-primary); }
::-webkit-scrollbar-thumb { background: var(--bg-elevated); border-radius: 3px; }
::-webkit-scrollbar-thumb:hover { background: var(--violet); }

/* Typography */
h1,h2,h3,h4,h5,h6 {
  font-weight: 700;
  letter-spacing: -0.025em;
  line-height: 1.1;
  color: var(--text-primary);
}
p { color: var(--text-secondary); line-height: 1.8; }

/* Container */
.container {
  width: 100%;
  max-width: var(--max-w);
  margin-inline: auto;
  padding-inline: var(--sp-6);
  position: relative;
  z-index: 1;
}

/* Focus visible */
*:focus-visible {
  outline: 2px solid var(--cyan);
  outline-offset: 3px;
  border-radius: 3px;
}

/* Skip link */
.skip-link {
  position: absolute;
  top: -100px;
  left: var(--sp-6);
  background: var(--grad-brand);
  color: var(--text-primary);
  padding: var(--sp-3) var(--sp-6);
  border-radius: var(--r-md);
  font-weight: 600;
  font-size: 0.9rem;
  z-index: 9999;
  transition: top var(--t-fast);
  white-space: nowrap;
}
.skip-link:focus { top: 12px; }

/* Gradient text utility */
.text-gradient {
  background: var(--grad-brand);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
}
.text-gradient-soft {
  background: var(--grad-text);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
}

/* Visually hidden */
.sr-only {
  position: absolute;
  width: 1px; height: 1px;
  padding: 0; margin: -1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
  border: 0;
}

/* Section spacing */
.section { padding: var(--section-y) 0; position: relative; }
.section + .section { border-top: 1px solid rgba(255,255,255,0.03); }

/* Section label */
.label {
  display: inline-flex;
  align-items: center;
  gap: var(--sp-2);
  font-size: 0.72rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.14em;
  color: var(--cyan);
  margin-bottom: var(--sp-5);
}
.label::before {
  content: '';
  display: block;
  width: 20px; height: 1.5px;
  background: var(--grad-brand);
  border-radius: 2px;
}

/* Section heading */
.heading-xl {
  font-size: clamp(2.2rem,5.5vw,3.8rem);
  font-weight: 900;
  letter-spacing: -0.035em;
  line-height: 1.06;
  background: var(--grad-text);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  margin-bottom: var(--sp-6);
}
.heading-lg {
  font-size: clamp(1.8rem,4vw,3rem);
  font-weight: 800;
  letter-spacing: -0.03em;
  line-height: 1.1;
  background: var(--grad-text);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  margin-bottom: var(--sp-5);
}
.heading-md {
  font-size: clamp(1.4rem,3vw,2rem);
  font-weight: 700;
  letter-spacing: -0.02em;
}

/* Body large */
.body-lg {
  font-size: clamp(1rem,2vw,1.2rem);
  line-height: 1.8;
  color: var(--text-secondary);
  font-weight: 400;
  max-width: 680px;
}

/* Divider */
.divider { height: 1px; background: var(--border); margin: var(--sp-16) 0; }

/* ── Logo rendering ── */
.logo img,
.footer-logo img,
.logo-link img {
  display: block;
  height: 40px;
  width: auto;
  object-fit: contain;
  object-position: left center;
}
/* Nav-specific icon — don't override with base rule */
.nav-icon-img,
.nav-wordmark-img {
  max-width: none !important;
  height: auto;
}
.footer-logo img {
  height: 36px;
}
.logo,
.footer-logo,
.logo-link {
  display: inline-flex;
  align-items: center;
  flex-shrink: 0;
  text-decoration: none;
}
