@import "./fonts.css";
@import "tailwindcss";
@import "tw-animate-css";

@theme {
  /* ITTrack Professional Theme - Clean Blue & White */
  --color-primary: #0345bf;
  --color-primary-foreground: #ffffff;
  
  --color-secondary: #f8fafc;
  --color-secondary-foreground: #0345bf;
  
  --color-accent: #0345bf;
  --color-accent-foreground: #ffffff;
  
  --color-muted: #f1f5f9;
  --color-muted-foreground: #64748b;
  
  --color-background: #ffffff;
  --color-foreground: #1e293b;
  
  --color-card: #ffffff;
  --color-card-foreground: #1e293b;
  
  --color-popover: #ffffff;
  --color-popover-foreground: #1e293b;
  
  --color-border: #e2e8f0;
  --color-input: #e2e8f0;
  --color-ring: #0345bf;
  
  --color-destructive: #dc2626;
  --color-destructive-foreground: #ffffff;
  
  --radius-sm: 0.5rem;
  --radius-md: 0.75rem;
  --radius-lg: 1rem;
  --radius-xl: 1.5rem;
}

@plugin "@tailwindcss/typography";

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

@theme inline {
  --font-sans:
    "Poppins", "Inter", ui-sans-serif, system-ui, sans-serif, "Apple Color Emoji",
    "Segoe UI Emoji", "Segoe UI Symbol", "Noto Color Emoji";
  --font-mono:
    "Geist Mono", ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas,
    "Liberation Mono", "Courier New", monospace;
  --font-serif:
    "Noto Serif", ui-serif, Georgia, Cambria, "Times New Roman", Times, serif;

  --radius-sm: calc(var(--radius) - 4px);
  --radius-md: calc(var(--radius) - 2px);
  --radius-lg: var(--radius);
  --radius-xl: calc(var(--radius) + 4px);
  --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-border: var(--border);
  --color-input: var(--input);
  --color-ring: var(--ring);
  --color-chart-1: var(--chart-1);
  --color-chart-2: var(--chart-2);
  --color-chart-3: var(--chart-3);
  --color-chart-4: var(--chart-4);
  --color-chart-5: var(--chart-5);
  --color-sidebar: var(--sidebar);
  --color-sidebar-foreground: var(--sidebar-foreground);
  --color-sidebar-primary: var(--sidebar-primary);
  --color-sidebar-primary-foreground: var(--sidebar-primary-foreground);
  --color-sidebar-accent: var(--sidebar-accent);
  --color-sidebar-accent-foreground: var(--sidebar-accent-foreground);
  --color-sidebar-border: var(--sidebar-border);
  --color-sidebar-ring: var(--sidebar-ring);
}

:root {
  --radius: 0.75rem;
  --background: 0 0% 100%;
  --foreground: 215 25% 27%;
  --card: 0 0% 100%;
  --card-foreground: 215 25% 27%;
  --popover: 0 0% 100%;
  --popover-foreground: 215 25% 27%;
  --primary: 218 97% 38%;
  --primary-foreground: 0 0% 100%;
  --secondary: 210 40% 98%;
  --secondary-foreground: 218 97% 38%;
  --muted: 210 40% 96%;
  --muted-foreground: 215 16% 47%;
  --accent: 218 97% 38%;
  --accent-foreground: 0 0% 100%;
  --destructive: 0 84% 60%;
  --destructive-foreground: 0 0% 98%;
  --border: 214 32% 91%;
  --input: 214 32% 91%;
  --ring: 218 97% 38%;
  --chart-1: 218 97% 38%;
  --chart-2: 173 58% 39%;
  --chart-3: 197 37% 24%;
  --chart-4: 43 74% 66%;
  --chart-5: 27 87% 67%;
}

