@import "tailwindcss" source(none);
@source "../src";
@import "tw-animate-css";

@custom-variant dark (&:is(.dark *));

@theme inline {
  --font-sans: "Inter", ui-sans-serif, system-ui, sans-serif;

  --radius-sm: calc(var(--radius) - 4px);
  --radius-md: calc(var(--radius) - 2px);
  --radius-lg: var(--radius);
  --radius-xl: calc(var(--radius) + 4px);
  --radius-2xl: calc(var(--radius) + 8px);
  --radius-3xl: calc(var(--radius) + 12px);

  --color-background: var(--background);
  --color-foreground: var(--foreground);
  --color-card: var(--card);
  --color-card-foreground: var(--card-foreground);
  --color-popover: var(--popover);
  --color-popover-foreground: var(--popover-foreground);
  --color-primary: var(--primary);
  --color-primary-foreground: var(--primary-foreground);
  --color-secondary: var(--secondary);
  --color-secondary-foreground: var(--secondary-foreground);
  --color-muted: var(--muted);
  --color-muted-foreground: var(--muted-foreground);
  --color-accent: var(--accent);
  --color-accent-foreground: var(--accent-foreground);
  --color-destructive: var(--destructive);
  --color-destructive-foreground: var(--destructive-foreground);
  --color-border: var(--border);
  --color-input: var(--input);
  --color-ring: var(--ring);
  --color-ink: var(--ink);
  --color-ink-2: var(--ink-2);
  --color-ink-3: var(--ink-3);
  --color-ink-4: var(--ink-4);

  --color-surface: var(--surface);
  --color-surface-2: var(--surface-2);
  --color-hairline: var(--hairline);

  --shadow-soft: 0 1px 2px oklch(0 0 0 / 0.04), 0 8px 24px -12px oklch(0 0 0 / 0.08);
  --shadow-elev: 0 2px 4px oklch(0 0 0 / 0.05), 0 24px 60px -20px oklch(0 0 0 / 0.15);
  --shadow-glow: 0 12px 40px -10px oklch(0.66 0.24 32 / 0.35);
}

:root {
  --radius: 0.875rem;

  /* Brand */
  --brand: oklch(0.66 0.24 32); /* #FF4308 */
  --brand-ink: oklch(0.55 0.24 32);
  --brand-tint: oklch(0.97 0.03 32);

  /* Neutrals */
  --background: oklch(1 0 0);
  --foreground: oklch(0.16 0 0);
  --ink: oklch(0.11 0 0);
  --ink-2: oklch(0.35 0 0);
  --ink-3: oklch(0.55 0 0);
  --ink-4: oklch(0.7 0 0);

  --surface: oklch(0.985 0 0);
  --surface-2: oklch(0.965 0 0);
  --hairline: oklch(0.92 0 0);

  --card: oklch(1 0 0);
  --card-foreground: oklch(0.16 0 0);
  --popover: oklch(1 0 0);
  --popover-foreground: oklch(0.16 0 0);

  --primary: var(--brand);
  --primary-foreground: oklch(1 0 0);
  --secondary: oklch(0.965 0 0);
  --secondary-foreground: oklch(0.16 0 0);
  --muted: oklch(0.965 0 0);
  --muted-foreground: oklch(0.45 0 0);
  --accent: oklch(0.965 0 0);
  --accent-foreground: oklch(0.16 0 0);
  --destructive: oklch(0.6 0.22 25);
  --destructive-foreground: oklch(1 0 0);
  --border: oklch(0.92 0 0);
  --input: oklch(0.92 0 0);
  --ring: var(--brand);
}

