/* ==========================================================================
   Crumbless Animation System
   Subtle, polished animations for dark-themed UI
   ========================================================================== */

/* CSS Variables for Animations
   ========================================================================== */
:root {
  /* Duration tokens */
  --duration-fast: 150ms;
  --duration-normal: 200ms;
  --duration-slow: 300ms;

  /* Easing functions */
  --ease-out: cubic-bezier(0.33, 1, 0.68, 1);
  --ease-spring: cubic-bezier(0.34, 1.56, 0.64, 1);

  /* Glow shadows */
  --shadow-glow-violet: 0 4px 20px -4px rgba(139, 92, 246, 0.4);
  --shadow-glow-emerald: 0 4px 20px -4px rgba(16, 185, 129, 0.4);
}

/* Page Transitions
   ========================================================================== */

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

.animate-fade-up {
  animation: fadeUpIn 0.3s ease-out;
}

/* Skeleton Loaders
   ========================================================================== */

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

.skeleton-shimmer {
  background: linear-gradient(
    90deg,
    rgba(255, 255, 255, 0.03) 0%,
    rgba(255, 255, 255, 0.08) 50%,
    rgba(255, 255, 255, 0.03) 100%
  );
  background-size: 200% 100%;
  animation: shimmer 1.5s infinite;
}

/* Button Effects
   ========================================================================== */

.btn-glow {
  transition: all var(--duration-normal) var(--ease-out);
  box-shadow: 0 0 0 0 rgba(139, 92, 246, 0);
}

.btn-glow:hover {
  transform: translateY(-1px);
  box-shadow: var(--shadow-glow-violet);
}

.btn-glow:active {
  transform: translateY(0);
}

/* Gradient button variant for generate buttons */
.btn-glow-gradient {
  transition: all var(--duration-normal) var(--ease-out);
  box-shadow: 0 0 0 0 rgba(139, 92, 246, 0);
}

.btn-glow-gradient:hover {
  transform: translateY(-1px);
  box-shadow: var(--shadow-glow-violet), var(--shadow-glow-emerald);
}

.btn-glow-gradient:active {
  transform: translateY(0);
}

/* Card Effects
   ========================================================================== */

.card-lift {
  transition: all var(--duration-normal) var(--ease-out);
}

.card-lift:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 30px -8px rgba(0, 0, 0, 0.5);
}

/* Subtle lift for nested interactive elements */
.card-lift-subtle {
  transition: all var(--duration-fast) var(--ease-out);
}

.card-lift-subtle:hover {
  transform: translateY(-1px);
  box-shadow: 0 4px 16px -4px rgba(0, 0, 0, 0.4);
}

/* Utility Classes
   ========================================================================== */

/* Smooth transitions for interactive elements */
.transition-smooth {
  transition: all var(--duration-normal) var(--ease-out);
}

.transition-fast {
  transition: all var(--duration-fast) var(--ease-out);
}

.transition-slow {
  transition: all var(--duration-slow) var(--ease-out);
}

/* Spring animations for playful interactions */
.transition-spring {
  transition: all var(--duration-normal) var(--ease-spring);
}

/* Sticky Table Headers
   ========================================================================== */

/* Table container for scroll */
.table-container {
  max-height: calc(100vh - 250px);
  overflow-y: auto;
  border-radius: 1rem;
}

/* Sticky header positioning */
.table-sticky thead {
  position: sticky;
  top: 0;
  z-index: 10;
  background: #12121a;
}

.table-sticky thead tr {
  background: #12121a;
}

.table-sticky thead th {
  position: relative;
  background: inherit;
}

/* Subtle gradient shadow when scrolled */
.table-sticky thead::after {
  content: '';
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  height: 1px;
  background: linear-gradient(90deg,
    rgba(139, 92, 246, 0.3) 0%,
    rgba(16, 185, 129, 0.3) 100%
  );
  opacity: 0;
  transition: opacity var(--duration-normal) var(--ease-out);
}

