/* Custom styles for Magna Insurance & Benefits */

/* Ensure smooth scrolling for anchor links */
html {
  scroll-behavior: smooth;
}

/* Base font settings */
body {
  font-family: 'Inter', sans-serif;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

/* Display font */
.font-display {
  font-family: 'Space Grotesk', sans-serif;
}

/* Geometric decorations */
.geo-circle {
  position: absolute;
  border-radius: 50%;
  pointer-events: none;
}

.geo-triangle {
  position: absolute;
  width: 0;
  height: 0;
  pointer-events: none;
}

.geo-square {
  position: absolute;
  transform: rotate(45deg);
  pointer-events: none;
}

/* Floating animation for hero cards */
@keyframes float {
  0%, 100% {
    transform: translateY(0px);
  }
  50% {
    transform: translateY(-10px);
  }
}

.float-1 {
  animation: float 4s ease-in-out infinite;
}

.float-2 {
  animation: float 5s ease-in-out infinite 0.5s;
}

.float-3 {
  animation: float 4.5s ease-in-out infinite 1s;
}

/* Scroll reveal animations (below fold only) */
.reveal {
  opacity: 1;
  transform: translateY(0);
  transition: opacity 0.6s ease, transform 0.6s ease;
}

@media (prefers-reduced-motion: no-preference) {
  .reveal {
    opacity: 0;
    transform: translateY(30px);
  }
  .reveal.visible {
    opacity: 1;
    transform: translateY(0);
  }
}

/* Custom scrollbar */
::-webkit-scrollbar {
  width: 8px;
}

::-webkit-scrollbar-track {
  background: #1a1a2e;
}

::-webkit-scrollbar-thumb {
  background: #ff6b57;
  border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
  background: #ff8574;
}

/* Mobile menu */
#mobile-menu {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.3s ease;
}

#mobile-menu.open {
  max-height: 400px;
}

/* Service card hover */
.service-card {
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.service-card:hover {
  transform: translateY(-6px);
  box-shadow: 0 20px 40px rgba(255, 107, 87, 0.15);
}

/* CTA button pulse */
@keyframes pulse-coral {
  0%, 100% {
    box-shadow: 0 0 0 0 rgba(255, 107, 87, 0.4);
  }
  50% {
    box-shadow: 0 0 0 12px rgba(255, 107, 87, 0);
  }
}

.btn-pulse {
  animation: pulse-coral 2s infinite;
}

/* Select dropdown styling */
select {
  background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' fill='none' viewBox='0 0 20 20'%3e%3cpath stroke='%23ff6b57' stroke-linecap='round' stroke-linejoin='round' stroke-width='1.5' d='M6 8l4 4 4-4'/%3e%3c/svg%3e");
  background-position: right 0.5rem center;
  background-repeat: no-repeat;
  background-size: 1.5em 1.5em;
  padding-right: 2.5rem;
}

/* Focus visible for accessibility */
:focus-visible {
  outline: 2px solid #ff6b57;
  outline-offset: 2px;
}

/* 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;
  }

  html {
    scroll-behavior: auto;
  }

  .float-1,
  .float-2,
  .float-3 {
    animation: none;
  }
}

/* High contrast mode support */
@media (forced-colors: active) {
  .service-card {
    border: 1px solid ButtonText;
  }

  .btn-pulse {
    outline: 2px solid ButtonText;
  }
}