.dark {
  --background: oklch(0.14 0 0);
  --foreground: oklch(0.98 0 0);
  --ink: oklch(0.98 0 0);
  --ink-2: oklch(0.75 0 0);
  --ink-3: oklch(0.62 0 0);
  --ink-4: oklch(0.78 0 0);
  --surface: oklch(0.18 0 0);
  --surface-2: oklch(0.22 0 0);

  --hairline: oklch(0.28 0 0);
  --card: oklch(0.18 0 0);
  --card-foreground: oklch(0.98 0 0);
  --popover: oklch(0.18 0 0);
  --popover-foreground: oklch(0.98 0 0);
  --primary: var(--brand);
  --primary-foreground: oklch(1 0 0);
  --secondary: oklch(0.24 0 0);
  --secondary-foreground: oklch(0.98 0 0);
  --muted: oklch(0.24 0 0);
  --muted-foreground: oklch(0.7 0 0);
  --accent: oklch(0.24 0 0);
  --accent-foreground: oklch(0.98 0 0);
  --border: oklch(0.28 0 0);
  --input: oklch(0.28 0 0);
  --ring: var(--brand);
}

@layer base {
  * {
    border-color: var(--color-border);
  }
  html {
    font-family: var(--font-sans);
    -webkit-font-smoothing: antialiased;
    text-rendering: optimizeLegibility;
  }
  body {
    background-color: var(--color-background);
    color: var(--color-foreground);
    font-feature-settings: "cv02", "cv03", "cv04", "ss01";
  }
  ::selection {
    background: var(--brand);
    color: white;
  }
}

/* ---------- Utilities ---------- */

@utility container-airfis {
  width: 100%;
  margin-inline: auto;
  padding-inline: 1.25rem;
  max-width: 1240px;
  @media (min-width: 768px) {
    padding-inline: 2rem;
  }
}

@utility eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.75rem;
  font-weight: 500;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--brand);
}

@utility h-display {
  font-size: clamp(2.25rem, 4.2vw, 3.5rem);
  line-height: 1.4;
  letter-spacing: -0.03em;
  font-weight: 700;
}
@utility h-hero {
  font-size: clamp(2rem, 4.6vw, 4rem);
  line-height: 1.4;
  letter-spacing: -0.03em;
  font-weight: 600;
}
@utility h-section {
  font-size: clamp(1.75rem, 3.2vw, 2.75rem);
  line-height: 1.4;
  letter-spacing: -0.025em;
  font-weight: 700;
}

@utility hairline {
  border-top: 1px solid var(--hairline);
}

@utility glass-card {
  background: color-mix(in oklab, white 70%, transparent);
  backdrop-filter: blur(14px) saturate(1.2);
  border: 1px solid var(--hairline);
  border-radius: var(--radius-2xl);
  box-shadow: var(--shadow-soft);
}

@utility surface-card {
  background: var(--card);
  border: 1px solid var(--hairline);
  border-radius: var(--radius-2xl);
  transition:
    transform 0.4s cubic-bezier(0.2, 0.7, 0.2, 1),
    box-shadow 0.4s cubic-bezier(0.2, 0.7, 0.2, 1),
    border-color 0.3s ease;
}
@utility surface-card-hover {
  &:hover {
    transform: translateY(-3px);
    box-shadow: var(--shadow-elev);
    border-color: color-mix(in oklab, var(--brand) 25%, var(--hairline));
  }
}

@utility btn-brand {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  height: 34px;
  padding-inline: 0.75rem;
  border-radius: 999px;
  background: var(--brand);
  color: white;
  font-weight: 500;
  font-size: 0.9375rem;
  letter-spacing: -0.01em;
  transition:
    transform 0.2s ease,
    box-shadow 0.3s ease,
    filter 0.2s ease;
  box-shadow: 0 8px 24px -10px oklch(0.66 0.24 32 / 0.55);
  &:hover {
    transform: translateY(-1px);
    box-shadow: var(--shadow-glow);
    filter: brightness(1.03);
  }
}
@utility btn-ghost {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  height: 34px;
  padding-inline: 0.75rem;
  border-radius: 999px;
  background: transparent;
  color: var(--ink);
  border: 1px solid var(--hairline);
  font-weight: 500;
  font-size: 0.9375rem;
  transition:
    background 0.2s ease,
    border-color 0.2s ease;
  &:hover {
    background: var(--surface);
    border-color: color-mix(in oklab, var(--ink) 20%, var(--hairline));
  }
}
@utility btn-dark {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  height: 34px;
  padding-inline: 0.75rem;
  border-radius: 999px;
  background: var(--ink);
  color: white;
  font-weight: 500;
  font-size: 0.9375rem;
  transition:
    transform 0.2s ease,
    background 0.2s ease;
  &:hover {
    transform: translateY(-1px);
    background: black;
  }
}

