/* =============================================================
   VexPass — css/index.css
   © Blackreach Enterprises · vexpass.com
   ============================================================= */

/* ── Custom properties ────────────────────────────────────── */
:root {
  /* Backgrounds */
  --bg:        #000000;
  --bg-2:      #0a0a0a;
  --bg-3:      #111111;
  --bg-4:      #161616;

  /* Borders */
  --border:    rgba(255, 255, 255, 0.07);
  --border-md: rgba(255, 255, 255, 0.13);
  --border-hi: rgba(255, 255, 255, 0.24);

  /* Text — contrast-checked against dark backgrounds */
  --text-1:    #ffffff;                    /* 21:1 on #000 */
  --text-2:    rgba(255, 255, 255, 0.75);  /* ~10:1 */
  --text-3:    rgba(255, 255, 255, 0.55);  /* ~5.2:1 — WCAG AA compliant */
  --text-4:    rgba(255, 255, 255, 0.36);  /* decorative labels only */

  /* Brand */
  --accent:    #c00000;
  --accent-lo: rgba(192, 0, 0, 0.10);
  --accent-md: rgba(192, 0, 0, 0.22);

  /* Radii */
  --radius-sm: 8px;
  --radius-md: 11px;
  --radius-lg: 18px;

  /* Transitions */
  --ease-out:  cubic-bezier(0.16, 1, 0.3, 1);
}

/* ── Reset ────────────────────────────────────────────────── */
*,
*::before,
*::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

/* ── Base ─────────────────────────────────────────────────── */
html {
  scroll-behavior: smooth;
}

