/* Custom styles that complement Tailwind */
@import url("https://fonts.googleapis.com/css2?family=Poppins:wght@400;500;600;700;800&family=Space+Grotesk:wght@500;700&display=swap");

html {
  scroll-behavior: smooth;
}

body {
  background-color: #222531;
  font-family: "Poppins", ui-sans-serif, system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  color: #fff;
  overflow-x: hidden;
}

.display-font {
  font-family: "Space Grotesk", "Poppins", sans-serif;
  letter-spacing: -0.02em;
}

.pHighlight {
  color: #F7931A;
}

/* Background glow accents */
.bg-radial {
  background-image:
    radial-gradient(circle at 20% 10%, rgba(247, 147, 26, 0.18), transparent 50%),
    radial-gradient(circle at 80% 20%, rgba(247, 147, 26, 0.10), transparent 55%),
    radial-gradient(circle at 50% 100%, rgba(247, 147, 26, 0.12), transparent 50%);
}

.gradient-text {
  background: linear-gradient(135deg, #ffffff 0%, #F7931A 60%, #ffd9a8 100%);
  -webkit-background-clip: text;
          background-clip: text;
  -webkit-text-fill-color: transparent;
          color: transparent;
}

/* Hero tag — unique eyebrow with OG stamp */
.hero-tag {
  display: inline-flex;
  align-items: center;
  gap: 0.65rem;
  padding: 0.4rem 0.9rem 0.4rem 0.45rem;
  background: linear-gradient(135deg, rgba(247, 147, 26, 0.08), rgba(255, 255, 255, 0.02));
  border: 1px solid rgba(247, 147, 26, 0.25);
  border-radius: 9999px;
  position: relative;
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.06),
    0 10px 30px -12px rgba(247, 147, 26, 0.35);
}
.hero-tag::before {
  content: "";
  position: absolute;
  inset: -1px;
  border-radius: 9999px;
  padding: 1px;
  background: linear-gradient(120deg, rgba(247, 147, 26, 0.6), rgba(247, 147, 26, 0) 40%, rgba(247, 147, 26, 0.6) 100%);
  -webkit-mask:
    linear-gradient(#000 0 0) content-box,
    linear-gradient(#000 0 0);
  -webkit-mask-composite: xor;
          mask-composite: exclude;
  pointer-events: none;
  opacity: 0.7;
}
.hero-tag-stamp {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  padding: 0.25rem 0.7rem;
  background: linear-gradient(135deg, #F7931A, #f7a93a);
  color: #1a1d27;
  font-family: "Space Grotesk", "Poppins", sans-serif;
  font-weight: 800;
  font-size: 0.72rem;
  letter-spacing: 0.16em;
  border-radius: 9999px;
  box-shadow: 0 4px 14px -2px rgba(247, 147, 26, 0.6);
}
.hero-tag-main {
  font-size: 0.78rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: #f5f5f5;
}
.hero-tag-divider {
  width: 1px;
  height: 14px;
  background-color: rgba(255, 255, 255, 0.18);
}
.hero-tag-since {
  font-size: 0.78rem;
  font-weight: 500;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: #9ca3af;
}
.hero-tag-since strong {
  color: #F7931A;
  font-weight: 700;
}

/* Section eyebrow label */
.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.35rem 0.85rem;
  border: 1px solid rgba(247, 147, 26, 0.35);
  background-color: rgba(247, 147, 26, 0.08);
  color: #F7931A;
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  border-radius: 9999px;
}
.eyebrow::before {
  content: "";
  width: 6px;
  height: 6px;
  background-color: #F7931A;
  border-radius: 9999px;
  box-shadow: 0 0 8px #F7931A;
}

/* Particle layers */
.particles,
#particles-2 {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
  z-index: 0;
}
#particles-2 {
  height: 600px;
  bottom: 0;
  top: auto;
}