@utility tick {
  &::before {
    content: "";
    width: 18px;
    height: 18px;
    border-radius: 999px;
    background: var(--brand-tint);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23FF4308' stroke-width='3' stroke-linecap='round' stroke-linejoin='round'><polyline points='20 6 9 17 4 12'/></svg>");
    background-size: 12px 12px;
    background-repeat: no-repeat;
    background-position: center;
    flex-shrink: 0;
  }
}

/* ---------- Keyframes ---------- */

@keyframes fade-up {
  from {
    opacity: 0;
    transform: translateY(16px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}
@keyframes float-y {
  0%,
  100% {
    transform: translateY(0);
  }
  50% {
    transform: translateY(-10px);
  }
}
@keyframes marquee {
  from {
    transform: translateX(0);
  }
  to {
    transform: translateX(-50%);
  }
}
@keyframes pulse-dot {
  0%,
  100% {
    box-shadow: 0 0 0 0 oklch(0.66 0.24 32 / 0.55);
  }
  70% {
    box-shadow: 0 0 0 18px oklch(0.66 0.24 32 / 0);
  }
}
@keyframes route-dash {
  to {
    stroke-dashoffset: -120;
  }
}
@keyframes car-move {
  0% {
    offset-distance: 0%;
  }
  100% {
    offset-distance: 100%;
  }
}
@keyframes shimmer {
  0% {
    background-position: -200% 0;
  }
  100% {
    background-position: 200% 0;
  }
}

@utility animate-fade-up {
  animation: fade-up 0.9s cubic-bezier(0.2, 0.7, 0.2, 1) both;
}
@utility animate-float {
  animation: float-y 6s ease-in-out infinite;
}
@utility animate-marquee {
  animation: marquee 40s linear infinite;
}
@utility pulse-ring {
  animation: pulse-dot 2.2s cubic-bezier(0.4, 0, 0.6, 1) infinite;
}

/* Reveal on scroll */
@utility reveal {
  opacity: 0;
  transform: translateY(24px);
  transition:
    opacity 0.9s cubic-bezier(0.2, 0.7, 0.2, 1),
    transform 0.9s cubic-bezier(0.2, 0.7, 0.2, 1);
}
@utility reveal-in {
  opacity: 1;
  transform: translateY(0);
}

@keyframes beam-sweep {
  0% {
    transform: translateX(-120%) skewX(-12deg);
    opacity: 0;
  }
  35% {
    opacity: 0.55;
  }
  100% {
    transform: translateX(220%) skewX(-12deg);
    opacity: 0;
  }
}
@keyframes particle-rise {
  0% {
    transform: translateY(0) scale(1);
    opacity: 0;
  }
  20% {
    opacity: 0.8;
  }
  100% {
    transform: translateY(-140px) scale(0.6);
    opacity: 0;
  }
}
@keyframes glow-pulse {
  0%,
  100% {
    box-shadow: 0 0 0 0 rgba(255, 67, 8, 0.35);
  }
  50% {
    box-shadow: 0 0 36px 4px rgba(255, 67, 8, 0.28);
  }
}

@utility animate-beam {
  animation: beam-sweep 7s ease-in-out infinite;
}
@utility animate-particle {
  animation: particle-rise 9s linear infinite;
}
@utility animate-glow {
  animation: glow-pulse 3.2s ease-in-out infinite;
}
@utility btn-glow {
  background-image: linear-gradient(135deg, #ff6a38, #ff4308);
  color: #fff;
  border-radius: 9999px;
  height: 34px;
  padding-inline: 0.75rem;
  font-weight: 600;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  transition:
    transform 0.25s ease,
    box-shadow 0.25s ease;
  box-shadow: 0 10px 30px -12px rgba(255, 67, 8, 0.6);
}
@utility btn-glow-hover {
  transform: translateY(-2px) scale(1.02);
  box-shadow: 0 18px 50px -14px rgba(255, 67, 8, 0.75);
}