.table-sticky.scrolled thead::after {
  opacity: 1;
}

/* Custom scrollbar for tables */
.table-container::-webkit-scrollbar {
  width: 8px;
}

.table-container::-webkit-scrollbar-track {
  background: rgba(255, 255, 255, 0.05);
  border-radius: 4px;
}

.table-container::-webkit-scrollbar-thumb {
  background: rgba(255, 255, 255, 0.1);
  border-radius: 4px;
  transition: background var(--duration-fast) var(--ease-out);
}

.table-container::-webkit-scrollbar-thumb:hover {
  background: rgba(255, 255, 255, 0.2);
}

/* A/B Test Visualizations
   ========================================================================== */

/* Progress bar animation for A/B test comparison bars */
@keyframes progressGrow {
  from {
    width: 0;
    opacity: 0;
  }
  to {
    opacity: 1;
  }
}

.ab-test-bar {
  animation: progressGrow 0.8s ease-out forwards;
}

/* Confidence ring animation */
@keyframes drawCircle {
  from {
    stroke-dasharray: 0 100;
  }
}

.confidence-ring {
  animation: drawCircle 1s ease-out forwards;
}

/* Pulse animation for winner badges */
@keyframes pulseGlow {
  0%, 100% {
    opacity: 1;
  }
  50% {
    opacity: 0.7;
  }
}

.winner-badge {
  animation: pulseGlow 2s ease-in-out infinite;
}