/* Sticky nav */
.site-nav {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 50;
  transition: background-color 0.3s ease, backdrop-filter 0.3s ease, border-color 0.3s ease;
  border-bottom: 1px solid transparent;
}
.site-nav.scrolled {
  background-color: rgba(34, 37, 49, 0.85);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom-color: rgba(247, 147, 26, 0.15);
}
.nav-link {
  position: relative;
  color: #d1d5db;
  font-weight: 500;
  font-size: 0.95rem;
  padding: 0.25rem 0;
  white-space: nowrap;
  transition: color 0.25s ease;
}
.nav-link:hover {
  color: #F7931A;
}
.nav-link::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: -4px;
  width: 0;
  height: 2px;
  background-color: #F7931A;
  transition: width 0.25s ease;
}
.nav-link:hover::after {
  width: 100%;
}

/* Preloader */
.preloader {
  position: fixed;
  inset: 0;
  background-color: #222531;
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 9999;
  transition: opacity 0.6s ease;
}
.preloader .spinnerBTC img {
  width: 80px;
  height: 80px;
  animation: spin 1.2s linear infinite;
}
@keyframes spin {
  from { transform: rotate(0deg); }
  to { transform: rotate(360deg); }
}

/* Fade-in */
.reveal {
  opacity: 0;
  transform: translateY(20px);
  transition: opacity 0.9s ease, transform 0.9s ease;
}
.reveal.is-visible {
  opacity: 1;
  transform: translateY(0);
}

/* 3D cube */
.scene {
  width: 240px;
  height: 240px;
  perspective: 800px;
  margin: 0 auto;
  filter: drop-shadow(0 30px 40px rgba(247, 147, 26, 0.25));
}
.cube {
  width: 100%;
  height: 100%;
  position: relative;
  transform-style: preserve-3d;
  animation: cubeSpin 30s infinite linear;
}
.cube .face {
  position: absolute;
  width: 240px;
  height: 240px;
  background-color: #2e313e;
  border: 2px solid rgba(247, 147, 26, 0.4);
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  border-radius: 14px;
}
.cube .face img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.cube .face.front  { transform: translateZ(120px); }
.cube .face.back   { transform: rotateY(180deg) translateZ(120px); }
.cube .face.right  { transform: rotateY(90deg)  translateZ(120px); }
.cube .face.left   { transform: rotateY(-90deg) translateZ(120px); }
.cube .face.top    { transform: rotateX(90deg)  translateZ(120px); }
.cube .face.bottom { transform: rotateX(-90deg) translateZ(120px); }

@keyframes cubeSpin {
  0%   { transform: rotateX(0deg) rotateY(0deg); }
  100% { transform: rotateX(360deg) rotateY(360deg); }
}

/* Image frame for content sections */
.media-frame {
  position: relative;
  border-radius: 24px;
  overflow: hidden;
  background: linear-gradient(135deg, rgba(247, 147, 26, 0.18), rgba(46, 49, 62, 0.0));
  padding: 8px;
}
.media-frame::before {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: 24px;
  border: 1px solid rgba(247, 147, 26, 0.25);
  pointer-events: none;
}
.media-frame img {
  border-radius: 18px;
  width: 100%;
  height: auto;
}

/* Stat cards */
.stat-card {
  background: linear-gradient(160deg, rgba(247, 147, 26, 0.95), rgba(247, 147, 26, 0.7));
  border-radius: 20px;
  padding: 1.5rem 1rem;
  text-align: center;
  position: relative;
  overflow: hidden;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
  box-shadow: 0 12px 30px -10px rgba(247, 147, 26, 0.5);
}
.stat-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 18px 40px -8px rgba(247, 147, 26, 0.6);
}
.stat-card::after {
  content: "";
  position: absolute;
  top: -40%;
  right: -40%;
  width: 180px;
  height: 180px;
  background-color: rgba(255, 255, 255, 0.12);
  border-radius: 50%;
}

