@import "tailwindcss";

@theme inline {
  --font-sans: "Helvetica Neue", Helvetica, Arial, sans-serif;
  --font-heading: var(--font-heading), "IBM Plex Mono", monospace;

  --color-background: #fcf9f8;
  --color-on-background: #1b1c1c;
  --color-surface: #fcf9f8;
  --color-on-surface: #1b1c1c;
  --color-surface-dim: #dcd9d9;
  --color-surface-bright: #fcf9f8;
  --color-surface-container-lowest: #ffffff;
  --color-surface-container-low: #f6f3f2;
  --color-surface-container: #f0eded;
  --color-surface-container-high: #eae7e7;
  --color-surface-container-highest: #e4e2e1;
  --color-surface-variant: #e4e2e1;
  --color-on-surface-variant: #454558;
  --color-primary: #0000ff;
  --color-on-primary: #ffffff;
  --color-primary-container: #0000ff;
  --color-on-primary-container: #b3b7ff;
  --color-secondary: #5f5e5e;
  --color-on-secondary: #ffffff;
  --color-secondary-container: #e4e2e1;
  --color-on-secondary-container: #656464;
  --color-tertiary: #720001;
  --color-on-tertiary: #ffffff;
  --color-error: #ba1a1a;
  --color-on-error: #ffffff;
  --color-outline: #757589;
  --color-outline-variant: #c5c4db;
  --color-inverse-surface: #303030;
  --color-inverse-on-surface: #f3f0ef;
  --color-inverse-primary: #bec2ff;
  --color-dark-bg: #282828;
}

html {
  scroll-behavior: smooth;
}

/* Scroll snap for section-by-section navigation */
.snap-container {
  scroll-snap-type: y proximity;
}

.snap-section {
  scroll-snap-align: start;
}

/* Prevent scroll-snap from interfering with GSAP pinned sections */
.pin-spacer {
  scroll-snap-align: none !important;
}

body {
  font-family: var(--font-sans);
  background: linear-gradient(90deg, rgba(238,238,238,0.2) 0%, rgba(238,238,238,0.2) 100%), url('/images/body-texture.webp'), var(--color-background);
  background-attachment: fixed;
  background-size: cover;
  color: var(--color-on-background);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: hidden;
}

.text-huge {
  font-size: clamp(2rem, 8vw, 8rem);
  line-height: 0.9;
  letter-spacing: -0.04em;
}

/* Performance optimizations */
img {
  decoding: async;
}

/* Hero entrance animations — headline uses slide-only (no opacity)
   so LCP fires immediately; CTAs fade in after. */
@keyframes hero-slide-up {
  from {
    transform: translateY(40px);
  }
  to {
    transform: translateY(0);
  }
}

@keyframes hero-fade-up {
  from {
    opacity: 0;
    transform: translateY(30px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.hero-slide-up {
  animation: hero-slide-up 0.8s cubic-bezier(0.33, 1, 0.68, 1) both;
}

.hero-fade-up {
  animation: hero-fade-up 0.6s cubic-bezier(0.33, 1, 0.68, 1) both;
}

.hero-fade-up-delay-1 {
  animation-delay: 0.5s;
}

.hero-fade-up-delay-2 {
  animation-delay: 0.65s;
}

.hero-fade-up-delay-3 {
  animation-delay: 0.8s;
}

/* Scroll-down cue animation */
@keyframes scroll-down {
  0%, 100% {
    transform: translateY(0);
    opacity: 1;
  }
  50% {
    transform: translateY(8px);
    opacity: 0.4;
  }
}

.animate-scroll-down {
  animation: scroll-down 1.8s ease-in-out infinite;
}

/* Skeleton wave animation */
@keyframes wave {
  0% {
    background-position: -1000px 0;
  }
  100% {
    background-position: 1000px 0;
  }
}

.skeleton-wave {
  background: linear-gradient(
    90deg,
    var(--color-surface-container) 0%,
    var(--color-surface-container-high) 50%,
    var(--color-surface-container) 100%
  );
  background-size: 200% 100%;
  animation: wave 2s infinite;
}



/* Prevent layout shift for lazy-loaded images */
img {
  aspect-ratio: auto;
}

/* Optimize animations for reduced motion preference */
@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }

  .skeleton-wave {
    animation: none;
    background: var(--color-surface-container-high);
  }
}

/* Hide scrollbar for horizontal carousels */
.scrollbar-hide {
  -ms-overflow-style: none;
  scrollbar-width: none;
}
.scrollbar-hide::-webkit-scrollbar {
  display: none;
}

/* Custom cursor - hide native cursor on desktop */
@media (pointer: fine) and (prefers-reduced-motion: no-preference) {
  html,
  body {
    cursor: none;
  }
  a,
  button,
  [role="button"],
  [data-cursor] {
    cursor: none;
  }
}

/* Hug state glow */
.cursor-hugged {
  box-shadow: 0 0 25px rgba(0, 1, 187, 0.25);
}