html,
body {
  height: 100%;
  background: var(--bg);
  color: var(--text-1);
  font-family: 'Public Sans', sans-serif;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

body {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

/* ── Text selection ───────────────────────────────────────── */
::selection {
  background: var(--accent-lo);
  color: #ff4444;
}

/* ── Skip link (accessibility) ────────────────────────────── */
.skip-link {
  position: absolute;
  top: -100%;
  left: 1rem;
  z-index: 9999;
  padding: 10px 20px;
  background: var(--accent);
  color: #fff;
  font-size: 0.85rem;
  font-weight: 600;
  border-radius: var(--radius-sm);
  text-decoration: none;
  transition: top 0.2s;
}

.skip-link:focus {
  top: 1rem;
}

/* ── Global focus ring ────────────────────────────────────── */
:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 3px;
  border-radius: 4px;
}

/* ── Noise texture overlay ────────────────────────────────── */
body::before {
  content: '';
  position: fixed;
  inset: 0;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 256 256' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)' opacity='1'/%3E%3C/svg%3E");
  opacity: 0.022;
  pointer-events: none;
  z-index: 0;
}

/* ── Radial glow ──────────────────────────────────────────── */
body::after {
  content: '';
  position: fixed;
  top: -30vh;
  left: 50%;
  transform: translateX(-50%);
  width: 900px;
  height: 600px;
  background: radial-gradient(ellipse at center, rgba(192, 0, 0, 0.07) 0%, transparent 70%);
  pointer-events: none;
  z-index: 0;
}

/* ── Page-load animations ─────────────────────────────────── */
@keyframes fadeUp {
  from {
    opacity: 0;
    transform: translateY(18px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.anim { animation: fadeUp 0.65s var(--ease-out) both; }
.d1   { animation-delay: 0.04s; }
.d2   { animation-delay: 0.11s; }
.d3   { animation-delay: 0.18s; }
.d4   { animation-delay: 0.25s; }
.d5   { animation-delay: 0.33s; }

@media (prefers-reduced-motion: reduce) {
  .anim,
  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-delay: 0.01ms !important;
    transition-duration: 0.01ms !important;
  }

  html {
    scroll-behavior: auto;
  }
}

/* ═══════════════════════════════════════════════════════════
   NAVBAR
   ═══════════════════════════════════════════════════════════ */
.navbar {
  position: sticky;
  top: 0;
  z-index: 100;
  /* Red accent line at very top */
  border-top: 2px solid var(--accent);
  border-bottom: 1px solid var(--border);
  background: rgba(0, 0, 0, 0.82);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
}

.navbar-inner {
  max-width: 1080px;
  margin: 0 auto;
  padding: 0 28px;
  height: 60px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}

/* ── Logo ── */
.nav-logo {
  display: flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
  flex-shrink: 0;
}

.nav-logo-img {
  height: 26px;
  width: auto;
  display: block;
}

.nav-logo-wordmark {
  font-size: 1rem;
  font-weight: 750;
  letter-spacing: -0.02em;
  color: var(--text-1);
  /* Hidden visually when image loads fine; always in DOM for screen readers */
  line-height: 1;
}

.nav-actions {
  display: flex;
  align-items: center;
  gap: 10px;
}

/* ═══════════════════════════════════════════════════════════
   BUTTONS
   ═══════════════════════════════════════════════════════════ */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  font-family: 'Public Sans', sans-serif;
  font-size: 0.83rem;
  font-weight: 650;
  letter-spacing: 0.01em;
  border-radius: var(--radius-sm);
  height: 38px;
  padding: 0 17px;
  cursor: pointer;
  text-decoration: none;
  white-space: nowrap;
  transition: background 0.15s ease, border-color 0.15s ease, color 0.15s ease,
              transform 0.1s ease, box-shadow 0.15s ease;
  border: 1px solid transparent;
}

.btn:active {
  transform: scale(0.96);
}

/* Ghost */
.btn-ghost {
  background: transparent;
  border-color: var(--border-md);
  color: var(--text-2);
}

.btn-ghost:hover {
  border-color: var(--border-hi);
  color: var(--text-1);
  background: rgba(255, 255, 255, 0.05);
}

/* Primary (white) */
.btn-primary {
  background: var(--text-1);
  color: #000;
  font-weight: 700;
}

.btn-primary:hover {
  background: rgba(255, 255, 255, 0.88);
  box-shadow: 0 0 0 3px rgba(255, 255, 255, 0.08);
}

/* Accent (red) */
.btn-accent {
  background: var(--accent);
  color: #fff;
  font-weight: 700;
}

.btn-accent:hover {
  background: #a80000;
}

/* Large */
.btn-lg {
  font-size: 0.9rem;
  height: 46px;
  padding: 0 24px;
  border-radius: var(--radius-md);
}

/* ═══════════════════════════════════════════════════════════
   HAMBURGER (mobile)
   ═══════════════════════════════════════════════════════════ */
.hamburger {
  display: none;
  flex-direction: column;
  gap: 5px;
  /* 44×44 minimum touch target per WCAG 2.5.5 */
  width: 44px;
  height: 44px;
  align-items: center;
  justify-content: center;
  background: none;
  border: 1px solid var(--border-md);
  cursor: pointer;
  border-radius: var(--radius-sm);
  transition: background 0.15s, border-color 0.15s;
  flex-shrink: 0;
}

.hamburger:hover {
  background: rgba(255, 255, 255, 0.05);
  border-color: var(--border-hi);
}

.hamburger span {
  display: block;
  width: 18px;
  height: 1.5px;
  background: var(--text-2);
  border-radius: 2px;
  transition: transform 0.3s ease, opacity 0.2s ease, width 0.2s ease;
  transform-origin: center;
}

.hamburger[aria-expanded="true"] span:nth-child(1) {
  transform: translateY(6.5px) rotate(45deg);
}

.hamburger[aria-expanded="true"] span:nth-child(2) {
  opacity: 0;
  width: 0;
}

.hamburger[aria-expanded="true"] span:nth-child(3) {
  transform: translateY(-6.5px) rotate(-45deg);
}

/* ═══════════════════════════════════════════════════════════
   MOBILE MENU
   ═══════════════════════════════════════════════════════════ */
.mobile-menu {
  position: fixed;
  top: 62px; /* navbar height (60px) + 2px top border */
  left: 0;
  width: 100%;
  background: rgba(4, 4, 4, 0.97);
  border-bottom: 1px solid var(--border);
  padding: 16px 20px 22px;
  display: flex;
  flex-direction: column;
  gap: 10px;
  transform: translateY(-10px);
  opacity: 0;
  visibility: hidden;
  transition: transform 0.22s var(--ease-out), opacity 0.22s ease,
              visibility 0.22s ease;
  z-index: 99;
}

.mobile-menu.open {
  transform: translateY(0);
  opacity: 1;
  visibility: visible;
}

/* ═══════════════════════════════════════════════════════════
   HERO
   ═══════════════════════════════════════════════════════════ */
.hero {
  position: relative;
  z-index: 1;
  max-width: 1080px;
  margin: 0 auto;
  padding: 104px 28px 100px;
  text-align: center;
}

.hero-eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.09em;
  text-transform: uppercase;
  color: var(--accent);
  background: var(--accent-lo);
  border: 1px solid var(--accent-md);
  border-radius: 999px;
  padding: 6px 14px;
  margin-bottom: 34px;
}

.hero-title {
  font-size: clamp(2.6rem, 6vw, 4.4rem);
  font-weight: 800;
  line-height: 1.04;
  letter-spacing: -0.045em;
  color: var(--text-1);
}

.hero-sub {
  margin: 22px auto 0;
  max-width: 500px;
  font-size: 1.02rem;
  font-weight: 400;
  color: var(--text-3);
  line-height: 1.78;
}

.hero-cta {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: 10px;
  margin-top: 38px;
}

/* ── Stat chips ── */
.stats-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: 10px;
  margin-top: 52px;
}