/* Exchange / social cards */
.brand-card {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 0.75rem;
  padding: 1.5rem 1.25rem;
  min-width: 160px;
  border-radius: 18px;
  background-color: rgba(34, 37, 49, 0.7);
  border: 1px solid rgba(255, 255, 255, 0.06);
  transition: transform 0.3s ease, border-color 0.3s ease, background-color 0.3s ease, box-shadow 0.3s ease;
}
.brand-card:hover {
  transform: translateY(-4px);
  border-color: rgba(247, 147, 26, 0.5);
  background-color: rgba(46, 49, 62, 0.9);
  box-shadow: 0 12px 30px -8px rgba(247, 147, 26, 0.35);
}
.brand-card img {
  height: 56px;
  width: auto;
  object-fit: contain;
  transition: transform 0.3s ease;
}
.brand-card:hover img {
  transform: scale(1.08);
}
.brand-card span {
  font-size: 0.85rem;
  font-weight: 600;
  color: #d1d5db;
}

.social-card {
  width: 64px;
  height: 64px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background-color: rgba(34, 37, 49, 0.7);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 18px;
  transition: transform 0.3s ease, border-color 0.3s ease, background-color 0.3s ease, box-shadow 0.3s ease;
}
.social-card:hover {
  transform: translateY(-4px) scale(1.05);
  border-color: rgba(247, 147, 26, 0.6);
  background-color: rgba(46, 49, 62, 1);
  box-shadow: 0 10px 24px -6px rgba(247, 147, 26, 0.45);
}
.social-card img {
  width: 32px;
  height: 32px;
  object-fit: contain;
  transition: filter 0.3s ease;
}