.dark {
  --background: 222 47% 11%;
  --foreground: 210 40% 98%;
  --card: 222 47% 11%;
  --card-foreground: 210 40% 98%;
  --popover: 222 47% 11%;
  --popover-foreground: 210 40% 98%;
  --primary: 217 91% 60%;
  --primary-foreground: 222 47% 11%;
  --secondary: 217 33% 17%;
  --secondary-foreground: 210 40% 98%;
  --muted: 217 33% 17%;
  --muted-foreground: 215 20% 65%;
  --accent: 217 33% 17%;
  --accent-foreground: 210 40% 98%;
  --destructive: 0 62% 30%;
  --destructive-foreground: 210 40% 98%;
  --border: 217 33% 17%;
  --input: 217 33% 17%;
  --ring: 217 91% 60%;
  --chart-1: 220 70% 50%;
  --chart-2: 160 60% 45%;
  --chart-3: 30 80% 55%;
  --chart-4: 280 65% 60%;
  --chart-5: 340 75% 55%;
}

@layer base {
  * {
    @apply border-border outline-ring/50;
  }
  body {
    @apply bg-background text-foreground;
  }
  /* Override font-medium to use 600 instead of 500 since we removed font-weight 500 */
  .font-medium {
    font-weight: 600;
  }
}

/* Custom Loading & Animation Classes */
@layer utilities {
  .animate-fade-in {
    animation: fadeIn 0.3s ease-in-out;
  }

  @keyframes fadeIn {
    from {
      opacity: 0;
      transform: translateY(10px);
    }
    to {
      opacity: 1;
      transform: translateY(0);
    }
  }

  .animate-pulse-slow {
    animation: pulse 3s cubic-bezier(0.4, 0, 0.6, 1) infinite;
  }

  .animate-shimmer {
    background: linear-gradient(
      90deg,
      rgba(255, 255, 255, 0) 0%,
      rgba(255, 255, 255, 0.3) 50%,
      rgba(255, 255, 255, 0) 100%
    );
    background-size: 200% 100%;
    animation: shimmer 2s infinite;
  }

  @keyframes shimmer {
    0% {
      background-position: -200% 0;
    }
    100% {
      background-position: 200% 0;
    }
  }

  .animate-scale-in {
    animation: scaleIn 0.3s ease-out;
  }

  @keyframes scaleIn {
    from {
      opacity: 0;
      transform: scale(0.95);
    }
    to {
      opacity: 1;
      transform: scale(1);
    }
  }

  /* Pulse Ring Animation for CTA buttons */
  @keyframes pulseRing {
    0% {
      transform: scale(0.33);
      opacity: 0;
    }
    80%, 100% {
      opacity: 0;
    }
    40% {
      opacity: 0.4;
    }
  }

  /* Utility class for pulse-ring effect */
  .pulse-ring {
    position: relative;
  }
  .pulse-ring::before {
    content: "";
    position: absolute;
    border: 3px solid transparent;
    border-radius: 50%;
    top: -0.5rem;
    left: -0.5rem;
    width: calc(100% + 1rem);
    height: calc(100% + 1rem);
    border-color: var(--color-primary);
    animation: pulseRing 1.5s cubic-bezier(0.66, 0, 0, 1) infinite;
    pointer-events: none;
    opacity: 0;
    box-sizing: border-box;
  }

  /* Micro-interactions */
  .hover-lift {
    transition: transform 0.3s ease, box-shadow 0.3s ease;
  }

  .hover-lift:hover {
    transform: translateY(-4px);
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.1);
  }

  .hover-scale {
    transition: transform 0.2s ease;
  }

  .hover-scale:hover {
    transform: scale(1.02);
  }

  .icon-bounce:hover {
    animation: iconBounce 0.6s ease;
  }

  @keyframes iconBounce {
    0%, 100% {
      transform: translateY(0);
    }
    50% {
      transform: translateY(-6px);
    }
  }

  .icon-spin-slow:hover {
    animation: iconSpin 2s linear infinite;
  }

  @keyframes iconSpin {
    from {
      transform: rotate(0deg);
    }
    to {
      transform: rotate(360deg);
    }
  }

  .icon-pulse:hover {
    animation: iconPulse 0.6s ease-in-out;
  }

  @keyframes iconPulse {
    0%, 100% {
      transform: scale(1);
    }
    50% {
      transform: scale(1.1);
    }
  }

  /* Smooth scrolling */
  html {
    scroll-behavior: smooth;
  }
}