.stat-chip {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 0.78rem;
  font-weight: 500;
  color: var(--text-3);
  border: 1px solid var(--border);
  border-radius: 999px;
  padding: 8px 16px;
  background: var(--bg-3);
  letter-spacing: 0.01em;
}

/* ═══════════════════════════════════════════════════════════
   DIVIDER
   ═══════════════════════════════════════════════════════════ */
.divider {
  position: relative;
  z-index: 1;
  border: none;
  border-top: 1px solid var(--border);
  margin: 0;
}

/* ═══════════════════════════════════════════════════════════
   FEATURES
   ═══════════════════════════════════════════════════════════ */
.features {
  position: relative;
  z-index: 1;
  max-width: 1080px;
  margin: 0 auto;
  padding: 92px 28px;
}

.section-header {
  text-align: center;
  margin-bottom: 54px;
}

.section-label {
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--text-4);
  margin-bottom: 14px;
}

.section-title {
  font-size: clamp(1.75rem, 3vw, 2.4rem);
  font-weight: 750;
  letter-spacing: -0.03em;
  color: var(--text-1);
  line-height: 1.14;
}

.section-sub {
  margin: 14px auto 0;
  max-width: 420px;
  font-size: 0.9rem;
  color: var(--text-3);
  line-height: 1.72;
}

/* ── Feature grid ── */
.feature-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1px;
  background: var(--border);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  overflow: hidden;
}

.feature-card {
  background: var(--bg-2);
  padding: 34px 30px;
  transition: background 0.2s ease;
}

.feature-card:hover {
  background: var(--bg-3);
}

.feature-icon {
  width: 42px;
  height: 42px;
  border-radius: var(--radius-sm);
  border: 1px solid var(--border-md);
  background: var(--bg-4);
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 20px;
  color: var(--text-3);
  transition: border-color 0.2s, color 0.2s;
  flex-shrink: 0;
}

.feature-card:hover .feature-icon {
  border-color: var(--accent-md);
  color: var(--accent);
}

.feature-name {
  font-size: 0.9rem;
  font-weight: 680;
  color: var(--text-1);
  margin-bottom: 10px;
  letter-spacing: -0.015em;
}

.feature-desc {
  font-size: 0.84rem;
  color: var(--text-3);
  line-height: 1.72;
}