/* Primary CTA button */
.btn-primary {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding: 0.9rem 2.2rem;
  background: linear-gradient(135deg, #F7931A, #f7a93a);
  color: #fff;
  font-weight: 700;
  border-radius: 9999px;
  box-shadow: 0 14px 30px -8px rgba(247, 147, 26, 0.55);
  transition: transform 0.25s ease, box-shadow 0.25s ease, filter 0.25s ease;
  cursor: pointer;
}
.btn-primary:hover {
  transform: translateY(-2px) scale(1.02);
  box-shadow: 0 18px 38px -8px rgba(247, 147, 26, 0.7);
  filter: brightness(1.05);
}
.btn-primary .arrow {
  transition: transform 0.25s ease;
}
.btn-primary:hover .arrow {
  transform: translateX(4px);
}

/* Scroll hint */
.scroll-hint {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  color: rgba(255, 255, 255, 0.5);
  font-size: 0.8rem;
  letter-spacing: 0.15em;
  text-transform: uppercase;
}
.scroll-hint .dot {
  width: 6px;
  height: 6px;
  border-radius: 9999px;
  background-color: #F7931A;
  animation: pulse 1.6s infinite ease-in-out;
}
@keyframes pulse {
  0%, 100% { opacity: 0.3; transform: scale(0.8); }
  50% { opacity: 1; transform: scale(1.4); }
}

/* Back-to-top */
.back-to-top {
  position: fixed;
  right: 24px;
  bottom: 24px;
  width: 48px;
  height: 48px;
  background: linear-gradient(135deg, #F7931A, #f7a93a);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.3s ease, transform 0.3s ease;
  z-index: 999;
  box-shadow: 0 10px 24px -6px rgba(247, 147, 26, 0.5);
}
.back-to-top.show {
  opacity: 1;
  pointer-events: auto;
}
.back-to-top:hover {
  transform: translateY(-3px);
}
.back-to-top img {
  width: 22px;
  height: 22px;
}

/* Block card — on-chain proof (compact pill) */
.block-card {
  display: inline-flex;
  align-items: center;
  gap: 0.85rem;
  padding: 0.55rem 1rem 0.55rem 0.85rem;
  background: rgba(34, 37, 49, 0.65);
  border: 1px solid rgba(247, 147, 26, 0.28);
  border-radius: 9999px;
  text-decoration: none;
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  transition: transform 0.3s ease, border-color 0.3s ease, box-shadow 0.3s ease, background-color 0.3s ease;
}
.block-card:hover {
  transform: translateY(-2px);
  border-color: rgba(247, 147, 26, 0.65);
  background: rgba(46, 49, 62, 0.85);
  box-shadow: 0 14px 32px -10px rgba(247, 147, 26, 0.4);
}
.block-card-head {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  padding-right: 0.85rem;
  border-right: 1px solid rgba(255, 255, 255, 0.1);
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: #F7931A;
}
.block-card-icon {
  flex-shrink: 0;
}
.block-card-body {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.9rem;
  color: #e5e7eb;
}
.block-card-hash {
  font-family: "Space Grotesk", "Poppins", sans-serif;
  font-weight: 700;
  color: #fff;
  letter-spacing: -0.01em;
}
.block-card-sep {
  color: rgba(255, 255, 255, 0.3);
}
.block-card-date {
  color: #9ca3af;
}
.block-card-arrow {
  color: rgba(255, 255, 255, 0.5);
  font-size: 0.85rem;
  margin-left: 0.35rem;
  transition: color 0.25s ease, transform 0.25s ease;
}
.block-card:hover .block-card-arrow {
  color: #F7931A;
  transform: translate(2px, -2px);
}

/* Step cards (How to Buy) */
.step-card {
  position: relative;
  background-color: rgba(34, 37, 49, 0.7);
  border: 1px solid rgba(255, 255, 255, 0.06);
  border-radius: 20px;
  padding: 1.75rem 1.5rem;
  transition: transform 0.3s ease, border-color 0.3s ease, background-color 0.3s ease;
}
.step-card:hover {
  transform: translateY(-4px);
  border-color: rgba(247, 147, 26, 0.4);
  background-color: rgba(46, 49, 62, 0.9);
}
.step-number {
  display: inline-block;
  font-family: "Space Grotesk", sans-serif;
  font-size: 0.85rem;
  font-weight: 700;
  letter-spacing: 0.15em;
  color: #F7931A;
  padding: 0.3rem 0.7rem;
  border: 1px solid rgba(247, 147, 26, 0.35);
  border-radius: 9999px;
  background-color: rgba(247, 147, 26, 0.08);
}

/* Check bullet list */
.check-bullet {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 22px;
  height: 22px;
  flex-shrink: 0;
  background: linear-gradient(135deg, #F7931A, #f7a93a);
  color: #fff;
  border-radius: 9999px;
  font-size: 0.75rem;
  font-weight: 700;
  margin-top: 2px;
}

/* Contract address bar */
.contract-bar {
  display: inline-flex;
  align-items: center;
  gap: 0.75rem;
  padding: 0.65rem 0.75rem 0.65rem 1rem;
  background-color: rgba(34, 37, 49, 0.85);
  border: 1px solid rgba(247, 147, 26, 0.25);
  border-radius: 9999px;
  max-width: 100%;
}
.contract-bar--full {
  width: 100%;
  max-width: 100%;
  border-radius: 14px;
  justify-content: space-between;
  flex-wrap: wrap;
}
.contract-label {
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: #F7931A;
}
.contract-value {
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  font-size: 0.8rem;
  color: #e5e7eb;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  max-width: 280px;
}
.contract-bar--full .contract-value {
  max-width: 100%;
  white-space: normal;
  word-break: break-all;
}
.contract-copy {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  padding: 0.4rem 0.85rem;
  background-color: rgba(247, 147, 26, 0.12);
  color: #F7931A;
  border-radius: 9999px;
  font-size: 0.78rem;
  font-weight: 600;
  transition: background-color 0.2s ease, color 0.2s ease, transform 0.2s ease;
  border: none;
  cursor: pointer;
}
.contract-copy:hover {
  background-color: #F7931A;
  color: #fff;
}
.contract-copy.copied {
  background-color: #22c55e;
  color: #fff;
}

/* Mobile menu */
.mobile-menu {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.3s ease;
}
.mobile-menu.open {
  max-height: 400px;
}

/* Safe area for iOS notches in fixed nav */
.site-nav .container {
  padding-left: max(1rem, env(safe-area-inset-left));
  padding-right: max(1rem, env(safe-area-inset-right));
}

/* ===== Mobile tweaks ===== */
@media (max-width: 640px) {
  /* Hero tag: single outer pill, single line, fluid scaling so it always fits */
  .hero-tag {
    flex-wrap: nowrap;
    justify-content: center;
    column-gap: clamp(0.35rem, 1.2vw, 0.65rem);
    padding: 0.4rem clamp(0.6rem, 2.5vw, 0.9rem) 0.4rem clamp(0.35rem, 1.8vw, 0.45rem);
    border-radius: 9999px;
    white-space: nowrap;
    max-width: 100%;
  }
  .hero-tag-stamp {
    font-size: clamp(0.55rem, 2.1vw, 0.72rem);
    padding: clamp(0.18rem, 0.6vw, 0.25rem) clamp(0.45rem, 1.8vw, 0.7rem);
    letter-spacing: 0.12em;
    flex-shrink: 0;
  }
  .hero-tag-main,
  .hero-tag-since {
    font-size: clamp(0.55rem, 2.1vw, 0.78rem);
    letter-spacing: 0.06em;
    flex-shrink: 0;
  }
  .hero-tag-divider {
    height: 12px;
    flex-shrink: 0;
  }

  /* Block card: stack head + body vertically, drop the vertical divider */
  .block-card {
    flex-direction: column;
    align-items: flex-start;
    gap: 0.5rem;
    border-radius: 16px;
    padding: 0.75rem 1rem;
    max-width: 100%;
  }
  .block-card-head {
    border-right: none;
    padding-right: 0;
    padding-bottom: 0.25rem;
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
    width: 100%;
  }
  .block-card-body {
    flex-wrap: wrap;
    font-size: 0.85rem;
  }

  /* Hero title: prevent "GENERATIONAL" from overflowing on narrow phones */
  h1.display-font {
    font-size: 2.5rem;
    line-height: 1.05;
  }

  /* Cube: scale slightly down on tiny screens */
  .scene {
    width: 200px;
    height: 200px;
  }
  .cube .face {
    width: 200px;
    height: 200px;
  }
  .cube .face.front  { transform: translateZ(100px); }
  .cube .face.back   { transform: rotateY(180deg) translateZ(100px); }
  .cube .face.right  { transform: rotateY(90deg)  translateZ(100px); }
  .cube .face.left   { transform: rotateY(-90deg) translateZ(100px); }
  .cube .face.top    { transform: rotateX(90deg)  translateZ(100px); }
  .cube .face.bottom { transform: rotateX(-90deg) translateZ(100px); }

  /* Contract bar in footer: stack neatly */
  .contract-bar--full {
    flex-direction: column;
    align-items: stretch;
    gap: 0.6rem;
    padding: 0.85rem 1rem;
  }
  .contract-bar--full .contract-copy {
    align-self: flex-end;
  }
  .contract-value {
    font-size: 0.72rem;
  }

  /* Brand cards: full-row width feels better than 160px min */
  .brand-card {
    min-width: 0;
    width: 100%;
    flex-direction: row;
    justify-content: flex-start;
    padding: 1rem 1.25rem;
    gap: 1rem;
  }
  .brand-card img {
    height: 40px;
  }

  /* Nav: a bit tighter, touch-friendly mobile menu */
  .site-nav .container {
    padding-top: 0.65rem;
    padding-bottom: 0.65rem;
  }
  #mobile-menu .nav-link {
    padding: 0.65rem 0;
    font-size: 1rem;
  }

  /* Stat cards: prevent number+icon from breaking awkwardly */
  .stat-card .display-font.text-4xl {
    font-size: 2rem;
  }

  /* NFT pills: full-row friendly */
  #nft .flex.flex-wrap {
    gap: 0.5rem;
  }

  /* Section padding */
  section,
  header#home {
    scroll-margin-top: 60px;
  }

  /* Back-to-top: respect bottom safe area */
  .back-to-top {
    right: 16px;
    bottom: calc(16px + env(safe-area-inset-bottom, 0px));
  }
}

/* Very narrow phones (<= 380px) */
@media (max-width: 380px) {
  h1.display-font {
    font-size: 2.2rem;
  }
  .hero-tag-stamp {
    font-size: 0.66rem;
    padding: 0.22rem 0.55rem;
  }
  .block-card-hash {
    font-size: 0.95rem;
  }
}