/* Number counter animation */
@keyframes countUp {
  from {
    opacity: 0;
    transform: translateY(10px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.stat-number {
  animation: countUp 0.5s ease-out forwards;
}

/* Stagger animation for multiple metrics */
.metric-item:nth-child(1) { animation-delay: 0ms; }
.metric-item:nth-child(2) { animation-delay: 100ms; }
.metric-item:nth-child(3) { animation-delay: 200ms; }
.metric-item:nth-child(4) { animation-delay: 300ms; }

/* Auth Page - Animated Gradient Mesh Background
   ========================================================================== */

@keyframes meshDrift1 {
  0%, 100% {
    transform: translate(0, 0) scale(1);
    opacity: 0.15;
  }
  25% {
    transform: translate(80px, -60px) scale(1.1);
    opacity: 0.2;
  }
  50% {
    transform: translate(-40px, 40px) scale(0.95);
    opacity: 0.12;
  }
  75% {
    transform: translate(60px, 80px) scale(1.05);
    opacity: 0.18;
  }
}

@keyframes meshDrift2 {
  0%, 100% {
    transform: translate(0, 0) scale(1);
    opacity: 0.1;
  }
  33% {
    transform: translate(-100px, 60px) scale(1.15);
    opacity: 0.15;
  }
  66% {
    transform: translate(70px, -80px) scale(0.9);
    opacity: 0.08;
  }
}

@keyframes meshDrift3 {
  0%, 100% {
    transform: translate(0, 0) scale(1) rotate(0deg);
    opacity: 0.08;
  }
  50% {
    transform: translate(50px, 50px) scale(1.2) rotate(30deg);
    opacity: 0.14;
  }
}

@keyframes meshDrift4 {
  0%, 100% {
    transform: translate(0, 0) scale(1);
    opacity: 0.06;
  }
  40% {
    transform: translate(-60px, -40px) scale(1.1);
    opacity: 0.12;
  }
  80% {
    transform: translate(40px, 60px) scale(0.95);
    opacity: 0.08;
  }
}

@keyframes meshPulse {
  0%, 100% {
    opacity: 0.04;
  }
  50% {
    opacity: 0.08;
  }
}

.auth-mesh-bg {
  position: fixed;
  inset: 0;
  overflow: hidden;
  pointer-events: none;
  z-index: 0;
}

.auth-mesh-bg::before {
  content: '';
  position: absolute;
  inset: 0;
  background:
    radial-gradient(ellipse 80% 60% at 50% 50%, rgba(139, 92, 246, 0.04) 0%, transparent 70%);
  animation: meshPulse 8s ease-in-out infinite;
}

.auth-mesh-blob {
  position: absolute;
  border-radius: 50%;
  filter: blur(80px);
  will-change: transform, opacity;
}

.auth-mesh-blob--violet-1 {
  width: 900px;
  height: 900px;
  top: -20%;
  left: -10%;
  background: radial-gradient(circle, rgba(139, 92, 246, 0.5) 0%, rgba(124, 58, 237, 0.2) 40%, transparent 70%);
  filter: blur(60px);
  animation: meshDrift1 20s ease-in-out infinite;
}

.auth-mesh-blob--emerald {
  width: 800px;
  height: 800px;
  bottom: -15%;
  right: -5%;
  background: radial-gradient(circle, rgba(16, 185, 129, 0.4) 0%, rgba(52, 211, 153, 0.15) 40%, transparent 70%);
  filter: blur(60px);
  animation: meshDrift2 25s ease-in-out infinite;
}

.auth-mesh-blob--violet-2 {
  width: 600px;
  height: 600px;
  top: 30%;
  right: 5%;
  background: radial-gradient(circle, rgba(124, 58, 237, 0.35) 0%, rgba(139, 92, 246, 0.1) 50%, transparent 70%);
  filter: blur(50px);
  animation: meshDrift3 18s ease-in-out infinite;
}

.auth-mesh-blob--violet-3 {
  width: 500px;
  height: 500px;
  bottom: 10%;
  left: 15%;
  background: radial-gradient(circle, rgba(167, 139, 250, 0.3) 0%, rgba(167, 139, 250, 0.08) 50%, transparent 70%);
  filter: blur(50px);
  animation: meshDrift4 22s ease-in-out infinite;
}

.auth-mesh-blob--accent {
  width: 400px;
  height: 400px;
  top: 10%;
  left: 45%;
  background: radial-gradient(circle, rgba(52, 211, 153, 0.25) 0%, transparent 60%);
  filter: blur(40px);
  animation: meshDrift1 30s ease-in-out infinite reverse;
}

/* Noise texture overlay for depth */
.auth-mesh-bg::after {
  content: '';
  position: absolute;
  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='noise'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(/%23noise)' opacity='0.03'/%3E%3C/svg%3E");
  opacity: 0.4;
  mix-blend-mode: overlay;
}

/* Auth form card with glassmorphism */
.auth-card {
  background: rgba(17, 17, 20, 0.7);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 1.5rem;
  box-shadow:
    0 0 0 1px rgba(255, 255, 255, 0.03),
    0 20px 50px -12px rgba(0, 0, 0, 0.5),
    0 0 80px -20px rgba(139, 92, 246, 0.08);
}

/* Subtle glow line at top of card */
.auth-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 10%;
  right: 10%;
  height: 1px;
  background: linear-gradient(
    90deg,
    transparent,
    rgba(139, 92, 246, 0.4) 30%,
    rgba(52, 211, 153, 0.3) 70%,
    transparent
  );
  border-radius: 1px;
}

/* Entrance animation for auth card */
@keyframes authCardEnter {
  from {
    opacity: 0;
    transform: translateY(20px) scale(0.98);
  }
  to {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

.auth-card-enter {
  animation: authCardEnter 0.6s cubic-bezier(0.33, 1, 0.68, 1) forwards;
}

/* Logo entrance */
@keyframes authLogoEnter {
  from {
    opacity: 0;
    transform: translateY(-10px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.auth-logo-enter {
  animation: authLogoEnter 0.4s ease-out forwards;
}

/* Landing Page Card Animations
   ========================================================================== */

/* Scroll-reveal: cards start hidden, animate in when visible */
.landing-card {
  opacity: 0;
  transform: translateY(40px) scale(0.95);
  transition: opacity 0.7s cubic-bezier(0.33, 1, 0.68, 1),
              transform 0.7s cubic-bezier(0.33, 1, 0.68, 1);
  will-change: opacity, transform;
}

.landing-card.is-visible {
  opacity: 1;
  transform: translateY(0) scale(1);
}

/* Staggered entrance delays */
.landing-card:nth-child(1) { transition-delay: 0s; }
.landing-card:nth-child(2) { transition-delay: 0.1s; }
.landing-card:nth-child(3) { transition-delay: 0.2s; }

/* 3D perspective container */
.landing-cards-grid {
  perspective: 1200px;
}

/* 3D tilt card wrapper */
.landing-card-tilt {
  transform-style: preserve-3d;
  transition: transform 0.4s cubic-bezier(0.33, 1, 0.68, 1),
              box-shadow 0.4s cubic-bezier(0.33, 1, 0.68, 1),
              border-color 0.35s ease;
}

.landing-card-tilt:hover {
  border-color: rgba(139, 92, 246, 0.25) !important;
  box-shadow:
    0 20px 40px -12px rgba(139, 92, 246, 0.15),
    0 0 0 1px rgba(139, 92, 246, 0.08);
}

/* Gradient overlay on hover */
.landing-card-tilt::before {
  content: '';
  position: absolute;
  inset: 0;
  border-radius: inherit;
  background: linear-gradient(135deg, transparent 40%, rgba(139, 92, 246, 0.06) 100%);
  opacity: 0;
  transition: opacity 0.35s ease;
  pointer-events: none;
  z-index: 0;
}

.landing-card-tilt:hover::before {
  opacity: 1;
}

/* CTA button shimmer effect */
.landing-btn-shimmer {
  position: relative;
  overflow: hidden;
}

.landing-btn-shimmer::after {
  content: '';
  position: absolute;
  top: 0;
  left: -100%;
  width: 60%;
  height: 100%;
  background: linear-gradient(
    90deg,
    transparent,
    rgba(255, 255, 255, 0.15),
    transparent
  );
  animation: btnShimmer 3s infinite;
  pointer-events: none;
}

@keyframes btnShimmer {
  0% { left: -100%; }
  100% { left: 200%; }
}

/* Status pulse for tier tags */
@keyframes statusPulse {
  0%, 100% { opacity: 1; transform: scale(1); }
  50% { opacity: 0.5; transform: scale(0.8); }
}

.landing-status-dot {
  animation: statusPulse 2s ease-in-out infinite;
}

/* Discount badge subtle glow */
.landing-discount-badge {
  position: relative;
}

.landing-discount-badge::after {
  content: '';
  position: absolute;
  inset: -1px;
  border-radius: inherit;
  background: inherit;
  opacity: 0.4;
  filter: blur(8px);
  z-index: -1;
}

/* Section header scroll reveal */
.landing-section-header {
  opacity: 0;
  transform: translateY(24px);
  transition: opacity 0.6s cubic-bezier(0.33, 1, 0.68, 1),
              transform 0.6s cubic-bezier(0.33, 1, 0.68, 1);
}

.landing-section-header.is-visible {
  opacity: 1;
  transform: translateY(0);
}

/* Popular card extra glow pulse */
@keyframes popularGlow {
  0%, 100% {
    box-shadow:
      0 0 40px -8px rgba(139, 92, 246, 0.15),
      0 0 0 1px rgba(139, 92, 246, 0.1);
  }
  50% {
    box-shadow:
      0 0 60px -8px rgba(139, 92, 246, 0.25),
      0 0 0 1px rgba(139, 92, 246, 0.15);
  }
}

.landing-card-popular {
  animation: popularGlow 4s ease-in-out infinite;
}

/* Feature list stagger animation */
.landing-card.is-visible .landing-feature-item {
  opacity: 1;
  transform: translateX(0);
}

.landing-feature-item {
  opacity: 0;
  transform: translateX(-12px);
  transition: opacity 0.4s ease, transform 0.4s ease;
}

.landing-feature-item:nth-child(1) { transition-delay: 0.3s; }
.landing-feature-item:nth-child(2) { transition-delay: 0.4s; }
.landing-feature-item:nth-child(3) { transition-delay: 0.5s; }
.landing-feature-item:nth-child(4) { transition-delay: 0.6s; }
@tailwind base;
@tailwind components;
@tailwind utilities;

@layer base {
  /* Smooth rendering for dark theme */
  html {
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    text-rendering: optimizeLegibility;
    /* Safari dark mode support - prevents white backgrounds on form elements and system UI */
    color-scheme: dark;
  }

  /* Force dark backgrounds on all form elements including dropdown options */
  select,
  select option,
  select optgroup,
  input,
  textarea {
    background-color: rgb(17, 17, 20);
    color: white;
    color-scheme: dark;
  }

  /* Style select dropdown options specifically */
  select option {
    background-color: rgb(24, 24, 27);
    color: white;
    padding: 8px 12px;
  }

  select option:hover,
  select option:focus,
  select option:checked {
    background-color: rgb(139, 92, 246);
    color: white;
  }

  /* Ensure datalist suggestions are dark */
  datalist {
    background-color: rgb(24, 24, 27);
    color: white;
  }

  /* Style autofill to maintain dark theme */
  input:-webkit-autofill,
  input:-webkit-autofill:hover,
  input:-webkit-autofill:focus,
  input:-webkit-autofill:active,
  select:-webkit-autofill,
  textarea:-webkit-autofill {
    -webkit-box-shadow: 0 0 0 30px rgb(17, 17, 20) inset !important;
    -webkit-text-fill-color: white !important;
    caret-color: white;
  }

  /* Safari fix: bg-white/5 with backdrop-filter renders incorrectly in Safari.
     This provides a fallback solid dark background that Safari will use. */
  @supports (-webkit-backdrop-filter: blur(1px)) {
    .safari-dark-bg {
      background-color: rgba(15, 15, 17, 0.95);
    }
  }

  /* Default border color for dark theme elements */
  .dark * {
    border-color: rgba(255, 255, 255, 0.1);
  }

  /* Landing page specific base styles */
  .dark {
    --tw-text-opacity: 1;
    color: rgb(255 255 255 / var(--tw-text-opacity));
  }

  /* Improve heading rendering */
  h1, h2, h3, h4, h5, h6 {
    text-wrap: balance;
  }

  /* Better paragraph spacing */
  p {
    text-wrap: pretty;
  }
}

@layer components {
  /* Landing page button styles */
  .landing-btn {
    @apply inline-flex items-center justify-center gap-2 rounded-md font-medium transition-all;
  }

  .landing-btn-lg {
    @apply h-10 px-6 text-sm;
  }

  .landing-btn-xl {
    @apply px-6 py-5 sm:px-8 sm:py-6 text-base sm:text-lg;
  }

  .landing-btn-primary {
    @apply bg-violet-600 hover:bg-violet-700 text-white;
  }

  .landing-btn-outline {
    @apply border border-gray-700 hover:border-violet-500 hover:bg-violet-500/10 text-white;
  }

  /* Landing page gradient text */
  .landing-gradient-text {
    @apply text-transparent bg-clip-text bg-gradient-to-r from-violet-400 to-emerald-400;
  }

  /* Bento card base - uses dark background for Safari compatibility
     Safari renders white/5 + backdrop-blur incorrectly as solid white */
  .bento-card {
    @apply relative rounded-2xl border border-white/10 bg-[#111114]/80 backdrop-blur-sm;
  }

  /* Bento card glow effect */
  .bento-glow {
    box-shadow: 0 0 40px rgba(139, 92, 246, 0.15);
  }

  /* Popular card glow */
  .bento-glow-emerald {
    box-shadow: 0 0 60px rgba(16, 185, 129, 0.2);
  }

  /* Section container */
  .landing-section {
    @apply py-16 sm:py-20 lg:py-24 px-4 sm:px-6 lg:px-8;
  }

  /* Section heading */
  .landing-heading {
    @apply text-3xl sm:text-4xl lg:text-5xl font-bold tracking-tight;
  }

  /* Section subheading */
  .landing-subheading {
    @apply text-base sm:text-lg text-gray-400;
  }
}

@layer utilities {
  /* Backdrop blur for older browsers */
  .backdrop-blur-sm {
    -webkit-backdrop-filter: blur(4px);
    backdrop-filter: blur(4px);
  }

  .backdrop-blur-lg {
    -webkit-backdrop-filter: blur(16px);
    backdrop-filter: blur(16px);
  }

  /* Safari fix: bg-white/5 with backdrop-filter renders as solid white in Safari.
     This overrides the background to use a dark semi-transparent color instead.
     The @supports rule targets Safari's webkit backdrop-filter support. */
  @supports (-webkit-backdrop-filter: blur(1px)) {
    /* Override bg-white/5 when combined with backdrop-blur */
    .bg-white\/5.backdrop-blur-sm,
    .bg-white\/5.backdrop-blur-lg,
    .backdrop-blur-sm.bg-white\/5,
    .backdrop-blur-lg.bg-white\/5 {
      background-color: rgba(17, 17, 20, 0.85) !important;
    }

    /* Also handle bg-white/10 which can have similar issues */
    .bg-white\/10.backdrop-blur-sm,
    .bg-white\/10.backdrop-blur-lg,
    .backdrop-blur-sm.bg-white\/10,
    .backdrop-blur-lg.bg-white\/10 {
      background-color: rgba(20, 20, 24, 0.9) !important;
    }
  }

  /* Line height utilities for tight headings */
  .leading-none {
    line-height: 1;
  }

  .leading-tight {
    line-height: 1.25;
  }

  /* Letter spacing for headings */
  .tracking-tight {
    letter-spacing: -0.025em;
  }

  .tracking-tighter {
    letter-spacing: -0.05em;
  }

  /* Toast Slide Animations */
  @keyframes slideInRight {
    from {
      opacity: 0;
      transform: translateX(100%);
    }
    to {
      opacity: 1;
      transform: translateX(0);
    }
  }

  @keyframes slideOutRight {
    from {
      opacity: 1;
      transform: translateX(0);
    }
    to {
      opacity: 0;
      transform: translateX(100%);
    }
  }

  .toast-enter {
    animation: slideInRight 0.3s cubic-bezier(0.34, 1.56, 0.64, 1) forwards;
  }

  .toast-exit {
    animation: slideOutRight 0.2s ease forwards;
  }

  /* Progress bar animation for auto-dismiss */
  @keyframes shrinkWidth {
    from { width: 100%; }
    to { width: 0%; }
  }

  .toast-progress {
    animation: shrinkWidth var(--toast-duration, 5s) linear forwards;
  }
}
/* Modal Backdrop Animations */
@keyframes fadeIn {
  from { opacity: 0; }
  to { opacity: 1; }
}

@keyframes fadeOut {
  from { opacity: 1; }
  to { opacity: 0; }
}

.modal-backdrop-enter {
  animation: fadeIn 0.2s ease forwards;
}

.modal-backdrop-exit {
  animation: fadeOut 0.15s ease forwards;
}

/* Modal Content Animations */
@keyframes modalEnter {
  from {
    opacity: 0;
    transform: scale(0.95) translateY(10px);
  }
  to {
    opacity: 1;
    transform: scale(1) translateY(0);
  }
}

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

.modal-content-enter {
  animation: modalEnter 0.25s cubic-bezier(0.34, 1.56, 0.64, 1) forwards;
}

.modal-content-exit {
  animation: modalExit 0.15s ease forwards;
}

/* Lightbox Animations - faster, more dramatic */
@keyframes lightboxBackdropEnter {
  from { opacity: 0; }
  to { opacity: 1; }
}

@keyframes lightboxBackdropExit {
  from { opacity: 1; }
  to { opacity: 0; }
}

@keyframes lightboxImageEnter {
  from {
    opacity: 0;
    transform: scale(0.9);
  }
  to {
    opacity: 1;
    transform: scale(1);
  }
}

@keyframes lightboxImageExit {
  from {
    opacity: 1;
    transform: scale(1);
  }
  to {
    opacity: 0;
    transform: scale(0.9);
  }
}

.lightbox-backdrop-enter {
  animation: lightboxBackdropEnter 0.15s ease forwards;
}

.lightbox-backdrop-exit {
  animation: lightboxBackdropExit 0.12s ease forwards;
}

.lightbox-image-enter {
  animation: lightboxImageEnter 0.2s cubic-bezier(0.34, 1.56, 0.64, 1) forwards;
}

.lightbox-image-exit {
  animation: lightboxImageExit 0.12s ease forwards;
}
/* ==========================================================================
   Sidebar Styles - Expanded & Collapsed States
   ========================================================================== */

/* Expanded State (default) */
#sidebar .sidebar-btn {
  justify-content: flex-start;
  padding-left: 1rem;
  padding-right: 1rem;
  gap: 0.75rem;
}

#sidebar .sidebar-icon {
  width: 20px;
  text-align: center;
}

#sidebar .sidebar-text {
  opacity: 1;
  max-width: 200px;
}

#sidebar .sidebar-tooltip {
  display: none;
}

/* Collapsed State */
#sidebar[data-collapsed="true"] {
  padding-left: 0.75rem;
  padding-right: 0.75rem;
}

#sidebar[data-collapsed="true"] .sidebar-btn {
  justify-content: center;
  padding-left: 0;
  padding-right: 0;
  gap: 0;
}

#sidebar[data-collapsed="true"] .sidebar-icon {
  width: 24px;
  font-size: 22px;
}

#sidebar[data-collapsed="true"] .sidebar-text {
  opacity: 0;
  max-width: 0;
  margin-left: 0;
}