/* ═══════════════════════════════════════════════════════════
   TRUST BANNER
   ═══════════════════════════════════════════════════════════ */
.trust {
  position: relative;
  z-index: 1;
  background: var(--bg-2);
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
}

.trust-inner {
  max-width: 1080px;
  margin: 0 auto;
  padding: 84px 28px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 56px;
}

.trust-text {
  flex: 1;
}

.trust-label {
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--text-4);
  margin-bottom: 14px;
}

.trust-title {
  font-size: clamp(1.5rem, 2.5vw, 2.1rem);
  font-weight: 750;
  letter-spacing: -0.03em;
  color: var(--text-1);
  line-height: 1.2;
  margin-bottom: 16px;
}

.trust-desc {
  font-size: 0.87rem;
  color: var(--text-3);
  line-height: 1.78;
  max-width: 440px;
}

.trust-desc a {
  color: var(--text-2);
  text-decoration: underline;
  text-underline-offset: 3px;
  text-decoration-color: var(--border-hi);
  transition: color 0.15s;
}

.trust-desc a:hover {
  color: var(--text-1);
}

.trust-actions {
  display: flex;
  flex-direction: column;
  gap: 10px;
  flex-shrink: 0;
}

/* ═══════════════════════════════════════════════════════════
   FOOTER
   ═══════════════════════════════════════════════════════════ */
.footer {
  position: relative;
  z-index: 1;
  border-top: 1px solid var(--border);
  padding: 28px;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  max-width: 1080px;
  margin: 0 auto;
  width: 100%;
}

.footer-logo img {
  height: 20px;
  width: auto;
  display: block;
  opacity: 0.5;
  transition: opacity 0.2s;
}

.footer-logo:hover img {
  opacity: 0.75;
}

.footer-copy {
  font-size: 0.76rem;
  color: var(--text-4);
}

.footer-copy a {
  color: var(--text-4);
  text-decoration: underline;
  text-underline-offset: 3px;
  transition: color 0.15s;
}

.footer-copy a:hover {
  color: var(--text-3);
}

.footer-links {
  display: flex;
  gap: 20px;
}

.footer-links a {
  font-size: 0.76rem;
  color: var(--text-4);
  text-decoration: none;
  transition: color 0.15s;
}

.footer-links a:hover {
  color: var(--text-3);
}

/* ── Arrow icon helper ── */
.arrow {
  display: inline-block;
  width: 13px;
  height: 13px;
  flex-shrink: 0;
}

/* ═══════════════════════════════════════════════════════════
   RESPONSIVE
   ═══════════════════════════════════════════════════════════ */
@media (max-width: 860px) {
  .feature-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 767px) {
  .nav-actions {
    display: none !important;
  }

  .hamburger {
    display: flex !important;
  }

  .feature-grid {
    grid-template-columns: 1fr;
  }

  .hero {
    padding: 72px 20px 80px;
  }

  .features {
    padding: 64px 20px;
  }

  .trust-inner {
    flex-direction: column;
    align-items: flex-start;
    gap: 32px;
    padding: 56px 20px;
  }

  .trust-actions {
    flex-direction: row;
    flex-wrap: wrap;
    width: 100%;
  }

  .trust-actions .btn {
    flex: 1;
    justify-content: center;
    min-width: 140px;
  }

  .footer {
    flex-direction: column;
    align-items: flex-start;
    padding: 24px 20px;
  }

  .stats-row {
    gap: 8px;
  }

  .navbar-inner {
    padding: 0 16px;
  }

  .mobile-menu {
    padding: 14px 16px 20px;
  }
}

@media (min-width: 768px) {
  .hamburger {
    display: none !important;
  }

  .mobile-menu {
    display: none !important;
  }
}

/* High-contrast mode support */
@media (forced-colors: active) {
  .btn-primary {
    border: 2px solid ButtonText;
  }

  .feature-icon {
    border: 1px solid ButtonText;
  }
}