/* Show tooltips only when collapsed */
#sidebar[data-collapsed="true"] .sidebar-tooltip {
  display: block;
}

#sidebar[data-collapsed="true"] .group:hover .sidebar-tooltip {
  opacity: 1;
  visibility: visible;
}

/* Section headers */
#sidebar .sidebar-section {
  margin-bottom: 0.5rem;
}

#sidebar .sidebar-section-label {
  height: auto;
  padding-top: 0.25rem;
  padding-bottom: 0.25rem;
}

/* Section headers in collapsed state */
#sidebar[data-collapsed="true"] .sidebar-section {
  margin-bottom: 0.25rem;
}

#sidebar[data-collapsed="true"] .sidebar-section-label {
  opacity: 0;
  height: 0;
  padding: 0;
  overflow: hidden;
}

/* Collapse toggle button alignment */
#sidebar[data-collapsed="true"] > div:first-child > div:first-child {
  justify-content: center;
}

/* Smooth width transition for sidebar */
#sidebar {
  transition: width 0.2s ease-in-out, padding 0.2s ease-in-out;
}
/*
 * This is a manifest file that'll be compiled into application.css, which will include all the files
 * listed below.
 *
 * Any CSS (and SCSS, if configured) file within this directory, lib/assets/stylesheets, or any plugin's
 * vendor/assets/stylesheets directory can be referenced here using a relative path.
 *
 * You're free to add application-wide styles to this file and they'll appear at the bottom of the
 * compiled file so the styles you add here take precedence over styles defined in any other CSS
 * files in this directory. Styles in this file should be added after the last require_* statement.
 * It is generally better to create a new file per style scope.
 *


 */

@tailwind base;
@tailwind components;
@tailwind utilities;

@font-face {
    font-family: 'Avenir';
    src: url(/fonts/AvenirLTStd-Roman.otf) format('otf'),
    url(/fonts/AvenirLTStd-Roman.otf) format('otf');
    font-weight: 400;
    font-style: normal;
}
